Generating Function
A generating function is essentially a summary for a sequence of numbers. It's a formal power series where the coefficients encode a sequence of numbers,
The ordinary generating function for a sequence
There is also a continuous analogue. If instead of a sequence one has a function
This plays the role of a continuous generating function, directly paralleling the discrete case.
When one reparametrizes with
and related choices of weighting lead to other transforms such as the Mellin transform.
Application in probability theory
For a discrete random variable
The PGF of
Sum of independent random variables
This is where the magic happens. If you have two independent discrete random variables,
This is incredibly useful because multiplying polynomials (or power series) is often much simpler than dealing with the distribution of the sum directly.
Relation to convolution
The process of finding the probability distribution of the sum of two independent random variables is equivalent to computing the convolution of their individual probability distributions.
Let
This sum is precisely the coefficient of the
In short: multiplication of generating functions corresponds to the convolution of their coefficient sequences.