Office for Mathematics, Science, and Technology Education
College of Education @ University of Illinois
MSTE: Celebrating 25 years!

Estimation of Pi

This applet is designed to approximate the value of pi. It accomplishes this purpose by firing random data points at a circle inscribed within a square. The probability of a data point landing within the circle is a ratio of the circle's area to the area of the square.

Where r equals the length of the radius of the circle, the area of the circle is then π*r*r. The diameter of the circle is the same as the length of each side of the square. Since the diameter of the circle, twice the radius, equals (2*r), the area of the square is equal to (2*r)*(2*r).

The probability of a point landing within the circle equals (π*r*r)/(2*r*2*r). By then performing algebra and removing (r*r) from the numerator and the denominator the simplified equation becomes P(landing in circle) = π/4.

Next, multiply both sides by 4.

Pi is now equivalent to four times the probability of a data point landing in the circle.


We're sorry, your browser does not support HTML5 Canvas...
Loading, please wait...

Number of Drops
Number of Hits
Hits / Drops
π ≈ 4 * Hits / Drops

Simulation Credits

  • Original Java Applet by Nick Exner (1998)
  • JavaScript+HTML5 Remake by Evan Ramos (2014)

Social Media Links:

Connect with us

Additional navigation options:

© 1994-2018 MSTE | Privacy Policy
505 East Green St., Suite 102, Champaign, IL 61820 | (217) 244-7486