Fourier Transform of Exponential Integral combination $e^{-x}\operatorname{Ei}(x)-e^{x}\operatorname{Ei}(-x)$ When trying to solve an ODE using Fourier methods, I met the following solution:
$$\omega \left(e^{-\omega}\operatorname{Ei}(\omega) - e^{ax}\operatorname{Ei}(-\omega)\right)$$
Which I have to Fourier transform back. I attempted using my 'dirty physics' approach:

*

*Use the definition of the Exponential Integral to write,
$$ \operatorname{Ei}(\omega) = -\int_{-\omega}^\infty \text{d}t~ t^{-1} e^{-t} = e^\omega \int_0^\infty \, \text{d}u\frac{e^{-u}}{\omega-u}$$
And thus we can write the combination in the brackets as
$$e^{-\omega}\operatorname{Ei}(\omega)-e^{\omega}\operatorname{Ei}(-\omega) = 2\omega\int_0^\infty \text{d}u \, \frac{e^{-u}}{\omega^2-u^2} $$


*Do the Fourier transform for the above by changing the order of integration,
\begin{align}
\int_{-\infty}^\infty \frac{\text{d}\omega}{2\pi} ~e^{i\omega x}\left[ e^{-\omega} \operatorname{Ei}(\omega)-e^\omega \operatorname{Ei}(-\omega)\right] &= \int_{-\infty}^\infty \frac{\text{d}\omega}{2\pi}~e^{i\omega x} 2\omega\int_0^\infty \text{d}u \, \frac{e^{-u}}{\omega^2-u^2}\\
&= \int_0^\infty \text{d}u~ e^{-u} \int_{-\infty}^\infty \frac{\text{d}\omega}{2\pi}~\frac{2\omega}{\omega^2-u^2}e^{i\omega x}\\
&=i\operatorname{sgn}(x)\int_{0}^{\infty} \text{d}u~ e^{-u} \cos(xu)\\
&=i~\frac{\operatorname{sgn}(x)}{1+x^2}
\end{align}


*Use the usual property of the Fourier Transform that $\mathcal{F}[i\omega f(\omega)] = \partial_x f(x)$,
\begin{align}
\int_{-\infty}^{\infty}\frac{\text{d}\omega}{2\pi} ~e^{i\omega x} \omega\left[ e^{-\omega}\operatorname{Ei}(\omega)-e^\omega \operatorname{Ei}(-\omega)\right] = \partial_x \left(\frac{\operatorname{sgn}(x)}{1+x^2}\right) = \frac{2\delta(x)}{1+x^2}-\frac{2|x|}{(1+x^2)^2}
\end{align}
However if you evaluate the above in Mathematica, I get simply $2\delta(x)$ as the result, which is the first piece of the above.
Does anyone know where I am messing it up and would be able to help with a rigorous treatment?
 A: It might be simpler to work out the direct transform in terms of distributions. If $1/x$ is defined by
$$\left( \frac 1 x, \phi \right) =
\operatorname{v.\!p.} \int_{-\infty}^\infty \frac {\phi(x)} x dx,$$
then
$$\mathcal F[\operatorname{sgn} x] = -\frac {2 i} w, \\
\mathcal F\left[ \frac 1 {x^2+1} \right] = \pi e^{-\left| w \right|}, \\
\mathcal F\left[ \frac {i \operatorname{sgn} x} {x^2+1} \right] =
 \frac 1 w * e^{-\left| w \right|} =
 \operatorname{v.\!p.} \int_{-\infty}^\infty
  \frac {e^{-\left| w - \tau \right|}} \tau d\tau = \\
 e^{-w} \operatorname{v.\!p.} \int_{-\infty}^w \frac {e^\tau} \tau d\tau +
 e^w \operatorname{v.\!p.} \int_w^\infty \frac {e^{-\tau}} \tau d\tau = \\
 e^{-w} \operatorname{Ei}(w) - e^w \operatorname{Ei}(-w).$$
Taking the distributional derivative, we indeed obtain
$$\mathcal F^{-1}\left[
 w e^{-w} \operatorname{Ei}(w) - w e^w \operatorname{Ei}(-w) \right] =
-\frac {2 \left| x \right|} {(x^2+1)^2} + 2 \delta(x),$$
where the first term is an ordinary function.
