Why MGF Derivatives Contain Moment Information
A moment generating function packages information about a distribution into a function of one real variable. Its name reflects a precise relationship: when the function is finite on an open interval around zero, its derivatives at zero give the raw moments of the random variable. The condition about an interval matters. Knowing only that the function is defined at zero is not enough to justify differentiating it through an expectation.
The key step is to justify exchanging differentiation and expectation. This tutorial states the required condition, explains why it supplies a suitable bound, and works through examples where the identity applies and where it does not. The distinction between a derivative and a power-series coefficient is especially important in calculations.
Here \(X^0=1\), so the order-zero identity says \(M_X(0)=E[1]=1\). For \(n\geq 1\), \(E[X^n]\) is a raw moment: it is not centered by subtracting the mean. The theorem also implies that \(E[|X|^n]\) is finite under the stated MGF condition, so these expectations are well-defined.
Why Differentiation Under the Expectation Is Valid
For a fixed value of \(X\), ordinary calculus gives \(\frac{d^n}{dt^n}e^{tX}=X^n e^{tX}\). But \(M_X(t)\) is an expectation of \(e^{tX}\), and differentiating the integrand alone does not automatically prove that the derivative can pass through the expectation. The neighborhood condition provides the needed control over the integrand, including when \(X\) can be large in magnitude.
Since the MGF is finite on an open interval around zero, choose \(a>0\) such that \(M_X(a)\) and \(M_X(-a)\) are finite.
For every real \(x\), \(e^{a|x|}\leq e^{ax}+e^{-ax}\). Consequently, \(E[e^{a|X|}]\leq M_X(a)+M_X(-a)<\infty\).
Fix \(b\) with \(0<b<a\). For each fixed nonnegative integer \(n\), there is a finite constant \(C\) such that \(y^n e^{by}\leq C e^{ay}\) for all \(y\geq0\). Thus \(|X|^n e^{b|X|}\) has finite expectation.
On any sufficiently small interval of \(t\)-values with \(|t|\leq b\), the \(n\)th derivative of \(e^{tX}\) is bounded in absolute value by \(|X|^n e^{b|X|}\). The same type of bound applies to the difference quotients used for the next derivative. The dominated convergence theorem therefore permits differentiation under the expectation, repeatedly.
This establishes \(M_X^{(n)}(t)=E[X^n e^{tX}]\) at interior points where the local bounds apply. Setting \(t=0\) gives the stated raw-moment formula. It also explains why finiteness merely at \(t=0\) is not the condition: \(M_X(0)=1\) for every probability distribution, whether or not the MGF is finite at any nonzero \(t\).
Worked Examples
Worked Example: A Third Derivative and Its Series Coefficient
A random variable \(X\) takes the value \(-1\) with probability \(1/2\) and the value \(2\) with probability \(1/2\). Find \(M_X'''(0)\), and verify it directly from the third raw moment. Identify the coefficient of \(t^3\) in the MGF expansion.
Method and condition. The distribution has finite support, so \(e^{tX}\) is bounded over the two possible values of \(X\) for every fixed real \(t\). Its MGF is finite on an interval around zero, and the derivative identity applies.
Step 1: Write the MGF. Weight \(e^{tx}\) by the probability at each possible value:
Step 2: Differentiate three times. Each differentiation of \(e^{ct}\) introduces a factor of \(c\). Therefore
At zero, \(e^0=1\), so
Step 3: Check by calculating the raw moment.
Step 4: Distinguish the coefficient from the derivative. The \(t^3\) term in \(e^{2t}\) has coefficient \(2^3/3!=8/6=4/3\). After multiplying by the probability \(1/2\), its contribution to the coefficient in \(M_X(t)\) is \(2/3\), not \(1/3\). The \(e^{-t}\) term contributes \(-1/12\), so the total coefficient of \(t^3\) is \(2/3-1/12=7/12\). The third derivative at zero is \(3!\) times that coefficient:
The derivative and the direct moment agree. Common mistake avoided: treating the coefficient of \(t^3\) as the third derivative. For a power series, the coefficient must be multiplied by \(3!\).
Worked Example: Checking a Third Moment from a Density
A continuous random variable has density \(f_X(x)=2x\) for \(0<x<1\), and zero elsewhere. Find \(M_X'''(0)\) using the MGF expansion, then verify the answer by integration.
Method and condition. First check the density: \(\int_0^1 2x\,dx=1\). Since \(X\) is bounded between 0 and 1, \(e^{tX}\leq e^{|t|}\) for every possible value of \(X\). Thus its MGF is finite for every real \(t\), and differentiation under the expectation is justified.
Step 1: Express the MGF as an expectation.
Expand the exponential in its power series. On the bounded interval \(0\leq x\leq1\), the series for \(e^{tx}\) converges uniformly for each fixed \(t\), so it can be integrated term by term:
The last equality follows from \(\int_0^1 x^{k+1}\,dx=1/(k+2)\). The coefficient of \(t^3\) is therefore
Step 2: Convert that coefficient to a derivative. The third derivative at zero is \(3!\) times the coefficient:
Step 3: Verify by direct integration.
The two methods agree. Common mistake avoided: reporting \(1/15\), the series coefficient, as the third moment. The required factor \(3!\) gives the moment \(2/5\).
Worked Example: When the MGF Derivative Rule Does Not Apply
Let \(X\) have the Cauchy density \(f_X(x)=1/[\pi(1+x^2)]\) for real \(x\). Determine whether the derivative identity can be used to find its first moment.
Method and condition. Before differentiating an MGF, check that it is finite on an open interval around zero. At \(t=0\), \(M_X(0)=E[1]=1\), but this single value does not establish the required condition.
For \(t>0\), the positive-tail part of the expectation is
For sufficiently large \(x\), \(1+x^2\leq 2x^2\), so the integrand is at least \(e^{tx}/(2\pi x^2)\). The latter function has a divergent integral on a positive tail: exponential growth eventually exceeds the polynomial factor \(x^2\). Hence \(M_X(t)=\infty\) for \(t>0\). For \(t<0\), the same argument applies on the negative tail by substituting \(y=-x\), and again the expectation diverges.
Thus \(M_X(t)\) is finite at zero but not at any nonzero \(t\); it does not exist on an open interval around zero. The derivative identity cannot be invoked. In fact, the absolute first moment diverges, since
The symmetric principal value of \(E[X]\) is not the ordinary expectation: the positive and negative parts are both infinite. Common mistake avoided: differentiating \(M_X(0)=1\) as if the MGF were defined near zero. A function’s value at one point does not guarantee that a derivative exists there.
What the Result Does and Does Not Say
The result is powerful because one function can encode all raw moments, provided the MGF exists in a neighborhood of zero. It is not a rule for differentiating any expression that happens to equal 1 at zero. Always check the MGF’s domain before applying the identity, especially for distributions with substantial tail probabilities.
A related distinction is that finite moments alone do not guarantee an MGF exists near zero. The derivative formula has a specific hypothesis: finiteness on an open interval containing zero. Once that condition holds, the theorem justifies the derivative calculation; without it, a separate argument is needed for any proposed moment calculation.
| Situation | What follows |
|---|---|
| MGF finite on an open interval around zero | All raw moments exist, and \(M_X^{(n)}(0)=E[X^n]\). |
| MGF finite only at zero | This gives \(M_X(0)=1\), but does not justify taking derivatives. |
| A coefficient of \(t^n\) is known in a valid MGF series | Multiply that coefficient by \(n!\) to obtain the \(n\)th derivative at zero. |
The most reliable exam procedure is to state the local existence condition, differentiate carefully, evaluate at zero, and distinguish the derivative from any series coefficient used along the way. This reasoning is aligned with the SOA VEE Mathematical Statistics syllabus.
Check Your Understanding
For each problem, first check whether the MGF condition needed for the identity is satisfied.
- \(X\) equals 0 with probability 0.4 and 3 with probability 0.6. Find \(M_X'''(0)\). (Answer: \(16.2\))
- \(X\) has density \(f_X(x)=3x^2\) for \(0<x<1\), and zero elsewhere. Find \(M_X''(0)\) by using the derivative identity and direct integration. (Answer: \(3/5=0.6\))
- \(X\) equals \(-1\) or \(1\), each with probability \(1/2\). Find the coefficient of \(t^4\) in \(M_X(t)\), then find \(M_X^{(4)}(0)\). (Answer: coefficient \(1/24\); derivative \(1\))
- A density is \(f_X(x)=2e^{-2x}\) for \(x>0\), and zero elsewhere. Its MGF is finite for \(t<2\). Use the identity to find \(M_X''(0)\). (Answer: \(1/2\))
- \(X\) has density \(1/[\pi(1+x^2)]\) on the real line. Is \(M_X(0)=1\) sufficient to apply the derivative identity for \(E[X]\)? (Answer: No; the MGF is infinite for every nonzero \(t\), so it is not finite on an open interval around zero.)