# Reference for a tangent squared sum identity

Can anyone help me find a formal reference for the following identity about the summation of squared tangent function:

$$\sum_{k=1}^m\tan^2\frac{k\pi}{2m+1} = 2m^2+m,\quad m\in\mathbb{N}^+.$$

I have proved it, however, the proof is too long to be included in a paper. So I just want to refer to some books or published articles.

I also found it to be a special case of the following identity,

$$\sum_{k=1}^{\lfloor\frac{n-1}{2}\rfloor}\tan^2\frac{k\pi}{n} = \frac16(n-1)(-(-1)^n (n + 1) + 2 n - 1),\quad n\in\mathbb{N}^+$$

which is provided by Wolfram.

Thank you very much!

-
I can't give you a reference but check this question out. math.stackexchange.com/questions/2339/… – Aleks Vlasev Oct 20 '12 at 5:06
Thanks Aleks, it is pretty good to find this proof. However I think I'd better find a reference for it. – albert Oct 20 '12 at 5:15