Generating functions
Objective. Use probability and moment generating functions.
- 1. Learn
- 2. Worked example
- 3. Practice
- 4. Feedback
- 5. Continue
Learn: the key idea
Generating functions encode an entire probability distribution in a single function, with the moment generating function M(t) = E[e^(tX)] whose derivatives at t = 0 give the moments: M′(0) = E[X], M″(0) = E[X²]. For discrete non-negative integer variables, the probability generating function G(s) = E[s^X] similarly encodes probabilities as its Taylor coefficients. For X ~ Poisson(λ), M(t) = exp(λ(e^t − 1)), and differentiating twice at t = 0 recovers mean λ and variance λ.
Worked example
For a random variable with moment generating function M(t) = e^(3t+2t²), find E[X] using generating functions.
- 1Differentiate M(t) = e^(3t+2t²) using the chain rule
- 2M′(t) = (3+4t)e^(3t+2t²)
- 3Evaluate at t = 0: M′(0) = (3+0)e^0
- 4Simplify to obtain the mean
Answer: E[X] = 3
Concept mastery
Based on your past attempts at this lesson — the question types to practise again come first.
Complete a practice set to see your concept breakdown here.
Practice
Practice happens on its own screen, one question at a time. Answers stay hidden until you submit yours, and you can stop and pick up at the same question later.
Start practisingCommon mistake. A frequent mistake is computing E[X²] directly from M(0) rather than from M″(0), confusing the function's value with its derivatives. Remember moments come from differentiating the generating function then setting t = 0.
Your progress
Tick each step as you finish it. Your exact reading position is saved automatically, so Continue drops you back on the same line.
0 of 5 steps complete
Your place saves automatically as you read.