Intuition The one idea behind everything on this page
A random quantity X is fully described by an infinite list of summary numbers called moments, and the moment generating function is a single machine that stores all of them at once. Before you can trust that machine you must be fluent in six small ideas — expectation, powers of a random variable, the number e , the exponential as a function of a dial t , the Taylor series, and independence — so this page builds each from zero and shows how they snap together.
Below is the full cast of symbols the parent note uses. We meet them in an order where each one only needs the ones before it.
Definition Random variable
X is a number that comes out of a random experiment . Roll a die: X is the face. Measure a person's height: X is the height. It is not one fixed number — it is a placeholder for "whatever the experiment gives this time".
Think of X as an arrow that lands somewhere on a number line, and there is a "cloud of chance" saying how likely each landing spot is. Some spots are thick with probability, some are thin.
Figure s01 (below): the horizontal chalk line is the number line of possible values of X ; the blue curve above it is the cloud of chance (taller where a value is more likely); the pink arrow shows one particular landing of X at the value 6 . Read it as "this run of the experiment happened to give X = 6 , and 6 sat under a thick part of the cloud, so it was a likely outcome."
Why the topic needs it: the MGF is a fingerprint of a distribution . No random variable, nothing to fingerprint. See Probability Distributions for how that "cloud of chance" is written down.
Definition Probability mass and density
If X only lands on separated values (like die faces), p ( x ) is the ==probability that X equals exactly x ==. Bars of height p ( x ) , and all bars sum to 1 .
If X can land anywhere on a continuum (like height), f ( x ) is a density : a smooth curve where area under a stretch = probability of landing in that stretch. Total area = 1 .
Definition Support — the values that actually matter
The support of X is the set of x where there is any chance at all: the x with p ( x ) > 0 (discrete) or f ( x ) = 0 (continuous). Everywhere outside the support the weight is 0 , so those points contribute nothing. This is what "∑ x " and "∫ − ∞ ∞ " secretly mean: sweep over every possible value, but only the support pulls its weight.
f ( x ) is the probability that X = x ."
Why it feels right: it looks just like p ( x ) .
The fix: for a continuous X , P ( X = one exact point ) = 0 . Only areas (integrals) of f are probabilities. That is why the continuous MGF uses ∫ … f ( x ) d x and the discrete one uses ∑ … p ( x ) .
Why the topic needs it: the two MGF formulas in the parent — a sum and an integral — are literally "add up e t x weighted by how likely x is". p and f are the weights.
Definition Generic functions
g , h and generic variables U , V
Throughout this page, g and h are any ordinary functions you might apply to a random value — e.g. g ( x ) = x , or g ( x ) = x 2 , or g ( x ) = e t x . Likewise U and V are any two random variables . We write things in this generic form so one statement covers all the specific cases the parent needs at once.
The expected value E [ g ( X )] is the ==average of g ( X ) , where each possible value is weighted by its probability==. The sum runs over every x in the support of X (all x with p ( x ) > 0 ); the integral runs over the whole real line, but only the support (where f ( x ) = 0 ) contributes:
E [ g ( X )] = ∑ x : p ( x ) > 0 g ( x ) p ( x ) (discrete) , E [ g ( X )] = ∫ − ∞ ∞ g ( x ) f ( x ) d x (continuous) .
Intuition Balance-point picture
Put a weight p ( x ) on the number line at each spot x . The expectation E [ X ] is the balance point — where a ruler carrying those weights would sit level on a finger.
Figure s02 (below): five blue bars sit at the values x = 1 , 2 , 3 , 5 , 8 with heights proportional to their probabilities p ( x ) = 0.1 , 0.15 , 0.3 , 0.25 , 0.2 . The pink arrow marks the balance point — the value at which the loaded ruler tips level. That balance point is E [ X ] = 1 ( 0.1 ) + 2 ( 0.15 ) + 3 ( 0.3 ) + 5 ( 0.25 ) + 8 ( 0.2 ) = 4.15 . Notice it leans toward 8 because that value, though not the most likely, is far out and carries real weight.
Why the topic needs it: the MGF is an expectation: M X ( t ) = E [ e tX ] . Every derivation is "apply E , use linearity".
n -th moment
The ==n -th moment== of X is E [ X n ] : take the random value, raise it to the n -th power, then average.
E [ X ] = center (mean).
E [ X 2 ] feeds spread: Var ( X ) = E [ X 2 ] − ( E [ X ] ) 2 .
E [ X 3 ] feeds lopsidedness (skew), E [ X 4 ] feeds tail-heaviness, and so on.
Intuition Why raise to powers?
Squaring makes big deviations count more , so E [ X 2 ] feels width. Cubing keeps the sign, so E [ X 3 ] can tell left-lean from right-lean. Each higher power is a sharper "probe" of the shape.
Why the topic needs it: the whole point of the MGF is to store this infinite list E [ X ] , E [ X 2 ] , E [ X 3 ] , … compactly. No moments, no reason for a moment-generating function.
e and e u
e ≈ 2.718 is the special base for which the function e u equals its own slope everywhere : the curve's steepness at any point equals its height there.
Figure s03 (below): the pale-yellow curve is y = e u . At the marked pink point (u = 0.7 ) the dashed blue line is the tangent; its slope is drawn equal to the curve's height there (≈ 2.01 ). This picture is the equation d u d e u = e u — height and slope coincide at every point.
Why the topic needs it: the MGF is built on e tX . When we later differentiate the MGF many times to extract moments, the exponential's self-derivative property is what makes the algebra clean instead of monstrous.
Definition The dummy variable
t
t is a tuning knob we invented . It is not a value of X and it is not time. We slide t near 0 and watch how e tX responds; the response encodes the moments.
t must mean something physical, like time."
Why it feels right: t usually means time.
The fix: here t is pure bookkeeping. Its job is to be differentiated with respect to and then set to 0 . Any letter would do; t is tradition.
t near 0 ?
Near t = 0 , e tX ≈ 1 + tX + 2 t 2 X 2 + ⋯ — a tidy stack where the coefficient of each power of t is a different moment. Far from 0 the stack is still true but we only ever read it at 0 .
Definition Where the MGF is allowed to live — the neighbourhood of
0
The MGF M X ( t ) = E [ e tX ] is a sum or integral , and like any sum/integral it can blow up to + ∞ . It is only defined for those t where the total stays finite . For many familiar variables that happens on an ==open interval around 0 == of the form ( − r , r ) (or a one-sided piece of it); r is the "radius" of good behaviour.
Always safe at t = 0 : M X ( 0 ) = E [ e 0 ] = E [ 1 ] = 1 , finite for everyone.
Can fail for t = 0 : if the tail of X is heavy, e t x grows faster than the weight p ( x ) or f ( x ) shrinks, so the sum/integral diverges. Then no MGF exists for that t (e.g. the Exponential( λ ) MGF only converges for t < λ ; a Cauchy variable has no interval at all).
M X ( t ) is automatically finite, so I can skip checking."
Why it feels right: it looks like a harmless average.
The fix: always confirm the sum/integral converges on an interval around 0 before using M X . If it only converges at the single point t = 0 , the MGF is useless and you switch to the Characteristic Function , which is finite for every t .
Why the topic needs it: M X ( t ) = E [ e tX ] is a function of t . Every property (shift-scale M X ( a t ) , moment extraction " t = 0 ") is an operation on this dial — and every one of them silently assumes we are inside the convergence interval.
Definition Taylor series (at
0 )
Any smooth function g ( t ) can be rewritten near 0 as a sum of powers of t plus a leftover remainder R n ( t ) that collects everything past the n -th term:
g ( t ) = polynomial part g ( 0 ) + g ′ ( 0 ) t + 2 ! g ′′ ( 0 ) t 2 + ⋯ + n ! g ( n ) ( 0 ) t n + R n ( t ) .
The coefficient of t n is n ! g ( n ) ( 0 ) .
converges (informal sketch)
The remainder after n terms is controlled by the size of the ( n + 1 ) -th derivative times ( n + 1 )! t n + 1 . For g ( u ) = e u every derivative is again e u — bounded on any finite interval — while the ( n + 1 )! 1 factor crashes to 0 faster than t n + 1 can grow . So R n ( t ) → 0 as n → ∞ for every t : the exponential's series converges everywhere. This factorial-beats-power reason is exactly why the e tX expansion is safe to write term by term.
Intuition Why this is the whole trick
A power series has two readings of the coefficient of t n : it is n ! E [ X n ] (from the series above after averaging) and n ! M X ( n ) ( 0 ) (Taylor's rule). Setting them equal forces E [ X n ] = M X ( n ) ( 0 ) . The exponential was engineered so each power of t tags exactly one moment. (This term-by-term averaging is legitimate precisely on the convergence interval from §6.)
Why the topic needs it: this is the bridge from "MGF" to "moments". Deepen it in Taylor Series .
Definition Independent random variables
X and Y are independent (written X ⊥ Y ) if knowing one tells you nothing about the other. The key consequence, for any functions g and h :
E [ g ( X ) h ( Y )] = E [ g ( X )] E [ h ( Y )] .
Two separate clouds of chance that don't lean on each other. Their joint behaviour factors into "X 's cloud times Y 's cloud".
Why the topic needs it: Property 2 of the parent — M X + Y ( t ) = M X ( t ) M Y ( t ) — is exactly this factoring applied to g ( x ) = e t x and h ( y ) = e t y . Without independence the split is illegal. See Independence (Probability) .
Definition Reading the notation
M X ′ ( t ) = first derivative of the MGF (slope as we turn the dial).
M X ( n ) ( t ) = the n -th derivative (differentiate n times).
t = 0 = "then plug in t = 0 ".
So E [ X n ] = M X ( n ) ( 0 ) = d t n d n M X ( t ) t = 0 says: differentiate n times, then set the dial to zero.
t = 0 isolates one moment
Differentiating drops one power of t from each term. After n derivatives, every term that still carries a t vanishes at t = 0 ; only the term that was exactly n ! t n E [ X n ] survives, and its leftover constant is E [ X n ] .
Why the topic needs it: this is the moment-extraction formula — the payoff line of the whole topic.
Probability weights p or f
Expectation E averages with weights
Number e and self derivative
Taylor series stacks powers of t
MGF M of t equals E of e to the tX
Differentiate at 0 to get moments
Independence factors products
Everything on the left is prerequisite plumbing; the node M X ( t ) = E [ e tX ] is the topic itself, and the two outputs (moments via derivatives, sums via multiplication) are why we bothered — all guarded by convergence near 0 .
Test yourself — cover the right side.
What does X stand for, and is it a fixed number? A random variable — a placeholder for whatever number the experiment produces; not fixed.
Difference between p ( x ) and f ( x ) ? p ( x ) is the probability X equals exactly x (discrete); f ( x ) is a density where area under it gives probability (continuous).
What is the support of X ? The set of values with any chance: x where p ( x ) > 0 (discrete) or f ( x ) = 0 (continuous); only these contribute to sums/integrals.
In E [ g ( X )] and E [ g ( X ) h ( Y )] , what are g and h ? Any ordinary functions applied to the random value (e.g. x , x 2 , or e t x ).
Write E [ g ( X )] in the continuous case. ∫ − ∞ ∞ g ( x ) f ( x ) d x .
State linearity of expectation, naming what U , V , a , b are. For random variables U , V and constants a , b : E [ a U + bV ] = a E [ U ] + b E [ V ] .
What is the n -th moment of X ? E [ X n ] — the average of X raised to the n -th power.
What makes e u special among exponentials? d u d e u = e u ; it is its own derivative, so it survives repeated differentiation.
Write the Taylor series of e u and say why it converges everywhere. 1 + u + 2 ! u 2 + 3 ! u 3 + ⋯ ; the ( n + 1 )! 1 factor crushes the remainder faster than t n + 1 grows, so R n → 0 for all t .
Where is M X ( t ) actually defined, and what must you check? Only where E [ e tX ] is finite — typically an open interval around t = 0 ; always confirm the sum/integral converges there.
In the MGF, what role does t play? A dummy tuning dial we differentiate with respect to and then set to 0 ; not time, not a value of X .
What does X ⊥ Y let you do to E [ g ( X ) h ( Y )] ? Factor it: E [ g ( X ) h ( Y )] = E [ g ( X )] E [ h ( Y )] .
Translate M X ( n ) ( 0 ) in words. Differentiate the MGF n times, then evaluate at t = 0 .
Why does setting t = 0 after n derivatives isolate one moment? Every remaining term still containing t becomes 0 ; only the constant E [ X n ] survives.
Ready? Then head back to the parent note and watch these pieces assemble into M X ( t ) = E [ e tX ] .