Upload
nagma-modi
View
376
Download
0
Embed Size (px)
Citation preview
Solution of algebraic & transdental equation with Newton Raphson method & Secant
method
1S.N.P.I.T. & R.C.
Presented by: 130490106065 – Modi Nagma
130490106085 – Patel Pinal
140493106015 – Padhiyar Sagar
140493106025 – Taylor Kishan
2S.N.P.I.T. & R.C.
Two Fundamental Approaches
1. Bracketing or Closed Methods
- Bisection Method
- False-position Method (Regula falsi).
2. Open Methods
- Newton-Raphson Method
- Secant Method
- Fixed point Methods
Roots of Equations
3S.N.P.I.T. & R.C.
Newton Raphson’s Method The equation for
Newton’s Method can be determined graphically!
4S.N.P.I.T. & R.C.
Continue.....
The equation for Newton’s Method can be determined graphically!
From the diagram tan Ө = ƒ'(x0) = ƒ(x0)/(x0 – x1)
5S.N.P.I.T. & R.C.
Continue....
The equation for Newton’s Method can be determined graphically!
From the diagram tan Ө = ƒ'(x0) = ƒ(x0)/(x0 – x1)
Thus, x1=x0 -ƒ(x0)/ƒ'(x0).
6S.N.P.I.T. & R.C.
In general, if the nth approximation is xn and f’(xn) ≠0, then the next approximation is given by:
3
1
( )12
'( )
nn n
n
f xx x
f x
Equation/Formula 2
Continue…
7S.N.P.I.T. & R.C.
Starting with x1 = 2, find the third approximation x3 to the root of the equation
x3 – 2x – 5 = 0
Example Of Newton Raphson’s method
Example 1
8S.N.P.I.T. & R.C.
We apply Newton’s method with f(x) = x3 – 2x – 5 and f’(x) = 3x2 – 2
Newton himself used this equation to illustrate his method.
He chose x1 = 2 after some experimentation because f(1) = -6, f(2) = -1 and f(3) = 16
Continue…
Example 1
9S.N.P.I.T. & R.C.
Equation 2 becomes:
Continue…
10S.N.P.I.T. & R.C.
3
2
2 51
3 2
n nn n
n
x xx x
x
With n = 1, we have:
Continue…..
11S.N.P.I.T. & R.C.
3
1 12 1 2
1
3
2
2 5
3 2
2 2(2) 52
3(2) 2
2.1
x xx x
x
With n = 2, we obtain:
It turns out that this third approximation x3 ≈ 2.0946is accurate to four decimal places.
Continue….
12S.N.P.I.T. & R.C.
3
2 23 2 2
2
3
2
2 5
3 2
2.1 2(2.1) 52.1
3(2.1) 2
2.0946
x xx x
x
Use Newton’s method to find correct to eight decimal places.
First, we observe that finding is equivalent to finding the positive root of the equation x6 – 2 = 0
So, we take f(x) = x6 – 2
Then, f’(x) = 6x5
Example 2
Newton Raphson’s method6 2
6 2
13S.N.P.I.T. & R.C.
So, Formula 2 (Newton’s method) becomes:
Continue…
14S.N.P.I.T. & R.C.
6
1 5
2
6
nn n
n
xx x
x
Choosing x1 = 1 as the initial approximation, we obtain:
As x5 and x6 agree to eight decimal places, we conclude that to eight decimal places.
Continue…
2
3
4
5
6
1.16666667
1.12644368
1.12249707
1.12246205
1.12246205
x
x
x
x
x
6 2 1.12246205
15S.N.P.I.T. & R.C.
Newton Raphson’s method Use Newton’s method to find correct to four
decimal places.
Where, N=12
q=3
= 1
S.N.P.I.T. & R.C. 16
1 1
11n n q
n
Nx x q
q x
0x
3 12
continue….
So, Formula 2 (Newton’s method) for find out qthrootbecomes:
S.N.P.I.T. & R.C. 17
1 3 1
1 123 1 1
3n n
n
x xx
1 4.6667x
Continue…. Choosing x1 = 1 as the initial approximation, we obtain:
As x5 and x6 agree to four decimal places, we conclude that to four decimal places.
S.N.P.I.T. & R.C. 18
3 12 2.2894
2
3
4
5
6
7
3.2948
2.5650
2.3180
2.2898
2.2894
2.2894
x
x
x
x
x
x
Secant Method
19S.N.P.I.T. & R.C.
Continue....
First we find two points(x0,x1), which are hopefully near the root (we may use the bisection method).
A line is then drawn through the two points and we find where the line intercepts the x-axis, x2.
20S.N.P.I.T. & R.C.
Continue....
If f(x) were truly linear, the straight line would intercept the x-axis at the root.
However since it is not linear, the intercept is not at the root but it should be close to it.
21S.N.P.I.T. & R.C.
Continue....
From similar triangles we can write that,
10
10
1
21
xfxf
xx
xf
xx
1x 0x2x
1xf
0xf
22S.N.P.I.T. & R.C.
Continue....
From similar triangles we can write that,
Solving for x2 we get:
10
10
1
21
xfxf
xx
xf
xx
10
10112
xfxf
xxxfxx
23S.N.P.I.T. & R.C.
Continue....
Iteratively this is written as:
nn
nnnnn
xfxf
xxxfxx
1
11
24S.N.P.I.T. & R.C.
S.N.P.I.T. & R.C. 25
Approx. f '(x) with backward FDD:
Substitute this into the N-R equation:
to obtain the iterative expression:
i 1 i
i 1 i
f (x ) f (x )f '(x)
x x
ii 1 i
i
f (x )x x
f '(x )
i i 1 ii 1 i
i 1 i
f (x )(x x )x x
f (x ) f (x )
Continue….
x
f(x)
1
2
new est.
x
f(x)
1
new est.
2
FALSE POSITION
SECANT METHOD
The new estimateis selected from theintersection with thex-axis
26S.N.P.I.T. & R.C.
Example of Secant Method
The floating ball has a specific gravity of 0.6 and has aradius of 5.5cm.You are asked to find the depth to which the ball issubmerged when floating in water.
The equation that gives the depth x to which the ball is
submerged under water is given by
010993.3165.0 423 xx
27S.N.P.I.T. & R.C.
Use the secant method of finding roots ofequations to find the depth to which the ball issubmerged under water. Conduct three iterations toestimate the root of the above equation. Find theabsolute relative approximate error at the end of eachiteration, and the number of significant digits at leastcorrect at the converged iteration.
28S.N.P.I.T. & R.C.
S.N.P.I.T. & R.C. 29
Secant Method
From the physics of the problem
11.00
)055.0(20
20
x
x
Rx
x
water
Figure 2 :Floating ballproblem
S.N.P.I.T. & R.C. 30
Let us assume
11.0,0 UL xx
4423
4423
10662.210993.311.0165.011.011.0
10993.310993.30165.000
fxf
fxf
U
L
Hence,
010662.210993.311.00 44 ffxfxf UL
31
Iteration 1
0660.0
10662.210993.3
10662.2010993.311.044
44
UL
ULLUm
xfxf
xfxxfxx
5
423
101944.3
10993.30660.0165.00660.00660.0
fxf m
00660.00 ffxfxf mL
0660.0,0 UL xxS.N.P.I.T. & R.C.
32
Iteration
1 0.0000 0.1100 0.0660 N/A -3.1944x10-5
2 0.0000 0.0660 0.0611 8.00 1.1320x10-5
3 0.0611 0.0660 0.0624 2.05 -1.1313x10-7
4 0.0611 0.0624 0.0632377619 0.02 -3.3471x10-10
LxUx mx %a mxf
010993.3165.0 423 xxxfTable 1: Root of
for secant Method.
S.N.P.I.T. & R.C.
33S.N.P.I.T. & R.C.