# How to derive the formula for $\sum_{n=0}^{\infty}\tan^{-1}(\frac{x^{2}}{n^{2}})$ [duplicate]

How to derive the formula $$\sum_{n=1}^{\infty}\tan^{-1}\left(\frac{x^{2}}{n^{2}}\right)=\tan^{-1}\left[\frac{\tan\left(\frac{x\pi}{\sqrt{2}}\right)-\tanh\left(\frac{x\pi}{\sqrt{2}}\right)}{\tan\left(\frac{x\pi}{\sqrt{2}}\right)+\tanh\left(\frac{x\pi}{\sqrt{2}}\right)}\right]$$

Is the formula correct? How do I derive the above formula? I tried to apply the formula integral as the limit of sum formula.

## marked as duplicate by alexjo, MathOverview, Ben Sheller, Shailesh, Simply Beautiful ArtOct 7 '17 at 0:36

• When you ask "is the formula correct?" do you have any reason to believe it is correct or incorrect? What have you tried so far? Some context would help – TomGrubb Oct 6 '17 at 16:07
• Maybe index starts at $n=1$ – Raffaele Oct 6 '17 at 16:42

I'd start that sum at $n=1$ if I were you.
Now, up to multiples of $\pi$, $$\sum_{n=1}^\infty\tan^{-1}\frac{x^2}{n^2}$$ is the argument of the complex number $$\prod_{n=1}^\infty\left(1+\frac{ix^2}{n^2}\right).$$
But $$\prod_{n=1}^\infty\left(1-\frac{z^2}{n^2}\right)=\frac{\sin\pi z}{\pi z}$$ so how about choosing $z$ to make $-z^2=ix^2$?