Let $$ \text{S}_k = \sum_{n=1}^\infty\cfrac{1}{1+\cfrac{n^2}{1+\cfrac{1}{\ddots1+\cfrac{1}{1+n^2}}}},\quad\text{$k$ rows in the continued fraction} $$ So for example, the terms of the sum $\text{S}_6$ are $$ \cfrac{1}{1+\cfrac{n^2}{1+\cfrac{1}{1+\cfrac{1}{1+\cfrac{1}{1+\cfrac{1}{1+n^2}}}}}} $$ Using a symbolic computation software (Mathematica), I got the following interesting results: $$ \begin{align} \text{S}_4 &= \frac{\pi}{4}\left(\coth(\pi)+\sqrt{3}\coth(\sqrt{3}\pi)\right)-\frac{1}{2}\\ \text{S}_6 &= \frac{\pi}{4}\left(\sqrt{2}\coth\left(\sqrt{2}\pi\right)+\sqrt{\frac{4}{3}}\coth\left(\sqrt{\frac{4}{3}}\pi\right)\right)-\frac{1}{2}\\ \text{S}_8 &= \frac{\pi}{4}\left(\sqrt{\frac{3}{2}}\coth\left(\sqrt{\frac{3}{2}}\pi\right)+\sqrt{\frac{7}{4}}\coth\left(\sqrt{\frac{7}{4}}\pi\right)\right)-\frac{1}{2}\\ \text{S}_{10} &= \frac{\pi}{4}\left(\sqrt{\frac{5}{3}}\coth\left(\sqrt{\frac{5}{3}}\pi\right)+\sqrt{\frac{11}{7}}\coth\left(\sqrt{\frac{11}{7}}\pi\right)\right)-\frac{1}{2}\\ \text{S}_{12} &= \frac{\pi}{4}\left(\sqrt{\frac{8}{5}}\coth\left(\sqrt{\frac{8}{5}}\pi\right)+\sqrt{\frac{18}{11}}\coth\left(\sqrt{\frac{11}{7}}\pi\right)\right)-\frac{1}{2}\\ \text{S}_{14} &= \frac{\pi}{4}\left(\sqrt{\frac{13}{8}}\coth\left(\sqrt{\frac{13}{8}}\pi\right)+\sqrt{\frac{29}{18}}\coth\left(\sqrt{\frac{29}{18}}\pi\right)\right)-\frac{1}{2}.\\ \end{align} $$

The numbers appearing at the first $\coth$ term are easy to guess: they are the famous Fibonacci numbers.

The numbers at the second $\coth$ term can also be guessed: they appear to be the Lucas numbers. Those are constructed like the Fibonacci numbers but starting with $2,1$ instead of $0,1$.


Conjecture: $$\text{S}_{2k}=\frac{\pi}{4}\left(\sqrt{\frac{F_k}{F_{k-1}}}\coth\left(\sqrt{\frac{F_k}{F_{k-1}}}\pi\right)+\sqrt{\frac{L_k}{L_{k-1}}}\coth\left(\sqrt{\frac{L_k}{L_{k-1}}}\pi\right)\right)-\frac{1}{2}$$

I have verified this conjecture for many $k$'s and it always work out perfectly. To me this is quite amazing, but I am not able to verify the conjecture. Can anyone prove it?

Moreover, if true the conjecture implies that


