0% found this document useful (0 votes)
431 views20 pages

Unit1 - NM Solution To Equation

The document is about numerical methods for solving algebraic and transcendental equations. It discusses the bisection method in detail. The bisection method works by repeatedly bisecting the interval between values of the function where the signs change. This guarantees finding a root. Example problems are provided to illustrate the bisection method approach. The document also mentions other methods like the false position method that aim to speed up convergence while maintaining guarantees, before moving on to discuss them in subsequent sections.

Uploaded by

adityapawar1865
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
431 views20 pages

Unit1 - NM Solution To Equation

The document is about numerical methods for solving algebraic and transcendental equations. It discusses the bisection method in detail. The bisection method works by repeatedly bisecting the interval between values of the function where the signs change. This guarantees finding a root. Example problems are provided to illustrate the bisection method approach. The document also mentions other methods like the false position method that aim to speed up convergence while maintaining guarantees, before moving on to discuss them in subsequent sections.

Uploaded by

adityapawar1865
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 20

S ANJAY G HODAWAT U NIVERSITY

K OLHAPUR
S.Y. B. T ECH .
C OMPUTER S CIENCE AND E NGINEERING

C OURSE C ODE : CST2301


UNIT 1: S OLUTION TO A LGEBRAIC AND T RANSCENDENTAL
E QUATIONS

Mathematics for Modern Computing

Prepared by

Mr. S.S. Salgare


Assistant Professor
Sanjay Ghodawat University, Kolhapur

August 19, 2022


Mr. S.S. Salgare

Contents
1 Solution of Algebraic and Transcendental Equations 2
1.1 Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2
1.2 Bisection (Bolzano) Method . . . . . . . . . . . . . . . . . . . 3
1.3 False Position Method (Regula-Falsi Method) . . . . . . . . . 6
1.4 Secant Method . . . . . . . . . . . . . . . . . . . . . . . . . . . 10
1.5 Newton Raphson Method . . . . . . . . . . . . . . . . . . . . 12
1.5.1 Geometrical Interpretation: . . . . . . . . . . . . . . . 13

CONTENTS 1
Mr. S.S. Salgare

1 Solution of Algebraic and Transcendental Equations


1.1 Introduction
Consider the equation of the from F ( x ) = 0.If F(x) is quadratic, cubic or bi
quadratic expression then algebraic formulas are available for expressing
the root. But when F ( x ) is a polynomial of higher degree or an expression
involving transcendental function e.g 1 + cos x − 5x, x tan x − cosh x etc.
algebraic methods are not available. In this unit ,we shall describe some
numerical methods for the solution of F ( x ) = 0, where F ( x) is algebraic or
transcendental or both.

Algebraic Equation: In Mathematics , an algebraic equation or polynomial


equation is an equation of the from

P=Q

Where P and Q are polynomials with coefficients in some field.


e.g.
1. x5 − 3x + 1 = 0
⇒Algebraic equation with integer coefficients
xy x3 1
2. y4 + = –xy2 + y2 −
2 3 7
⇒ multivariate polynomial equation over the rational
Transcendental Equation:
A function which is not an algebraic function. or A function which cannot
be expressed in terms of algebra is called Transcendental function.
Example of transcendental function include the exponential function ,the
trigonometric function and the inverse functions of both.

A transcendental equation is an equation containing a transcendental


function e.g .
1. x = e− x
2. x = cos x
1
3. log x + + sin x = 0
e
consider the equation of the form f ( x ) = 0. If f ( x ) is quadratic, cube or bi
quadratic expression then algebraic formulas are available for expressing
the roots . But when f ( x ) is a polynomial of higher degree or an expression
involving transcendental function e.g.1 + cos x − 5x, x tan x − cosh x, e x −
sin x etc. algebraic methods are not available.
In this unit , we shall describe some numerical methods for the solution of
f ( x ) = 0 , where f ( x ) = 0 is algebraic or transcendental or both.

1 SOLUTION OF ALGEBRAIC AND TRANSCENDENTAL 2


