How to prove that if $\theta _1,\theta _2,\theta _3$ be the arguments of the primitive roots of unity, $\sum \cos p\theta = 0$ when $p$ is a positive integer less than $\dfrac {n} {abc\ldots k}$, where $a, b, c, \ldots, k$ are the different constituent primes of n and when $p=\dfrac {n} {abc\cdots k}$, $\sum \cos p\theta = \dfrac {\left( -\right)^\mu n} {abc\cdots k}$, where $\mu$ is the number of the constituent primes.

Any help would be much appreciated.

Here is where i got stuck i was hoping for a direct proof starting with the LHS of $\sum \cos p\theta = 0$.

**Solution attempt**

Well as we know the number of primitive roots(roots the power of which give all the roots) is the number of integers(including unity) less than n and prime to it. Hence we get this number from Euler's totient or phi function.

In the first part of the problem we are asked to assume $0 < p < \dfrac {n} {abc\ldots k}$.

So applying Taylor's series expansion to LHS we get $\sum _{i=1}^{i=\varphi \left( n\right) }\cos p\theta _{i} = \sum _{i=1}^{i=\varphi \left( n\right) }\left( 1-\dfrac {\left( p\theta _{i}\right) ^{2}} {2!}+\dfrac {\left( p\theta _{i}\right) ^{4}} {4!}-...\right) $

Combining terms from various expansions we get $\sum _{i=1}^{i=\varphi \left( n\right) }\cos p\theta _{i} = \varphi \left( n\right) -\dfrac {p^{2}} {2!}\sum _{i=1}^{i=\varphi \left( n\right) }\theta _{i}^{2} + \dfrac {p^{4}} {24}\sum _{i=1}^{i=\varphi \left( n\right) }\theta _{i}^{4} - ...$

I am unsure how to proceed from here although the pattern of alternating signs required for the second result are starting to appear. Any clues or pointers about results related to arguments of primitive roots, would be highly appreciated.