0% found this document useful (0 votes)
543 views17 pages

Numerical Analysis: Lecture - 3

This document discusses errors that occur in numerical calculations involving multiplication, division, powers, and sums due to rounding of numbers. It provides formulas to calculate relative error, absolute error, and the range that the true answer lies within for different types of calculations. Several examples are worked through applying these formulas to estimate errors in calculations involving multiplication, division, powers, and sums of rounded numbers.

Uploaded by

khizar
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
543 views17 pages

Numerical Analysis: Lecture - 3

This document discusses errors that occur in numerical calculations involving multiplication, division, powers, and sums due to rounding of numbers. It provides formulas to calculate relative error, absolute error, and the range that the true answer lies within for different types of calculations. Several examples are worked through applying these formulas to estimate errors in calculations involving multiplication, division, powers, and sums of rounded numbers.

Uploaded by

khizar
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 17

NUMERICAL ANALYSIS

Lecture -3

Page 1 of 17
ERROR IN MULTIPLICATION
Suppose exact value of a number be= x1
Suppose exact value of another number be= x2
Suppose approximate value of a number be= x1
Suppose approximate value of another number be= x2
Error in first number: e1=x1-x1
Error in second number:e2=x2-x2
Let Z be the product of two numbers=Z=x1.x2
Let Z be the product of approximate values=Z=x1.x2
Error=ez=Z-Z
= (x1.x2 )- (x1.x2)
Page 2 of 17
= x1.x2- (x1- e1)(x2-e2)
=x1x2-( x1 x2- e1x2-e2x1-e1e2)
= x1x2-( x1x2- e1x2-e2x1)
Neglecting e1e2 as it is very small
=x1x2-x1x2+e1x2+e2x1
So ez =e1x2+e2x1
Absolute error=|ez|=|e1x2+e2x1|≤|e1x2|+|e2x1|
And =|ez|≤|e1x2|+|e2x1|
Relative error= R.E=Absolute Error/|Z|
=|e1x2+e2x1|/|x1x2|
=| e1x2 +e2x1/x1x2 |
Page 3 of 17
=| e1x2/x1x2 + e2x1/x1x2 |
R.E=| e1/x1 + e2/x2|≤| e1/x1|+| e2/x2|
So R.E≤| e1/x1|+| e2/x2|
ERROR IN QUOTIENT
Suppose exact value of a number be= x1
Suppose exact value of another number be= x2
Suppose approximate value of 1st number be= x1
Suppose approximate value of 2nd number be= x2
Error in first number = e1=x1-x1
Error in second number=e2=x2-x2
Let Z be the quotient of two numbers=Z=x1/x2
Page 4 of 17
Let Z be the quotient of approximate values: Z=x1/x2
Error=ez=Z-Z
=x1/x2-x1/x2
=x1/x2 - x1-e1/x2-e2
= x1/x2 - x1(1-e1/x1)/x2(1-e2/x2)
= x1/x2 -x1(1-e1/x1) × x2(1-e2/x2)-1
= x1/x2 - x1(1-e1/x1) × x2(1- (-1 )e2/x2)
[As (1+x)n=1+nx+…]
= x1/x2-x1(1-e1/x1)×x2(1+e2/x2)
= x1/x2-x1x2 (1-e1/x1+e2/x2)
= x1/x2-x1/x2+e1/x2-x1/x2×e2
Page 5 of 17
= e1/x2 - x1/x22 × e2
R.E=A.E/|Z|
≤| e1/x2-x1/x22. e2|/|x1/x2|
≤|(e1/x2-x1/x22. e2 )/ x1/x2|
≤|e1/x1 - e2/x2|≤|e1/x1| + |e2/x2|
𝑒1 𝑒2
⟹ |𝑒𝑧 | ≤ | | + | |
𝑥1 𝑥2
ERROR IN POWER
Let a number be=x
Such that Z=xn
Appraximate Value of ‘x’=x

Page 6 of 17
Error in x: e=x-x
Error in Z: e=Z-Z
=xn-(x)n
=xn-(x-e)n
=xn-xn(1 - e/x)n
=xn-xn(1+n(-e/x))
=xn-xn+nexn-1
So ez = nexn-1
R.E=|nexn-1|/|xn|
=| nexn-1/xn|
=|ne/x| =|n||e/x|
Page 7 of 17
EXAMPLE # 1
4.0643
Given the data then estimate the relative error, maximum
37.487
absolute error, the range in which true answers lie.
Solution:
Let x1=4.0643 e1=1/2×10-4
Let x2=37.487 e=1/2×10-3
Z=x1/x2
= 4.0643/37.487
= 0.1084.
R.E≤ e1/x1 + e2/x2
≤ 1/2×10-3/4.0643 + 1/2×10-3/37.487
Page 8 of 17
≤ 2.5640 × 10-5
A.E ≤ R.E×ǀ Zǀ

