7
$\begingroup$

I was asked to find a formula for all even moments of the form $E(X^{2n})$ and all odd moments of the form $E(X^{2n+1})$ using a mgf. Can you help me find the even moments? I will attempt to solve for the odd moments using similar techniques.

Let $X$ be a continuous random variable having the density $f_X(x)=\frac{1}{2}e^{-|x|}$, where $-\infty < x < \infty$.

My work: I was able to obtain the following moment-generating function: $M_X(t)=(1-t^2)^{-1}.$ However, I am unsure of where to go from here. Thank you for your help.

$\endgroup$
10
  • 2
    $\begingroup$ Hint: If you can express $M_X(t)$ as a power series in $t$, (that is, something that looks like $1 + m_1t + m_2t^2 + m_3 t^3 + \cdots$) then you can find $E[X^n]$ in terms of $m_n$ $\endgroup$ Commented Sep 16, 2019 at 22:02
  • $\begingroup$ I think I see what you're saying. Since $M_X(t)=(1-t^2)^{-1}$, then it slightly resembles a geometric series: $ (1-t^2)^{-1}=1+t^2+(t^2)^2+(t^2^)3+ \cdots $. This can only happen if $|t^2| <1,$ which is satisfied $\endgroup$
    – Ron Snow
    Commented Sep 16, 2019 at 22:11
  • $\begingroup$ About odd moments : have you plotted the distribution ? What would be the mean ? the skew ? can you infer something about odd moments for symetrical distributions ? $\endgroup$ Commented Sep 16, 2019 at 22:26
  • $\begingroup$ I plotted the distribution. The mean appears to be 0, and the plot is symmetrical. I found this link that infers that odd moments of symmetrical distributions are 0. How could I show this result using mgfs? math.stackexchange.com/questions/72451/… $\endgroup$
    – Ron Snow
    Commented Sep 16, 2019 at 23:15
  • 1
    $\begingroup$ It does not contain the explanation what you are supposed to do with the moment generating function in order to obtain the moments? $\endgroup$ Commented Sep 17, 2019 at 0:38

5 Answers 5

9
$\begingroup$

One way to make your mgf approach to the problem easier is to use the power series

$$(1-t^2)^{-1}=\sum_{j=0}^{\infty} t^{2j}$$

Differentiating the rhs repeatedly is much easier than differentiating the lhs. (note this only applies for $|t|<1$ but as you are differentiating at $t=0$ it still works). You should see that it will just be a factorial. However is it probably even simpler to just evaluate the expectation directly

$$E(X^{2n})=\int_{-\infty}^{\infty}\frac{x^{2n}}{2}\exp(-|x|)dx$$

The result should be a gamma function (ie factorial). This also becomes clear from the mgf power series.

update regarding the mgf approach, to evaluate $E(X^{2n})$ we need to differentiate the rhs $2n$ times. The following result will be useful

$$\frac{\partial^k x^{r}}{\partial x^k} =\left( \begin{matrix}  \frac{r!}{(r-k)!}x^{r-k} & r=k,k+1,\dots \\ 0 & r=1,\dots,k-1 \end{matrix} \right) $$

Now if you apply this to the term $t^{2j}$ and take the "2n-th" derivative, we have $r=2j$ and $k=2n$ and $x=t$. Then we get $$\frac{\partial^{2n} t^{2j}}{\partial t^{2n}} =\left( \begin{matrix}  \frac{(2j)!}{(2j-2n)!}t^{2j-2n} & 2j=2n,2n+2,2n+4,2n+6,\dots \\ 0 & 2j=0,2,\dots,2n-2 \end{matrix} \right) $$

This means when we add up over all the terms we can write this as $$\sum_{j=0}^{\infty}\frac{\partial^{2n} t^{2j}}{\partial t^{2n}}=0+\dots+0+(2n)!+t^2\frac{(2n+2)!}{2!}+t^4\frac{(2n+4)!}{4!}+\dots$$

only the single tertm $(2n)!$ is not $0$ and also not a multiple of $t$. So setting $t=0$ leaves only that term.

$\endgroup$
4
  • $\begingroup$ Thank you for providing both ways to solve this problem. I think I would use the latter approach if I am given a choice- it seems more direct. $\endgroup$
    – Ron Snow
    Commented Sep 17, 2019 at 3:12
  • $\begingroup$ My second derivative of the rhs is $\Sigma^\infty _{j=0}[2j(2j-1)t^{2j-2}]$, but when this is evaluated at $t=0$, it is equal to zero. Where am I messing up? $\endgroup$
    – Ron Snow
    Commented Sep 17, 2019 at 3:16
  • 1
    $\begingroup$ There will always be a term that has a zero power, so that when $t=0$ you will get $t^0 = 0^0 = 1$, and the result will be the coefficient for that power. $\endgroup$
    – Ben
    Commented Sep 17, 2019 at 5:22
  • $\begingroup$ The updates to this post are very much appreciated. Thank you for the explanation. $\endgroup$
    – Ron Snow
    Commented Sep 18, 2019 at 5:01
