About Integration $\int_{-\infty}^{\infty} e^{-x^2} \cos(x^2) dx$ What i want to prove is following integral 
\begin{align}
\int_{-\infty}^{\infty} e^{-x^2} \cos(x^2) dx=\frac{1}{2} \sqrt{\left(1+\sqrt{2}\right) \pi }
\end{align}
can you give some explicit method to obtain this result?
 A: Hint: Try to compute
$$\left(\int_{-\infty}^{\infty} e^{-x^2} \cos(x^2) dx\right)\times\left(\int_{-\infty}^{\infty} e^{-y^2} \cos(y^2) dy\right)$$
by polar coordinates. Use the formula $2\cos x\cos y= \cos(x-y)+\cos(x+y)$ to break it into two parts and conclude one of them is zero.
A: By using a substitution, $\cos\theta = \text{Re}(e^{i\theta})$ and the (direct and inverse) Laplace transform:
$$\int_{0}^{+\infty}e^{-x^2}\cos(x^2)\,dx = \frac{1}{2}\cdot\text{Re}\int_{0}^{+\infty}e^{(i-1)x}\frac{dx}{\sqrt{x}}=\frac{1}{2}\cdot\text{Re}\int_{0}^{+\infty}\frac{ds}{\sqrt{\pi s}\left((1-i)+s\right)}$$
hence:
$$ \int_{0}^{+\infty}e^{-x^2}\cos(x^2)\,dx = \frac{1}{\sqrt{\pi}}\cdot\text{Re}\int_{0}^{+\infty}\frac{ds}{(1-i)+s^2} $$
and the claim easily follows.
A: So let us follow through on Eclipse Sun's suggestion. In doing so we will find that while the double integral can indeed be separated into two parts (two double integrals), neither of them turns out to be equal to zero.
Let
$$I = \int^\infty_{-\infty} e^{-x^2} \cos (x^2) \, dx = 2 \int^\infty_0 e^{-x^2} \cos (x^2) \, dx.$$
on squaring the integral we have
\begin{align*}
I^2 &= 4 \left(\int^\infty_0 e^{-x^2} \cos(x^2) \, dx\right)\times\left(\int_{0}^{\infty} e^{-y^2} \cos(y^2) \, dy\right)\\
&= 4 \int^\infty_0 \int^\infty_0 e^{-(x^2 + y^2)} \cos (x^2) \cos (y^2) \, dx dy.
\end{align*}
After making use of $2\cos x\cos y= \cos(x-y)+\cos(x+y)$ we have
$$I^2 = 2 \int^\infty_0 \int^\infty_0 e^{-(x^2 + y^2)} \cos (x^2 + y^2) \, dx dy + 2 \int^\infty_0 \int^\infty_0 e^{-(x^2 + y^2)} \cos (x^2 - y^2) \, dx dy.$$
Converting to polar coordinates $(x,y) \mapsto (r \cos \theta, r \sin \theta)$ we have
$$I^2 = 2 \int^{\frac{\pi}{2}}_0 \int^\infty_0 r e^{-r^2} \cos (r^2) \, dr d\theta + 2 \int^{\frac{\pi}{2}}_0 \int^\infty_0 r e^{-r^2} \cos (r^2 \cos 2\theta ) \, dr d\theta = 2 I_1 + 2 I_2.$$
For the first of these integrals, the $r$-integral can be found by preforming integration by parts twice before performing the $\theta$-integration. The result is $I_1 = \pi/8$.
For the second of these integrals, finding the $r$-integral first by performing integration by parts twice, leads to
$$I_2 = \frac{1}{2} \int^{\frac{\pi}{2}}_0 \frac{d\theta}{1 + \cos^2 (2\theta)} = \frac{\pi}{4\sqrt{2}}.$$
Thus
$$I^2 = 2 \left [\frac{\pi}{4} + \frac{\pi}{2\sqrt{2}} \right ] = \frac{\pi}{4} (1 + \sqrt{2}),$$
or
$$I = \frac{\sqrt{\pi}}{2} \sqrt{1 + \sqrt{2}},$$
as required. 
A: Let your integral be labelled
$$I_1=\int_{-\infty}^{\infty} e^{-x^2}\cdot \cos(x^2)\space dx,$$
and a second integral
$$I_2=\int_{-\infty}^{\infty} e^{-x^2}\cdot\sin(x^2)\space dx.$$
It follows that
$$I_1-i\cdot I_2=\int_{-\infty}^{\infty} e^{-x^2}\cdot(\cos(x^2)-i\cdot \sin(x^2))\space dx.$$
Apply Euler's formula in complex analysis:
$$I_1-i\cdot I_2=\int_{-\infty}^{\infty} e^{-x^2}\cdot e^{-ix^2} dx=\int_{-\infty}^{\infty} e^{-(1+i)x^2}dx.$$
Let $x=(1+i)^{-1/2}\ t$ such that $dx=(1+i)^{-1/2}\ dt$, where $t\in(-\infty,\infty)$:
$$I_1-i\cdot I_2=(1+i)^{-1/2}\cdot\int_{-\infty}^{\infty} e^{-t^2}dt.$$
Evaluate the Gaussian integral:
$$I_1-i\cdot I_2=(1+i)^{-1/2}\cdot\sqrt{\pi}.$$
Rewrite the expression by making use of general properties of the exponential function and logarithms:
$$I_1-i\cdot I_2=e^{\ln((1+i)^{-1/2})}\cdot\sqrt{\pi}=e^{-1/2\ln(1+i)}\cdot\sqrt{\pi}.$$
The complex number $1+i$ can be converted from cartesian notation to polar notation; $1+i=\sqrt{2}\space e^{i \pi/4}$. Taking the natural logarithm on both sides gives $\ln(1+i)=\ln(\sqrt{2}\space e^{i \pi/4})=\ln(\sqrt{2})+i \pi/4$. Therefore,
$$I_1-i\cdot I_2=e^{-1/2(\ln(\sqrt{2})+i \pi/4)}\cdot\sqrt{\pi} = e^{\ln(\frac{1}{\sqrt{\sqrt{2}}})}\cdot e^{-i \pi/8}\cdot\sqrt{\pi}=\frac{1}{\sqrt{\sqrt{2}}}\cdot e^{-i \pi/8}\cdot \sqrt{\pi}.$$
Apply Euler's formula in complex analysis:
$$I_1-i\cdot I_2=\frac{1}{\sqrt{\sqrt{2}}}\cdot (\cos(\pi/8)-i\cdot \sin(\pi/8))\cdot \sqrt{\pi}.$$
Rewrite $\cos(\pi/8)$ by making use of the half-angle formula for the cosine function, $\cos(x)=2\cos^2(x/2)-1$:
$$\cos(\pi/4)=2\cos^2(\pi/8)-1\rightarrow \cos^2(\pi/8)=\frac{1+\cos(\pi/4)}{2}=\frac{1+\sqrt{2}}{2\sqrt{2}}=\frac{2+\sqrt{2}}{4}.$$
Then, $\cos(\pi/8)=\frac{\sqrt{2+\sqrt{2}}}{2}$.
Rewrite $\sin(\pi/8)$ by making use of the half-angle formula for the sine function, $\cos(x)=1-2\sin^2(x/2)$:
$$\cos(\pi/4)=1-2\sin^2(\pi/8)\rightarrow \sin^2(\pi/8)=\frac{1-\cos(\pi/4)}{2}=\frac{1-\sqrt{2}}{2\sqrt{2}}=\frac{2-\sqrt{2}}{4}.$$
Then, $\sin(\pi/8)=\frac{\sqrt{2-\sqrt{2}}}{2}$.
Substitution into the expression gives
$$I_1-i\cdot I_2=\frac{1}{\sqrt{\sqrt{2}}}\cdot (\frac{\sqrt{2+\sqrt{2}}}{2}-i\cdot \frac{\sqrt{2-\sqrt{2}}}{2})\cdot \sqrt{\pi}= (\frac{\sqrt{\sqrt{2}+1}}{2}-i\cdot \frac{\sqrt{\sqrt{2}-1}}{2})\cdot \sqrt{\pi}.$$ 
After expanding the terms it follows that
$$I_1=\frac{\sqrt{\sqrt{2}+1}}{2}\cdot \sqrt{\pi},\space I_2=\frac{\sqrt{\sqrt{2}-1}}{2}\cdot \sqrt{\pi}.$$
The integral you wanted to evaluate is $I_1$.
