title: Improved Newton method using Bisection method in Python
body: <p>I have write a code which is solving a 2nd order system of nonlinear equations in high dimensional (i=0,N) through the Newton method (Jacobian N+1 * N+1) , having 2 boundary conditions.</p>
  
  <p>I would like to ask you, if I is possible to implement the bisection method in this Ndimensional problem. Unfortunately the Newton convergence does not work on some regions of my problem. </p>
  
  <p>according to this source: <a href="http://ursa.as.arizona.edu/~rad/phys305/root_finding/node4.html" rel="nofollow">http://ursa.as.arizona.edu/~rad/phys305/root_finding/node4.html</a></p>
  
  <p>"
  An improved root finding scheme is to combine the bisection and Newton-Raphson methods. The bisection method guarantees a root (or singularity) and is used to limit the changes in position estimated by the Newton-Raphson method when the linear assumption is poor. However, Newton-Raphson steps are taken in the nearly linear regime to speed convergence.</p>
  
  <p>In other words, if we know that we have a root bracketed between our two bounding points, we first consider the Newton-Raphson step. If that would predict a next point that is outside of our bracketed range, then we do a bisection step instead by choosing the midpoint of the range to be the next point. We then evaluate the function at the next point and, depending on the sign of that evaluation, replace one of the bounding points with the new point. This keeps the root bracketed, while allowing us to benefit from the speed of Newton-Raphson.
  "</p>
  
  <p>... is possible to do that in Python in a N dimensional problem?</p>
  
  <p>Rtsafe module of FORTRAN in ndimensional possible do this, and might Matlab has a similar module... </p>