|
pi Approximation #2
Home
| Current x |
.
|
Current x coordinate of dot
|
| Current y |
.
|
Current y coordinate of dot
|
| x2 + y2 |
.
|
(dot radius)2 = x2 + y2
|
| Inside Circle? |
.
|
(dot radius)2 < 12 ?
|
| Official pi |
.
|
Textbook value of pi
|
| Estimated pi |
.
|
(Dots In Circle) / Dots x 4
|
| Error |
.
|
(Official pi) - (Estimated pi)
|
| Error Percent |
.
|
Error / (Official pi) x 100
|
|
Size of sampling grid
|