Académique Documents
Professionnel Documents
Culture Documents
∫ dx
1-x2
B.Sc. IT 11-(01 &02)
COMPUTER ORIENTESD NUMERICAL METHODS
1
==============================================================
Q1. Explain briefly:
a) Inherent Errors
b) Truncation Errors
Ans: -
a) Inherent Errors – Most numerical computations are inexact, either
due to the given data being approximate or due to the limitations of
the computing aids like mathematical tables, disk calculators or the
digit computer. Due to this limitation, numbers have to be rounded
off, causing what are called rounding errors. In computations, inherent
errors can be minimized by obtaining better data by correcting
obvious errors in the data and by using computing aid of higher
precision. In hand computations, the round-off error can be reduced
by carrying out the computations to more significant figures, at each
step of the computations. A useful rule is that at each step of the
computations, retain at least one or more significant figure than that
given in the data, perform the last operation, and then round off.
b) Truncation Errors – These are errors caused by using approximate
formulae in computations – such as the one that arises when a
function f (x) is evaluated from an infinite series for x after truncating
it at a certain stage. The study of this type of error is usually
associated with the problem of convergence.
2 12 18 12 2 1 12 2 7
A= 13 15 20 B= 13 14 21 C= 30 18 22
19 17 1 9 18 7 9 16 4
12 2 1 -12 -2 -7
13 14 12 -30 -18 -22
B x –C = x -9 -16 -4
9 18 7
∫ dx
1-x2
B.Sc. IT 11-(01 &02)
COMPUTER ORIENTESD NUMERICAL METHODS
1
==============================================================
2- 12 18
-1
A = 13 15 20
19 17 1
Q3. Describe the Numerical Method, Method of False Position for the
solution of the equation y= f (x).
Ans: - In this method, we choose 3 points x0 and x1 such that f(x0) and
f(x1) are of opposite signs. Since the graph of y = f(x) crosses the x axis
between these 2 points, a root must lie between these points.
B (x1,f(x1))
X0 X2
A (x0,f(x0))
-2- P.T.O
5
∫ dx
1-x2
B.Sc. IT 11-(01 &02)
COMPUTER ORIENTESD NUMERICAL METHODS
1
==============================================================
The equation of the chord joining the 2 points [x0, f(x0)] and [x1, f(x1)] is
given by the equation
y- f(x0) = f(x1) – f(x0)
x – x0 x1 – x0
The method consists in replacing the part of the curve between the points
[x0, f(x0)] and [x1, f(x1)] by means of the chord joining the points and taking
the point of intersection of the chord with the x axis as an approximation to
the root. The point of intersection in the present case is obtained by putting
y=0.
Thus we obtain x x0 = f(x0) (x1 – x0)
f(x1) – f(x0)
If now f(x2) and f(x0) are of opposite signs, then the root lies between x0 and
x2 and we replace x1 by x2 in eqn 1 and obtain the next approximation. This
procedure is repeated until the root obtained to the desired accuracy.
Q4. From the following table, estimate the number of students who
obtained marks between 80—85.
Ans: - We shall find the number of students with marks less than 85
i.e. y (85)
Taking no = 90, x = 85 we have p = 85 – 90 = -0.5
10
Therefore, the table
x y ∇ ∇2 ∇3 ∇4
50 40
-3- P.T.O
5
dx
1-x2
∫B.Sc. IT 11-(01 &02)
COMPUTER ORIENTESD NUMERICAL METHODS
1
==============================================================
y(85) = y0 + p ∇ y0 + p (p + 1) ∇2 y0 + p (p +1) (p +2) ∇3 y0
2! 3!
+ p(p + 1) (p +2) (p + 3) ∇4 y0
4!
Y(85) = 150 – 0.5 x 19 – 0.5 x 0.5 x 16 - 0.5 x 0.5 x 1.5 x 23
2! 3!
- 0.5 x 0.5 x 2.5 x 1.5 x (-38)
4!
= 150 - 9.5 – 2.0 – 1.4375 + 1.4844375
= 138.546875 Ans.
Number of students with marks less than 85 is 138.5468 i.e. 139. but number
of students with marks less than 80 is 131. Hence, the number of students
getting marks between 80 – 85 = 139 –131 = 8 students only.
5
Q5. Evaluate ∫ dx
1-x2
by using Simpson’s 1 rule — given.
3
1
X X0=1 X1=2 X2=3 X3=4 X4=5
y Y0=3.921 Y1=3.921 Y2=2.78281 Y3=45 Y4=75.239
5 x4
∫ dx
1-x2
= ∫ f(x)dx = 1/3h [(y0 +y4) + 4 (y1+y3) + 2 y2]
1 x0
we get, h = x1 – x0 = 1
5
∫ dx
1-x2
= 1 (1) [(1.029 + 75.239) + 4 (3.921 + 45) + 2 x 2.78281]
3
1 = 1 [76.268 + 4 x 48.921 + 5.56562]
3
∫ dx
1-x2 -4- P.T.O
1
5
∫dx
1-x2
B.Sc. IT 11-(01 &02)
COMPUTER ORIENTESD NUMERICAL METHODS
1
==============================================================
= 1 x 277.51762
3
= 92.5058734 Ans.
5
The exact value of the integral is ∫ dx
1-x2
= 92.5058734
-5- P.T.O
5
∫ dx
1-x2
B.Sc. IT 11-(01 &02)
COMPUTER ORIENTESD NUMERICAL METHODS
1
==============================================================
Guidelines:
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
-6- P.T.O
5
∫ dx
1-x2
B.Sc. IT 11-(01 &02)
COMPUTER ORIENTESD NUMERICAL METHODS
1
==============================================================
EP = ER * 100 = 1.23*10-4 * 100 = 1023*10-2 Ans
3 5 7
1 4 6
9 8 2
3 5 7 1 0 0
Ans. The augmented matrix is 1 4 6 0 1 0
9 8 2 0 0 1
-7- P.T.O
5
∫dx
1-x2
B.Sc. IT 11-(01 &02)
COMPUTER ORIENTESD NUMERICAL METHODS
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.
-8- P.T.O
5
∫ dx
1-x2
B.Sc. IT 11-(01 &02)
COMPUTER ORIENTESD NUMERICAL METHODS
1
==============================================================
Q4. From the following table of values of values of x and y obtain dy/dx
and d 2y/dx 2 for x=4
X= 1 2 3 4 5
Y= 1.0 3.921 22.78281 45 675.239
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
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
2
d y = [569.16957] Ans.
dx 2
-9- P.T.O
5
dx
∫
1-x2
B.Sc. IT 11-(01 &02)
COMPUTER ORIENTESD NUMERICAL METHODS
1
==============================================================
Q5. Compute the following by using Romberg’s method.
4
∫ dx
1-x2
0
Given :
X 0 1 2 3 4
Y 0.231 1.345 4.4896 23.47 0.0234
0
∫ dx
1-x2 = 1 h [(y0+ y4) + 2 (y1+y2+y3) ]
2
= 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
∫ dx
1-x2 = 1 [58.8636] = 29.4318
2
and h = 0.5
∫ dx =1[58.8636]=14.7159
1-x2 4
0
- 10 - P.T.O
5
∫
dx
1-x2
B.Sc. IT 11-(01 &02)
COMPUTER ORIENTESD NUMERICAL METHODS
1
==============================================================
=1[4*29.4318 – 58.8636]
3
=58.8636 ans.
The end
- 11 - P.T.O