On Teaching Math Logo

On Teaching Math

Teach clearly. Engage deeply. Grow your impact.

Trapezoidal Rule Visualization

Trapezoidal Rule Visualization

Approximating the area under y = x² from x = 0 to x = 4

4
Approximate Area: 21.33 square units
Actual Area: 21.33 square units
Error: 0.00 square units (0.00%)

The Trapezoidal Rule

The Trapezoidal Rule approximates the definite integral (area under a curve) by dividing the area into trapezoids:

The Trapezoidal Rule formula is:
$$ \int_a^b f(x)\,dx \approx \frac{b-a}{2n} \left[f(x_0) + 2f(x_1) + 2f(x_2) + \dots + 2f(x_{n-1}) + f(x_n)\right] $$

In this visualization:

  • The curve is y = x²
  • The interval is [0, 4]
  • Blue trapezoids show the approximation
  • The exact area is 21.33 square units: $$ \int_0^4 x^2\,dx = \left[\frac{x^3}{3}\right]_0^4 = \frac{64}{3} \approx 21.33 $$

Use the slider to see how increasing the number of trapezoids improves the approximation.