BT11 02
BT11 02
∫ dx
1-x2 B.Sc.IT 11-02
1COMPUTER ORIENTED NUMERICAL METHODS
Q1. Round off the following numbers correct to the 3 significant figures:
a) 23.2927
b) 1.2399
c) 1292323
d) 982121
And also calculate Relative Error, Absolute Error and Percentage Error in each case.
Ans: - EA = The absolute error
ER = The relative error
EP = The percentage error
x = The true value of the quantity
a) Number rounded off to 3 significant figures = 23.3
∴ EA =| 23.2927 – 23.3| = 7.30*10-3
ER = EA = 7.30*10-3 = 3.13*10-4
x 23.2927
ER = EA = -1.00*10-4 = 8.07*10-5
x 1.2399
ER = EA = 2323 = 1.80*10-3
x 1292323
ER = EA = 121 = 1.23*10-4
x 982121
3 5 7
1 4 6
9 8 2
3
∫ dx
1-x2
1
Ans. f (x) = x 4 + x 2 – 6x – 9 = 0
f (2) = -1 = -ve
f (3) = 63=+ve
Therefore, root lies between 2&3.
Now,
x 4 = 9 + 6x - x 2
Hence the iteration method can be applied and we start with x0=2.then the successive approximations are,
x1=(9 + 6 * 2 - 4) 1 / 4=2.030543
Now, taking x1=x0
Repeating the process for x2, x3
x2 = 2.0323370
x3 = 2.03244
Hence x2&x3 being almost same, the root is 2.032 correct to 3 decimal places.
-2- P.T.O
5
∫ dx
1-x2
Q4. From the following1table of values of values of x and y obtain dy/dx and d 2y/dx2 for x=4
X= 1 2 3 4 5
Ans.
x y ∇y ∇ 2y ∇ 3y ∇ 4y
1 1
2 3.921 2.921
3 22.78281 18.8618 15.9408
4 45 22.2171 3.35538 -12. 58542
5 675.239 630.239 608.02181 604.66642 617.25184
Using backward difference formula: -
At x = 4 and p = 0 ; h = 1 where h is the interval between the values of x.
dy = 1 [∇ y n + 1 ∇ 2 y n + 1∇ 3 y n]
dx h 2 3
dy = 19.69974
dx
d 2y = 1 [∇ 2 y x + ∇ 3 y x + 11 ∇ 4 y x]
dx 2 h2 12
= 1 [15.9408 + (-12.58542) + 11 (617.25184)]
1 12
d 2y = [569.16957] Ans.
dx 2
Q5. Compute the following by using Romberg’s method.
∫ dx
1-x2
0
Given :
X 0 1 2 3 4
Y 0.231 1.345 4.4896 23.47 0.0234
Ans. Taking h = 2, 1, 0.5 successively we get the result using trapezoidal rule as
0
∫ dx
1-x2
-3- P.T.O
5
∫
= 1 h [(y0+ y4)
dx
1-x 2
+ 2 (y1+y2+y3) ]
2 1
= 1 x 2 [(.231 + 0.0234) + 2 (1.345 + 4.4896 +23.47)]
2
= [0.2544 + 2 x (58.6092) ]
= (58.8636)
Again using h = 1
∫
0 0.5
dx = 1 [58.8636] = 29.4318
1-x2
2
and h =
∫
=1[58.8636]=14.7159
dx 4
1-x2
0
so (h,h/2) = 1 [4f (h/2) –f (h)]
3
=1[4*29.4318 – 58.8636]
3
=58.8636 ans.
The end
-4- P.T.O