Labs / Mathematics
Riemann Sums
Pick a function, drag the a and b handles to set an interval, and slide the rectangle count up. Each rectangle estimates a sliver of the signed area, and their total creeps toward the exact integral as the strips get thinner. Areas below the axis count as negative.
approx 0exact 0error 0
What to try
- With only 4 rectangles, which rule—left, right, midpoint, or trapezoid—lands closest to the exact answer?
- Push n from 4 up to 120. How fast does the error fall for the midpoint rule compared with the left rule?
- Slide the interval so it straddles a point where the curve dips below the axis. Why does the total area shrink instead of grow?
- On sin x, drag b out to 2π. Why does the exact integral come out to zero even though there are tall rectangles?
- For a straight-enough piece of a curve, can you make the trapezoid error effectively vanish? What shape of curve fools it the most?