I promise this is my last post on the now week and a half old π pay! Building on the last post, I figured I could show how convergence actually works in the estimation algorithm. If you’ll recall, we plotted a number of x,y pairs inside a square inscribing a quarter circle. The ratio of those points inside the quarter circle to the overall number of points plotted was an estimate of pi. How good depended strongly on the number of points plotted. In fact the simplest method of estimation involves plotting thousands of points in one round, no iteration at all. But breaking the points into rounds can give us a neat look at how quickly the average will converge on pi and where the points themselves are plotted. So below the jump (a backsidesmack first!) I present a highly caffeinated animation of the process:
|From pi day|
Code is in the last pi day post or online at github.