# Gosper's unusual formula connecting $e$ and $\pi$

Wolfram MathWorld quotes (see equation $(26)$)

Gosper gives the unusual equation connecting $\pi$ and $e$ $$\sum_{n = 1}^{\infty}\frac{1}{n^{2}}\cos\left(\frac{9}{n\pi + \sqrt{n^{2}\pi^{2} - 9}}\right) = -\frac{\pi^{2}}{12e^{3}}\tag{1}$$

I did not find any references to a paper in which Gosper proved the above formula. I am perplexed by this cosine term in the formula and it does not seem to resemble any familiar series. A direct proof of this formula would be greatly appreciated. Or if someone knows Gosper's paper where this formula is established then do provide a link to that paper.

Update: We can see that $$\frac{9}{n\pi + \sqrt{n^{2}\pi^{2} - 9}} = n\pi - \sqrt{n^{2}\pi^{2} - 9}\tag{2}$$ and noting that $\cos(n\pi - \alpha) = (-1)^{n}\cos \alpha$ we can see that the formula of Gosper can be written as $$\sum_{n = 1}^{\infty}\frac{(-1)^{n}}{n^{2}}\cos\sqrt{n^{2}\pi^{2} - 9} = -\frac{\pi^{2}}{12e^{3}}\tag{3}$$ I think that the formula given by Gosper is probably a special case of a more general formula for the sum $$\sum_{n = 1}^{\infty}\frac{(-1)^{n}}{n^{2}}\cos\sqrt{n^{2}\pi^{2} + a^{2}}\tag{4}$$ (the formula $(3)$ corresponds to $a = 3i$). Looks like Gosper is also fond of strange formulas like Ramanujan.

• @ADG: As far as the expansion you provide is concerned, I see a problem there. When we divide by $n^{2}$ and try to sum up then we see that only the first term gives a convergent series and others lead to divergent series. – Paramanand Singh Feb 2 '15 at 3:37
• Gosper indeed seems to be fond of strange formulas like Ramanujan, and he apparently discovered some only to find out Ramanujan had discovered them years before. He was quoted as saying “Ramanujan reaches his hand from his grave to snatch your theorems from you.” here: books.google.com/…, and a similar quote appears on page 6 of this article: maths.unsw.edu.au/sites/default/files/… – Steve Kass Feb 2 '15 at 4:22
• @SteveKass: thanks for those links. – Paramanand Singh Feb 2 '15 at 4:40
• “Unusual”, but definitely not unintuitive. Expressions of the form $x+\sqrt{x^2-a^a}$ beg for a hyperbolic substitution of the form $x=a\cosh t.$ – Lucian Dec 12 '15 at 8:45

I know this general result: $$\displaystyle \sum_{k=1}^{\infty}\frac{\cos\bigl({k\pi-\sqrt{k^2\pi^2-a^2}\,}\bigr)}{k^2}=\frac{\pi^2}{12}\,\bigl({-\cosh(a)+\frac{3}{a}\sinh(a)}\bigr)$$
• I fixed a typo in the general result. It should be $-\cosh(a)$. – Tito Piezas III Oct 2 '16 at 11:29