[Math] Evaluating the definite integral $\int_{-\infty}^{+\infty} \mathrm{e}^{-x^2}x^n\,\mathrm{d}x$

calculusimproper-integralsintegration

I recognize that the $\int_0^\infty \mathrm{e}^{-x}x^n\,\mathrm{d}x = \Gamma(n+1)$ and $\int_{-\infty}^{+\infty} \mathrm{e}^{-x^2}\,\mathrm{d}x = \sqrt{\pi}$. I am having difficulty, however with $\int_{-\infty}^{+\infty} \mathrm{e}^{-x^2}x^n\,\mathrm{d}x$. By the substitution $u=x^2$, this can be equivalently expressed as $\frac{1}{2} \int_{-\infty}^{+\infty} \mathrm{e}^{-u}u^{\frac{n-1}{2}}\,\mathrm{d}u$. This integral is similar to the first one listed (which equates to the $\Gamma$ function), except that its domain spans $\mathbb{R}$ like the second integral (which equates to $\sqrt{\pi}$). Any pointers on how to evaluate this integral would be helpful.

Best Answer

The function $x\mapsto x^n e^{-x^2}$ is absolutely integrable on the real line. If $n$ is odd, the integrand is odd, and we have $$\int_0^\infty x^n e^{-x^2}\, dx = 0$$

Now consider the even case. We first use symmetry to get the integral onto $[0,\infty)$ and then use the subsitution $x \rightarrow \sqrt{x}$ as follows $$\int_{-\infty}^\infty x^n e^{-x^2}\, dx= 2\int_0^\infty x^n e^{-x^2}\, dx = 2\int_0^\infty x^{n/2} e^{-x}{dx\over2\sqrt{x}} = \Gamma\left({n + 1\over 2}\right).$$

Invoking the factorial property of the $\Gamma$ function relates this solution to the other posted solution.