If X is a random variable where X takes only non-negative integer values, then GX(s) = E(sX) is the probability generating function (pgf). Then
The mean and variance of X can also be computed using the pgf from
The pgf of the sum X + Y of two independent random variables is given by
and for random sampling, where Z = X1 + … + XN, with N itself a random variable and the Xi are iid, then