EQUATIONS
Mr. S.S. Salgare

1.2 Bisection (Bolzano) Method


This method is based on the repeated application of intermediate value
property. Let f ( x ) be continuous between a and b for this value of a and b
let assume f ( a). f (b) < 0. Then the first approximation to the root is:
a+b
x1 =
2

If f ( x1 ) = 0, then x1 is a root of f ( x ) = 0 otherwise, root lies between a and


x1 or x1 and b according as f ( x1 ) is +ve or –ve. This we bisect the interval as
before and continue the process until the root is found to desired accuracy.
Example 1 Find a positive root of x − cos x = 0 by bisection method correct upto
four decimal place which lies between 0 and 1.
Ans:Let f ( x ) = x − cos x
f (0) = −1;-ve and f (1) = 0.4597; +ve
Here f (0). f (1) < 0 ⇒ root lies between 0 and 1

1st iteration:
0+1
x1 = ⇒ x1 = 0.5
2
Now f ( x1 ) = −0.3776 ; -ve
Next f (0.5) f (1) < 0 ⇒ root lies between 0.5 and 1

2nd iteration:
0.5 + 1
x2 = ⇒ x2 = 0.75
2

1 SOLUTION OF ALGEBRAIC AND TRANSCENDENTAL 3


EQUATIONS
Mr. S.S. Salgare

Now f ( x2 ) = f (0.75) = 0.0183 ; +ve


Next f (0.5) f (0.75) < 0 ⇒ root lies between 0.5 and 0.75

3rd iteration:
0.5 + 0.75
x3 = ⇒ x3 = 0.625
2
Now f ( x3 ) = −0.1860 ; -ve
Next f ( x2 ) f ( x3 ) < 0 ⇒ root lies between 0.625 and 0.75

4th iteration:
0.625 + 0.75
x4 = ⇒ x4 = 0.6875
2
Now f ( x4 ) = −0.0853 ; -ve
Next f ( x2 ) f ( x4 ) < 0 ⇒ root lies between 0.6875 and 0.75

5th iteration:
0.6875 + 0.75
x5 = ⇒ x5 = 0.7188
2
Now f ( x5 ) = −0.0338 ; -ve
Next f ( x2 ) f ( x5 ) < 0 ⇒ root lies between 0.7188 and 0.75

6th iteration:
0.7188 + 0.75
x6 = ⇒ x6 = 0.7344
2
Now f ( x6 ) = −0.0078 ; -ve
Next f ( x2 ) f ( x6 ) < 0 ⇒ root lies between 0.7344 and 0.75

7th iteration:
0.7344 + 0.75
x7 = ⇒ x7 = 0.7422
2
Now f ( x7 ) = 0.0052 ; +ve
Next f ( x7 ) f ( x6 ) < 0 ⇒ root lies between 0.7344 and 0.7422

8th iteration:
0.7344 + 0.7422
x8 = ⇒ x8 = 0.7382
2
Now f ( x8 ) = −0.0005 ; -ve
Next f ( x7 ) f ( x8 ) < 0 ⇒ root lies between 0.7344 and 0.7422

9th iteration:
0.7383 + 0.7422
x9 = ⇒ x9 = 0.7403
2
Now f ( x9 ) = 0.0020 ; +ve
Next f ( x9 ) f ( x8 ) < 0 ⇒ root lies between 0.7383 and 0.7403

1 SOLUTION OF ALGEBRAIC AND TRANSCENDENTAL 4


EQUATIONS
Mr. S.S. Salgare

10th iteration:

0.7383 + 0.7403
x10 = ⇒ x10 = 0.7393
2
Now f ( x10 ) = 0.0004 ; +ve
Next f ( x10 ) f ( x8 ) < 0 ⇒ root lies between 0.7383 and 0.7393

11th iteration:
0.7383 + 0.7393
x11 = ⇒ x11 = 0.7388
2
Now f ( x11 ) = −0.0005 ; -ve
Next f ( x10 ) f ( x11 ) < 0 ⇒ root lies between 0.7388 and 0.7393

