Newton-Raphson Method
Newton Raphson method can be used for solving both single variable non linear equation and multi
variable set of non linear equations. WE shall discuss Newton-Raphson (NR) method for single variable
non-linear equation and then extend it for multi-variable set of non-linear equations.
Let f(x)=0 be an algebraic or transcendental equation which is derivable and continuous in certain
interval, then a real root of the equation can be quickly computed in that interval using NR method.
Let,
x 0 be the approximate solution of the given equation
and x 1 be the exact solution such that
x 1=x 0 +h, where h is a very small number
and f ( x 0 +h )=0 (1)
Now, if we can find h the solution can be obtained
Taking Taylor’s series expansion of (1) we get,
'
f ( x 1 ) =f ( x 0 +h ) =f ( x 0 ) +h f ( x 0 ) + second∧other higher order terms of h
f ' ( x 0 ) be the first derivative of f ( x )evaluated at x=x 0
As h is a very small number and second and higher order terms of h would be still smaller and those can
be neglected. Thus neglecting second and higher order terms we get
'
f ( x 0 ) + h f ( x0 ) =0
−f ( x 0)
∴ h= '
f ( x0 )
f ( x0 )
x 1=x 0−
f ' ( x0 )
From the above x 1 should be the actual root. However, as the higher order terms are neglected
there is a possibility that some error may be introduced in calculation of x 1 if h is not sufficiently
small. Hence two-three more iterations will yield the actual root of the equation.
In the NR method the convergence depends on the initial guess value of the root. If the initial
guess is proper the convergence is very quick. And if the initial guess is not proper, the iterative
procedure may not converse. Hence, the best option for solving non linear equation is to find
an approximate root using one or two iterations of Bisection method and then take that as the
initial guess for NR method.
Algorithm:
The steps for finding the roots of the equation using NR method are as follows:
Step1: Convert the given equation to the form f ( x )=0
Step 2: Make initial guess x 1∧x 2 such that f ( x 1 ) × f ( x2 ) < 0
Step 3; Find x 0 using the equation
x 0=( x ¿ ¿ 1+ x 2)/2 ¿
'
Step 4: Compute f ( x 0 ) and f ( x 0 )
f ( x 0)
Step 5: find x 1 using theequation x 1=x 0−
f ' ( x0 )
Step 6: if |x 1−x 0|≤ ε solution is reached
Step 7: else replace x 1 by x 0, goto step 4
Ex; Let us solve the same problem (that uses Bisection Method and Regula Falsi Method) using NR
method
Find a real root of x 3−x−1=0 using NR method
We shall take the same initial guesses
x 1=1∧x 2=2
f ( x 1 ) =−1
f ( x 2 ) =5
2+1
Then x 0= =1.5
2
Iteration No. 1
f ( x 0 ) =1.53−1.5−1=0.875
' 2
f ( x )=3 x −1
f ' ( x 0 )=3× 1.52−1=5.75
f (x 0)
x 1=x 0− '
f (x 0 )
0.875
x 1=1.5− =1.3478
5.75
x 1−x 0=|1.3478−1.5|=0.1522
Iteration No. 2
New value of x 0 is 1.3478
f ( x 0 ) =1.34783−1.3478−1=0.10057
f ' ( x 0 ) ¿ 3×(1.3478)2−1=¿4.44969
0.10057
x 1=1.3478− =1.3252
4.44969
x 1−x 0=|1.3252−1.3478|=0.0226
Iteration No 3:
New value of x 0 is 1.3252
f ( x 0 ) =1.32523−1.3252−1=0.00206
' 2
f ( x 0 ) ¿ 3×(1.3252) −1=¿ 4.26846
0.00206
x 1=1.3252− =1.32471
4.26846
x 1−x 0=|1.3252−1.3478|=0.00048
Iteration No. 4:
New value of x 0 is 1.32471
f ( x 0 ) =1.324713−1.32471−1=0.000034
' 2
f ( x 0 ) ¿ 3×(1.32471) −1=¿ 4.26457
0.000034
x 1=1.32471− =1.32470
4.26457
x 1−x 0=|1.32470−1.32471|=0.00001 This is tolerable
Hence the root is 1.32470
Newton Raphson Method for Multivariable Non linear set of Equations:
The Newton-Raphson Method can also be applied for a set of non linear multivariable algebraic or
transcendental equations. We shall first discuss the method for two variable algebraic equation and
then extend the same for more than two variables. Let a set of equations of two variables
f ( x , y )=0
g ( x , y )=0
Let x 1∧ y 1 be the actual roots and x 0∧ y 0 initial approximations such that
x 1=x 0 +h
And y 1= y 0 + k
Whereh∧k are very small numbers. Our problem is to find h∧k
Hence we have,
f ( x 1 , y 1 ) =0
(1)
g ( x 1 , y 1 )=0
Or
f ( x 0 +h , y 0 +k ) =0
(2)
g ( x 0+ h , y 0+ k ) =0
Taking Taylor series expansion of (2) we get
∂f ∂f
f ( x 0 +h , y 0 +k ) =f ( x 0 , y 0 ) +h
¿(x , y ) +k ¿ +higher order terms=0
∂x ∂ y (x , y )
0 0 0 0
(3)
∂g ∂g
g ( x 0 +h , y 0+ k ) =g ( x0 , y 0 ) +h ¿ +k ¿ + higher order terms=0
∂ x (x , y ) ∂ y (x , y )
0 0 0 0
Neglecting the higher terms of small numbers h∧k we get from (3),
∂f ∂f
f ( x 0 , y 0 ) +h
¿(x , y ) +k ¿ =0
∂x 0
∂ y (x , y ) (4 )
0 0 0
∂g ∂g
g ( x0 , y0 )+ h ¿(x , y ) +k ¿ =0
∂x 0
∂ y (x , y )
0 0 0
Expressing (4) in matrix from we get,
[ ][ ] [
∂f ∂f
]
¿(x , y ) ¿ −f ( x 0 , y 0 )
∂x 0 0
∂ y (x , y ) h 0 0
= (5)
∂g ∂g k −g ( x 0 , y 0 )
¿( x , y ) ¿(x , y )
∂x 0 0
∂y 0 0
¿[J ] []
h
k
=
[
−f ( x 0 , y 0 )
−g ( x 0 , y 0 ) ] (6)
where [ J ] is called the Jacobians
Solving (5) we get the value of h∧k
[ hk]=[ J ]
i.e.
−1
[−f ( x0 , y 0 )
−g ( x 0 , y 0 ) ] (7)
and hence the root of the set equation should be
x 1=x 0 +h
And y 1= y 0 + k
However if h∧k are not sufficiently small, there may be errors in these values as the higher order
terms ofh∧k in (3) are neglected. Hence few more iterations are necessary to arrive at sufficiently
correct roots.
Thus the value of x 0∧ y 0 are replaced by the calculated value of x 1∧ y 1 respectively and the above
procedure is repeated. When the values of h∧k are less than tolerable limit the iteration is stopped
sand solution is obtained.