# Summations in $\tan^2$

Hey all,

I was just wondering if anyone had come across the following identities, valid for $m\in\mathbb{N}$. I've used Abramowitz and Stegun, Maple, Mathematica etc but can't find them anywhere. I can prove these, though they happen 'accidentally' from a method which I am already looking at. Anyway the identities are

$$\sum_{k=1}^m \left(\tan\left(\frac{\pi(2k-1)}{4m}\right)\right)^2=m(2m-1) \hspace{4mm} \textrm{and} \hspace{4mm} \sum_{k=1}^m \left(\tan\left(\frac{\pi k}{2m+1}\right)\right)^2=m(2m+1)$$

and

$$\sum_{k=1}^m \left(\tan\left(\frac{\pi(2k-1)}{4m}\right)\right)^4=\frac{1}{3}m(2m-1)(4m^2+2m-3) \hspace{4mm} etc$$

There are other identities for all even powers but I haven't worked them out yet as I thought that there might not be any point if there are known results for these summations. It would be cool if there were lists of such identities, or even a general formula, as this would provide me with many useful references indeed!

Many thanks on Christmas!

-
How do you derive these identities? –  Anixx Dec 25 '10 at 15:19
seems you confused m and n in the last identity –  Anixx Dec 25 '10 at 15:20
Not much of a simplification, but your first sum can be "cut in half": for even $m$, your sum is the same as $$\sum_{k=1}^{\lfloor m/2\rfloor}\left(\tan^2\left(\frac{\pi}{4m}(2k-1)\right)+\cot^2\left(\frac{\pi}{‌​4m}(2k-1)\right)\right)$$ ; for odd $m$, add 1. –  J. M. Dec 25 '10 at 15:22
(and something similar can be done for the other sums) –  J. M. Dec 25 '10 at 15:24
You'll find this and a list of further identities here emis.de/journals/HOA/IJMMS/30/3185.pdf –  dke Dec 25 '10 at 15:48

There is one natural way to study such identities based on discrete Fourier series. You can define functions as a Fourier series with coefficients equal to your summands. Then your sums will be equal to the values of these functions at $0$. For two presented sums you'll get polynomials of 2 and 4 degrees respectively. They are 2 terms of some "good" sequence of polynomials which can be defined recursively. These polynomials will be closely connected with Bernoulli polynomials. Some similar polynomials (discrete Bernoulli polynomials) are known as Korobov polynomials.
Some related examples are here: Lemma 2+ formula (6) and more symmetrical Fourier series for $Q_{2n}(x)$ (page 10).