Enter the interval length L = b − a, a positive integer subinterval count n, and nonnegative derivative bounds M2 and M4. All inputs are dimensionless numbers. The rules assume equally spaced subintervals.

Simpson’s bound applies only when n is even. Odd n is valid for midpoint and trapezoidal bounds; disregard the Simpson output for odd n. This calculator evaluates arithmetic formulas and does not automatically check parity. Fractional n is invalid for all three methods.

The default derivative bounds are illustrative inputs, not verified bounds for your function.

\[B_{\mathrm{mid}}=\frac{M_2L^3}{24n^2},\qquad B_{\mathrm{trap}}=\frac{M_2L^3}{12n^2},\qquad B_{\mathrm{S}}=\frac{M_4L^5}{180n^4}\quad(n\text{ even}).\]

For midpoint and trapezoidal bounds, establish that f has a continuous second derivative on the full closed interval and that |f’‘(x)| ≤ M2 everywhere on it. For Simpson’s bound, establish a continuous fourth derivative and |f⁽⁴⁾(x)| ≤ M4 throughout the interval, with even n.

These conditions and derivative bounds must be established externally. A few sampled derivative values do not by themselves establish a global bound. The results bound absolute truncation error, not relative error or the exact error. See OpenStax: Numerical Integration.

Compare the applicable bound with your chosen absolute-error tolerance to assess the proposed n. This tool does not evaluate the integral or a Riemann sum, extrapolate approximation pairs, maximize derivatives, or automatically select a minimum n.

The implementation uses h = L/n and repeated multiplication to evaluate M2·L·h²/24, M2·L·h²/12 and M4·L·h⁴/180, which are algebraically equivalent to the displayed formulas.

Roundoff and function-evaluation errors are excluded. Displayed results are rounded to eight decimal places, so a displayed zero can represent a small positive bound and is not proof of exactness. Zero interval length gives zero bounds for the degenerate interval. Division by zero or an out-of-range intermediate calculation produces an unavailable result, not a zero error bound.

Arithmetic check with L = 1, n = 10, M2 = 1 and M4 = 1; derivative bounds are assumed.
MethodBound before display roundingDisplay at eight decimal places
Midpoint1/24000.00041667
Trapezoidal1/12000.00083333
Simpson (n is even)1/18000000.00000056

Reference

  1. OpenStax, Calculus Volume 2, Section 3.6: Numerical Integration.