Last time: | Next time: |
Today:
No student has ever worked harder than my brother-in-law Kpandja!
We want to evaluate
You encountered the following rules back in calculus class, as you may recall:
We actually usually start with left- and right-rectangle rules, and then consider the trapezoidal rule as the average of these. Simpson's can be considered an average of the trapezoidal and the midpoint rules.
As the authors point out, the first two methods (trapezoidal and midpoint) can be considered integrals of linear functions.
The trapezoidal method is the integral of a linear interpolator of two endpoints, and midpoint is the integral of the constant function passing through -- well, the midpoint of the interval!
This illustrates one important different application of these two methods:
These methods are both examples of what are called "Newton-Cotes methods" -- trapezoidal is a "closed" method, and midpoint is "open".
In the end we paste these methods together on a "partition" of the interval of integration -- that is, multiple sub-intervals, on each one of which we apply the simple rule. This pasted up version is called a "composite" rule.
We're going to start by assuming a partition of the interval that is equally spaced. But in the end, we should let the behavior of help us to determine the the partition of the interval:
The maximum subinterval width ()
goes to zero. The partition gets thinner and thinner, as the number of
subintervals (n) goes to .
The approximations get better and better, of course, as n) goes to . Notice that the larger subintervals occur where the function isn't changing as rapidly. This scheme would be called "adaptive", adapting itself to the function being integrated. That's what we're going to shoot for. |
Of particular interest in this section is the authors' very beautiful demonstration that Simpson's rule is the weighted average of the trapezoidal and midpoint methods.
In particular, that the midpoint method is twice as good as the trapezoidal method, and that the errors tend to be of opposite sign. This analysis is based off of an approximating parabola (see Figure 7.10, p. 271).
In that figure that bottom line is the tangent line at the midpoint (as suggested in paragraph above). The slope of that tangent line is actually equal to the slope of the secant line there, for a parabola. So the difference in those two slopes indicates the extent to which a parabolic model for fails on that section.