12th iteration:
0.7388 + 0.7393
x12 = ⇒ x12 = 0.7391
2
Now f ( x12 ) = 0.0000
Here f ( x12 ) = 0 ; so x = 0.7391 is approximate root of x − cos x = 0

Example 2 Find the real root of the equation x log10 x = 1.2 by Bisection correct
to four decimal places. (Take initial approximation a=2.74 and b=2.75)

Ans: x1 = 2.745; x2 = 2.7425; x3 = 2.7413; x4 = 2.7406; x5 = 2.7409; x6 =


2.7408; x7 = 2.7407
Thus x = 2.7407 is approximate root of x log10 x = 1.2

Example 3 Carry out four iteration of the bisection


  method for the root of
1 1
(2x + 1)2 = 4 cos πx lying in the interval ,
4 3
Ans:
x1 = 0.2917 ⇒ f ( x1 ) is +ve
x2 = 0.2709 ⇒ f ( x2 ) is -ve
x3 = 0.2813 ⇒ f ( x3 ) is -ve
x4 = 0.2865

Excerise 1.1

1) Find the root of the equation x3 − 4x − 9 = 0 using Bisection method is


four stage.(Take a=2.706 and b=2.707)

2) Find a positive real root of x − cos x = 0 by bisection method. correct


upto 4 decimal places between 0 and 1.

1 SOLUTION OF ALGEBRAIC AND TRANSCENDENTAL 5


EQUATIONS
Mr. S.S. Salgare

3) Perform five iterations of bisection method to obtain the smallest posi-


tive root of the equation x3 − 5x + 1 = 0
4) Find a real root of x3 − x = 1 between 1 and 2 by bisection method.
Compute five iterations.
5) Use bisection method to find out the positive square root of x2 − 30 = 0
correct to 4 decimal places.

Algorithm for Bisection Method


Step 01: Start the program
Step 02: Input the variable a, b for the task
Step 03: Check f ( a) f (b) < 0
Step 04: If yes proceed
Step 05: If no exit and print error message
Step 06: Repeat 7-11 if condition not satisfied
a+b
Step 07: x0 =
2
Step 08: If f ( x0 ) f ( x1 ) < 0
Step 09: x2 = x0
Step 10: ELSE
Step 11: x1 = x0
Step 12: condition
x1 − x2
Step 13: : < maximum possible error or f ( x0 ) = 0
x1
Step 14: Print output
Step 15: End of program

1.3 False Position Method (Regula-Falsi Method)


The bisection method guarantees that the iterative process will converge.
It is however slow. Thus attempts have been made to speed up bisection
method retaining its guaranteed convergence. A method of doing this is
called the method of false position. It is sometimes known as method of
liner interpolation. In this method, we choose two point x0 and x1 s.t.
f ( x0 ) f ( x1 ) < 0. Since the graph y = f ( x ) crosses the X-axis between these
two point , a root must lie in between these two point.

1 SOLUTION OF ALGEBRAIC AND TRANSCENDENTAL 6


EQUATIONS
Mr. S.S. Salgare

Now equation of chord joining these two point is

y − f ( x0 ) f ( x1 ) − f ( x0 )
=
x − x0 x1 − x0

y − f ( x0 ) f ( x1 ) − f ( x0 )
or ( x − x0 )
= x1 − x0
The method consists in replacing the curve AB by chord AB and taking the
point of intersection of the chord with X-axis as an approximation to the
root.Put y=0, we get

x1 − x0 x0 f ( x1 ) − x1 f ( x0 )
x2 = x0 − f ( x0 ) = (1)
f ( x1 ) − f ( x0 ) f ( x1 ) − f ( x0 )

Which is an approximation to the root. If now f ( x0 ) and f ( x2 ) are opposite


signs, then the root lies between x0 and x2 . So replacing x1 by x2 in (1) we
obtain the next approximation x3 . However the root could as well lie be-
tween x1 and x2 then we find x3 accordingly.

