Sign in to save

Bookmark this page so you can find it later.

Sign in to save

Bookmark this page so you can find it later.

Generating functions turn sequences into power series so patterns, sums, and recurrences become easier to manipulate. This cheat sheet helps students connect algebraic operations with sequence behavior. It is especially useful for counting problems, recurrence relations, and series identities in advanced high school math.

The main skill is recognizing which series form matches the sequence in a problem.

The core idea is to represent a sequence a0,a1,a2,a_0, a_1, a_2, \ldots by A(x)=n=0anxnA(x) = \sum_{n=0}^{\infty} a_n x^n. Geometric series such as 11x=n=0xn\frac{1}{1-x} = \sum_{n=0}^{\infty} x^n are the starting point for many tricks. Differentiating, integrating, shifting, and multiplying generating functions create new sequences.

Coefficient notation [xn]A(x)[x^n]A(x) lets you extract the exact term you need.

Key Facts

  • The ordinary generating function for a sequence a0,a1,a2,a_0, a_1, a_2, \ldots is A(x)=n=0anxnA(x) = \sum_{n=0}^{\infty} a_n x^n.
  • Coefficient extraction is written as [xn]A(x)[x^n]A(x), meaning the coefficient of xnx^n in the power series A(x)A(x).
  • The basic geometric series identity is 11x=n=0xn\frac{1}{1-x} = \sum_{n=0}^{\infty} x^n for x<1|x| < 1.
  • Shifting a generating function by multiplying by xkx^k gives xkA(x)=n=0anxn+kx^k A(x) = \sum_{n=0}^{\infty} a_n x^{n+k}.
  • Differentiating gives A(x)=n=1nanxn1A'(x) = \sum_{n=1}^{\infty} n a_n x^{n-1}, which helps create factors of nn.
  • The series for counting nonnegative solutions to a+b+c=na+b+c=n is 1(1x)3\frac{1}{(1-x)^3}, and [xn]1(1x)3=(n+22)[x^n]\frac{1}{(1-x)^3} = \binom{n+2}{2}.
  • If a recurrence is linear, multiply both sides by xnx^n, sum over valid nn, and solve algebraically for the generating function.
  • The product A(x)B(x)A(x)B(x) has coefficients [xn]A(x)B(x)=k=0nakbnk[x^n]A(x)B(x) = \sum_{k=0}^{n} a_k b_{n-k}, called convolution.

Vocabulary

Generating function
A power series such as A(x)=n=0anxnA(x) = \sum_{n=0}^{\infty} a_n x^n that stores the terms of a sequence as coefficients.
Coefficient extraction
The notation [xn]A(x)[x^n]A(x) means the coefficient of xnx^n in the expanded form of A(x)A(x).
Ordinary generating function
A generating function where the sequence term ana_n is paired directly with xnx^n.
Geometric series
A series of the form 1+x+x2+x3+1+x+x^2+x^3+\cdots whose sum is 11x\frac{1}{1-x} when x<1|x| < 1.
Convolution
A rule for multiplying generating functions where the coefficient of xnx^n is k=0nakbnk\sum_{k=0}^{n} a_k b_{n-k}.
Recurrence relation
An equation that defines each term of a sequence using earlier terms, such as an=an1+an2a_n = a_{n-1}+a_{n-2}.

Common Mistakes to Avoid

  • Forgetting the starting index is wrong because n=0anxn\sum_{n=0}^{\infty} a_n x^n and n=1anxn\sum_{n=1}^{\infty} a_n x^n store different coefficients.
  • Dropping initial terms after shifting is wrong because multiplying by xx changes the powers and may leave constants such as a0a_0 outside the shifted sum.
  • Using 11x\frac{1}{1-x} for every series is wrong because sequences like 1,2,3,4,1,2,3,4,\ldots need 1(1x)2\frac{1}{(1-x)^2}, not 11x\frac{1}{1-x}.
  • Treating multiplication as term-by-term multiplication is wrong because A(x)B(x)A(x)B(x) uses convolution, so [xn]A(x)B(x)=k=0nakbnk[x^n]A(x)B(x)=\sum_{k=0}^{n}a_k b_{n-k}.
  • Ignoring the condition x<1|x|<1 in analytic problems is wrong because formulas such as 11x=n=0xn\frac{1}{1-x}=\sum_{n=0}^{\infty}x^n rely on convergence when xx is a number.

Practice Questions

  1. 1 Find [x5]11x[x^5]\frac{1}{1-x}.
  2. 2 Find [x4]1(1x)3[x^4]\frac{1}{(1-x)^3}.
  3. 3 If A(x)=112xA(x)=\frac{1}{1-2x}, write the first five terms of the sequence a0,a1,a2,a3,a4a_0,a_1,a_2,a_3,a_4.
  4. 4 Explain why multiplying two generating functions counts combinations of choices whose exponents add to the target power.