0% found this document useful (0 votes)
64 views10 pages

NA Lec 7 PDF

This document provides an overview of the iterative method for finding roots of equations. The iterative method works by rewriting the equation as x=g(x) and then iteratively calculating xn+1=g(xn) until the values converge to the root. The method will converge if |g'(x)| < 1 for all x in the interval containing the root. Two examples are provided to demonstrate finding roots of equations using the iterative method to 4 decimal places. Exercises are provided at the end to find roots of additional equations using this method.

Uploaded by

hamid
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)
64 views10 pages

NA Lec 7 PDF

This document provides an overview of the iterative method for finding roots of equations. The iterative method works by rewriting the equation as x=g(x) and then iteratively calculating xn+1=g(xn) until the values converge to the root. The method will converge if |g'(x)| < 1 for all x in the interval containing the root. Two examples are provided to demonstrate finding roots of equations using the iterative method to 4 decimal places. Exercises are provided at the end to find roots of additional equations using this method.

Uploaded by

hamid
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/ 10

NUMERICAL ANALYSIS

Lecture -7

Dr. Muhammad Rafiq


Assistant Professor
University of Central Punjab
Lahore Pakistan

Page 1 of 10
ITRATIVE METHOD

To find the root of an equation f(x)=0 by this method we rewrite the equation in
the form of
x=g(x)
Let x=x0 be an initial approximation of the desired root “α” then first
approximation will be
x1=g(x0)
Now taking x1 as intial value 2nd approximation is given as
x2=g(x1)
And percending in the same way
xn=g(xn-1)

Page 2 of 10
THEOREM
If
I. α be the root of equation f(x)=0 which is equivalent to x=g(x)
II. I be any interval containing the point x= α
III. |𝑔́ (𝑥)| < 1 ∀ x ∈ I
Then the sequence of approximations x0, x1,x2, x3…..xn will converge to the root
‘α’ provided that the initial approximation is chosen in interval I. Condition III is
called “Condition of Convergence” for Iterative Method.
Example.1
Find a real root of cosx=3x-1 correct to 4 d.p using Iterative Method
Solution
f(x)=cosx-3x+1=0
f(0)=1-0+1=2>0
f(1)=cos(1)-3(1)+1=1.45<0
Page 3 of 10
Interval =[0,1]
Given equation can be written as
x=1/3[1+cosx]
Where
g(x)= 1/3[1+cosx]
𝑔́ (𝑥)= 1/3[-sinx]
|𝑔́ (𝑥)|= [sinx]/3
Maximum Value of sinx is 1
so
𝑔’(x)=1/3=0.33<1 ∀ x ∈ I
so we can start iterative procedure

Page 4 of 10
let
x0 =0
xn+1=g(xn)
x1=g(x0)=1/3[1+cosx]
x1=1/3[1+cos0]=2/3
x1=.66667
x2=g(x1)=1/3[1+cos0.66667]
x2=.59529
x3=g(x2)=1/3[1+cos0.59529]
x3=.60933
x4=g(x3)=1/3[1+cos0.60933]
x4=.60668
x5=g(x4)=1/3[1+cos0.60668]
Page 5 of 10
x5=.60718
x6=g(x5)=1/3[1+cos0.60718]
x6=.60709≅ .6071
x7=g(x6)=1/3[1+cos0.6071]
x7=. 60710
Root =. 60710
Example.2
Solve x3-3x-20=0 Correct to 4 d.p using Iterative Method.
Solution
f(x)=x3-3x-20=0
f(3)=(3)3-3(3)-20=-2<0
f(4)=(4)3-3(4)-20=32>0
interval=[3,4]
Page 6 of 10
given equation can be written as
x=1/3[x3-20]
g(x)= 1/3[x3-20]
𝑔’(x)= 1/3[3x2]
𝑔’(x)=x2≮ 1 ∀ x ∈ I
again given equation can be written as
x3-3x-20=0
x(x2 -3)=20
x=20/ x2 -3
g(x)= 20/ x2 -3
𝑔’(x)=-2x*20/ (x2 -3)2
𝑔’(x)=-40x/ (x2 -3)2
|𝑔’(x)|=40x/ (x2 -3)2
Page 7 of 10
For interval [3,4]
|𝑔’(x)|=40(3)/ ((3)2 -3)2
|𝑔’(x)|=120/ 36=3.33>1
𝑔’(x)=3.33≮ 1 ∀ x ∈ I
again
x3=3x+20
x=∛3𝑥 + 20
g(x)=(3x+20)1/3
𝑔’(x)=1/3[3x+20]1/3-1*3
𝑔’(x)=(3x+20)-2/3
𝑔’(x)=1/(3x+20)2/3<1
|𝑔’(x)|<1 ∀ x ∈ I
x0 =4
Page 8 of 10
xn+1=g(xn)
x1=g(x0)= =∛3(4) + 20
x1=3.1748
x2=g(x1)= =∛3(3.1748) + 20
x2=3.09106
x3=g(x2)= =∛3(3.09106) + 20
x3=3.08193
x4=g(x3)= =∛3(3.08193) + 20
x4=3.08097
x5=g(x4)= =∛3(3.08097) + 20
x5=3.080871
x6=g(x5)= =∛3(3.080871) + 20

Page 9 of 10
x6=3.080860
root==3.080860
NOTE
Smaller the value of |𝑔’(x)|, More rapid will be the convergence.

EXCERCISE
Find a real root of the following equations correct to 4 d.p. by Iterative
Method.
(1) x = cos(x)
(2)𝑥 3 − 𝑥 2 + 𝑥 − 7 = 0
(3) 𝑥 3 +x-1=0
(4)𝑥𝑡𝑎𝑛𝑥 = −1
(5) 𝑥 3 − 4𝑥 − 9 = 0

Page 10 of 10

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy