Assignment 3
Assignment 3
28/9/2017
1. Use the most accurate three-point formula to determine each missing entry in the following
tables.
x f px q f 1 px q x f px q f 1 px q
-0.3 -0.27652 7.4 -68.3193
(a) -0.2 -0.25074 (b) 7.6 -71.6982
-0.1 -0.16134 7.8 -75.1576
0.0 0.0 8.0 -78.6974
2. The data in Exercise 5 were taken from the following functions. Compute the actual errors
in Exer- cise 5, and find error bounds using the error formulas.
3. Use the values in the table below to approximate f 1 p0.900q, where f pxq sin x. The true
value is cos 0.900 0.62161. Use h 0.001, 0.005, 0.01. The floating-point accuracy of given
data is 5 digits. Compare the errors for different h. What will be the optimal h? (Hint:
Remember the error estimate obtained in terms of h and ε- the maximum round-off error.)
x f px q x f pxq
0.890 0.77707 0.901 0.78395
0.895 0.78021 0.905 0.78643
0.899 0.78270 0.910 0.78950
»
4. Approximate the following integrals using the Trapezoidal rule.
0.25
(a) pcos xq2dx
»
0
0.25
6. Repeat problem 1 using Simpsons rule and find a bound for the error using the error formula,
and compare this to the actual error.
n Roots xi Coefficients cj
2 0.5773502692 1.0000000000
-0.5773502692 1.0000000000
3 0.7745966692 0.5555555556
0.0000000000 0.8888888889
-0.7745966692 0.5555555556
4 0.8611363116 0.3478548451
0.3399810436 0.6521451549
-0.3399810436 0.6521451549
-0.8611363116 0.3478548451