Skip to content

Actuarial Statistics · Generating functions

Probability Generating Function (PGF): Definition, Properties and Uses

Updated 11 October 2026 · Fact-checked

The probability generating function of a random variable X taking values 0, 1, 2, … is G(s) = E[s^X] = Σ P(X = x) s^x. To solve questions, read probabilities as coefficients of powers of s, and get factorial moments by differentiating G(s) and setting s = 1.

Understand Probability Generating Function (PGF)

A probability generating function (PGF) packs a whole discrete distribution into one function. It works only for random variables that take non-negative integer values: 0, 1, 2, and so on. Claim counts are the classic actuarial example.

The definition is G(s) = E[s^X] = Σ s^x P(X = x), summed over x = 0, 1, 2, … Think of it as a polynomial or power series in s. The coefficient of s^x is exactly P(X = x). So if you know G(s), you know every probability.

Why is it useful? Differentiating G(s) and putting s = 1 gives factorial moments, from which you get the mean and variance. Also, the PGF of a sum of independent variables is the product of their PGFs. This makes sums of claim counts easy to handle.

The PGF is linked to the moment generating function (MGF): M(t) = G(eᵗ). The main differences: the PGF only suits non-negative integer variables, while the MGF suits any variable (where it exists). The PGF gives probabilities directly by expansion. The MGF gives moments by differentiating at t = 0.

The PGF always exists for |s| ≤ 1, because G(1) = 1 and the probabilities are non-negative. Uniqueness holds: two variables with the same PGF have the same distribution.

Key rules to remember

Definition
G(s) = E[s^X] = Σ s^x P(X = x), x = 0, 1, 2, …
X must take non-negative integer values. Valid at least for |s| ≤ 1.
Total probability
G(1) = 1
Use this as a quick check on any PGF you derive.
Probabilities from the PGF
P(X = k) = G⁽ᵏ⁾(0) ÷ k!
G⁽ᵏ⁾ is the k-th derivative. Equivalently, P(X = k) is the coefficient of sᵏ. So P(X = 0) = G(0).
Mean
E[X] = G′(1)
First factorial moment.
Factorial moments
E[X(X − 1)…(X − k + 1)] = G⁽ᵏ⁾(1)
Assumes the moment is finite.
Variance
Var(X) = G″(1) + G′(1) − [G′(1)]²
Since E[X(X − 1)] = G″(1) and E[X²] = G″(1) + G′(1).
Independent sum
If X and Y are independent, G_{X+Y}(s) = G_X(s) G_Y(s)
Needs independence.
Linear change
G_{a+X}(s) = sᵃ G_X(s) for integer a ≥ 0
Shifts the distribution by a.
Link to MGF
M_X(t) = G_X(eᵗ)
Valid where both exist.
Standard PGFs
Binomial(n, p): (1 − p + ps)ⁿ. Poisson(λ): e^{λ(s − 1)}. Geometric on 0, 1, 2, … with P(X = x) = p(1 − p)ˣ: p ÷ (1 − (1 − p)s)
Check which geometric definition the question uses.

How to solve Probability Generating Function (PGF) questions

Use this method for most PGF questions, whether you are given the distribution or the PGF.

  1. 1Check the variable takes values 0, 1, 2, … only. If not, the PGF is not defined in the usual way.
  2. 2If you are given the distribution, write G(s) = Σ s^x P(X = x) and sum the series using a known result (binomial, exponential or geometric series).
  3. 3If you are given G(s), check G(1) = 1. A failure signals an error or a missing constant.
  4. 4For probabilities, expand G(s) as a power series and read off the coefficient of sˣ. Or use P(X = k) = G⁽ᵏ⁾(0) ÷ k!.
  5. 5For moments, differentiate G(s), then substitute s = 1. Get G′(1) for the mean and G″(1) for E[X(X − 1)].
  6. 6Convert to the variance using Var(X) = G″(1) + G′(1) − [G′(1)]².
  7. 7For sums of independent variables, multiply the PGFs, then apply steps 4 to 6 to the product.
  8. 8State your answer clearly with the notation used, and note any assumption such as independence.

Quickest way: Read it off, then differentiate at 1

When to use it: When G(s) is given in a recognisable standard form or as a short polynomial, and the question asks for probabilities or the mean and variance.

  1. Compare G(s) with the standard PGFs (binomial, Poisson, geometric). If it matches, quote the known mean and variance.
  2. For a polynomial or simple series, read probabilities directly as coefficients.
  3. For the mean, compute G′(1) only. For the variance, compute G″(1) as well and use G″(1) + G′(1) − [G′(1)]².
  4. Use G(1) = 1 to check your answer or find an unknown constant.

