TITLE: log-trig integral with sin, cos, and tan
QUESTION [16 upvotes]: Here is another log-trig integral you may find challenging/fun. Or not :)
$$\int_{0}^{\frac{\pi}{2}}\ln(1+\sin(x))\ln(1+\cos(x))\tan(x)dx=\frac{\pi^{2}}{8}\ln(2)-\frac{5}{16}\zeta(3)$$

REPLY [9 votes]: The integral equals
$$
\int_0^1 dx\, \ln \left( 1 + \sqrt{1-x^2} \right) \frac{\ln(1+x)}{x} 
\\= \left.  -\text{Li}_2(-x)  \ln \left( 1 + \sqrt{1-x^2} \right) \right\lvert_0^1 + \int_0^1 dx\, \text{Li}_2(-x)\frac{1}{x} \left[1 - \frac{1}{\sqrt{1-x^2}} \right] 
\\=\text{Li}_3(-1)-\int_0^1 dx\, \frac{\text{Li}_2(-x)}{x\sqrt{1-x^2}}.
$$
Now, $\text{Li}_3(-1) = -\beta(3) = -\left(1 - 2^{1-3}\right) \zeta(3) = -\frac{3}{4} \zeta(3)$. In the second term, write $\text{Li}_2(-x)$ as a series and interchange summation and integration:
$$
-\int_0^1 dx\, \frac{\text{Li}_2(-x)}{x\sqrt{1-x^2}} 
= \sum_{k\geq 1} \frac{(-1)^{k-1}}{k^2} \int_0^1 dx\,x^{k-1} \left(1-x^2\right)^{-1/2} 
= \sum_{k\geq 1} \frac{(-1)^{k-1}}{2k^2} B\left(\frac{k}{2},\frac{1}{2}\right).$$
We calculate this sum, following Cody's suggestion to start with
$$
\sum_{k\geq 1} (-1)^{k-1} B\left(\frac{k}{2},\frac{1}{2}\right) x^{k-1} = \frac{\pi - 2\arcsin x}{\sqrt{1-x^2}}.
$$
Integrating once from $0$ to $x$ yields
$$
\sum_{k\geq 1} \frac{(-1)^{k-1}}{k} B\left(\frac{k}{2},\frac{1}{2}\right) x^{k} 
= \pi \arcsin x -\arcsin^2 x.
$$
Dividing by $x$ and integrating from $0$ to $1$ yields
$$
\sum_{k\geq 1} \frac{(-1)^{k-1}}{k^2} B\left(\frac{k}{2},\frac{1}{2}\right)
=  \int_0^{\pi/2}dx\, \frac{\pi x \cos x}{\sin x} - \frac{x^2 \cos x}{\sin x}
\\= -\int_0^{\pi/2}dx\, \pi \ln \sin x-2x\ln \sin x = \frac{\pi^2}{2} \ln 2 + 2 \int_0^{\pi/2}dx\, x\ln \sin x.
$$
The latter integral can be calculated as follows: use the identity $\ln \sin x = -\ln 2 -\sum_{k\geq0} \cos(2 k x)$ and interchange summation and integration. This gives the value $$2\int_0^{\pi/2}dx\, x\ln \sin x = -\dfrac{\pi^2}{4}\ln 2 + \beta(3) = -\dfrac{\pi^2}{4}\ln 2 + \dfrac{7}{8} \zeta(3).$$
Adding everything up yields the correct value of the integral:
$$
-\frac{3}{4} \zeta(3) + \frac{1}{2} \left[\frac{\pi^2}{2} \ln 2 -\dfrac{\pi^2}{4}\ln 2 + \dfrac{7}{8} \zeta(3)\right] = \frac{\pi^2}{8} \ln 2 - \frac{5}{16} \zeta(3).
$$