Negativity of $\int_0^1 \sin(k \pi x) \log(x)\;dx$ How to show that $$\int_0^1\sin(k\pi x)\log(x)dx\le0,$$  for $k=1,2,\ldots$
 A: $\sin (k\pi x)$ is positive on the intervals $(2n\pi/k,\, (2n+1)\pi/k)$ for $0 \leqslant n \leqslant (k-1)/2$, and negative on the intervals $((2m-1)\pi/k, 2m\pi/k)$ for $1 \leqslant m \leqslant k/2$. $\log x$ is negative and strictly increasing on $(0,1)$.
If $k = 1$, the integrand $\sin (\pi x)\log x$ is negative on the entire interval $(0,1)$, hence the integral is negative. For $k > 1$ and $1 \leqslant n \leqslant k/2$, we have
$$\begin{align}
\int_{2(n-1)\pi/k}^{2n\pi/k} \sin (k\pi x)\log x\,dx
&= \int_{2(n-1)\pi/k}^{(2n-1)\pi/k} \sin (k\pi x)\log x\,dx + \int_{(2n-1)\pi/k}^{2n\pi/k} \sin (k\pi x)\log x\,dx\\
&= \int_{2(n-1)\pi/k}^{(2n-1)\pi/k} \underbrace{\sin (k\pi x)}_{> 0}\underbrace{\left(\log x - \log \left(x + \frac{\pi}{k}\right)\right)}_{< 0}\,dx\\
&< 0.
\end{align}$$
If $k$ is even, we have
$$\int_0^1 \sin (k\pi x)\log x\,dx = \sum_{n=1}^{k/2} \int_{2(n-1)\pi/k}^{2n\pi/k} \sin (k\pi x)\log x\,dx < 0,$$
and if $k$ is odd, we have
$$\int_0^1 \sin (k\pi x)\log x\,dx = \sum_{n=1}^{(k-1)/2} \int_{2(n-1)\pi/k}^{2n\pi/k} \sin (k\pi x)\log x\,dx + \int_{1-\pi/k}^{1} \sin (k\pi x)\log x\,dx$$
where the sum is negative by the above, and the last integral is negative too, since $\sin (k\pi x) > 0$ on $(1-\pi/k,1)$, so in all cases
$$\int_0^1 \sin (k\pi x)\log x\,dx < 0.$$
