2
$\begingroup$

Let $X\sim N(0,1)$, compute $\mathrm E[X^3]$:

My attempt:

$$ \mathrm E[X^3]=\int_{-\infty}^{\infty}x^3\frac{1}{\sqrt{2\pi}}e^{-\frac{x^2}{2}}\mathrm d x \\ x^2=t \Rightarrow \mathrm dx=\frac{\mathrm dt}{2x}\\ \mathrm E[X^3]=\frac{1}{\sqrt{2\pi}}\int_{0}^{\infty} t\frac{1}{2}e^{-\frac{t}{2}}\mathrm dt=\frac{1}{\sqrt{2\pi}}E[Y] \\ Y\sim \exp(\frac{1}{2}) \\ \Rightarrow \mathrm E[X^3]=\frac{1}{\sqrt{2\pi}}\frac{1!}{0.5^1}=\frac{2}{\sqrt{2\pi}} $$

I used the fact that if $X\sim \exp(\lambda)$ then $\mathrm E[X^n]=\dfrac{n!}{\lambda^n}$

But the actual is result is $0$! Why is that? what am I missing here??

Thanks.

$\endgroup$
  • $\begingroup$ Observe that the first written integrand takes negative values, and the second does not. Btw, $X$ and $-X$ have equal distribution. So also $X^3$ and $(-X)^3=-X^3$ have equal distribution so that $\mathbb EX^3=\mathbb E[-X^3]=-\mathbb EX^3$. This implies that $\mathbb EX^3=0$. $\endgroup$ – drhab Feb 11 at 10:17
  • $\begingroup$ @drhab I am not sure I'm following $\endgroup$ – superuser123 Feb 11 at 10:19
  • $\begingroup$ You integrate an odd function on a symmetric interval... $\endgroup$ – Bertrand Feb 11 at 10:25
  • 2
    $\begingroup$ The change of variable formula is not valid here. Read the theorem on change of variables in baby Rudin. $\endgroup$ – Kavi Rama Murthy Feb 11 at 10:28
2
$\begingroup$

Your change of variables is off. If you want to reason on integral (though drhab reasonning is much simpler) :

$$ E[X^3]=\int_{-\infty}^{+\infty} x^3\frac{1}{\sqrt{2\pi}}e^{-x^2/2}dx$$ $$ E[X^3]=\int_{-\infty}^{0} x^3\frac{1}{\sqrt{2\pi}}e^{-x^2/2}dx + \int_{0}^{+\infty} x^3\frac{1}{\sqrt{2\pi}}e^{-x^2/2}dx$$ Applying the change of variable $x\mapsto -x$ in the first integral, step by step $$ E[X^3]=\int_{+\infty}^{0} (-x)^3\frac{1}{\sqrt{2\pi}}e^{-x^2/2}(-dx) + \int_{0}^{+\infty} x^3\frac{1}{\sqrt{2\pi}}e^{-x^2/2}dx$$ $$ E[X^3]=\int_{+\infty}^{0} x^3\frac{1}{\sqrt{2\pi}}e^{-x^2/2}dx + \int_{0}^{+\infty} x^3\frac{1}{\sqrt{2\pi}}e^{-x^2/2}dx$$ $$ E[X^3]=-\int_{0}^{+\infty} x^3\frac{1}{\sqrt{2\pi}}e^{-x^2/2}dx + \int_{0}^{+\infty} x^3\frac{1}{\sqrt{2\pi}}e^{-x^2/2}dx$$ $$E[X^3]=0$$

$\endgroup$
1
$\begingroup$

Your change of variable is valid, but not as regards the integration range.

If $x$ runs from $-\infty$ to $\infty$, $t:=x^2$ runs from $\infty$ to $0$ then back to $\infty$, and the two contributions cancel each other.

The good news is that your one-sided integral, from $0$ to $\infty$ is correct.

$\endgroup$

Your Answer

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Not the answer you're looking for? Browse other questions tagged or ask your own question.