TITLE: Another integral related to Fresnel integrals
QUESTION [9 upvotes]: How would we prove this result by real methods ?
$$\int_0^{\infty } \frac{\sin \left(\pi  x^2\right)}{x+2} \, dx=\frac{1}{4} \left(\pi-2 \pi  C\left(2 \sqrt{2}\right)-2 \pi  S\left(2 \sqrt{2}\right)+2 \text{Si}(4 \pi ) \right)$$
As you can easily see, Fresnel integrals are involved. What are your ideas on it?

REPLY [7 votes]: Ok, i will give it a shot:
Writing $\int_{0}^{\infty}e^{-t(x+2)}=\frac{1}{x+2}$ and using $\Im(e^{ix})=\sin(x)$ we may reformulate the problem as follows:
$$
I=\Im\left[\int_0^{\infty}dte^{-2 t}\underbrace{\int_0^{\infty}dxe^{i\pi x^2-tx}}_{J(t)}\right]
$$
the inner intgral $J(t)$ is quite straightforward (and also well known because it is just the laplace transform of a gaussian) if one is aware of the definition of the complementary Error function and completes the square.
We get
$$
J(t)=-\frac{(-1)^{3/4}}{2}e^{- a^2 t^2} \text{erfc}\left(i a t\right)
$$
with $a=\frac{(-1)^{3/4}}{2\sqrt{\pi}}$
We therefore left with 
$$
I=\Im\left[-\frac{(-1)^{3/4}}{2}\int_0^{\infty}dte^{-2 t}e^{- a^2 t^2} \text{erfc}\left(i a t\right)\right]
$$ 
To calculate this integral we use $\text{erfc}(z)=1-\text{erf}(z)$ and 4.3.12 in this fantastic paper to obtain:
$$
I=\Im\left[-\frac{(-1)^{3/4}}{4 a}e^\frac{1}{a^2}\left(\sqrt{\pi} \text{erfc}\left(\frac{1}{a}\right)-\frac{1}{i\sqrt{\pi}}\text{Ei}\left(-\frac{1}{a^2}\right)\right) \right]
$$
Here $\text{Ei}(z)$ denotes the exponential integral.
It's now a matter of straightforward but painstaking calculations to get everything in the form you suggested. I'm too lazy for that but instead give a proof of proposition 4.3.12
Proposition
$$
Q(a,b)=\int_0^{\infty}dte^{-b t}e^{- a^2 t^2} \text{erfc}\left(i a t\right)=\frac{1}{2 a i\sqrt{\pi}}e^{\frac{b^2}{4a^2}}\text{Ei}\left(-\frac{b^2}{4a^2}\right)
$$
Proof:
We may use the following respresentation of the error function:
(a proof may be found here)
$$
\text{erf}(z)=\frac{2e^{-z^2}}{\sqrt \pi}\sum_{n=1}^{\infty}\frac{2^n z^{2n+1}}{(2n+1)!!}
$$
And therefore
$$
Q(a,b)=\frac{2}{\sqrt \pi}\sum_{n=1}^{\infty}\int_{0}^{\infty}e^{-bt}\frac{2^n(i a t)^{2n+1}}{(2n+1)!!}dt=\frac{2}{\sqrt \pi}\sum_{n=1}^{\infty}\frac{(i a )^{2n+1}2^n (2n+1)!}{(2n+1)!!}=\\\frac{2 ia}{b^2\sqrt{\pi}}\sum_{n=1}^{\infty}\frac{ n! (4 a^2)^n}{(b^2)^n}
$$
using the asymptotic expansion of the Exponential integral (which is easily verified using i.p.b.)
$$
\text{Ei(z)}\sim\frac{e^{-z}}{z}\sum_{n=1}^{N-1}\frac{n!}{(-z)^n}
$$
We may ($z=-\frac{b^2}{4a^2}$) conclude that: 
$$
Q(a,b)=\frac{1}{2 a i \sqrt{\pi}}e^{\frac{b^2}{4a^2}}\text{Ei}\left(\frac{-b^2}{4a^2}\right)
$$
Q.E.D
Remark: I'm aware that the last equality sign holds only in an asymptotic way, but it seems to be possible to extend this to a real equality. If someone can hint me in the right direction i would be glad to make this point more rigouros!