Integral $\int_0^1 \frac{x\log x+1-x}{x \log^2 x}\log(1+x)\, dx=\log\frac{4}{\pi}$ Hi I am trying to prove this
$$
I:=\int_{0}^{1}
{x\log\left(\,x\,\right) + 1 - x \over x\log^{2}\left(\,x\,\right)}\,
\log\left(\,1 + x\,\right)\,{\rm d}x=\log\left(\,4 \over \pi\,\right).
$$
Thanks.
This is just a beautiful integral for many reasons.  Logs are everywhere and an inspirational solution!!!  I am not sure if breaking it up into three separate pieces is of any use, I  tried that by writing
$$
I=\int_0^1\frac{ \log(1+x)}{\log x}dx+\int_0^1\frac{\log(1+x)}{x \log^2 x}dx-\int_0^1\frac{\log(1+x)}{\log^2 x}dx
$$
but wasn't sure how to handle these.  Also  note that
$$
\int_0^1 \frac{x\log x+1-x}{x \log^2 x}dx=1,
$$
in case that happened to come up anywhere along the calculation.
 A: Substituting $\log x = -u$ gives $$
I = \int_0^{\infty} \frac{1-(x+1)e^{-x}}{x^2} \ln(1+e^{-x}) $$
Noticing that $\frac{d}{dx} (e^{-x}-1)/x = \frac{1-(x+1)e^{-x}}{x^2}$, we integrate by parts to obtain
$$
I = -\ln 2- \int_0^{\infty} \frac{dx}{x}e^{-x}  \frac{1-e^{-x}}{1+e^{-x}}
$$
So the problem is reduced to showing that 
$$J:=\int_0^{\infty} \frac{dx}{x}e^{-x}  \frac{1-e^{-x}}{1+e^{-x}}=\ln{\frac{\pi}{2}}$$
We have
$$J 
= \sum_{k\geq0} (-1)^{k} \int_0^{\infty} \frac{dx}{x} \left( e^{-x}-e^{-2x}\right)e^{-kx} 
$$
(Here I used the geometric series and interchanged summation and integration.)
$$
= \sum_{k\geq0} (-1)^{k} \ln \frac{k+2}{k+1} 
$$
$$
= \sum_{k\geq1} (-1)^{k-1} \ln \left( 1+\frac{1}{k} \right)
$$
(Here I used a well-known integral that follows from Frullani's theorem)
$$
= \sum_{k\geq1} \left[ \ln\left( 1+\frac{1}{2k-1}\right)-\ln\left( 1+\frac{1}{2k}\right) \right] \\
= \lim_{N\rightarrow\infty} \ln\left[ \prod_{k=0}^N   \frac{1+\frac{1}{2k-1}}{1+\frac{1}{2k}} \right] \\
= \ln \left[ \lim_{N\rightarrow\infty}  \prod_{k=0}^N   \frac{4k^2}{4k^2-1} \right] \\
= -\ln \left[\prod_{k\geq0}  \left( 1-\frac{1}{4k^2} \right) \right]\\
= -\ln \left[ \frac{\sin(\pi /2)} {\pi/2} \right]$$
Here I used the product formula for $\frac{\sin \pi x}{\pi x}$
Hence
$$
J= \ln \frac{\pi}{2} 
$$
as was to be proved.
A: Consider
\begin{align*}
\int_0^1 \frac{x\log{x}+1-x}{x}\, x^a\, \log{(1+x)}\, dx &= \int_0^1 \frac{x\log{x}+1-x}{x}\, x^a\, \sum_{n\ge 1} (-1)^{n+1}\frac{x^n}{n}\, dx\\
&=\sum_{n\ge 1} \int_0^1 \,  (-1)^{n+1} (x\log{x}+1-x)\, \frac{x^{a+n-1}}{n}\, dx\\
&= \sum_{n\ge 1} - \frac{\left(-1\right)^{n+1}}{{\left(a + n + 1\right)}^{2} n} + \frac{\left(-1\right)^{n+1}}{{\left(a + n\right)} n}  -\frac{\left(-1\right)^{n+1}}{{\left(a + n + 1\right)} n}\\
\int_0^1 \frac{x\log{x}+1-x}{x \log{x}}\, x^a\, \log{(1+x)}\, dx &= \sum_{n\ge 1} \frac{\left(-1\right)^{n + 1}}{n} \left(\frac{1}{a + n + 1} + \log\left(\frac{a + n}{a+n+1}\right)\right)\tag{$\int da$}\\
\int_0^1 \frac{x\log{x}+1-x}{x (\log{x})^2}\, x^a\, \log{(1+x)}\, dx &= \sum_{n\ge 1} \frac{\left(-1\right)^{n+1} {\left(a + n\right)} \log\left(\frac{a + n}{a + n + 1}\right) + \left(-1\right)^{n+1}}{n}\tag{$\int da$}\\
\end{align*}
Subst. $a=0$
\begin{align*}
\therefore \int_0^1 \frac{x\log{x}+1-x}{x (\log{x})^2}\, \log{(1+x)}\, dx &= \sum_{n\ge 1} \left(-1\right)^{n+1} \log\left(\frac{ n}{ n + 1}\right) + \frac{\left(-1\right)^{n+1}}{n}\hspace{20pt} \text{(Wallis product and log 2)}\\
&= \log{\left(\frac{2}{\pi}\right)}+\log{2} \\
&= \log{\left(\frac{4}{\pi}\right)}
\end{align*}
A: Note 
$$\frac{1}{x\log^2x}=-\frac{d}{dx}\frac{1}{\log x} $$
and hence
\begin{eqnarray}
I&=&\int_{0}^{1}
{x\log\left(\,x\,\right) + 1 - x \over x\log^{2}\left(\,x\,\right)}\,
\log\left(\,1 + x\,\right)\,{\rm d}x\\
&=&-\int_{0}^{1}
(x\log x + 1 - x)\log(1+x)d\frac{1}{\log x}\\
&=&-(x\log x + 1 - x)\log(1+x)\frac{1}{\log x}\bigg|_0^1+\int_{0}^{1}\frac{1}{\log x}d[
(x\log x + 1 - x)\log(1+x)]\\
&=&\int_0^1\frac{1}{\log x}\left(\frac{x \log x+1-x}{x+1}+\log x \log (x+1)\right)dx\\
&=&\int_0^1\log(x+1)dx+\int_0^1\frac{x}{x+1}+\int_0^1\frac{1}{\log x}\frac{1-x}{x+1}dx\\
&=&\log 2+J,
\end{eqnarray}
where
$$ J=\int_0^1\frac{1}{\log x}\frac{1-x}{x+1}dx.$$
Define
$$ f(a)=\int_0^1x^a\frac{1-x}{x+1}dx. $$
Then
\begin{eqnarray}
f(a)&=&\int_0^1\sum_{n=0}^\infty(-1)^nx^{a+n}(1-x)dx
&=&\sum_{n=0}^\infty(-1)^n\left(\frac{1}{n+a+1}-\frac{1}{n+a+2}\right)
\end{eqnarray}
and hence
$$ \int_0^a f(a)da=\sum_{n=0}^\infty(-1)^n\log\frac{n+a+1}{n+a+2},$$
and
$$ J=\lim_{a\to0}\sum_{n=0}^\infty(-1)^n\log\frac{n+a+1}{n+a+2}=\sum_{n=0}^\infty(-1)^n\log\frac{n+1}{n+2}=\log\frac{2}{\pi}.$$
Thus
$$ I=\log\frac{4}{\pi}. $$
