Section 17.2 Estimating error by using two step sizes
A practical way to estimate the error of some method of integration is to use it twice with two different step sizes, and compare the results. Typically, one compares the computations with steps \(h\) and \(h/2\text{.}\) Say, the first computation resulted in \(A_1\) and the second, more accurate, in \(A_2\text{.}\) If the exact value is \(E\text{,}\) then we expect \(|A_1-E|\approx 2^d|A_2-E|\) where \(d\) is the order of accuracy of the method. By the triangle inequality,
which gives us an idea of the error involved in \(A_2\) (the more accurate approximation):
where the symbol \(\lessapprox\) means the error is bounded by something like the right hand side. We do not assert this is an exact inequality, because the relation involving \(2^d\) is only approximate.
Let us return to Example 17.1.1 where Simpson's method with \(h=4\) was used to get an approximation \(A_1 = 96.9618\text{.}\) Reducing the step size to \(h=2\) we get a second approximation:
Since Simpson's rule has order \(d=4\text{,}\) the error of second approximation can be estimated by (17.2.1) as follows:
Recalling that the exact value is \(E = 96.8\text{,}\) we see that \(|A_2-E| = 0.0176\text{.}\) So our error estimate, while not rigorous, is much closer to reality than the theoretical estimate (17.1.1).