7
$\begingroup$

Hint: This is an example of a probability density function that is symmetric about zero:

$$f_X(0+x) = f_X(0-x) \quad \quad \quad \text{for all } x \in \mathbb{R}.$$

Visually, this means that the distribution is reflected around the zero line, and is the same on both sides. See if you can use this property to figure out (and then prove) what the odd moments would be. The even moments are a bit trickier, but see if you can use this property to reduce those moments to a simpler form.

$\endgroup$
2
  • 1
    $\begingroup$ Thank you for this hint. I see how odd moments would equal 0 around a symmetric distribution, but how can I obtain this result from my MGF? $\endgroup$
    – Ron Snow
    Commented Sep 16, 2019 at 23:17
  • 2
    $\begingroup$ I think the best method is to expand it out as a power series, as shown in the excellent answer by probabilityislogic. $\endgroup$
    – Ben
    Commented Sep 17, 2019 at 5:42
7
$\begingroup$

If you don't care to do unnecessary calculation, it is convenient to view your distribution as an equal mixture of an Exponential and its negative:

$$\frac{1}{2} e^{-|x|} = \frac{1}{2} e^{-x}\,\mathcal{I}(x\gt 0) + \frac{1}{2} e^{x}\,\mathcal{I}(x \lt 0).$$

Because $((-1)^n + (1)^n)/2$ is either $-1+1=0$ or $(1+1)/2 = 2/2 = 1$ as $n$ is odd or even, respectively, the odd moments of your distribution are zero and the even moments are the same as those of the Exponential. But, by definition, the even Exponential moments are

$$\mu_{2k} = \int_0^\infty x^{2k} e^{-x}\mathrm{d}x = \Gamma(2k+1) = (2k)!$$

Because this required no calculation more difficult than $1+1=2,$ it's hard to imagine a simpler solution.


If instead you wish to pursue the moment generating approach, begin by noting that the mgf of the Exponential distribution is $$\phi(t)=\int_0^\infty e^{tx} e^{-x}\mathrm{d}x = \int_0^\infty e^{-(1-t)x}\mathrm{d}x = \frac{1}{1-t}.$$ Thus the mgf of this mixture is

$$(\phi(t) + \phi(-t))/2 = \frac{1}{2}\left(\frac{1}{1-t} + \frac{1}{1-(-t)}\right) = \frac{1}{1-t^2}.$$

This is analytic near $0$ and therefore equals the power series expansion given by the Binomial Theorem as

$$\frac{1}{1-t^2} = (1 + (-t^2))^{-1} = \sum_{k=0}^\infty \binom{-1}{k} (-t^2)^k = \sum_{k=0}^\infty t^{2k} = \sum_{k=0}^\infty \color{red}{(2k)!}\, \color{gray}{\frac{t^{2k}}{(2k)!}},$$

from which you may read off the moments as the coefficients of $t^n/n!:$ again we see they are zero for the odd moments and $(2k)!$ for the even moments.

$\endgroup$
1
  • $\begingroup$ Thank you for sharing both the simplest way and the mgf way. $\endgroup$
    – Ron Snow
    Commented Sep 18, 2019 at 5:03
7
$\begingroup$

Since the OP seems to be having difficulty with the various hints in the comments and the other answers, here is a heuristic method that yields the right answer in this instance. \begin{align} E[\exp(tX)] &= E\left[1 + tX + \frac{(tX)^2}{2!} + \frac{(tX)^3}{3!} + \cdots\right]\\ &= 1 + tE[X] + \frac{t^2}{2!}E[X^2] + \frac{t^3}{3!}E[X^3] + \cdots\tag{1}\\ \end{align} and so if we have a power series for $E[\exp(tX)] = M_X(t)$ that we have managed to find by hook or by crook and without looking at the displayed equation above since that will just serve to confuse us, then we can just look at the coefficient of $t^n$ in the power series that we have and say "Hey Ma! I think that the coefficient of $t^n$ is just $\frac{1}{n!}E[X^n]$ and so I can find $E[X^n]$ by multiplying the coefficient that I already have by $n!$.

