[ home ] [ math / cs / ai / phy / as / chem / bio / geo ] [ civ / aero / mech / ee / hdl / os / dev / web / app / sys / net / sec ] [ med / fin / psy / soc / his / lit / lin / phi / arch ] [ off / vg / jp / 2hu / tc / ts / adv / hr / meta / tex ] [ chat ] [ wiki ]

Viewing source code

The following is the source code for post >>>/math/1022

If you have a function that cannot be integrated but which has a fourth
derivative, you can approximate the definite integral to a high degree of
accuracy using Simpson's rule.

Choose \(\Delta x\) such that \([a,b]\) is divided into an even number of subintervals.

\[\int_{a}^b f(x)\,dx = \lim_{\Delta x \to 0^+} \frac{\Delta x}{3}[f(x_0) + 4f(x_1) + 2f(x_2) + 4f(x_3) + 2f(x_4) + ... + 4f(x_{n-1}) + f(x_n)] \]

For the error, find the maximum value \(M\) of \(f^{(4)}(x)\) on \([a,b]\).
\[\frac{b-a}{180}M(\Delta x)^4\]