Is it always possible to find a $t>0$, such that
$$\int_{0}^{t}|\sum_{k=1}^{n}\cos kx|\,dx<C~~~?$$
where $C$ is independent of $n$.
Here is my idea:
We know that
\begin{align} \sum_{k=1}^{n}\cos kx&=\frac{\sin(n+\frac{1}{2})x}{2\sin\frac{1}{2}x}-\frac{1}{2}\\ &=\frac{\sin nx \cos\frac{1}{2}x+\cos nx\sin\frac{1}{2}x}{2\sin\frac{1}{2}x}-\frac{1}{2}\\ &=\frac{\sin nx\cos\frac{1}{2}x}{2\sin\frac{1}{2}x}+\frac{\cos nx}{2}-\frac{1}{2} \end{align} So we have \begin{align} \int_{0}^{t}|\sum_{k=1}^{n}\cos kx|\,dx\leq\int_{0}^{t}|\frac{\sin nx\cos\frac{1}{2}x}{2\sin\frac{1}{2}x}|+1\,dt \end{align} The key is that, could we find a constant $C$(just independent of $n$),such that \begin{align} \int_{0}^{t}|\frac{\sin nx\cos\frac{1}{2}x}{2\sin\frac{1}{2}x}|\,dt<C~? \end{align} It is an improper integral. If $$\lim_{\varepsilon \to 0^+}\int_{\varepsilon}^{t}|\frac{\sin nx\cos\frac{1}{2}x}{2\sin\frac{1}{2}x}|\,dt \to \infty$$ Then could we find an interval $[a,b](a>0)$, such that $$\int_{a}^{b}|\sum_{k=1}^{n}\cos kx|\,dx<C~~~?$$