PPolySim OS

Riemann Sums

Integration is just adding up rectangles. Stack more under the curve and the Riemann sum closes in on the true area — the idea behind the definite integral.

Riemann SumsLive

Controls

Rectangles approximate the area under the curve. Add more and the Riemann sum converges to the true integral.

Presets

▶ Run in Python

Data Inspector

Riemann sum20.7111
Exact integral20.8000
Error0.0889

Governing equation

Reading this result: With n=12 midpoint rectangles the step is dx = 0.667. The midpoint rule already cancels much of the error at each rectangle. Adding subintervals shrinks the error toward the exact integral; midpoint and trapezoid rules converge fastest (error ~1/n²), so from n=12 the estimate tightens quickly as you push toward n=100.

Runs locally in your browser — free forever. Scale to the cloud when reality gets heavy.

or unlock everything with Pro →
★ Sign in to save this setup
Save your tuned setup, or drop this simulation into your own site, docs, or course page.

How it works

Riemann sums approximate the area under a curve with rectangles evaluated at their left edge, midpoint, or right edge. This tool shows the rectangles and compares the sum to a high-resolution exact value, so you can see convergence and the midpoint rule's superior accuracy.

Ask the AI about this model

The math, the assumptions, real-world uses, or a code translation — explained for this exact simulation.

More Math simulations

Frequently asked questions

Is this Riemann sums integral tool really free?
Yes. Riemann Sums runs entirely in your browser using your device's own compute, so local use is free forever. You only pay Compute Tokens if you scale a job to the cloud.
Do I need to install anything?
No. Everything runs client-side in a modern browser — no downloads, no license, no account required to start.
Can I save or share my simulation?
Create a free account to save projects, and use a shareable embed or minted DOI to publish a live, interactive version anywhere.
How accurate are the results?
The solver uses established numerical methods, but results are for research and educational purposes and should be validated against experiment or professional review before you rely on them.