Simpson's Rule Calculator
Approximate the definite integral of any function over [a, b] using composite Simpson's 1/3 rule with a user-defined even number of subintervals.
Use the Simpson's Rule Calculator
Inputs
Supports: +, -, *, /, ^, sin, cos, tan, exp, log, ln, sqrt, abs, pi, e
Must be even — odd values are rounded up automatically.
Result
Formula Applied
Partition Table
| i | xi | f(xi) | Weight |
|---|
Enter values above and click Calculate to see the approximation.
Summary
Simpson's Rule Calculator approximates the definite integral of a function over [a, b] by fitting parabolic arcs between successive triplets of points. The composite Simpson's 1/3 rule divides the interval into n equal subintervals (n must be even) and applies the formula: (h/3) × [f(x₀) + 4f(x₁) + 2f(x₂) + 4f(x₃) + ⋯ + 4f(xₙ₋₁) + f(xₙ)], where h = (b−a)/n. Because it uses quadratic interpolation, it is more accurate than the trapezoidal rule for the same n and exact for polynomials up to degree 3.
How it works
- Enter a mathematical function such as x^2, sin(x), or e^x in the function field.
- Set the lower bound a and upper bound b of the integration interval.
- Choose an even number of subintervals n (higher values give greater accuracy).
- Click Calculate to apply composite Simpson's 1/3 rule.
- Review the approximation result, the step-size h, and the full partition table with coefficient weights.
Use cases
- Estimate areas under curves when an exact antiderivative is hard to find.
- Verify calculus homework using Simpson's rule approximations.
- Compare accuracy against the trapezoidal rule for the same interval.
- Integrate empirical data or physics functions numerically.
- Teach or learn the composite Simpson's 1/3 rule step by step.
- Check numerical integration results before applying higher-order methods.
- Explore how error shrinks as n grows — Simpson's error is O(h^4).