This procedure is repeated till the root is found to the desired accuracy.
Example 4 Find a real root of the equation 3x + sin x − e x = 0 by the method of
false position to four decimal place.
Ans:

Let f ( x ) = 3x + sin x − e x
Here f (0.3) = −0.154; −ve and f (0.4) = 0.0975; +ve
f (0.3) f (0.4) < 0 ⇒ Root lies between 0.3 and 0.4 ( x0 = 0.3, x1 = 0.4)

1 SOLUTION OF ALGEBRAIC AND TRANSCENDENTAL 7


EQUATIONS
Mr. S.S. Salgare

1st iteration:
x0 f ( x1 ) − x1 f ( x0 ) 0.3 × 0.0975 − 0.4 × (−0.154)
x2 = ⇒ x2 =
f ( x1 ) − f ( x0 ) 0.0975 + 0.154
x2 = 0.3612; f ( x2 ) = 0.0019 ( + ve)

Now f ( x2 ) f (0.3) < 0 ⇒ root lies between 0.3 and 0.3612

2nd iteration:
0.3 f (0.3612) − 0.3612 f (0.3) 0.3 × 0.0019 − 0.3612 × (−0.154)
x3 = ⇒ x3 =
f (0.3612) − f (0.3) 0.0019 + 0.154
x3 = 0.3605; f ( x3 ) = 0.0002 ( + ve)

Now f (0.3605) f (0.3) < 0 ⇒ root lies between 0.3 and 0.3605

3rd iteration:
0.3605 f (0.3) − 0.3 f (0.3605) 0.3605 × (−0.154) − 0.3 × (0.0002)
x4 = ⇒ x4 =
f (0.3) − f (0.3605) −0.154 − 0.0002
x4 = 0.3604; f ( x4 ) = −0.0001 ( − ve)

Now f (0.3604) f (0.3605) < 0 ⇒ root lies between 0.3604 and 0.3605

4th iteration:
0.3604 f (0.3605) − 0.3605 f (0.3604) 0.3604 × 0.0002 − 0.3605 × (−0.0001)
x5 = ⇒ x5 =
f (0.3605) − f (0.3604) 0.0002 − (−0.0001)
x5 = 0.3604

Since x4 and x5 are approximately same , hence the required real root is
0.3604 correct to four decimal place.
Example 5 Given that one of the root of non-liner equation cos x − xe x = 0 lies
between 0.5 and 1.0. Find the root correct three decimal places.
Ans: Let f ( x ) = cos x − xe x
x0 =0.5 0.053
x1 =1.0 -2.1780
x2 =0.512 0.014
x3 =0.516 0.005
x4 =0.517 0.002
x5 =0.517

1 SOLUTION OF ALGEBRAIC AND TRANSCENDENTAL 8


EQUATIONS
Mr. S.S. Salgare

The approximate root the equation cos x − xe x = 0 is x = 0.517

Example 6 Solve the equation x tan x + 1 = 0 by Regula-falsi method starting


with a=2.5 and b=3 correct to three decimal places.

Ans:
a=2.5 -868
b=3.0 0.572
x1 =2.801 0.007
x2 =2.799 0.002
x3 =2.798 -0.001
x4 =2.798

The approximate root the equation x tan x + 1 = 0 is x = 2.798

Example 7 Find a positive root of xe x = 2 by method of false position which lies


in the interval (0,1)

Ans:
x1 =0.7358 -0.4644
x2 =0.8312 -0.0562
x3 =0.8512 -0.0062
x4 =0.8525 -0.0005
x4 =0.8526

The approximate root the equation xe x = 2 is x = 0.8526

Excerise 1.2

1) Find a real root of the equation x3 − 2x − 5 = 0 by the method of false


position correct to three decimal places.

2) Find the root of the equation tan x + tanh x = 0 which lies in the interval
(2.35, 2.37) correct to four decimal places by method of false position.

3) Using the method of false position, find the root od equation x6 − x4 −