For the OP's specific case, he has already found that $$M_X(t) = \frac{1}{1-t^2} = 1 + t^2 + t^4 + \cdots + t^{2n} + \cdots \tag{2}$$ (that's the "by hook or by crook" part) and so he can compare $(1)$ and $(2)$ to figure out what the moments are. I will leave it to the OP to tell Ma that $E[X^n]=0$ whenever $n$ is odd. Whether he wishes to tell Ma what $E[X^n]$ is for even $n$ is a matter for him to decide. The $E[X^4]=12$ that the OP claims (in a comment) to have calculated doesn't sound right to me (I think it should be $E[X^4] = 4! = 24$), but who am I to interfere in the sacred relationship between mother and child?

$\endgroup$
1
  • $\begingroup$ Thank you for your entertaining input. I see what you are saying. So I am getting that $E[X^n]=n!$, since we multiple $n!$ by the coefficient of each $t^n$, where $n$ is even. Now I get how you expanded both $E[e^{tX}]$ and $M_X(t)$, but how can you use the coefficients of the two expansions with each other? I would like to understand the big picture. $\endgroup$
    – Ron Snow
    Commented Sep 17, 2019 at 3:04
2
$\begingroup$

So I calculated the first, second, third, and fourth derivatives. I got $E(X^1)=0$, $E(X^2)=2$, $E(X^3)=0$, and $E(X^4)=12$. These derivatives are quite long to compute at this point, so I m wondering if there is an easier way to go about this to obtain a formula for the evens.

You could use the Taylor series expansion:

$$\frac{1}{1-t^2} = \sum_{k=0}^\infty t^{2k}$$

However, this is a bit of a circular reasoning since the Taylor series expansion is itself derived by computing the derivatives. In that case you can just as well look up directly a formula for the higher order moments of the Laplace distribution.


You might find that Taylor series expansion indirectly - not using $f(x) = \sum_{n=0}^\infty f^{(n)}/n! t^k $ - by instead using the formula for a geometric series.

However, you could also 'manually' derive the derivatives (that means straight forward computation using chain rule and product rule) and when you look at the pattern of the terms then you will find that many of the terms become zero and a regular pattern emerges.

Say we substitute $u = t^2$ then the derivation it looks simpler:

$$ \frac{\text{d}^n}{\text{d}u^n} \frac{1}{(1-u)} = \frac{n!}{(1-u)^n}$$

Now use Faà di Bruno's formula (chain rule but then applied several times):

$$ \frac{\text{d}^n}{\text{d}t^n} \frac{1}{(1-u)} = \sum_{k=1}^n \frac{k!}{(1-u)^k} \cdot B_{n,k}(2t,2,0,...,0)$$

where $B_{n,k}$ refers to Bell polynomials. Most of the terms will be zero and you get

$$ \frac{\text{d}^{2n}}{\text{d}t^{2n}} \frac{1}{(1-t^2)} = \sum_{k=0}^n c_{nk} \frac{t^{2k}}{(1-t^2)^{1+n+k}}$$

with

$$c_{nk} = 2^{2k} \frac{(2n)! \cdot (n+k)!}{(n-k)! \cdot (2k)!} $$

and for the value at $t=0$ you have

$$ \frac{\text{d}^{2n}}{\text{d}t^{2n}} \frac{1}{(1-t^2)} = c_{n0} = (2n)! $$

$\endgroup$
4
  • $\begingroup$ Although I am not familiar with Faa di Bruno's formula, I like the structure of your answer. Thank you for your addition! $\endgroup$
    – Ron Snow
    Commented Sep 18, 2019 at 5:04
  • 1
    $\begingroup$ When you differentiate one time you get $2t\cdot\frac{1}{(1-t^2)} $ two times $2\cdot\frac{1}{(1-t^2)^2} + 2t\cdot4t\cdot\frac{1}{(1-t^2)^3} $ and so on. It is combinations of higher order derivatives of $f(u)=1/(1-u)$ and $g(t)$ that appear due to repeatedly differentiating (applying chain and product rules creating those multiple terms). Faa di Bruno's formula keeps track of those terms. In this case because the derivatives of $t^2$ terminate at some point it becomes relatively easy to keep track of the terms. Of course other ways to derive the series are easier but this one is also cool. $\endgroup$ Commented Sep 18, 2019 at 7:13
  • $\begingroup$ This is a really interesting result. Thank you for sharing it. $\endgroup$
    – Ron Snow
    Commented Sep 19, 2019 at 3:32
  • 1
    $\begingroup$ It is actually a cumbersome way to compute $!n( (1-t)^{-n} - (-1-t)^{-n})$ $\endgroup$ Commented Sep 19, 2019 at 6:47

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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