$(x+x^2+x^3+x^4+x^5+x^6)^5$
How do I find the coefficients of this product quickly?
$(x+x^2+x^3+x^4+x^5+x^6)^5$
How do I find the coefficients of this product quickly?
$\displaystyle(x+x^2+x^3+x^4+x^5+x^6)^5$
$\displaystyle=x^5(1+x+x^2+x^3+x^4+x^5)^5$
$\displaystyle=x^5\left(\frac{1-x^6}{1-x}\right)^5$
$\displaystyle=x^5(1-x^6)^5(1-x)^{-5} $
For the expansion of the last expression, see Generalized binomial theorem
Here's a combinatorial answer: the coefficient of $x^n$ in the polynomial $(x + x^2 + x^3 + x^4 + x^5 + x^6)^5$ is the number of ordered tuples $(n_1,n_2,n_3,n_4,n_5)$ with $n_i\in\{1,2,3,4,5,6\}$ (the set of exponents) such that $n_1 + n_2 + n_3 + n_4 + n_5=n$.
EDIT: This answer is not entirely satisfactory since it does not include a formula for the coefficients. I expanded the product using Wolfram Alpha and searched for the sequence on OEIS. Apparently the coefficients are called "sextinomial coefficients". If I interpreted the site correctly, the coefficient of $x^{k+5}$ is given by $$ \sum_{i=0}^{\lfloor k/6\rfloor} (-1)^i\binom{n}{6}\binom{n+k-1-6i}{n-1}. $$