x3 − 1 = 0 upto four decimal places.

4) Solve x3 − 5x + 3 = 0 by using Regla-falsi method

1 SOLUTION OF ALGEBRAIC AND TRANSCENDENTAL 9


EQUATIONS
Mr. S.S. Salgare

1.4 Secant Method


This method is quit similar to that of false position method except for the
condition f ( x1 ) f ( x2 ) < 0. Here the graph of the function y = f ( x ) in the
nbhd of the root is approximated by secant line or chord. Further the inter-
val at each iteration may not contains the root.

Let initially the limits of the interval be x0 and x1 . Then the first approx-
imation is given by

x1 − x0 x1 f ( x0 ) − x0 f ( x1 )
x2 = x0 − f ( x0 ) =
f ( x1 ) − f ( x0 ) f ( x0 ) − f ( x1 )

In general
x n f ( x n −1 ) − x n −1 f ( x n )
x n +1 =
f ( x n −1 ) − f ( x n )
In case at any stage f ( xn ) = f ( xn−1 ), this method fail. Hence this method
does not converge always while false position method will always con-
verge. The only advantage in this method lies the fact that if it converges,
then it will converge more rapidly then the false position.
Remarks:
1) In case at any stage f ( xn ) = f ( xn−1 ), this method will fail.
2) This method does not converge always.

Example 8 A real root of the equation f ( x ) = x3 –5x + 1 = 0 lies in the interval


(0, 1) . Perform four iterations of the secant method .

Ans: We have x0 = 0 and x1 = 1. Then f ( x0 ) = 1, f ( x1 ) = −3. By


secant method
1st approximation:
 
x1 –x0
x2 = x1 − f ( x1 )
f ( x1 )– f ( x0 )
x2 = 0.25 f ( x2 ) = −0.234375

2nd approximation:
 
x2 –x1
x3 = x2 − f ( x2 )
f ( x2 )– f ( x1 )
x3 = 0.186441 f ( x3 ) = −0.074276

3rd approximation:
 
x3 –x2
x4 = x3 − f ( x3 )
f ( x3 )– f ( x3 )
x4 = 0.201736 f ( x2 ) = −0.00029

1 SOLUTION OF ALGEBRAIC AND TRANSCENDENTAL 10


EQUATIONS
Mr. S.S. Salgare

4th approximation:
 
x4 –x3
x5 = x4 − f ( x4 )
f ( x4 )– f ( x3 )
x5 = 0.20164

Example 9 Compute root of the equation x2 e− x/2 = 1 in the interval [0, 2] using
secant method. The root should be correct to three decimal place.
Ans:
x2 = 1.359 f ( x2 ) = −0.064
x3 = 1.436 f ( x3 ) = 0.006
x4 = 1.429 f ( x4 ) = −0.001
x5 = 1.430 f ( x2 ) = 0.000

Example 10 Find a root of the equation x3 − 2x − 5 = 0 using secant method


correct to three decimal places.
Ans: Let f ( x ) = x3 − 2x − 5 so that f (2) = −1 and f (3) = 16. Taking
initial approximations x0 = 2 and x1 = 3, by secant method, we have
1st approximation:
 
x1 –x0
x2 = x1 − f ( x1 )
f ( x1 )– f ( x0 )
3−2
x2 = 3 − 16
16 + 1
x2 = 2.059 f ( x2 ) = −3.89
2nd approximation:
 
x2 –x1
x3 = x2 − f ( x2 )
f ( x2 )– f ( x1 )
x3 = 2.081 f ( x3 ) = −0.147204
3rd approximation:
 
x3 –x2
x4 = x3 − f ( x3 )
f ( x3 )– f ( x3 )
x4 = 2.094 f ( x2 ) = 0.003042
4th approximation:
 
x4 –x3
x5 = x4 − f ( x4 )
f ( x4 )– f ( x3 )
x5 = 2.094
Hence the root is 2.094 correct to three decimal places.

1 SOLUTION OF ALGEBRAIC AND TRANSCENDENTAL 11


