Calculating the simple continued fraction of logba

This performs an algorithm from T.H. Jackson and K.R. Matthews, On Shanks' algorithm for computing the continued fraction of logba, Journal of Integer Sequences 5 (2002) article 02.2.7.
We run the algorithm for c = dr, r = m,...,n.
Here a, b, d, m, n are positive integers satisfying a > b > 1, d > 1 and 1 ≤ m ≤ n.

With d=b, we have found that apart from a few initial exceptional values of r, the correct partial quotients will be returned.
Moreover, with d = b and a = b + 1, it seems that the correct partial quotients are always returned.
For example,

This is a BCMath version of the BC program log

Enter a:
Enter b:
Enter d:
Enter m:
Enter n:

Last modified 21st March 2018
Return to main page