Theorem (Multinomial Theorem): For any positive integer $m$ and any non-negative integer $n$, the following formula holds: $$ \left(\sum_{i=1}^m x_n\right)^n = \sum_{\begin{gathered} k_1+k_2+\dots+k_m=n; \\ k_1,k_2,\dots,k_m\geqslant 0\end{gathered}}\binom{n}{k_1,k_2,\dots,k_m}\prod_{t=1}^mx_t^{k_t} $$ where $\binom{n}{k_1,k_2,\dots,k_m}=n!\cdot\prod_{j=1}^m\dfrac{1}{k_j}=\dfrac{n!}{k_1!k_2!\dots k_m!}$.
I am looking for the special case of this theorem which can be applied to a polynomial of one variable. Thus, I need to find the expansion of $n$th degree polynomial $\left(P(x)\right)^n$, which is $P(x)=\sum_{k=0}^na_kx^k$.
I want to use the Multinomial Theorem to determine the coefficient of the $k$th term of the expanded form of polynomial $P(x)$ raised to the power of $n$, but I can't immediately notice something that would allow me to do that just as easily as I would do it with the Binomial Theorem after expanding binomals.
In other words, Binomial Theorem is too specific for my problem, and Multinomial Theorem is too general. I need to know something in between these two.
Let $P(x):=\sum_{k=0}^m a_kx^k$
When multiplying out $P(x)^n$, each summand of the result is created by by selecting from each factor of $P(x)^n$ a summand and multiplying them. Therefore, to get to degree $k$, we need to choose monoms whose degrees sum up to k:
$$ [x^k] P(x)^n = \sum_{i_1+...+i_n=k\\i_1,...,i_n\in\{0,...,m\}} a_{i_1}\cdots a_{i_n} $$ Here, $[x^k]$ denotes the operator which extracts the coefficient of $x^k$.