≤ 0.1084×2.5640×10-5
≤ 2.779376×10-6
Max. Absolute Error=2.779376×10-6
The range in which true answer lies
Z-A.E ≤ Z ≤ Z+A.E
0.1084-2.7794×10-6≤Z≤0.1084+2.7794×10-6
0.108397 ≤ Z ≤ 0.108402
(Correct to 3 d.p)

Page 9 of 17
EXAMPLE # 2
Given the data √48.425 the estimate the relative error ,
maximum Absolute error and the range in which answer lies.
Solution:
Z=(48.425)1/2
=6.9588.
LET x=48.425 e=1/2×10-3
R.E=ǀn ǀ × |𝑒/𝑥 |

=ǀ1/2ǀ(1×10/2×48.425)

= 5.1626×10-6

Page 10 of 17
Maximum Absolute error = R.E × ǀZǀ

=5.1626×10×6.9588
= 3.5925×10-5
The range in which true answers lie:
Z-A.E ≤ Z ≤ Z+A.E
6.9588- 3.5925× 10-5 ≤ Z ≤ 6.9588- 3.5925 ×10-5
6.9518 ≤ Z ≤ 6.9588
(Correct to 2 d.p)
EXAMPLE # 3
If given numbers are rounded estimate the relative error and
absolute error in the product 4.0643×0.37487
Page 11 of 17
Solution:
Let x1=4.0643 e1=1/2×10-4
Let x2=0.37487 e2=1/2×10-5
Let Z= x1 × x2
= 4.0643×0.377487
= 1.52358.
A.E : ez ≤ ǀx1 . e2 ǀ +ǀ x2 . e1ǀ

≤ (4.0643×1/2×10-3)+(0.37487×1/2×10-4)
≤ 3.9065×10-5
R.E ≤ ǀ e1/x1 ǀ + ǀe2/x2 |

Page 12 of 17

1×10-4 / 2×4.0643 + 1×10-5 / 2×0.37487
≤ 2.5640 × 10-5
EXAMPLE # 4
6.2343×0.82135
Given √ find relative error, absolute error and the
2.7268
range in which true answer lies.
Solution:
6.2343×0.82135
Z= √
2.7268

= √1.8778
= (1.8778)1/2

Page 13 of 17
Z = 1.37034 n=1/2 e=1/2×10-4
R.E≤1/2×1/2×10-4/1.8778
A.E ≤1.33134×10-5
≤R.E×|Z |
≤1.33134×10-5× 1.37034
≤1.82438×10-5
Z-A.E ≤ Z ≤ Z+A.E
1.37034-1.82438×10-5≤Z≤ 1.37034+1.82438×10-5
1.37032 ≤ Z ≤ 1.370358
(correct to 4 d.p)

Page 14 of 17
EXAMPLE # 5. Let 65.43 and 17.0591 be correctly rounded to
the number of digits shown. What is the smallest interval in
which the exact sum of numbers lies.
SOL: x1=65.43 e1=1/2×10-2
x2=17.0591 e2= 1/2×10-4
Let Z=x1+x2
=65.43+17.0591
=82.4891.
A.E≤ez≤e1+e2
≤5×10-3+5×10-5
≤5×10-3

Page 15 of 17
R.E ≤A.E/|Z|
≤5×10-3/|82.4891|
≤6.06×10-5
Z-A.E ≤ Z ≤ Z+A.E
82.4891-5×10-3 ≤ Z ≤ 82.4891+5×10-3
82.4841 ≤ Z ≤ 82.4941

Page 16 of 17
Exercise
Q # 1:Given the data 1.57695 × 2.65897 .Then estimate the
relative error, maximum absolute error, the range in which true
answers lies.
2.0793
Q #2:Given the data then estimate the relative error,
47.345
maximum absolute error, the range in which true answers lie.
2.1254×0.7435
Q # 3:Given √ find relative error, absolute error
5.2745×1.2548
and the range in which true answer lies.
3.1354
Q #4:Given √ find relative error, absolute error
2.5428×3.2561
and the range in which true answer lies.
Page 17 of 17

You might also like