Probability Generating Function of Discrete Uniform Distribution

Theorem
Let $$X$$ be a discrete random variable with the discrete uniform distribution with parameter $n$.

Then the p.g.f. of $$X$$ is:
 * $$\Pi_X \left({s}\right) = \frac {s \left({1 - s^n}\right)} {n \left({1 - s}\right)}$$

Proof
From the definition of p.g.f:


 * $$\Pi_X \left({s}\right) = \sum_{x \ge 0} p_X \left({x}\right) s^x$$

From the definition of the discrete uniform distribution:
 * $$\forall k \in \N, 1 \le k \le n: p_X \left({k}\right) = \frac 1 n$$

So:

$$ $$ $$

Hence the result.