5

I would like to know if the integral $$\int_0^\pi \ln^2(\sin x)dx$$ could be attacked with contour integration. I have seen the integral evaluated using the Fourier series for $\ln(\sin x)$ and Cauchy product for infinite sums, but this method gets extremely hard for higher degrees than 2, which is why I want to see it evaluated using complex analysis.

phi-rate
  • 2,345
  • Is this $\ln(\ln(\sin(x))$ or is this $\ln(\sin(x))*\ln(\sin(x)))$? – Thomas Jan 30 '22 at 20:16
  • 2
    It’s squared. It’s quite widely accepted notation from what I knew. – phi-rate Jan 30 '22 at 20:17
  • @intellect4 - both are widely accepted notation. Hence the question. For instance, while $\sin^2x$ usually means $(\sin(x))^2$, $d^2y$ usually means $d(d(y))$. – johnnyb Jan 31 '22 at 00:03
  • For "higher degrees" use $\int_0^\pi\ln^n\sin x,dx=f^{(n)}(0)$ where $f(\lambda)=\int_0^\pi\sin^\lambda x,dx$ is a "beta" integral; this gives expressions in terms of the polygamma functions (or, finally, values of the $\zeta$-function). – metamorphy Jan 31 '22 at 04:35
  • Thanks, I’ll look into it – phi-rate Feb 01 '22 at 00:24

1 Answers1

7

There is a method to evaluate your integral using contour integration, though I'm unsure if it generalises neatly to higher powers. First, let \begin{equation} \begin{split} I&=\int_0^\pi\log^2(\sin(\theta))d\theta\\ &=\frac12 \int_0^{2\pi}\log^2(\sin(\theta /2))d\theta\\ &=\frac12 \int_0^{2\pi}\left[\log(1-e^{i\theta})-\log(2) -\frac{i}{2}(\theta-\pi)\right]^2d\theta\\ \end{split} \end{equation} (Note that we're taking the principal branch of the logarithm) Expanding the square, and taking real parts (which we may do since $I$ is real valued), we see that $I=\frac{1}{2}(J_1+J_2+J_3)$, where \begin{equation} \begin{split} J_1&=\mathfrak{R}\int_0^{2\pi}\left[\log^2(2)-\frac14(\theta-\pi)^2\right]d\theta\\ J_2&=\mathfrak{R}\int_0^{2\pi}[-i\log(1-e^{i\theta})(\theta-\pi)]d\theta\\ J_3&=\mathfrak{R}\int_0^{2\pi}[\log^2(1-e^{i\theta})-2\log(2)\log(1-e^{i\theta})]d\theta\\ \end{split} \end{equation} It is easy to evaluate $J_1=2\pi\log^2(2)-\frac{\pi^3}{6}$. To evaluate $J_2$, note that $\mathfrak{R}[-i\log(1-e^{i\theta})]=\frac{1}{2}(\theta-\pi)$ for $\theta\in(0,2\pi)$, so \begin{equation} J_2=\int_0^{2\pi}\frac{1}{2}(\theta-\pi)^2d\theta=\frac{\pi^3}{3} \end{equation} Finally, to evaluate $J_3$, note that \begin{equation} \begin{split} J_3&=\mathfrak{R}\lim_{r\rightarrow 1^{-}}\int_0^{2\pi}[\log^2(1-re^{i\theta})-2\log(2)\log(1-re^{i\theta})]d\theta\\ &=\mathfrak{R}\lim_{r\rightarrow 1^{-}}\oint_{|z|=r}-\frac{i}{z}[\log^2(1-z)-2\log(2)\log(1-z)]dz\\ \end{split} \end{equation} Since the above integrand is analytic in the open unit disc (apart from a removable singularity at $z=0$), by Cauchy's integral theorem, the above integrals vanish for each $r\in(0,1)$, and thus $J_3=0$. Combining our work, we have that \begin{equation} I=\pi\log^2(2)+\frac{\pi^3}{12} \end{equation}