* R. William Gosper <rwg@osots.com> [Apr 20. 2005 20:46]:
[...]
Note that if we follow each Newton step with a true sqrt,
1 a + ------ n - 1 a n - 1 a = sqrt(---------------), n 2
with a a = sqrt(-), we get 0 b
agm(a, b) a a a . . . = ---------. 0 1 2 b
= agm(a/b, 1) =: agm(z, 1) = agm((1+z)/2, sqrt(z)) = = sqrt(z)*agm((1+sqrt(z)^2)/(2*sqrt(z), 1) which leads to the slightly more obvious a_0 = a/b, a_{n+1}=(a_n+1)/(2*sqrt(a_n)) sqrt( a_0 * a_1 * ...) = agm(a/b, 1) I tried a_{n+1}=(a_n+1)/(2*a_n) with a_0 = (1+x)/(1-x) and got the generating function for sequence 123: G.F.: prod(k=0,inf,(1+x^(2^k))/(1-x^(2^k)) G.F.: prod(k=0,inf,(1+x^(2^k))^(k+1))/(1-x) G.F.: prod(k=0,inf,(1+x^(2^k))^(k+2)) (Submitted but not yet in). -- p=2^q-1 prime <== q>2, cosh(2^(q-2)*log(2+sqrt(3)))%p=0 Life is hard and then you die.