which is also very nice ($\pi$ and $\varphi$ don't meet very often).

Simon Parker
  • 4,083
  • 2
  • 15
  • 23
  • 1
    Which program, and how hard was it for you to get it to give these results. Also, why did you start investigating these sums? They look very Ramanujanish. – marty cohen Jan 11 '15 at 03:53
  • Was it really necessary to nest everything that deeply? – Daniel W. Farlow Jan 13 '15 at 18:08
  • If someone has a better way to TeX this I would be happy to take his suggestion. – Simon Parker Jan 13 '15 at 18:11
  • Perhaps using the Gauß K notation for continued fractions might be better? http://en.wikipedia.org/wiki/Continued_fraction – Gahawar Jan 16 '15 at 13:24
  • I suspect that this is the sort of thing that using some property of linear recurrences one could make an argument of the sort, "It holds for the first $n$ terms, therefore it holds everywhere", however I can't quite form an argument off of that. (So I posted a really inelegant answer instead) – Milo Brandt Jan 19 '15 at 01:46

3 Answers3


This is again only a part of a proof, because I believe I made a mistake somewhere along the line. Anyway, we'll start from this equation $$ \frac{1}{1+\frac{n^2}{1+\frac{1}{1+\frac{\ddots}{1+\frac{1}{1+\frac{1}{1+n^2}}}}}}=\frac{F_{k-1}\:n^2+F_{k}}{F_{k-2}\:n^4+2F_{k-1}\:n^2+F_{k}} $$ where k is equal to the number of horizontal lines on the left hand side. user109899 went off of the same premise, but we'll change it up a little. Let's start by partially factoring the denominator on the right hand side. $$ \frac{1}{F_{k-2}\:n^4+2F_{k-1}\:n^2+F_{k}}=\frac{1}{(F_{(k-2)/2}\:n^2+F_{k/2})(L_{(k-2)/2}\:n^2+L_{k/2})} $$ This follows from the fact that $$ F_{n}+F_{n+2}=L_{n+1} $$ Now we need the complex roots of each term. On the left hand side, these are $$ \pm \:i\sqrt{\frac{F_{k/2}}{F_{(k-2)/2}}} $$ And on the right side these are just $$ \pm \:i\sqrt{\frac{L_{k/2}}{L_{(k-2)/2}}} $$ At this point I'm also going to define a couple of variables to represent these roots in a way that we can more easily work with. $$ a_1=\sqrt{\frac{F_{k/2}}{F_{(k-2)/2}}} $$ $$ a_2=\sqrt{\frac{L_{k/2}}{L_{(k-2)/2}}} $$ If we plug these roots back into the equation from the first step, we get an equation that looks like this $$ f(n)=\frac{F_{k-1}\:n^2+F_{k}}{(n+ia_1)(n-ia_1)(n+ia_2)(n-ia_2)} $$ For a more detailed description of this next step, read [this][1] thread. I won't explain this much since it's already shown there, but we need to find the residues of an equation $g(z):=\pi cot(\pi z)\:f(n)$ with poles at $\pm\:ia_1$ and $\pm\:ia_2$ (Note that the residue for each pole is identical to its opposite pole because $\coth$ is an odd function). $$ b_{a1}=\frac{\pi(F_{k-1}\:a_1^2-F_{k})\:\coth(\pi a_1)}{2a_1(ia_1+ia_2)(ia_1-ia_2)}=-\frac{\pi(F_{k-1}\:a_1^2-F_{k})\:\coth(\pi a_1)}{2a_1(a_1^2-a_2^2)} $$ $$ b_{a2}=\frac{\pi(F_{k-1}\:a_2^2-F_{k})\:\coth(\pi a_2)}{2a_2(ia_2+ia_1)(ia_2-ia_1)}=-\frac{\pi(F_{k-1}\:a_2^2-F_{k})\:\coth(\pi a_2)}{2a_2(a_2^2-a_1^2)} $$ We can then plug $f(x)$ into an infinite sum to evaluate it based upon these residues. $$ \sum_{n=-\infty}^{\infty}\frac{F_{k-1}\:n^2+F_{k}}{(n^2+a_1^2)(n^2+a_2^2)}=-(2b_{a1}+2b_{a2})=$$$$\frac{\pi(F_{k-1}\:a_1^2-F_{k})\:\coth(\pi a_1)}{a_1(a_1^2-a_2^2)}+\frac{\pi(F_{k-1}\:a_2^2-F_{k})\:\coth(\pi a_2)}{a_2(a_2^2-a_1^2)} $$ Using the identity $F_k-F_{k+1}\frac{F_{k/2}}{F_{(k+1)/2}}=-1$ and $F_k-F_{k+1}\frac{L_{k/2}}{L_{(k+1)/2}}=1$ for odd k, we can simplify this a bit further. $$ \small{\pi\left (F_{k-1}-\frac{F_{k}}{a_1^2}-\frac{F_{k-1}\:a_1^2-F_{k}}{a_2^2}\right )\:a_1\coth(\pi a_1)+\pi\left (F_{k-1}-\frac{F_{k}}{a_2^2}-\frac{F_{k-1}\:a_2^2-F_{k}}{a_1^2}\right )\:a_2\coth(\pi a_2)=} $$$$ \pi\left (\left (-1-\frac{F_{k-1}\:a_1^2-F_{k}}{a_2^2}\right )a_1\coth(\pi a_1)+\left (1-\frac{F_{k-1}\:a_2^2-F_{k}}{a_1^2}\right )a_2\coth(\pi a_2)\right ) $$ Because the original function is symmetric for negative $n$, we can subtract the zero term and divide the result by two in order to get the sum from 1 to infinity. $$ \frac{F_{k-1}\:0^2+F_{k}}{F_{k-2}\:0^4+2F_{k-1}\:0^2+F_{k}} = 1 $$ $$ \small{\sum_{n=1}^{\infty}\frac{F_{k-1}\:n^2+F_{k}}{(n^2+a_1^2)(n^2+a_2^2)}=\frac{\pi\left (\left (-1-\frac{F_{k-1}\:a_1^2-F_{k}}{a_2^2}\right )a_1\coth(\pi a_1)+\left (1-\frac{F_{k-1}\:a_2^2-F_{k}}{a_1^2}\right )a_2\coth(\pi a_2)\right ) - 1}{2}}= $$ $$ \small{\frac{\pi}{2}\left (\left (-1-\frac{F_{k-1}\:a_1^2-F_{k}}{a_2^2}\right )a_1\coth(\pi a_1)+\left (1-\frac{F_{k-1}\:a_2^2-F_{k}}{a_1^2}\right )a_2\coth(\pi a_2)\right ) - \frac{1}{2}} $$ Not-so-simple algebra and applying certain properties of fibonacci numbers shows that $$ -1-\frac{F_{k-1}\:\frac{F_{k/2}}{F_{k/2-1}}-F_{k}}{\frac{L_{k/2}}{L_{k/2-1}}}=-\frac{2}{F_{k-1}+1} $$and similarly$$ 1-\frac{F_{k-1}\:\frac{L_{k/2}}{L_{k/2-1}}-F_{k}}{\frac{F_{k/2}}{F_{k/2-1}}}=-\frac{2F_{k-1}}{F_{k-1}-1} $$ Plugging these values into the equation now gives $$ \frac{\pi}{2}\left (\left (-\frac{2}{F_{k-1}+1}\right )a_1\coth(\pi a_1)+\left (-\frac{2F_{k-1}}{F_{k-1}-1}\right )a_2\coth(\pi a_2)\right ) - \frac{1}{2} $$ At this point, if we expand the variables, we get $$ \small{\frac{\pi}{2}\left (\left (-\frac{2}{F_{k-1}+1}\right )\sqrt{\frac{F_{k/2}}{F_{k/2-1}}}\coth\left (\sqrt{\frac{F_{k/2}}{F_{k/2-1}}}\pi \right )+\left (-\frac{2F_{k-1}}{F_{k-1}-1}\right )\sqrt{\frac{L_{k/2}}{L_{k/2-1}}}\coth\left (\sqrt{\frac{L_{k/2}}{L_{k/2-1}}}\pi \right )\right ) - \frac{1}{2}} $$ Which is very similar to your original equation, but is not the same. I think I must have made a mistake in my math somewhere, but hopefully this helps in finding a correct proof. I've spent over half a day on this equation now, though, so I'll leave that to someone else :-)

