<s>[INST] Proving $\sum\limits_{r=1}^n \cot \frac{r\pi}{n+1}=0$ using complex numbers Let $x_1,x_2,...,x_n$ be the roots of the equation $x^n+x^{n-1}+...+x+1=0$.

The question is to compute the expression $$\frac{1}{x_1-1} + \frac{1}{x_2-1}+...+\frac{1}{x_n-1}$$
  Hence to prove that $$\sum_{r=1}^n \cot \frac{r\pi}{n+1}=0$$ 

I tried rewriting the expression as $$\sum_{i=1}^n \frac{\bar{x_i}-1}{|x_i-1|^2}$$
I then used the fact that $$x^{n+1}-1=(x-1)(x^n+x^{n-1}+...+x+1=0$$ so $x_i$ are the complex nth roots of unity.Using cosine formula I found that $$|x_i-1|^2=2-2\cos(\frac{2i\pi}{n+1})=4(\sin \frac{\pi}{n+1})^2$$
After substituting this I couldn't simplify the resulting expression.Any ideas?Thanks.
 [/INST] For the first part : 
Write $$x^n+x^{n-1}+...+x+1 =(x-x_1)(x-x_2)\ldots (x-x_{n})$$
Take log both the sides
$$\log (x^n+x^{n-1}+...+x+1)= \log(x-x_1) +\log(x-x_2)+\ldots +\log(x-x_n)$$
Differentiating w.r.t. $x$, we get 
$$\frac{ nx^{n-1}+(n-1)x^{n-2}+\ldots+ 1}{x^n+x^{n-1}+...+x+1}= \frac{1}{x-x_1}+\frac{1}{x-x_2}+\ldots +\frac{1}{x-x_n}$$
Now put $x=1$
$$\frac{(n)+(n-1)+\ldots + 1}{1+1+\ldots +1}=-\left(\frac{1}{x_1-1} + \frac{1}{x_2-1}+...+\frac{1}{x_n-1}\right)$$
$$\color{red}{\boxed{ \frac{1}{x_1-1} + \frac{1}{x_2-1}+...+\frac{1}{x_n-1}=- \frac{n}{2} }}$$
</s>