Mathematics Stack Exchange is a question and answer site for people studying math at any level and professionals in related fields. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Show that $(1 - x - x^2 - x^3 - x^4 - x^5 -x^6)^{-1}$ is the generating function for the umber of ways a sum of r can occur if a die is rolled a number of times.

share|cite|improve this question
This seems similar to this question. – robjohn Nov 6 '13 at 9:15

Consider the product $$ \left(x+x^2+x^3+x^4+x^5+x^6\right)^n\tag{1} $$ The choice of a term in each factor of $(1)$ corresponds to the choice of a face on each of $n$ dice. The coefficient of $x^k$ in $(1)$ is the number of ways for the faces of $n$ dice to sum to $k$.

The coefficient of $x^k$ in the sum of $(1)$ over all $n$ gives the number of ways to roll a $k$ on the faces of any number of dice.

Using the formula for the sum of a geometric series, we get $$ \sum_{n=0}^\infty\left(x+x^2+x^3+x^4+x^5+x^6\right)^n=\frac1{1-\left(x+x^2+x^3+x^4+x^5+x^6\right)}\tag{2} $$

share|cite|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.