Ethan MacBrough
  • 1,821
  • 10
  • 18
  • Thanks a lot for this detailed analysis. I am sorry that it didn't quite work out. – Simon Parker Jan 13 '15 at 16:06
  • 1
    Maybe the identity $$ -1-\frac{F_{k-1}\:\frac{F_{k/2}}{F_{k/2-1}}-F_{k}}{\frac{L_{k/2}}{L_{k/2-1}}}=-\frac{2}{F_{k-1}+1} $$ is false. Based on some numerical it is approximately $-2-\frac{10}{3F_k}$ for $k$ (even) not divisible by $4$, and $-\frac{10}{3F_k} for $k$ divisible by $4$. – Thijs Jan 16 '15 at 13:49
  • 1
    Also you use the identity $F_k-F_{k+1}\frac{F_{k/2}}{F_{(k+1)/2}}=-1$, but $k/2$ and $(k+1)/2$ cannot both be integer. I don't understand the equation directly below the quoted identity. Excuse the formatting in my other, I can't edit it, because it took me longer than 5 minutes to write. – Thijs Jan 16 '15 at 13:58

This answer contains computer-assisted algebra bashing. Pencil wielding mathematicians be warned.

Let $$f_k(n)=\frac{1}{1+\frac{n^2}{1+\frac{1}{\frac{^\ddots_1}{1+n^2}}}}$$ where there are $2k$ horizontal fraction bars. Then, we have $$f_2(n)=\frac{1}{1+\frac{n^2}{1+\frac{1}{1+\frac{1}{1+n^2}}}}=\frac{\frac{1}2}{n^2+1}+\frac{\frac{3}2}{n^2+3}$$ $$f_{k+1}(n)=\frac{1}{1+\frac{n^2}{1+\frac{1}{1+\frac{\frac{1}{f_k(x)}-1}{n^2}}}}$$ where the first identity can be checked by Mathematica and the second is pretty obvious, if you think about undoing the top of the fraction, adding a bit in the middle, then redoing the top.

