Math

Simpson's Rule Calculator

Approximate definite integrals with Simpson's 1/3 rule and compare with the trapezoid rule.

Enter your values

Results update instantly as you type — no submit needed.

Results
Simpson's rule estimate
3.24123804
Δx (h)
0.25
Subintervals used
8
Trapezoid rule estimate
3.25174401
Approximate error
0.00007122

Compared with a high-resolution Simpson run.

x = 0f(x) = sqrt(1 + x^3)x = 2
ixᵢf(xᵢ)weight
0011
10.251.0077824
20.51.060662
30.751.1924244
411.4142142
51.251.7184664
61.52.091652
71.752.521784
8231

Quick answer

Simpson's rule approximates a definite integral by fitting parabolas through pairs of subintervals: ∫f ≈ (Δx/3)[f₀ + 4f₁ + 2f₂ + … + 4f_{n−1} + f_n], where n is even.

∫ₐᵇ f(x) dx ≈ (Δx/3)[f₀ + 4f₁ + 2f₂ + ⋯ + 4fₙ₋₁ + fₙ]

How to use the Simpson's Rule Calculator

  1. 1Enter f(x) and the limits of integration.
  2. 2Choose an even number of subintervals — more subintervals means more accuracy.
  3. 3Read the estimate, Δx and the weighted table of sample points.

Frequently asked questions

Why must n be even for Simpson's rule?

Each parabola spans two subintervals, so the interval count has to be divisible by two. If you enter an odd n this calculator rounds up to the next even number.

Is Simpson's rule more accurate than the trapezoid rule?

Almost always. Simpson's rule is exact for cubics and has error on the order of h⁴, while the trapezoid rule error is on the order of h².