All examples By author By category About

cjburgoyne

Estimating Pi

This is a visual explanation of how Monte Carlo methods can be used to estimate the value of Pi. It is a circle inscribed within a square. Click the button to simulate the dropping of 1000 needles randomly across the square. An estimate of Pi is calculated based on the proportion of points that fall within the circle. Repeating this simulation many times and averaging the results will yield a fairly accurate approximation of the true value of Pi.