The number π
About this app
Approximate π: inscribed/circumscribed polygons clamp π between two bounds, or Monte Carlo with random points (fraction ×4 ≈ π). Estimate vs. true π live.
What π is
The number π is the ratio of a circle’s circumference to its diameter, π = 3.14159… It is irrational: its decimal expansion never ends and never repeats. Circumference and area are C = 2πr and A = πr². Because π cannot be written as a fraction, it has been pinned down by approximation methods since antiquity.
Two methods in the app
In polygon mode, a regular n-gon is inscribed in the circle and another is circumscribed around it. Half their perimeters give a lower and an upper bound for π; more corners mean a tighter squeeze. In Monte Carlo mode, random points fall into a square, and four times the share landing inside the quarter circle approaches π.
Try it yourself
In polygon mode, increase n and watch the gap between the bounds shrink. In Monte Carlo mode, start the simulation and choose how many points fall per step. The values panel shows the estimate, the true value of π, the error and the hit counts. Notice how slowly the random method gains accuracy by comparison.
Frequently asked questions
- How did Archimedes calculate pi?
- Archimedes drew regular polygons inside and outside a circle and computed their perimeters; the circumference lies between the two. Using 96-sided polygons, he showed that π lies between 3 10/71 and 3 1/7.
- How does the Monte Carlo method estimate pi?
- Scatter random points uniformly in a unit square. A quarter circle of radius 1 covers the fraction π/4 of the square, so on average that fraction of points lands inside it. Hence π ≈ 4 · hits / total; the accuracy improves only slowly as the number of points grows.
- Why is pi irrational?
- Irrational means π cannot be written as a ratio of two integers, which was proved in the 18th century. As a consequence its decimal expansion never terminates and never settles into a repeating pattern.
- What does the app show?
- It approximates π in two ways: with inscribed and circumscribed n-gons that bracket π, and with random points in a quarter circle. Estimate, error, bounds and hit counts are shown live.
Subject: School mathematics (Gymnasium)
More from School mathematics (Gymnasium)
- Tree diagram & path rules
- Binomial identities through geometry
- Unit circle & sine curve
- Exponential growth & decay
- Ulm’s glass pyramid
- Equation balance
- Half-life & decay
- Decomposing composite solids
A VisuApp by heyprof: interactive, free in your browser, no sign-up. What is a VisuApp? · All apps