Next, suppose we have $$f_k(n)=\frac{\frac{\alpha}2}{n^2+\alpha}+\frac{\frac{\beta}2}{n^2+\beta}$$ where $\alpha=\frac{F_{k}}{F_{k-1}}$ and $\beta=\frac{L_{k}}{L_k-1}$. This is true for $k=2$. We can prove it inductively in a very elegant way by substituting in Binet's formula to get $$\alpha=\frac{\varphi^n-(1-\varphi)^n}{\varphi^{n-1}-(1-\varphi)^{n-1}}$$ $$\beta=\frac{\varphi^n+(1-\varphi)^n}{\varphi^{n-1}+(1-\varphi)^{n-1}}$$ and then plugging the whole mess for $f_k$ into the recurrence relation, setting it equal to $f_{k+1}$ and letting FullSimplify look at it and shrug tell you this is equivalent to a certain rational expression equaling zero, which is, after multiplying out the denominator* $$2 \left(-2+\sqrt{5}\right) \left(\left(6-2 \sqrt{5}\right)^{2 k}-\left(-1+\sqrt{5}\right)^{4 k}\right) e^{i k \pi } n+2 \left(-3+\sqrt{5}\right) \left(\left(6-2 \sqrt{5}\right)^{2 k}-\left(-1+\sqrt{5}\right)^{4 k}\right) e^{i k \pi } n^3+\left(-1+\sqrt{5}\right) \left(\left(6-2 \sqrt{5}\right)^{2 k}-\left(-1+\sqrt{5}\right)^{4 k}\right) e^{i k \pi } n^5=0$$ which looks pretty nasty, and even though Mathematica can't seem to handle it itself, we can solve it pretty easily; it comes down to showing that each coefficient vanishes; in particular we could factor out the following expression from each term $$\left(6-2 \sqrt{5}\right)^{2 k}-\left(-1+\sqrt{5}\right)^{4 k}$$ however, notice that $(-1+\sqrt{5})^2=6-2\sqrt{5}$ so the expression equals $$(6-2\sqrt{5})^{2k}-(6-2\sqrt{5})^{2k}=0.$$ This, along with the assumption that Mathematica's reductions suffice to complete the inductive proof that $$f_k(n)=\frac{\frac{\alpha}2}{n^2+\alpha}+\frac{\frac{\beta}2}{n^2+\beta}$$ with $\alpha=\frac{F_k}{F_{k-1}}$ and $\beta=\frac{L_k}{L_{k-1}}$.

Then, your conjecture follows immediately from the identity $$\sum_{n=1}^{\infty}\frac{1}{n^2+c}=\frac{\pi\sqrt{c}\coth(\pi\sqrt{c})-1}{2c}.$$

*The denominator is a non-constant polynomial in $n$, which can only be $0$ at finitely many points for a fixed $k$. Thus this proof shows that the desired equality holds for all but finitely many points, and, since two rational functions agreeing at countably many points are clearly equal, this suffices and we can therefore safely ignore the denominator.

Milo Brandt
  • 58,703
  • 5
  • 98
  • 184

This is not a full answer but a partial result.

You can prove by induction that the described fraction of yours with $k$ horizontal lines is equal to $\frac{F_{k-1}n^2+F_{k}}{F_{k-2}n^4+2F_{k-1}n^2+F_k}$ with $k\ge3$. Perhaps with partial fractioning, you can compute the series using the well known result: $$ \sum_{n=1}^{\infty}\frac{1}{n^2+z^2}=\frac{\pi z\coth(\pi z)-1}{2z^2} $$ As a partial result you can compute the limit directly: $$ \lim_{k\to\infty}\frac{F_{k-1}n^2+F_{k}}{F_{k-2}n^4+2F_{k-1}n^2+F_k}=\lim_{k\to\infty}\frac{F_{k-1}}{F_{k-2}}\frac{n^2+\frac{F_{k}}{F_{k-1}}}{n^4+2\frac{F_{k-1}}{F_{k-2}}n^2+\frac{F_k}{F_{k-2}}}=\varphi\frac{n^2+\varphi}{n^4+2\varphi n^2+\varphi^2}=\frac{\varphi}{n^2+\varphi} $$ And therefore: $$ \lim_{k\to\infty}\sum_{n=1}^\infty\frac{1}{1+\frac{n^2}{1+\frac{1}{\stackrel{\ddots}{1+\frac{1}{1+n^2}}}}}=\sum_{n=1}^{\infty}\frac{\varphi}{n^2+\varphi}=\varphi\frac{\pi \sqrt{\varphi}\coth(\pi \sqrt{\varphi})-1}{2\varphi}=\frac{\pi \sqrt{\varphi}\coth(\pi \sqrt{\varphi})-1}{2} $$ I hope this is helpful.

Redundant Aunt
  • 11,320
  • 2
  • 18
  • 63