X X) X (F: Test1 - Set1 - Oct20155 1
X X) X (F: Test1 - Set1 - Oct20155 1
TEST 1
NAME : __________________________________________________
1.
UITM No : ______________
2.
GROUP/PROG:_______________
3.
LECTURER : MAZNITA
4.
________
Show analytically that there exists at least one root of f between the values 2.1 and
3.8.
Use the Bisection method with three iterations to reduce the interval of the root of f.
How many iterations are required if the Bisection method is used to locate the root of
f accurate up to 4 decimal places?
(10 marks)
Question 2
In an investigation, the solution to the equation e 0.5 x 5x x 2 is needed for subsequent
analysis. The solution is known to be a value close to 0.5. Find this value accurate to 3
significant digits by applying Newtons method. Then, calculate the percentage relative
error for all the iterations.
(10 marks)
Question 3
Show algebraically that the square root of a value K can be calculated or approximated by
solving the equation x 2 K 0 . Then, use the Secant method with 2 iterations to estimate
48.7
0.5
.
(7 marks)
Question 4
Illustrate a case where Newtons method may diverge.
(3 marks)
END
Test1_Set1_oct20155
Solution
Question 1
1a)
f ( x ) x 2 2x 15
f ( 2.1) 6.3900
f ( 3.8 ) 7.0400 f ( 2.1).f ( 3.8 ) 0, r [ 2.1 ,3.8 ]
1b)
ab
,
2
Bisection formula c
f(a)
f(b)
f(c)
interval
root
est.
2.1
3.8
2.95
-6.3900
7.0400
-0.3975
[2.95,3.8]
2.95
2.95
3.8
3.375
-0.3975
7.0400
3.1406
[2.95,3.375]
3.375
2.95
1.3264
[2.95,3.1625] 3.1625
(b a )
2
0.5x10 4
3.8 2.1
ln
0.5x10 4
n
ln 2
n 15.05
Hence, requires at least 16 iterations.
Question 2
f ( x ) e 0.5x x 2 5x
Newtons formula:
x n 1 x n
f ( xn )
f ' ( xn )
f(x)
fderv(x)
x(n+1)
0.5000
0.2123
0.2361
-0.9660
0.0954
0.0006
-3.3580
-4.0193
-3.9652
0.2123
0.2361
0.2362
Test1_Set1_oct20155
x new x old
x new
n
1
2
3
x 100
xn
0.5000
0.2123
0.2361
or %
x(n+1)
0.2123
0.2361
0.2362
x n 1 x n
x n 1
x 100
% rel. error
135.52
10.08
0.04
Question 3
Identify equation:
x 48.7
Secant formula:
0.5
x x n 1
x n 1 x n f n n
f n f n 1
x 2 48.7
x 2 48.7 0
f(x) x 2 48.7
, fn f ( x n )
You may choose initial guesses x0=6 and x1=7 (or any values sufficiently close):
n
1
2
x n-1
xn
6.0000 7.0000
7.0000 6.9769
f(xn-1)
-12.7000
0.3000
f(xn)
0.3000
-0.0225
x n+1
6.9769
6.9785
Question 4
Refer notes pg. 40 & 41 Cases of Failure of Newtons Method
PART2: Chapter3 any one of the cases.
Test1_Set1_oct20155