Numerical integration continued --- Simpson’s rules - We can add more segments OR - We can use a higher order polynomial
Simpson’s 1/3 rule use a second order interpolating polynomial If we use Lagrange form
Integrate and do some algebra
If we use a=x0 and b=x2, and x1=(b+a)/2 widthAverage height Error for Simpson’s 1/3 rule
As with Trapezoidal rule, can use multiple applications of Simpson’s 1/3 rule need even number of segments, odd number of points 9 points, 4 segments
As in multiple trapzoid, break integral up Substitute Simpson’s 1/3 rule for each integral and collect terms
Example: Numerically integrate from 0 to 1 using 1) single trapezoid, 2) multiple trapezoid, 3) single Simpson’s 1/3 and 4) multiple Simpson’s 1/3
True, analytic value of I is
Really quite bad 1) Single trapezoidal rule
2) Multiple trapezoidal rule
3) Single Simpson’s 1/3 rule
4) Multiple Simpson’s 1/3 rule
Simpson’s 1/3 rule is limited to applications with equally-spaced data even number of segments odd number of points Simpson’s 3/8 rule used when there are odd number of segments even number of points
Simpson’s 3/8 rule uses a third order Lagrange polynomial Four equally spaced points, separated by or
Can do multiple segment application of Simpson’s 3/8 rule. Can also mix and match Simpson’s 1/3 and 3/8 to fill up segments
Example: 12 points, 11 segments Each 3/8 rule application takes 3 segments Each 1/3 rule application takes 2 segments
Neither 2 nor 3 go into 11 But 3 3’s and a 2 do. 1/3 rule 3/8 rule
Higher order Newton-Cotes closed formulas Simpson’s 1/3 - 2nd order Lagrange Simpson’s 3/8 - 3rd order Lagrange we can keep going but don’t usually - Simpson is accurate enough when applied in multiple segments
Integration with unequal segments If all unequal, stuck with multiple trapezoid rule application If you can find some sets of equal segments, use Simpson’s rules