File Exchange

image thumbnail

Newton's method done right

version 1.2 (5.99 KB) by

Newton's method for solving systems of nonlinear equations, including nonsquare and inconsistent



View License

Newton's method for solving a system of nonlinear equations, see's_method
Newton(X,F,X0) solves nonlinear system F(x)=0 by Newton's method, using the given initial approximation X0. The derivative (Jacobian) is evaluated symbolically. The iterations are performed numerically.

The included demo NewtonDemoRunMe.m shows how to run the Newton.m function. E.g., it creates a slide-show and a movie, illustrating the behavior of the iterates.

Comments and Ratings (2)

Andrew Knyazev

The code works in Symbolic Math Toolbox 5.7 (R2011b). Previous versions of the toolbox may not support creating symbolic vectors this way. There may be other issues, too, with prior unsupported versions of the toolbox.


Xu (view profile)

Hey,man! X=sym('X',[2 1]); is not a valid command..... Tried your algorithm, but did not work.



added a conversion to a toolbox


Multiple improvements and updates.


Bug fixes in Newton.m and a new script NewtonDemoRunMe.m with examples.

MATLAB Release
MATLAB 7.13 (R2011b)

Download apps, toolboxes, and other File Exchange content using Add-On Explorer in MATLAB.

» Watch video

Win prizes and improve your MATLAB skills

Play today