upper bound for $L^1$ norm of Dirichlet kernel I showed there exists a constant $c$ such that $\|D_N\|_1 \geq c \log N$ and $c$ is independent to $N$
using the fact that $$\| D_N\|_1= \frac 1 \pi \int_{[0,\pi]} \left|\frac{\sin(2N+1)y}{\sin y}\right|\,dt \geq \frac{1}{\pi}\int_{[0,\pi/2]} \left| \frac{\sin(2N+1)y}{\sin y} \right| \, dt$$
and $$\frac 1 {| y |} \leq \frac{1}{\sin(y)} \leq \frac{\pi}{2|y|} \text{ for } y \in [0, \frac{\pi}{2}].$$
Now I want to show that there is a upper bound (i.e there exists a constant $c'$ such that $\|D_N\|_1 \leq c' \log N$ for $N\geq2$)
but this time I can't deduce the interval and the function diverges to infinity near $\pi$, so i have no clue how to start. Am I sppose to divide $[0, 2\pi]$ into three subintervals such as $[0, \delta], [\delta, 2\pi-\delta],$ and $[2\pi-\delta, 2\pi]$ and show on each interval $L^1$ norm of Dirichlet kernel converges to $0$ or multiple of $\log N$ as $\delta \rightarrow 0$? I saw this trick a lot in the other examples.

$\displaystyle\|D_n\|=\frac1\pi\int_0^\pi\left(f(x)|\sin(n+\frac12)x|+\frac{2|\sin(n+\frac12)x|}x\right)\text dx=I_1+I_2$,where $\displaystyle f(x)=\frac1{\sin\frac x2}-\frac2x$.
We have $\displaystyle|f(x)|\le1-\frac2\pi$,so $I_1=\mathcal O(1)$.
$\displaystyle I_2=\frac2\pi\int_0^\pi\frac{|\sin(n+\frac12)x|}x\text dx=\frac2\pi\int_0^{(n+\frac12)\pi}\frac{|\sin x|}x\text dx=\mathcal O(1)+\frac2\pi\sum\limits_{k=1}^n\int_{k\pi}^{(k+1)\pi}\frac{|\sin x|}x\text dx$.
Since $\displaystyle\frac2{(k+1)\pi}\le\int_{k\pi}^{(k+1)\pi}\frac{|\sin x|}x\text dx\le\frac2{k\pi},I_2=\frac4{\pi^2}\log n+\mathcal O(1)$.
So $\displaystyle\|D_n\|=\frac4{\pi^2}\log n+\mathcal O(1)$.
