You are on page 1of 3

Universiti Teknologi Mara

Fakulti Sains Komputer & Matematik


MAT 575

TEST 1

NAME : __________________________________________________

1.

UITM No : ______________

2.

GROUP/PROG:_______________

LECTURER : MAZNITA

3.

Instructions : 1. Answer all FIVE questions in 1 hour 15 mins.

4.
5.

2. Perform all calculations using FOUR decimal places.


3. Attach this question paper with your answer sheets.

Question 1
Justify that x 1.56 approximate x 1.5611 to 3 significant digits.
(3 marks)
Question 2
Let f ( x ) x 3 2x 1.
a)

Use the Bisection method with three iterations to reduce the interval of the root of f if
r [0.4 , 0.5] .

b)

How many iterations are required if the Bisection method is used to locate the root of
f accurate up to 5 decimal places given r [0.4 , 0.5] ?
(10 marks)

Question 3
The value 3 21 can be estimated using iterative methods. Show that the value can be
found by solving the equation x 3 21 0 . Hence, use the Secant method to find the
solution accurate to 1 decimal place if x 0 2 and x1 3 .
(8 marks)
Question 4
Show analytically that there is an intersection of g ( x ) x 2 1 and h( x ) 2 cos x between
the values x 0.7 and x 0.8 . Then, by applying Newtons method find the point of
intersection correct to 4 significant digits. (Note: calculator in radian)
(7 marks)

Question 5
Provide one advantage of Bisection method and one disadvantage of Newtons method.
(2 marks)
END
Good Luck!

Test1_Set1_mac2016

Solution
Question 1
1.5611 1.56

0.7046103 5x103
1.5611
The relative error 5x103 , thus x 1.56 approximate x 1.5611 to 3 significant
digits.

Question 2
1a)
f ( x ) x 3 2x 1

f (0.4) 0.1360
f (0.5) 0.1250 f (0.4).f (0.5) 0, r [0.4 0.5]
ab
, initial interval [0.4,0.5]
Bisection formula c
2
iteration
a
b
c
fa
fb
fc
0.5
0.45
1
0.4
-0.1360 0.1250 -0.0089
0.45
0.475 -0.0089 0.1250 0.0572
2
0.5
0.45
3
0.475 0.4625 -0.0089 0.0572 0.0239

interval of root
[0.45,0.5]
[0.45,0.475]
[0.45,0.4625]

After 3 iterations the root is in the interval [0.45, 0.4625].


1b)

0.5 x 10 5 since error tolerence is 5D

(b a )
2

0.5 x 10 5

0.5 0.4
ln
0.5 x 10 5

n
ln 2
n 14.29

Hence, requires at least 15 iterations.

Question 3
Identify equation:
x 3 21

Secant formula:

x 3 21
x 21 0
3

f(x) x 21
3

x x n 1
x n 1 x n f n n

f n f n 1

, fn f ( x n )

You may choose initial guesses x0=2 and x1=3 (or any values sufficiently close):
iteration
xn
xn-1
fn
fn-1
xn+1
(1D)
1
2
3
-13
6
2.6842
2.7
2
2.6842
2
-1.6603
-13
2.7844
2.8
3
2.7844 2.684211 0.586875 -1.6603
2.7582
2.8
1
1
Checking: E 2.7582 - 2.7844 0.262x10 0.5x10 (1D)

Test1_Set1_mac2016

Question 4
g ( x ) x 2 1 and h( x ) 2 cos x
g ( x ) h( x )

x 2 1 2 cos x

x 2 1 2 cos x 0

f ( x ) x 2 1 2 cos x f ' ( x ) 2 x ( 2 sin x ) 2 x 2 sin x

Show analytically that the intersection point is between x=0.7 and x=0.8.
(0.7) 0.0397

f (0.8) 0.2466 f (0.7).f (0.8) 0,

r [0.7 0.8]

Newtons formula:
f ( xn )
x n 1 x n
f ' ( xn )
Initial guess x0=0.7: (or any other value sufficiently close)
Iteration
1
2
3

Xn
0.7
0.7148
0.7146

f
-0.0397
0.0004
0.0000

f (x)
2.6884
2.7404
2.7399

Xn+1
0.7148
0.7146
0.7146

Thus, the root correct to 4 significant digits is 0.7146.


The point of intersection is (0.7146, g(0.7146)) = (0.7146, h(0.7146)) = (0.7146, 1.5107)

Question 5
Advantage of Bisection: (one only)
1. simple to use
2. will definitely converge if criteria is fulfilled
Disadvantage of Newton:
1. may fail or diverge

Test1_Set1_mac2016

You might also like