EQUATIONS
Mr. S.S. Salgare

Example 11 Find the root of the equation xe x = cos x using the secant method
correct to four decimal places.

Solution: Let f ( x ) = xe x − cos x or f ( x ) = cos x − xe x . Taking the initial


approximation x0 = 0, x1 = 1. So that f ( x0 ) = −1, f ( x1 ) = −2.17798.Then
by secant method,
1st approximation:
 
x1 –x0
x2 = x1 − f ( x1 )
f ( x1 )– f ( x0 )
1
x2 = 1 + (−2.17798)
3.17798
x2 = 0.3147 f ( x2 ) = 0.5199

2nd approximation:
 
x2 –x1
x3 = x2 − f ( x2 )
f ( x2 )– f ( x1 )
x3 = 0.4467 f ( x3 ) = 0.20354

3rd approximation:
 
x3 –x2
x4 = x3 − f ( x3 )
f ( x3 )– f ( x3 )
x4 = 0.517

Repeatint this process, the successive approximations are x5 = 0.5169, x6 =


0.5177, x7 = 0.5177 etc. Hence the root is 0.5177 correct to four decimal
places.

Excerise 1.3

1) Find real root of the equation 3x + sin x − e x by using secant method.

2) Find the real root of the equation tan x + tanh x = 0 which lies in the
interval (2, 30 correct to 3 decimal places.

3) Find a root of the equation x3 − 8x − 5 = 0 using the secant method.

4) Determine a root of the equation sin x + 3 cos x − 2 = 0 using the secant


method. The initial approximations are 1.5 and 2.

1.5 Newton Raphson Method


Let x0 be an approximate root of the equation f ( x ) = 0. If x1 = x0 + h be
the exact root,then F ( x1) = 0

f ( x0 + h ) = 0

1 SOLUTION OF ALGEBRAIC AND TRANSCENDENTAL 12


EQUATIONS
Mr. S.S. Salgare

h2
f ( x0 ) + h f 0 ( x0 ) +
f ”( x0 )+ = . . . 0 (Taylor’s series)
2!
Since h is small ,neglecting h2 and higher power of h,we get
f ( x0 ) + h f 0 ( x0 ) = 0
f ( x0 )
h=−
f 0 ( x0 )
A closer approximation to the root is given by
f ( x0 )
x1 = x0 − −
f 0 ( x0 )
Similarly starting with x1 , a still better approximation x2 is given by-
f ( x1 )
x2 = x1 −
f 0 ( x1 )
In general
f ( xn )
x n +1 = x n − (n = 0, 1, 2 . . . )
f 0 ( xn )
Which is known as the Newton – Raphson formula or Newton’s iteration
formula .

Remarks:
1. This method is useful in case of large value of f 0 ( x ) i.e. , when the
graph of f ( x ) while crossing the X-axis is nearly vertical.
2. If f ( x ) is zero or nearly 0, the method fails.
3. Newton’s formula converges provided the initial approximation x0 is
chosen sufficiently close to the root.
4. The order of convergence of Newton – Raphson method is 2.

1.5.1 Geometrical Interpretation:


Let x0 be a point near the root α of equation f ( x ) = 0, then tangent at
A ( x0 , f ( x0 )) is
y − f ( x0 ) = f 0 ( x0 )( x − x0 ) (Slope pont form)
It cuts X-axis at
f ( x0 )
x1 = x0 − − put y=0
f 0 ( x0 )
which is 1st approximation to the root α. If A1 corresponds to x1 on the
curve, then tangent at A1 will cut X-axis at x2 , nearer to α and is therefore
2nd approximation to root α. Repeating this process, we approach the root
α quite rapidly . Hence the method consists in replacing the part of curve
between A and X-axis by the means of the tangent to the curve at A0 .

1 SOLUTION OF ALGEBRAIC AND TRANSCENDENTAL 13


EQUATIONS
Mr. S.S. Salgare

Example 12 Set up a Newton iteration for computing the square root x of a given
positive number c and apply it to c = 2

