Pi Experiments

Animations show the properties of pi and how to calculate it.

Rolling circle

Roll the circle once without slipping. The distance traveled is its circumference; divide it by the diameter to get pi.

Diameter1Distance01234567Distance ÷ diameter0123π
Distance ÷ diameter
Distance
0.000000
Diameter
1
0.000000000000
1

Regular polygon approximation

Approximate the circle’s circumference with polygon perimeters, then divide by its diameter to estimate pi.

― Inscribed○ Circle┄ Circumscribed
Bounds on π3.000000< π <3.464102
Perimeter ÷ diameter (diameter = 1)
Inscribed
3.000000 ÷ 1 ≈ 3.000000
Circumscribed
3.464102 ÷ 1 ≈ 3.464102
Regular 6-gon
How it works

A regular polygon’s perimeter is its side length times its number of sides. As you add sides, its perimeter approaches the circle’s circumference. Dividing by the circle’s diameter gives an approximation of pi. Inscribed polygons give smaller values and circumscribed polygons give larger ones, so you can also check the approximation’s accuracy. Archimedes used this approach. Displayed bounds are rounded outward to keep pi inside the interval.

n × sin(π / n) < π < n × tan(π / n)

Monte Carlo method

Estimate pi from the share of random points inside the circle.

● Inside the circle● Outside the circle

The diagram displays up to the first 20,000 points.

Estimate of π—4 × M ÷ N
Total dots (N)
0
Inside the circle (M)
0
1,000 points / second
Estimate history
3.33.0π00 N

Circle area

Cut the circle into sectors and rearrange them without changing its area. Finer cuts bring the shape closer to a rectangle.

Radius (r)
Half the circumference × radius
Radius × radius × π
πr × r = πr²
8 sectors