solving the integral $ \int_0^\infty \dfrac{\sin xt}{x(x^2+1)} dx $ How to solve the following integral by differential equations techniques?
$$ \int_0^\infty \dfrac{\sin xt}{x(x^2+1)} dx $$
 A: Recalling the Laplace transform

$$ F(s)=\int_{0}^{\infty} f(t) e^{-st} dt. $$

We can use it to solve the problem. Taking Laplace transform with respect to $t$ gives

$$ f(t)=\int_0^\infty \dfrac{\sin xt}{x(x^2+1)} dx \implies F(s)=\int_{0}^{\infty}\frac{dx}{(1+x^2)(s^2+x^2)}  . $$

The last integral can be evaluated using partial fraction techniques (see below) to give

$$ \implies F(s) = \frac{1}{2}\,{\frac {\pi }{s \left( s+1 \right) }}. $$

Now, we can find the inverse Laplace transform using convolution technique as

$$ f(t)=\frac{\pi}{2}\int_{0}^{t} e^{-\tau}d\tau = \frac{\pi}{2}(1-e^{-t}). $$

Alternatively, one can use partial fraction technique 

$$  \frac{\pi}{2}\frac {1}{s(s+1)}=\frac{\pi}{2}\left(\frac{1}{s}-\frac{1}{s+1}\right). $$

to find the inverse Laplace transform
Notes:

1) The Laplace transform of $\sin(az)$ with respect to $z$ is
  $$ {\frac {a}{{s}^{2}+{a}^{2}}}. $$
2) $$\frac{1}{(1+x^2)(s^2+x^2)}={\frac {1}{ \left( {s}^{2}+{x}^{2} \right)  \left(1- {s}^{2} \right)}}-{\frac {1}{ \left( {x}^{2}+1 \right)\left(1- {s}^{2} \right) }}.$$
3) Inverse Laplace transform of $\frac{1}{s}$ and $\frac{1}{1+s}$ are given by
  $$  1,\quad e^{-t} $$
  respectively.  

A: This integral is custom-made for analysis via integration in the complex plane.  I'm not sure if you have any familiarity with the following concepts (e.g., residues), but I am going to evaluate it here in this fashion for completeness.
Consider the following integral in the complex plane:
$$\oint_C dz \frac{e^{i z t}}{z (z^2+1)}$$
where $C$ is the following contour:

Thus, we avoid the pole at $z=0$ by deforming into the upper half plane.  The contour integral is thus equal to
$$\int_{-R}^{-\epsilon} dx \frac{e^{i x t}}{x (x^2+1)} + i \epsilon \int_{\pi}^0 d\phi \, e^{i \phi} \frac{e^{i \epsilon e^{i \phi} t}}{\epsilon e^{i \phi} (\epsilon^2 e^{i 2 \phi}+1)}+ \\ \int_{\epsilon}^{R} dx \frac{e^{i x t}}{x (x^2+1)} +i R \int_0^{\pi} d\theta \, e^{i \theta} \frac{e^{i R e^{i \theta} t}}{R e^{i \theta} (R^2 e^{i 2 \theta}+1)} $$
We take the limit as $\epsilon \to 0$ and $R \to \infty$.  Note that the second integral becomes $-i \pi$.  The fourth integral vanishes when $t \gt 0$; its magnitude is bounded by
$$\frac{2}{R^2} \int_0^{\pi/2} d\theta \, e^{-R t \sin{\theta}} \le  \frac{2}{R^2} \int_0^{\pi/2} d\theta \, e^{-2 R t \theta/\pi}  \le \frac{\pi}{R^3 t}$$
On the other hand, the contour integral is equal to, by the residue theorem, $i 2 \pi$ times the residue at the pole $z=i$ (i.e., the only pole within the contour $C$).  Thus
$$PV \int_{-\infty}^{\infty} dx \frac{e^{i x t}}{x (x^2+1)} - i \pi = i 2 \pi \frac{e^{-t}}{2 i^2} $$
or 
$$PV \int_{-\infty}^{\infty} dx \frac{e^{i x t}}{x (x^2+1)} = i \pi \left ( 1 - e^{-t}\right )$$
Now, take the imaginary part of both sides; the principal value disappears and we get, for $t \gt 0$:
$$\int_{0}^{\infty} dx \frac{\sin{ x t}}{x (x^2+1)} =  \frac{\pi}{2} \left ( 1 - e^{-t}\right )$$
