Based on ksolve+, developed by Kare Krig and Michael Gottlieb.