Calculate $\int_{-\infty}^{\infty} e^{-x^2}\cos (ax) dx$ using Taylor series cosine Let $a > 0$. Im trying to show that $\int_{-\infty}^{\infty} e^{-x^2} \cos (ax) dx = \sqrt{\pi}e^{-\frac{1}{4}a^2}$. I'm taking a course on measure theory, and I want to prove this using the Lesbesgue's Dominated Convergence Theorem. The idea is to write
$$
\cos ax = \sum_{m=0}^\infty \frac{(-1)^m}{(2m)!} (ax)^{2m},
$$
so assuming we may switch the integral and summation using the above mentioned theorem (which I haven't proved yet), we get
\begin{align*}
\lim_{R\to\infty} \int_{-R}^{R} e^{-x^2} \cos (ax) dx
&= \lim_{R\to\infty} \int_{-R}^R e^{-x^2} \sum_{m=0}^\infty \frac{(-1)^m}{(2m)!} (ax)^{2m} dx\\
&= \lim_{R\to\infty} \sum_{m=0}^\infty \frac{(-1)^m\cdot a^{2m}}{(2m)!} \int_{-R}^R e^{-x^2} x^{2m}dx.
\end{align*}
But now we are left with
$$
\int_{-R}^R e^{-x^2} x^{2m} dx
$$
for $m\in \mathbb{N}$. I know that for $m=0$ this integral doesn't have a nice solution, and I doubt it has a nice solution for $m\geq 1$. Is it possible to solve this problem using this route, or is it a dead end?
I'm aware that there are other methods to solve this, see  Gaussian-like integral : $\int_0^{\infty} e^{-x^2} \cos( a x) \ \mathrm{d}x$.
Edit: I solved it using Lebesgue's Dominated Convergence Theorem (LDCT). First, I proved that the improper Riemann-integral was equal to the Lebesgue integral, and then I switched the summation and integration using LDCT. I ended up with $\int_{\mathbb{R}} e^{-x^2}\cdot x^n d\lambda^1$, which I could calculate using an improper Riemann-integral. I ended up with the Taylor series of $\sqrt{\pi}e^{-\tfrac{1}{4}a^2}$.
 A: Note that if we let $F(z)$ be defined as 
$$F(z)=\int_{-\infty}^{\infty}e^{-zx^2}\,dx=\sqrt{\pi}z^{-1/2}$$
then we can easily see that
$$F^{(n)}(1)=(-1)^n\int_{-\infty}^\infty x^{2n}e^{-x^2}\,dx=\frac{(-1)^n\sqrt{\pi}(2n-1)!!}{2^n}$$
Therefore, we have
$$\bbox[5px,border:2px solid #C0A000]{\int_{-\infty}^\infty x^{2n}e^{-x^2}\,dx=\frac{\sqrt{\pi}(2n-1)!!}{2^n}=\frac{\sqrt{\pi}(2n)!}{4^n\,n!}}$$
Now, we have
$$\bbox[5px,border:2px solid #C0A000]{\int_{-\infty}^\infty e^{-x^2}\,\cos(ax)\,dx=\sqrt{\pi}\sum_{n=0}^\infty\frac{(-1)}{n!}^n\left(\frac{a^2}{4}\right)^n=\sqrt{\pi}e^{-a^2/4}}$$
A: I have two ideas. The first one is to use the Taylor series for $e^x$. The other idea is to use integration by parts with $u = e^{-x^2}$ and $dv = \cos{(ax)} dx$. I am thinking with some luck several iterations of integration by parts might give you the same integral back and then you can solve for the integral.
A: $$\int_{-R}^R e^{-x^2} x^{2m} dx \leq \int_{-\infty}^\infty e^{-x^2} x^{2m} dx.$$
Performing $m$ integrations by parts reduces this to a certain multiple of $\int_{-\infty}^\infty e^{-x^2} dx$, which is fairly well-known to be $\sqrt{\pi}$. (Cf. https://en.wikipedia.org/wiki/Normal_distribution#Moments)
This should furnish the dominating function that you need in order to continue.
