[SciPy-user] Solving an equation using scipy.optimize.newton
Wed Sep 5 10:33:03 CDT 2007
I'm trying to solve an equation f(x) = 0 with scipy.optimize.newton.
However the problem isn't so simple. There are bound constraints for my
equation: the equation cannot be evaluated when x is out of [Min, Max], but
the root is always in the interval of [Min, Max]
When newton() iterates to find a root, it sometimes try to evaluate the
equation with a x out of [Min, Max], and then error occurs.
How to solve this problem ?
I couldn't easily find two points with different signs every time, so methods
like brentq don't work here.
Thanks a lot!
More information about the SciPy-user