Ans: Let x = c ⇒ x2 − c = 0
Let f ( x ) = x2 − c ,then f 0 ( x ) = 2x
By Newton Raphson method :
f ( xn )
x n +1 = x n −
f 0 ( xn )
Then
x2 –c
x n +1 = x n − n
2xn
 
1 c
x n +1 = xn +
2 xn
For c = 2, choosing x0 = 1
Then  
1 2
x1 = 1+
2 1
x1 = 1.5
 
1 2
x2 = 1.5 +
2 1.5
x2 = 1.4167
 
1 2
x3 = 1.4167 +
2 1.4167
x3 = 1.4142
 
1 2
x4 = 1.4142 +
2 1.4142
x4 = 1.4142

Thus 2 = 1.4142 approximately
Example 13 Find the positive solution of 2 sin x = x by Newton Raphson method
Ans: Let f ( x ) = 2 sin x–x. Then f 0 ( x ) = 2 cos x − 1 and here f (1) = 0.6829
and f (2) = −0.1814
So f (1) f (2) < 0 root lies between 1 and 2. Let x0 = 2. By Newton Raphson
method

f ( xn )
x n +1 = x n −
f 0 ( xn )
2 sin xn − xn
= xn −
2 cos xn − 1

1 SOLUTION OF ALGEBRAIC AND TRANSCENDENTAL 14


EQUATIONS
Mr. S.S. Salgare

1st iteration:
2 sin x0 − x0
x1 = x0 −
2 cos x0 − 1
2 sin 2 − 2
= 2−
2 cos 2 − 1
= 1.9010
2nd iteration:
2 sin x1 − x1
x2 = x1 −
2 cos x1 − 1
2 sin 1.9010 − 1.9010
= 1.9010 −
2 cos 1.9010 − 1
= 1.8955
3rd iteration:
2 sin x2 − x2
x3 = x2 −
2 cos x2 − 1
2 sin 1.8955 − 1.8955
= 1.8955 −
2 cos 1.8955 − 1
= 1.8955
Thus the solution is x = 1.8955 approximately.
Example 14 Apply Newton method to the equation f ( x ) = x3 + x − 1 = 0
Ans:Let f ( x ) = x3 + x − 1 then f 0 ( x ) = 3x2 + 1. Here f (1) = 1 and f (0) =
−1. As f (1) f (0) < 0 so root lies between 0 and 1. By Newton Raphson
method
Let x0 = 1
f ( xn )
x n +1 = x n −
f 0 ( xn )
xn3 + xn − 1
= xn −
3xn2 + 1
1st iteration:
f ( x0 )
x1 = x0 −
f 0 ( x0 )
1
= 1−
4
= 0.75
2nd iteration:
f ( x1 )
x2 = x1 −
f 0 ( x1 )
(0.75)3 + 0.75 − 1
= 0.75 −
3(0.75)2 + 1
= 0.6860

1 SOLUTION OF ALGEBRAIC AND TRANSCENDENTAL 15


EQUATIONS
Mr. S.S. Salgare

3rd iteration:
f ( x2 )
x3 = x2 −
f 0 ( x2 )
(0.6860)3 + 0.6860 − 1
= 0.6860 −
3(0.6860)2 + 1
= 0.6823

4th iteration:
f ( x3 )
x4 = x3 −
f 0 ( x3 )
(0.6823)3 + 0.6823 − 1
= 0.6823 −
3(0.6823)2 + 1
= 0.6823

The approximate Solution is x = 0.6823

Example 15 Find by Newton’s method, the real root of the equation 3x = cos x +
1 correct to four decimal place. (Take x0 = 0.6)

Ans: Let f ( x ) = 3x − cos x − 1 and f 0 ( x ) = 3 + sin x. Let x0 = 0.6


BY Newton Raphson method,

f ( xn )
x n +1 = x n −
f 0 ( xn )
3xn – cos xn − 1
= xn −
3 + sin xn
xn sin xn + cos xn + 1
=
3 + sin xn

