It is usual in Fourier analysis to prove the orthogonality of the basis $\{\cos(nt),\sin(nt)\}$ by considering the integrals from $-\pi$ to $\pi$. The proof is standard and can be found in several books.
I was wondering if there is a simple way to prove an analogous result with sums. Namely,
$\sum_{t=1}^N \sin\left(\frac{2\pi t p }{N}\right)\cos\left(\frac{2\pi t q}{N}\right)=0$ $\quad \forall p,q\leq [\frac{N}{2}] \in \Bbb Z $
$\sum_{t=1}^N \cos\left(\frac{2\pi t p }{N}\right)\cos\left(\frac{2\pi t q }{N}\right)=0$ $\quad \forall p\neq q\leq [\frac{N}{2}] \in \Bbb Z$
$\sum_{t=1}^N \sin\left(\frac{2\pi t p }{N}\right)\sin\left(\frac{2\pi t q }{N}\right)=0$ $\quad \forall p\neq q\leq [\frac{N}{2}] \in \Bbb Z$
And when $p=q$ the last two equations should give $\frac{N}{2}$.
The obvious trick (true in general for proving anything about Fourier series) is to use $e^{int}$ instead of $\cos nt, \sin nt$. Let $\omega = e^{2\pi i/N}$ and note that $\omega^{N(p+q)} = 1$ for any integer $p,q$. Now:
$$\sum_{n = 1}^N e^{np2\pi i/N}e^{nq2\pi i/N} = \sum_{n = 1}^N \omega^{(p+q)n} = \frac{\omega^{(p+q)(N+1)} - \omega^{p+q}}{\omega^{p+q} - 1} = 0$$
as long as $p+q \ne 0$, so that the denominator isn't $0$. When $p+q = 0$, the sum is obviously $N$.
To prove your results, $$\begin{align}\sum_{n=1}^N \sin\left(\frac{2\pi n p }{N}\right)\cos\left(\frac{2\pi n q}{N}\right) &= \frac1{4i}\sum_{n=1}^N (\omega^{pn} - \omega^{-pn})(\omega^{qn} + \omega^{-qn})\\&= \frac1{4i}\left[\sum_{n=1}^N \omega^{(p+q)n} + \sum_{n=1}^N \omega^{(p-q)n}-\sum_{n=1}^N \omega^{(q-p)n}-\sum_{n=1}^N \omega^{(p+q)n}\right] \end{align}$$ If $p \ne \pm q$, then all four sums are $0$. If $p = \pm q$, then two sums are $0$ and the other two are $N$, but of opposite signs, so the overall sum is still $0$.
A similar analysis works for the other two formulas.