TITLE: Finding when $\frac{1}{\pi}\int_0^{j\pi} \frac{\sin t}{t}\,dt - \frac{1}{2}$ is positive / negative
QUESTION [5 upvotes]: Could you help me with the following question?

Show that the following numbers are positive for $j$ odd and negative otherwise: $$\frac{1}{\pi}\int_0^{j\pi} \frac{\sin t}{t}\,dt - \frac{1}{2}$$

REPLY [4 votes]: We have
$$
\int_0^\infty\frac{\sin t}t\mathrm dt=\frac\pi2
$$
and thus
$$
\frac1\pi\int_0^{j\pi}\frac{\sin t}t\mathrm dt-\frac12=-\frac1\pi\int_{j\pi}^\infty\frac{\sin t}t\mathrm dt\;.
$$
Integrating by parts yields
$$
\begin{align}
\int_{j\pi}^\infty\frac{\sin t}t\mathrm dt
&=
\left[-\frac{\cos t}t\right]_{j\pi}^\infty-\int_{j\pi}^\infty\frac{\cos t}{t^2}\mathrm dt
\\
&=
\frac{(-1)^j}{j\pi}-\int_{j\pi}^\infty\frac{\cos t}{t^2}\mathrm dt\;,
\end{align}
$$
and then
$$
\left|\int_{j\pi}^\infty\frac{\cos t}{t^2}\mathrm dt\right|\lt\int_{j\pi}^\infty\frac1{t^2}\mathrm dt=\frac1{j\pi}
$$
gives the desired result.