Big O for a $\cos$ series

1.7k Views Asked by At

I have to show that $ \sum_1^N \cos(nx) = O(\frac 1{|x|}), [-\pi, \pi] $, x different from 0.

I really don't know how to show that. I obviously know that $\cos(nx)$ is bounded by $1$, I know what big O means, but I have totally no clue for that one. Any hint? Thank you.

2

There are 2 best solutions below

4
On

We have

$$ \left|\sum_{n=1}^{N} \cos(nx) \right| \leq \sum_{n=1}^{N} |cos(nx)| \leq \sum_{n=1}^{N} 1 = N = N\pi \frac{1}{\pi} \leq N\pi \frac{1}{|x|} $$

for $x \in [-\pi,\pi]$, $x \neq 0$.

More generally, since the sum is bounded by the constant $N$ we can deduce that

$$ \sum_{n=1}^{N} \cos(nx) = O(f(x)) $$

for any function $f$ satisfying $|f(x)| \geq c > 0$ for some constant $c$. In our case we had $c = 1/\pi$.

0
On

Hint: A standard identity sometimes called Lagrange's identity says that our sum is equal to $$-\frac{1}{2}+\frac{\sin((N+\frac{1}{2})x)}{2\sin\left(\frac{x}{2}\right)}.$$