Skip to main content

Section 13.4 Error estimates

How to estimate the accuracy of integration rules? Here is an empirical method which is similar to how we estimated the accuracy of differentiation rules in Section 12.1.

There is a method to determine the order of error of an approximation to some derivative of \(f\text{:}\)

  1. Let \(d = 0\)
  2. Apply the integration rule to \(f(x) = x^d\) on the interval \([0, h]\text{,}\) with the smallest possible number of evaluation points. Find the error term.
  3. If the error term is zero, increase \(d\) by \(1\) and return to step 2.
  4. Express the error as \(C \,d! \,h^{d+1}\) with an explicit constant \(C\text{.}\) Note that the factorial \(d!\) is here because it is the derivative of \(f\) of order \(d\text{,}\) which is the source of the error.
  5. The error bound for a single subinterval is \(C \max |f^{(d)}| h^{d+1}\text{.}\)
  6. When the estimate is applied on an interval \([a,b]\) with step size \(h=(b-a)/n\text{,}\) the error estimate is multiplied by \(n\text{;}\) thus the final result is \(C \max |f^{(d)}| (b-a) h^d \text{.}\)

Using the process describe above, estimate the error of the midpoint rule.

Solution

The midpoint rule is exact for \(x^0\) and \(x^1\text{.}\) But for \(\int_0^h x^2\,dx\) it predicts \(\int_0^h x^2\,dx = h^3/4\text{,}\) while the true value is \(h^3/3\text{.}\) So we stop at \(d=2\) with the error of \(h^3/12\text{,}\) which can be written as \(\dfrac{1}{24} \ 2! \ h^3\text{.}\) Therefore, the constant factor in the error formula: is \(C=1/24\text{.}\) In conclusion, the error of the midpoint rule is at most

\begin{equation*} |\text{error}| \le \frac{1}{24}\max_{[a,b]} |f''| (b-a) h^2 \end{equation*}