Professional Documents
Culture Documents
f (xi + h) − f( xi − h) 1 (3)
f 0 (xi ) = + f (ξ)h2 . (2)
2h 6
In practice, we will also have round-off errors when evaluating function values f (xi +h) and f (xi −h). Assume
the round-off errors are e(xi + h) and e(xi − h), respectively, then the total error of the approximation is
h=10.ˆ(-8:0.001:-4);
1
EP501 Numerical Methods Homework 4 Due Oct 25, 2013 11:59 pm
c. Plot the absolute value of the error as a function of h, using loglog function. Describe what you observe,
and explain why.
d. Based on your answer to a, check if the result in d is consistent. You will need to find values of M and
ε first..
This phenomenon is called round-off error instability.