1st iteration:
(0.6) sin(0.6) + cos(0.6) + 1
x1 =
3 + sin(0.6)
= 0.6071

2nd iteration:
(0.6071) sin(0.6071) + cos(0.6071) + 1
x2 =
3 + sin(0.6071)
= 0.6071

Here x1 = x2 .Hence the desired root is 0.6071 correct to four decimal


places.

Example 16 Evaluate 12 to four decimal place by Newton’s iterative method

1 SOLUTION OF ALGEBRAIC AND TRANSCENDENTAL 16


EQUATIONS
Mr. S.S. Salgare


Ans: Let x = 12,so that x2 − 12 = 0
Take f ( x ) = x2 − 12. Newton’s iterative formula gives

f ( xn )
xnn+1 = xn –
f 0 ( xn )
x2 − 12
= xn − n
2xn
 
1 12
= xn +
2 xn

Also f (3) = −3 (-ve) and f (4) = 4 (+ve). So root lies between 3 and 4. Take
x0 = 3.Then  
1 12
x1 = 3+ ⇒ x1 = 3.5
2 3
   
1 12 1 12
x2 = x1 + = 3.5 + ⇒ x2 = 3.4643
2 x1 2 3.5
   
1 12 1 12
x3 = x2 + = 3.4643 + ⇒ x3 = 3.4641
2 x2 2 3.4643
   
1 12 1 12
x4 = x3 + = 3.4641 + ⇒ x4 = 3.4641
2 x3 2 3.4641

Since x3 = x4 upto 4 decimal places. So we have 12 = 3.4641

Example 17 Using Newton’s iterative method, find the real root of x log10 x =
1.2 correct to five decimal places.
log x
Ans: Let f ( x ) = x log10 x − 1.2 = x − 1.2
log 10
 
1 1
f 0 (x) = x + log x
log 10 x
1
= (1 + log x )
10
= 0.4343 + log10 x

Let x0 be the initial approximation

1st iteration:
f ( x0 )
x1 = x0 −
f 0 ( x0 )
3 log(3) − 1.2)
= 3−
log(3) + 0.4343

1 SOLUTION OF ALGEBRAIC AND TRANSCENDENTAL 17


EQUATIONS
Mr. S.S. Salgare

x1 = 2.74615

2nd iteration:
f ( x1 )
x2 = x1 −
f 0 ( x1 )
2.74615 log(2.74615) − 1.2)
= 2.74615 −
log(2.74615) + 0.4343

x2 = 2.74065

3rd iteration:
f ( x2 )
x3 = x2 −
f 0 ( x2 )
2.74065 log(2.74065) − 1.2)
= 2.74065 −
log(2.74065) + 0.4343

x3 = 2.74065

Thus the approximate solution is 2.74065

Excerise 1.4
1) Find a root of the equation x sin x + cos x = 0 by Newton Raphson
method with x0 = π

2) Find a real root of the equation x = e− x , using the Newton – Raphson


method.

3) Starting with x0 = 3, find a root of x3 − 3x − 5 = 0, correct to three dec-


imal places. Use Newton Raphson method

4) Find the interval of length 1, in which the root of f ( x ) = 3x3 − 4x2 −


4x − 7 = 0 lies. Take the middle point of this interval as the starting ap-
proximation and iterate two times, using the Newton-Raphson method

5) By using Newton Raphson method, find the root of x4 − x − 10 = 0


which is near to x = 2, correct to three decimal places.

6) Determine the root of x4 + x3 − 7x2 − x + 5 = 0, which lies between 2


and 3 correct to three decimal places.

1 SOLUTION OF ALGEBRAIC AND TRANSCENDENTAL 18


EQUATIONS
Mr. S.S. Salgare

7) Using Newton Raphson method evaluate to two decimal figures, the


root of the equation e x = 3x laying between 0 and 1.

*****************************

1 SOLUTION OF ALGEBRAIC AND TRANSCENDENTAL 19


EQUATIONS

You might also like