Last time | Next time |
Today:
Will and Natalie are using a slightly different, and very good cross-multiplying approach to writing the equivalent polynomial: \[ \frac{5x-7}{x^2(x+4)} = \frac{A}{x}+\frac{B}{x^2}+\frac{C}{x+4} \] Therefore \[ 5x-7 = x^2(x+4)\left(\frac{A}{x}+\frac{B}{x^2}+\frac{C}{x+4}\right) = \frac{Ax^2(x+4)}{x}+\frac{Bx^2(x+4)}{x^2}+\frac{Cx^2(x+4)}{x+4} \] So, cancelling common terms, we get \[ 0x^2+5x-7 = Ax(x+4)+B(x+4)+Cx^2 = (A+C)x^2+(4A+B)x+4B \] and our three equations \[ \begin{array}{ccccc} {A}&{}&{+C}&{=}&{0}\cr {4A}&{+B}&{}&{=}&{5}\cr {}&{4B}&{}&{=}&{-7} \end{array} \]
\[ A=\int{dA} \]
"dA" is called an "infinitesimal" -- it's a tiny chunk of area -- tinier than anything you know ("vanishingly small")!
What's numerical integration all about? We do pretty much the same thing, only we have a finite sum \[ A=\sum{\Delta {A}} \]
where the $\Delta {A}$ are small, but not vanishingly small.
but as the image to the right (above) and the graphical insight below show, we can think of the Midpoint rule as being a "Tangent rule":
Be careful however not to confuse the midpoint and trapezoidal rule. The trapezoid represented above is not the same as the trapezoid of the trapezoidal rule (which is the average of the left- and right-endpoint methods):
Midpoint Rule: \[ \int_a^b f(x) dx \approx M_n = \Delta x [f(\overline{x_1})+f(\overline{x_2})+\cdots+f(\overline{x_n}) \] where \[ \Delta x = \frac{b-a}{n} \] and $\overline{x_i}=\frac{1}{2}(x_{i-1}+x_i)=$ midpoint of $[x_{i-1},x_i]$.
(their arithmetic average, in this case).
Trapezoidal Rule: \[ \int_a^b f(x) dx \approx T_n = \frac{\Delta x}{2} [f(x_0)+2f(x_1)+2f(x_2)+\cdots++2f(x_{n-1})+f(x_n)] \] where \[ \Delta x = \frac{b-a}{n} \] and $x_i=a + i \Delta x$.
Notice that the number of subintervals in Simpson's rule must be even.
Now we can go further:
(their weighted arithmetic averages).
Here are the error bounds, that illustrate that the errors of midpoint and trapezoidal are related, and suggest how to combine them to create a better method (Simpson's rule):