Arnold's Trivium problem 51 
Calculate $$ f(k) = \int_{-\infty}^{+\infty} e^{ikx}\frac{1 - e^x}{1+e^x}dx.$$

As far as I know, this is not a function but rather the Fourier transform in tempered distributions.

1) What is a rigorous proof of Arnold's problem ?
2) How people usually use and manipulate Fourier Transform of tempered distributions ?

Edit : Thx a lot to joriki and sos440 for two very nice and rigorous proofs.
To summarize, 
joriki's idea is to get a regular integral by derivation and then using the Rediues Theorem ;
while sos440 is removing the 'constant' term that makes the integral diverge and treat it seperatly.
If anyone has another different method, I'd be glad.
 A: We divide the integral into two parts:
\begin{align*}
f(k)
&= \int_{\Bbb{R}} \mathrm{sgn}(x) e^{-ikx} \, dx + \int_{\Bbb{R}} e^{-ikx} \left( \frac{1-e^{-x}}{1+e^{-x}} - \mathrm{sgn}(x) \right) \, dx
\end{align*}
The first one can be easily computed by integration by parts as follows:
\begin{align*}
\int_{\Bbb{R}} \mathrm{sgn}(x) e^{-ikx} \, dx
&= -\int_{\Bbb{R}} 2\delta(x) \frac{e^{-ikx}}{-ik} \, dx
 = -\frac{2i}{k}.
\end{align*}
Indeed, this manipulation can be justified in the context of tempered distributions. (Just observe what happens when the Fourier transform and the differentiation are interchanged.)
The remaining part is now integrable in ordinary sense, and we have
\begin{align*}
\int_{\Bbb{R}} e^{-ikx} \left( \frac{1-e^{-x}}{1+e^{-x}} - \mathrm{sgn}(x) \right) \, dx
&= 4i \int_{0}^{\infty} \frac{\sin (kx) \, e^{-x}}{1+e^{-x}} \, dx \\
&= 4i \sum_{n=1}^{\infty}(-1)^{n-1} \int_{0}^{\infty} \sin (kx) \, e^{-nx} \, dx \\
&= 4i \sum_{n=1}^{\infty}(-1)^{n-1} \frac{k}{k^2 + n^2}
\end{align*}
Combining,
\begin{align*}
f(k)
&= -2i \sum_{n=-\infty}^{\infty} \frac{k}{n^2 + k^2}
 = -\frac{2\pi i}{\sinh (\pi k)}.
\end{align*}
A: The poles are at $x=(2n+1)\pi\mathrm i$, and the corresponding residues are $-2\mathrm e^{-(2n+1)\pi k}$. If we ignore issues of convergence, this suggests that the integral is
$$
-4\pi\mathrm i\sum_{n=0}^\infty\mathrm e^{-(2n+1)\pi k}=\frac{-4\pi\mathrm i\mathrm e^{-\pi k}}{1-\mathrm e^{-2\pi k}}=\frac{-2\pi\mathrm i}{\sinh\pi k}\;.
$$
To make this rigorous in the context of tempered distributions, you can take the derivative of the function being Fourier-transformed, calculate the resulting convergent integral, and divide by $-\mathrm ik$ (see Tempered distributions and Fourier transform at Wikipedia). The residues are slightly more complicated to evaluate, but as one might expect the result is the same.
