0% found this document useful (0 votes)
26 views3 pages

Numerical Error Analysis

1. The document calculates the true value and error for approximations of increasing order of an exponential function f(1.5). The error decreases with each higher order approximation. 2. It evaluates a polynomial function f(x) at points x1, xu, and xr and calculates the sign of f(x1)×f(xr) and f(xu)×f(xr) to determine the location of a root between the points. 3. Similarly, it evaluates another polynomial f(x) at points x1, xu, and xr, and calculates the sign of the products to locate a root between the points.

Uploaded by

Neha Siddiqui
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)
26 views3 pages

Numerical Error Analysis

1. The document calculates the true value and error for approximations of increasing order of an exponential function f(1.5). The error decreases with each higher order approximation. 2. It evaluates a polynomial function f(x) at points x1, xu, and xr and calculates the sign of f(x1)×f(xr) and f(xu)×f(xr) to determine the location of a root between the points. 3. Similarly, it evaluates another polynomial f(x) at points x1, xu, and xr, and calculates the sign of the products to locate a root between the points.

Uploaded by

Neha Siddiqui
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/ 3

Problem 1

True Value:
.
𝑓(1.5) = 𝑒 = 4.481689
Zero-Order:
𝑓(1.5) = 1
4.481689 − 1
|𝜀 | = × 100% = 77.68 %
4.481689
|𝜀 | = 𝑁. 𝐴.
First-Order:
𝑓(1.5) = 1 + 1.5 = 2.5
4.481689 − 2.5
|𝜀 | = × 100% = 44.22 %
4.481689
2.5 − 1
|𝜀 | = × 100% = 60%
2.5
Second- Order:
1.5
𝑓(1.5) = 1 + 1.5 + = 3.625
2
4.481689 − 3.625
|𝜀 | = × 100% = 19.12 %
4.481689
3.625 − 2.5
|𝜀 | = × 100% = 31.03%
3.625
Third-Order:
3! = 3 × 2 × 1 = 6
1.5 1.5
𝑓(1.5) = 1 + 1.5 + + = 4.1875
2 3!
4.481689 − 4.1875
|𝜀 | = × 100% = 6.56 %
4.481689
4.1875 − 3.625
|𝜀 | = × 100% = 13.43%
4.1875
Fourth-Order:
4! = 4 × 3 × 2 × 1 = 24
1.5 1.5 1.5
𝑓(1.5) = 1 + 1.5 + + + = 4.3984375
2 3! 4!
4.481689 − 4.3984375
|𝜀 | = × 100% = 1.86 %
4.481689
4.3984375 − 4.1875
|𝜀 | = × 100% = 4.80%
4.3984375
Fifth- Order:
5! = 5 × 4 × 3 × 2 × 1 = 120
1.5 1.5 1.5 1.5
𝑓(1.5) = 1 + 1.5 + + + + = 4.46171875
2 3! 4! 5!
4.481689 − 4.46171875
|𝜀 | = × 100% = 0.45 %
4.481689
4.46171875 − 4.3984375
|𝜀 | = × 100% = 1.42%
4.46171875
Sixth-Order:
6! = 6 × 5 × 4 × 3 × 2 × 1 = 720
1.5 1.5 1.5 1.5 1.5
𝑓(1.5) = 1 + 1.5 + + + + + = 4.477539063
2 3! 4! 5! 6!
4.481689 − 4.477539063
|𝜀 | = × 100% = 0.09 %
4.481689
4.477539063 − 4.46171875
|𝜀 | = × 100% = 0.35%
4.477539063
Seventh-Order:
7! = 7 × 6 × 5 × 4 × 3 × 2 × 1 = 5040
1.5 1.5 1.5 1.5 1.5 1.5
𝑓(1.5) = 1 + 1.5 + + + + + + = 4.48092913
2 3! 4! 5! 6! 7!
4.481689 − 4.48092913
|𝜀 | = × 100% = 0.02 %
4.481689
4.48092913 − 4.477539063
|𝜀 | = × 100% = 0.08%
4.48092913
Problem 2
𝑓(𝑥 ) = 4(0) − 6(0) + 7(0) − 2.3 = −2.3
𝑓(𝑥 ) = 4(1) − 6(1) + 7(1) − 2.3 = 2.7

𝑓(𝑥 ) × 𝑓(𝑥 ) = (−2.3) × (2.7) = −6.21 < 0

𝒙𝟏 𝒙𝒖 𝒙𝒓 𝒇(𝒙𝟏 ) 𝒇(𝒙𝒖 ) 𝒇(𝒙𝒓 ) 𝒇(𝒙𝟏 ) × 𝒇(𝒙𝒓 ) 𝒇(𝒙𝒖 ) × 𝒇(𝒙𝒓 ) 𝜺𝒂 %


0 1 0.5 -2.3 2.7 0.2 -0.46 < 0 0.54 > 0 N.A.
0 0.5 0.25 -2.3 0.2 -0.8625 1.98375 > 0 -0.1725 < 0 100
0.25 0.5 0.375 -0.8625 0.2 -0.3073 0.2655 > 0 -0.6156 < 0 33.3
0.375 0.5 0.4375 -3.073 0.2 -0.05098 0.01567 > 0 -0.101096 < 0 14.29
0.4375 0.5 0.46875 -0.05098 0.2 0.07481 -3.8169< 0 0.014974 > 0 6.67

Problem 3
𝑓(𝑥 ) = −13 − 20(−1) + 19(−1) + 3(−1) = 23
𝑓(𝑥 ) = −13 − 20(0) + 19(0) + 3(0) = −13

𝑓(𝑥 ) × 𝑓(𝑥 ) = (23) × (−13) = −299 < 0

𝒙𝟏 𝒙𝒖 𝒙𝒓 𝒇(𝒙𝟏 ) 𝒇(𝒙𝒖 ) 𝒇(𝒙𝒓 ) 𝒇(𝒙𝟏 ) × 𝒇(𝒙𝒓 ) 𝜺𝒂 %


-1 0 -0.3611 23 -13 -3.4418 -79.1614 < 0 N.A.
-1 -0.3611 -0.4443 23 -3.4418 -0.62647 -14.4095 < 0 18.73
-1 -0.4443 -0.42077 23 -0.62647 -1.44418 -33.216 <0 0.56

You might also like