The complex trigonometric function degenerates to the positive integer

Following Johann Cigler's suggestion, set $q=e^{\frac{i\pi}{N}}$. We will need the two evaluations $$\prod_{n=1}^{2N-1}(1-q^n)=\left.\frac{x^{2N}-1}{x-1}\right|_{x=1}=2N \tag{1}$$ $$\prod_{n=1}^{N-1}(1-q^{2n})=\left.\frac{x^{N}-1}{x-1}\right|_{x=1}=N \tag{2}$$ In your expression we can write things in the form $$2+2\sum _{m=1}^{n\ }\cos \frac{\ m\pi \ }{N}=2+\sum_{m=1}^n(q^m+q^{-m})=\frac{(1-q^{n+1})(1+q^n)}{q^n(1-q)}$$ and $$1+2\sum _{m=1}^{n\ }\cos \frac{\ m\pi \ }{N}=1+\sum_{m=1}^n(q^m+q^{-m})=\frac{(1-q^{2n+1})}{q^n(1-q)}.$$ Putting everything together, we see that your expression evaluates as \begin{gather*} \prod_{n=1}^{N-1}\frac{(1-q^{n+1})(1+q^n)}{q^n(1-q)}\cdot \frac{q^n(1-q)}{(1-q^{2n+1})}=\prod_{n=1}^{N-1}\frac{(1-q^{n+1})(1+q^n)}{1-q^{2n+1}} \\ =\frac{(1-q^N)}{1-q}\prod_{n=1}^{N-1}\frac{(1-q^n)(1+q^n)}{1-q^{2n+1}}=(1-q^N)\frac{\prod_{n=1}^{N-1}(1-q^{2n})^2}{\prod_{n=1}^{2N-1}(1-q^n)}=2\cdot\frac{N^2}{2N}=N \end{gather*} as desired.


I have no answer, but it seems that the problem is equivalent with $\frac{(-1;q)_{N-1}(-q;q)_{N-1}}{\binom{2N-2}{N-1}_q}=N$ for $q=e^{i \pi/N}.$