Common mistakes in Probability Generating Function (PGF)

  • Using G″(1) as E[X²] or as the variance

    Students copy the MGF idea that the second derivative gives the second moment.

    Fix: G″(1) = E[X(X − 1)]. Then Var(X) = G″(1) + G′(1) − [G′(1)]².

  • Differentiating at s = 0 for moments, or at s = 1 for probabilities

    The two evaluation points get mixed up.

    Fix: Probabilities: evaluate at s = 0 and divide by k!. Moments: evaluate at s = 1.

  • Forgetting to divide by k! when finding P(X = k) from a derivative

    Students remember G⁽ᵏ⁾(0) but not the factorial from the Taylor series.

    Fix: Write P(X = k) = G⁽ᵏ⁾(0) ÷ k! every time. Or just read the coefficient of sᵏ.

  • Multiplying PGFs for dependent variables

    The product rule is remembered without its condition.

    Fix: State independence before using G_{X+Y}(s) = G_X(s) G_Y(s).

  • Applying the PGF to a variable that is not a non-negative integer

    Students treat the PGF as a general-purpose tool.

    Fix: Use the PGF only for counts. For continuous or general variables use the MGF.

  • Using the wrong geometric form

    Geometric is defined on 1, 2, … in some texts and on 0, 1, … in others.

    Fix: Derive the PGF from the stated probability function. Do not rely on memory.

Worked examples

Example 1

X has PGF G(s) = (0.4 + 0.6s)³. Find P(X = 2), E[X] and Var(X).

Show the solution
  1. This is a binomial PGF with n = 3 and p = 0.6, since (1 − p + ps)ⁿ with 1 − p = 0.4.
  2. Check: G(1) = (0.4 + 0.6)³ = 1.
  3. P(X = 2) is the coefficient of s²: C(3, 2) × 0.6² × 0.4 = 3 × 0.36 × 0.4 = 0.432.
  4. G′(s) = 3(0.4 + 0.6s)² × 0.6 = 1.8(0.4 + 0.6s)². So G′(1) = 1.8, which is E[X].
  5. G″(s) = 1.8 × 2(0.4 + 0.6s) × 0.6 = 2.16(0.4 + 0.6s). So G″(1) = 2.16.
  6. Var(X) = 2.16 + 1.8 − 1.8² = 3.96 − 3.24 = 0.72.
  7. Check with np(1 − p) = 3 × 0.6 × 0.4 = 0.72.

Answer: P(X = 2) = 0.432, E[X] = 1.8, Var(X) = 0.72.

Example 2

The number of claims X has PGF G(s) = k ÷ (2 − s). Find k, P(X = 0), P(X = 1) and E[X].

Show the solution
  1. Use G(1) = 1: k ÷ (2 − 1) = k = 1. So G(s) = 1 ÷ (2 − s).
  2. Rewrite: G(s) = (1/2) ÷ (1 − s/2) = (1/2) Σ (s/2)ˣ for |s| < 2.
  3. So P(X = x) = (1/2)(1/2)ˣ = (1/2)^(x+1).
  4. P(X = 0) = 1/2 and P(X = 1) = 1/4.
  5. G′(s) = 1 ÷ (2 − s)². So G′(1) = 1, giving E[X] = 1.
  6. Check: this is geometric on 0, 1, … with p = 1/2, whose mean is (1 − p) ÷ p = 1.

Answer: k = 1, P(X = 0) = 1/2, P(X = 1) = 1/4, E[X] = 1.

Exam tips

  • Always state that X takes values 0, 1, 2, … before using a PGF.
  • Memorise the binomial, Poisson and geometric PGFs. Recognising them saves several lines of working.
  • Write the factorial-moment-to-variance formula in full. Examiners award marks for the method.
  • Use G(1) = 1 to check your result or find an unknown constant before doing anything else.
  • In MCQs, check whether the question wants P(X = k) or a moment. That decides whether you evaluate at 0 or at 1.

Practice questions from Generating functions

Probability Generating Function (PGF): frequently asked questions

What is the difference between a PGF and an MGF?

The PGF is G(s) = E[sˣ] and applies only to non-negative integer variables. The MGF is M(t) = E[eᵗˣ] and applies to any variable where it exists. They are related by M(t) = G(eᵗ). The PGF gives probabilities by expansion, and the MGF gives moments by differentiating at 0.

How do I find probabilities from a probability generating function?

Expand G(s) as a power series in s. The coefficient of sˣ is P(X = x). Alternatively, differentiate k times, set s = 0 and divide by k!.

Why is G(1) always equal to 1?

At s = 1, G(1) = Σ P(X = x), which is the sum of all probabilities. That sum is 1 for any proper distribution.

How do I get the variance from a PGF?

Compute G′(1) and G″(1). Then use Var(X) = G″(1) + G′(1) − [G′(1)]². Remember G″(1) is E[X(X − 1)], not E[X²].