I have seen the following formula in papers (without citations) and in Mathematica's documentation about Tanh[]:
$$ \frac{\tanh(z)}{8z}=\sum_{k=1}^{\infty} \frac{1}{(2k-1)^2 \pi^2+4z^2} $$
I have no idea how to prove it and I have also encountered in my research similar sums involving, for instance, $\mathrm{coth}$. It would be nice to have a general method for working with these problems; any suggestions?
There is the infinite product representation
$$\cosh\,z=\prod_{k=1}^\infty \left(1+\frac{4z^2}{\pi^2(2k-1)^2}\right)$$
Taking logarithms gives
$$\log\cosh\,z=\sum_{k=1}^\infty \log\left(1+\frac{4z^2}{\pi^2(2k-1)^2}\right)$$
If we differentiate both sides, we have
$$\tanh\,z=\sum_{k=1}^\infty \frac{\frac{8z}{\pi^2(2k-1)^2}}{1+\frac{4z^2}{\pi^2(2k-1)^2}}$$
which simplifies to
$$\tanh\,z=\sum_{k=1}^\infty \frac{8z}{4z^2+\pi^2(2k-1)^2}$$
Note that the infinite product that we started with is the factorization of $\cosh$ over its (imaginary) zeroes.
Here is a related question.