revert segment solver to use fsolve directly instead of root, closes issue #36