The general continued fraction a0 + b1/(a1+) b2/(a2+) b3/(a3+...) is associated with the product of matrices [an bn] [ 1 0] whose eigenvalues are [a + sqrt(a*a+4*b)]/2 and -2*b / [a + sqrt(a*a+4*b)] and in most cases where an and bn depend "smoothly enough" on n these eigenvalues will govern convergence speed. So for example, the continued fractions I mentioned in a previous post were F1(z) = (sqrt(pi)/2)*erfc(z) F2(z) = (sqrt(pi)/2)*erf(z) so that for any z>0 we have sqrt(pi)/2 = F1(z) + F2(z) and F1(z) = exp(-z^2) * 1/(2z+) 2/(2z+) 4/(2z+) 6/(2z+) 8/(2z+...) F2(z) = exp(-z^2) * z/(1-x+) (2x/(3-x+)) (4x/(5-2x+)) (6x/(7-2x+)) (8x/((9-2x+...) where x=2*z*z. The F1 continued fraction's convergence then is governed by the eigenvalues of [2z 2n] [ 1 0] or more precisely by the |ratio| of the eigenvalues, when n-->infinity. This ratio is e1/e2 where e1 = z + sqrt(z*z+2*n) e2 = -2*n / (z+sqrt(z*+2*n)) ratio = -1 - sqrt(2*z/n) - z*z/n + O(n^(-3/2)) and hence the convergence ultimately is slow, specifically after n decks of the F1 continued fraction we expect error of order exp(-const*sqrt(n)) i.e. order sqrt(n) correct decimal places. This is "slower than geometric" albeit still fast enough to get polynomial time. The F2 continued fraction's convergence similarly is governed by the eigenvalues of [2*n+1-2*x 2*n*x] [1 0 ] yielding ratio = -2*n/x - 2*(1-x)/x - O(n^(-1)) which predicts ultimately very rapid, factorial style, convergence, namely n decks ought to yield error of order (x/2)^n / n!. Now returning for a more careful look at the slow continued fraction F1, its eigenvalue ratio is exactly - (z + sqrt(z*z+2*n)) / (2*n) which for large n ultimately sucks, i.e. approaches -1; but if z is large then you can get fast convergence for quite a while, only slowing down once n reaches order z. So if we only use about z terms of the F1 continued fraction with z large, then we expect error of order 1/z! very roughly. Remember, for the purpose of computing pi, we are free to choose any z we like in an effort to get faster speed. Choosing large z makes the F1 fraction converge faster at least initially. Unfortunately large z makes the F2 fraction converge slower! You need n of order x or more before the ultimate fast convergence sets in where x=2*z*z. -- Warren D. Smith http://RangeVoting.org <-- add your endorsement (by clicking "endorse" as 1st step)