If $ \alpha_i, i=0,1,2...n-1 $ be the nth roots of unity, the $\sum_{i=0}^{n-1} \frac{\alpha_i}{3- \alpha_i}$ is equal to? If $ \alpha_i,  i=0,1,2...n-1 $ be the nth roots of unity, the $\sum_{i=0}^{n-1} \frac{\alpha_i}{3- \alpha_i}$ is equal to?
A) $ \frac{n}{3^n-1} $
B) $ \frac{n-1}{3^n-1} $
C) $ \frac{n+1}{3^n-1} $
D) $ \frac{n+2}{3^n-1} $
Attempt: I know that $(3- \alpha_0)(3- \alpha_1)....(3-\alpha_{n-1})= (3^n-1)/2 $
But I have no clue about the numerator. Adding 3 and subracting 3 from the numberator would make the fraction simpler, but I would still have to sum up $ 1/(3- \alpha_i) $
 A: Let $\dfrac{a_i}{3-a_i}=b_i\iff a_i=\dfrac{3b_i}{1+b_i}$
As $a_i^n=1,$
$$\left(\dfrac{3b_i}{1+b_i}\right)^n=1\iff(3^n-1)b_i^n-\binom n1b_i^{n-1}+\cdots=0$$
By Vieta's formula,
$$\displaystyle\sum_{i=0}^{n-1}b_i=\dfrac{\binom n1}{3^n-1}$$
A: $$\frac{u}{3-u}=\frac{3}{3-u}-1$$
So your sum is:
$$-n+3\sum \frac{1}{3-a_i}$$
Letting $p(x)=x^n-1$, show that $\frac{p'(x)}{p(x)}=\sum \frac{1}{x-a_i}$.

More generally, if $p(x)=(x-b_1)(x-b_2)\cdots (x-b_n)$ then $$\sum \frac{b_i}{b-b_i} = -n + b\frac{p'(b)}{p(b)}$$
A: (For future reference.) Introducing
$$f(z) = \frac{z}{3-z} \frac{nz^{n-1}}{z^n-1}$$
we get
$$S_n = \sum_{q=0}^{n-1} 
\frac{\exp(2\pi i q/n)}{3-\exp(2\pi i q/n)}
= \sum_{q=0}^{n-1} \mathrm{Res}_{z=\exp(2\pi i q/n)} f(z).$$
Residues sum to zero so we have
$$S_n + \mathrm{Res}_{z=3} f(z) +
\mathrm{Res}_{z=\infty} f(z) = 0$$
Observe that
$$\mathrm{Res}_{z=3} f(z) =
- \frac{n3^n}{3^n-1}$$
and
$$\mathrm{Res}_{z=\infty} f(z) =
-\mathrm{Res}_{z=0} \frac{1}{z^2} f(1/z) 
\\ = -\mathrm{Res}_{z=0} 
\frac{1}{z^2} \frac{1/z}{3-1/z} \frac{n/z^{n-1}}{1/z^n-1}
\\ = -\mathrm{Res}_{z=0} 
\frac{1}{z^2} \frac{1}{3z-1} \frac{nz}{1-z^n}
\\ = -\mathrm{Res}_{z=0} 
\frac{1}{z} \frac{1}{3z-1} \frac{n}{1-z^n}
= n.$$
Hence
$$S_n - \frac{n3^n}{3^n-1} + n = 0$$
or
$$S_n = \frac{n3^n-n(3^n-1)}{3^n-1} 
= \frac{n}{3^n-1}.$$
