Orthogonality of roots of unity
= Orthogonality of roots of unity
For $\omega=e^{2\pi i/N}$,
$$
\sum_{n=0}^{N-1}\omega^{kn}
=\begin{cases}N,&N\mid k,\\0,&N\nmid k.\end{cases}
$$
This finite geometric sum is the orthogonality relation underlying the <discrete Fourier transform>.