# Calculate an infinite continued fraction

Is there a way to algebraically determine the closed form of any infinite continued fraction with a particular pattern? For example, how would you determine the value of $$b+\cfrac1{m+b+\cfrac1{2m+b+\cfrac1{3m+b+\cdots}}}$$?

Edit (2013-03-31):

When $m=0$, simple algebraic manipulation leads to $b+\dfrac{\sqrt{b^2+4}}{4}$. The case where $m=2$ and $b=1$ is $\dfrac{e^2+1}{e^2-1}$, and I've found out through WolframAlpha that the case where $b=0$ is an expression related to the Bessel function: $\dfrac{I_1(\tfrac2m)}{I_0(\tfrac2m)}$. I'm not sure why this happens.

• What do you mean by closed form? What form do you want? – Ethan Mar 27 '13 at 5:50
• The $m$ increments linearly or as a multiple of $2$? – hjpotter92 Mar 27 '13 at 5:51
• @Ethan: Closed form, represented in terms of finitely many elementary functions, not as a recursive expression. – Fernando Martínez Mar 27 '13 at 5:59
• @BackinaFlash: The $m$ increments linearly. – Fernando Martínez Mar 27 '13 at 6:00
• Continued fractions of this form tend to be related to hypergeometric functions. The best example I could find right now is en.wikipedia.org/wiki/… ... when $b=-1$ and $m=2$, you get $\tanh1-1 = -2/(1+e^2)$. – Greg Martin Mar 27 '13 at 8:01

You can start from the difference equation for the modified Bessel functions:

$$Z_{n+1}(x)=-\frac{2n}{x}Z_n(x)+Z_{n-1}(x)$$

Let $x=\dfrac2{m}$:

$$Z_{n+1}\left(\frac2{m}\right)=-nm\,Z_n\left(\frac2{m}\right)+Z_{n-1}\left(\frac2{m}\right)$$

Divide both sides of the recurrence with $Z_n\left(\frac2{m}\right)$ and rearrange:

$$\frac{Z_n\left(\tfrac2{m}\right)}{Z_{n-1}\left(\tfrac2{m}\right)}=\cfrac1{nm+\cfrac{Z_{n+1}\left(\tfrac2{m}\right)}{Z_n\left(\tfrac2{m}\right)}}$$

Now, replace $n$ with $n+\frac{b}{m}$:

$$\frac{Z_{n+\tfrac{b}{m}}\left(\tfrac2{m}\right)}{Z_{n+\tfrac{b}{m}-1}\left(\tfrac2{m}\right)}=\cfrac1{nm+b+\cfrac{Z_{n+\tfrac{b}{m}+1}\left(\tfrac2{m}\right)}{Z_{n+\tfrac{b}{m}}\left(\tfrac2{m}\right)}}$$

One can do something similar for $\cfrac{Z_{n+\tfrac{b}{m}+1}\left(\tfrac2{m}\right)}{Z_{n+\tfrac{b}{m}}\left(\tfrac2{m}\right)}$; iterating this transformation yields the CF

$$\frac{Z_{n+\tfrac{b}{m}}\left(\tfrac2{m}\right)}{Z_{n+\tfrac{b}{m}-1}\left(\tfrac2{m}\right)}=\cfrac1{nm+b+\cfrac1{(n+1)m+b+\cfrac1{(n+2)m+b+\cdots}}}$$

Letting $n=1$, we have

$$\frac{Z_{\tfrac{b}{m}+1}\left(\tfrac2{m}\right)}{Z_{\tfrac{b}{m}}\left(\tfrac2{m}\right)}=\cfrac1{m+b+\cfrac1{2m+b+\cfrac1{3m+b+\cdots}}}$$

Now, $Z$ can either be $I$ (first kind) or $K$ (second kind) (or a linear combination of those two); we use a big gun to decide which of the two solutions of the modified Bessel recurrence should be taken, in the form of Pincherle's theorem. Before using Pincherle's theorem, though, we have to make sure that the continued fraction we are dealing with is convergent; one could use, e.g. Śleszyński–Pringsheim to show that the continued fraction being considered is indeed well-defined.

Having shown the convergence, Pincherle says that $Z$ should be the so-called minimal solution of the modified Bessel recurrence. Roughly speaking, the minimal solution of a difference equation is the unique solution that "decays" as the index $n$ increases (all the other solutions, meanwhile, are termed dominant solutions).

The asymptotics of $I$ and $K$ show that $I$ is the minimal solution; thus Pincherle says that

$$\frac{I_{\tfrac{b}{m}+1}\left(\tfrac2{m}\right)}{I_{\tfrac{b}{m}}\left(\tfrac2{m}\right)}=\cfrac1{m+b+\cfrac1{2m+b+\cfrac1{3m+b+\cdots}}}$$

Your desired continued fraction is not too hard to obtain from this form.

(This solution is more or less an adaptation of the method presented here to more general arithmetic progressions.)

Reference:

D. H. Lehmer, "Continued fractions containing arithmetic progressions", Scripta Mathematica vol. 29, pp. 17-24

Theorem 1: $$b+\frac{1}{a+b\quad+}\quad\frac{1}{2a+b\quad+}\quad\frac{1}{3a+b\quad+}\quad\dots = \frac{I_{b/a-1}(2/a)}{I_{b/a}(2/a)}$$

Theorem 2 $$b-\frac{1}{a+b\quad-}\quad\frac{1}{2a+b\quad-}\quad\frac{1}{3a+b\quad-}\quad\dots = \frac{J_{b/a-1}(2/a)}{J_{b/a}(2/a)}$$

and other results...