Re: [math-fun] Another approximation of pi
DWilson>I would tend to group approximations into two general categories: Definition-based approximations, which follow mathematical properties, for example π ~= 3 π ~= ln(640320^3+744)/sqrt(163) The first follows from the approximate equality of the perimeter of a circle and its circumscribed hexagon, the second follows from a truncated series expansion in class theory. There are reasons for these approximations. Value-based approximations have no apparent direct relationship to mathematical definitions. For example, π ~= 22/7 π ~= 355/113 π ~= sqrt(9.87) π ~= cbrt(10) π^4 + π^4 ~= e^6 e^π - π ~= 20 all seem to be value-based. These relationships are commonly found by observation or numerical analysis of the numerical values, not derived from mathematical properties. This is clearly a subjective distinction. Tomorrow we may find reasons for approximations that baffle us today. ---------------- E.g., where would you put Out[426]= 22/7 + Sin[22/7] In[427]:= N[% - π, 2] Out[427]= 3.4*10^-10 ?-) rwg
On Sun, Oct 14, 2012 at 11:45 PM, Bill Gosper <billgosper@gmail.com> wrote:
E.g., where would you put
Out[426]= 22/7 + Sin[22/7]
In[427]:= N[% - π, 2] Out[427]= 3.4*10^-10
?-) rwg
In the numerical category: The function f(x) = cot(x/2) has a 0 at pi, and by the continued fraction, 22/7 is a convergent to pi (and thus a good approximation). If you plug f(x) into Newton's method, you get the iteration: x --> x + sin(x). Admittedly the approximation that you get from this is much better than you'd expect in the generic Newton. Victor
In thinking about this more, the goodness of the approximation of this iteration isn't that surprising. If you're looking for a zero of a function f(x) by Newton, and you're close, then if epsilon is the error before you iterate, the error after you iterate is something like (1/2)*|f''(\xi)/f'(\xi)|*epsilon^2, where \xi is close to the your input value. However, in the case that f(x) = cot(x/2), we have f''(x)/f'(x) = - cot(x/2) which has a zero at x = pi. Thus we should expect something like cubic convergence in this case, instead of the more normal quadratic convergence. Very clever, Bill. Victor On Mon, Oct 15, 2012 at 12:18 PM, Victor Miller <victorsmiller@gmail.com>wrote:
On Sun, Oct 14, 2012 at 11:45 PM, Bill Gosper <billgosper@gmail.com>wrote:
E.g., where would you put
Out[426]= 22/7 + Sin[22/7]
In[427]:= N[% - π, 2] Out[427]= 3.4*10^-10
?-) rwg
In the numerical category: The function f(x) = cot(x/2) has a 0 at pi, and by the continued fraction, 22/7 is a convergent to pi (and thus a good approximation). If you plug f(x) into Newton's method, you get the iteration: x --> x + sin(x). Admittedly the approximation that you get from this is much better than you'd expect in the generic Newton.
Victor
participants (2)
-
Bill Gosper -
Victor Miller