# Departing from the moment generating function

• Feb 2nd 2008, 03:11 PM
paolopiace
Departing from the moment generating function
Thanks for all your help, guys! Special thanks to Mr.F!

The previous attempts were discouraging:
http://www.mathhelpforum.com/math-he...-function.html

Now I change approach totally, depart from the moment generating function and use the straight definition of moments. Please follow me...

Bottom line, you will see that I'm not getting to the expected results yet. Therefore I would appreciate if you double check and see what I am doing wrong.

Restating the problem - I need to analytically calculate the even moments of the following pdf:

$\displaystyle p(x;\lambda) =\left\{\begin{array}{cc}2 \lambda x\ e^{-\lambda{x^2}}& x\geq 0\\0 & x<0\end{array}\right. (\lambda>0)$

I know that the even moments are these and I need to find a way to prove it:

$\displaystyle E[x^{2n}]=\frac{n!}{\lambda^n}\ (n=0,1,2, ...)$

To do so, let's simply calculate the even-moments with the regular integration. By definition:

$\displaystyle E[X^{2n}]=\int_0^\infty x^{2n}\ 2\lambda x\ e^{-\lambda x^2} dx$

Integrating by parts:

$\displaystyle E[X^{2n}]=-\int_0^\infty x^{2n}\ (-2\lambda x)\ e^{-\lambda x^2} dx = \left[-x^{2n}e^{-\lambda x^2}\right]_0^\infty+\ I_1$

$\displaystyle I_1=2n\int_0^\infty x^{2n-1}\ e^{-\lambda x^2} dx = -\frac{n}{\lambda}\int_0^\infty x^{2n-2}\ (-2\lambda x)\ e^{-\lambda x^2} dx =$

$\displaystyle \left[-\frac{n}{\lambda}\ x^{2n-2}\ e^{-\lambda x^2}\right]_0^\infty+\ I_2$

$\displaystyle I_2=\frac{n}{\lambda}(2n-2)\int_0^\infty x^{2n-3}\ e^{-\lambda x^2} dx = -\frac{n(n-1)}{\lambda^2}\int_0^\infty x^{2n-4}\ (-2x\lambda)\ e^{-\lambda x^2} dx =$

$\displaystyle \left[-\frac{n(n-1)}{\lambda^2}\ x^{2n-4}\ e^{-\lambda x^2}\right]_0^\infty\ +\ I_3$

$\displaystyle I_3\ =-\frac{n(n-1)(n-2)}{\lambda^3} \int_0^\infty x^{2n-6}(-2x\lambda)\ e^{-\lambda x^2} dx$

and, in general:

$\displaystyle I_k\ =-\frac{n!}{(n-k)!\ \lambda^k} \int_0^\infty x^{2(n-k)} d(e^{-\lambda x^2})=-\frac{n!}{(n-k)!\ \lambda^k}\left[x^{2(n-k)}\ e^{-\lambda x^2}\right]_0^\infty+\ I_{k+1}$

The iteration stops when k=n with

$\displaystyle I_n = (n!/\lambda^n)[e^{-\lambda x^2}]_0^\infty$

therefore:

$\displaystyle E[X^{2n}]=-\sum_{k=0}^n\frac{n!}{(n-k)!\ \lambda^k}\left[\frac{x^{2(n-k)}}{e^{\lambda x^2}}\right]_0^\infty\ =\ -\sum_{k=0}^n\frac{n!}{(n-k)!\ \lambda^k}\left[0-0\right]\ =\ 0$

And here I am... ZERO! That cannot be! What's wrong here? (Swear)(Swear)

• Feb 2nd 2008, 09:51 PM
CaptainBlack
Quote:

Originally Posted by paolopiace
Thanks for all your help, guys! Special thanks to Mr.F!

The previous attempts were discouraging:
http://www.mathhelpforum.com/math-he...-function.html

Now I change approach totally, depart from the moment generating function and use the straight definition of moments. Please follow me...

Bottom line, you will see that I'm not getting to the expected results yet. Therefore I would appreciate if you double check and see what I am doing wrong.

Restating the problem - I need to analytically calculate the even moments of the following pdf:

$\displaystyle p(x;\lambda) =\left\{\begin{array}{cc}2 \lambda x\ e^{-\lambda{x^2}}& x\geq 0\\0 & x<0\end{array}\right. (\lambda>0)$

I know that the even moments are these and I need to find a way to prove it:

$\displaystyle E[x^{2n}]=\frac{n!}{\lambda^n}\ (n=0,1,2, ...)$

To do so, let's simply calculate the even-moments with the regular integration. By definition:

$\displaystyle E[X^{2n}]=\int_0^\infty x^{2n}\ 2\lambda x\ e^{-\lambda x^2} dx$

Integrating by parts:

$\displaystyle E[X^{2n}]=-\int_0^\infty x^{2n}\ (-2\lambda x)\ e^{-\lambda x^2} dx = \left[-x^{2n}e^{-\lambda x^2}\right]_0^\infty+\ I_1$

$\displaystyle I_1=2n\int_0^\infty x^{2n-1}\ e^{-\lambda x^2} dx = -\frac{n}{\lambda}\int_0^\infty x^{2n-2}\ (-2\lambda x)\ e^{-\lambda x^2} dx =$

$\displaystyle I_{2n}=\int_0^\infty x^{2n}\ 2\lambda x\ e^{-\lambda x^2} dx = \left[-x^{2n}e^{-\lambda x^2}\right]_0^\infty+\frac{n}{\lambda}\ I_{2(n-1)}=\frac{n}{\lambda}\; I_{2(n-1)}$

and as $\displaystyle I_0=1$ proves the result.

RonL