Monte Carlo Pi Explorer
random points and convergence behavior
why error shrinks slowly 🖖
Monte Carlo error shrinks proportional to 1/√N, not 1/N — a consequence of the Central Limit Theorem, since the estimate is an average of N independent inside/outside coin flips whose variance falls as 1/N. That square root is expensive: gaining one more correct decimal digit takes roughly 100× more points, not 10×, which is why the point cloud can look convincingly circular long before the digits stop wobbling. It's also why this method rarely gets used just to compute π in practice — it earns its keep on high-dimensional integrals, where deterministic grid methods scale exponentially with dimension but Monte Carlo's 1/√N rate doesn't care how many dimensions you're in.
a fixed answer from pure luck 🖖
Here is the strange part: π is a fixed, exact number, yet this tool pins it down using nothing but chance. Each single point lands unpredictably, inside or outside the circle by luck alone. But their running average behaves — the Law of Large Numbers guarantees that as you pile on points, the noisy fraction settles toward one stable value. The takeaway: randomness, averaged in bulk, becomes a dependable measuring instrument.
the needle that cheated 🖖
Long before points on a screen, Buffon's needle (1777) estimated π by dropping needles across evenly spaced lines — arguably the first Monte Carlo experiment. In 1901 Mario Lazzarini reported that 3,408 tosses gave π = 3.1415929, right to six decimals. The catch: that is exactly 355/113, a famous old approximation, and 3,408 is suspiciously the precise number of throws needed to hit it — he almost certainly stopped the instant luck matched the target.