Trapezoidal Rule Calculator
Approximate a definite integral by dividing the interval into trapezoids. Enter a function, limits, and number of subintervals to see the estimate, step size, table, and graph.
Use x with operators such as +, −, *, /, ^, sin, cos, exp, or sqrt.
Provide the lower limit a, upper limit b, and number of trapezoids n.
Review the trapezoidal approximation, graph, and evaluation table.
h = (b − a) / n
For f(x) = x² on [0, 1] with n = 4, the step size is h = 0.25. The weighted function sum is 2.75, so T₄ = 0.25 ÷ 2 × 2.75 = 0.34375.
| Point | xᵢ | f(xᵢ) | Weight | Weighted value |
|---|
What is the trapezoidal rule?
It is a numerical integration method that approximates the area under a curve by connecting adjacent sample points with straight lines and summing the resulting trapezoids.
Does increasing n improve accuracy?
Usually yes. More subintervals create narrower trapezoids, which generally follow a smooth curve more closely.
Which functions can I enter?
You can use x, numbers, parentheses, powers with ^, and common functions including sin, cos, tan, sqrt, abs, exp, log, and ln.
Is the result exact?
No. The result is an approximation. Accuracy depends on the function, interval, and number of subintervals.
Results are estimates generated locally in your browser using standard mathematical formulas. They are for informational and educational purposes only and are not a substitute for verification in coursework, examinations or professional contexts requiring certified accuracy. VisionVix accepts no liability for decisions based on this tool's output.
This calculator provides numerical approximations for educational and general analytical use. Verify results independently for precision-critical scientific or engineering work.