previous | start | next

## Simulations (Buffon Needle Experiment)

- Devised by Comte George-Louis Leclerc de Buffon.
- A needle of length 1 inch is dropped onto paper that is ruled with lines 2 inches apart.
- If the needle drops onto a line, we count it as a hit.
- The quotient tries / hits approximates pi.
- Our program randomly generates the lower point of the needle and an angle.
- The upper point of the needle is given by yhigh = ylow + sin(angle).
- If yhigh >= 2, we count the needle as a hit.

previous | start | next