TITLE: Root of unity filter
QUESTION [15 upvotes]: Can some one help me understand the technique called "Root of unity filter" . I just know how to use it. It's as follow:
For series $f(x)=a_0+a_1x+a_2x^2+\cdots+a_nx^n$ we need to find the sum of coefficient of terms in which the power is a multiple of any number say $k$ for finding the same we have $\omega $ as $\mathrm{k^{th}}$ of unity and write
$$ \dfrac{f(1)+f(\omega)+f(\omega ^2)+ \cdots+ f(\omega^{k-1})}{k}=(a_0 + a_k + a_{2k}+\cdots)$$
please help me understand why and how this works , I tried googling but didn't get any satisfactory answer

REPLY [6 votes]: Hint: This technique is  called series multisection.

Some instructive examples can be found in H.S. Wilf's book generatingfunctionology (2.4.5) to (2.4.9).

Setting  $\omega_r=\exp\left(\frac{2\pi i}{r}\right), r\geq 1$ an integral value, the formula
\begin{align*}
\sum_{k=0}^{\left\lfloor\frac{n-a}{r}\right\rfloor}\binom{n}{a+kr}x^{a+kr}=\frac{1}{r}\sum_{k=1}^{r}\left(\omega_{r}^k\right)^{-a}\left(1+x\omega_r^k\right)^n, \qquad 0\leq a\leq n,a\leq r-1
\end{align*}
is stated as (6.20) in Binomial Identities Derived from Trigonometric and Exponential Series by H.W. Gould.



An application proving a binomial identity can be found e.g. in this MSE answer.