# Find $\int_0^1\frac{\ln^2(1-x)}{x}\ dx$

In solving $\displaystyle\int_0^\frac{\pi}{4}\dfrac{\ln(\sin x)\ln(\cos x)}{\sin x\cos x}\ dx,$ I have found that this is equal to $\dfrac{1}{16}\displaystyle\int_0^1\dfrac{\ln^2(1-x)}{x}\ dx.$ WolframAlpha says that the desired value is $\dfrac{\zeta(3)}{8},$ so I suspect a conversion to a series is necessary.

How do I prove $\displaystyle\int_0^1\dfrac{\ln^2(1-x)}{x}\ dx=\displaystyle\sum_{n=1}^\infty\dfrac{2}{n^3}$?

Note that the above integral can also be given as $\displaystyle\int_0^1\dfrac{\ln^2x}{1-x}\ dx$, which I know is equal to $\displaystyle\sum_{n=0}^\infty x^n\ln^2x.$

Also for reference, here is a picture of my original work to get to this point.

• What's up with everyone usign \displaystyle lately? We don't need that anywhere, especially in the title – Yuriy S Aug 4 '16 at 21:01
• @You'reInMyEye That's just how I write integrals. Chalk it up to me not having a lot of experience on Math.SE and not knowing all of the minutiae that you all prefer. My apologies. – Arcturus Aug 4 '16 at 21:09
• Eridan, that was nothing personal, more a comment for general public. I edited at least three displaystyle titles today. I'm not sure myself why it's not allowed, but I think it may cause some problems with browsing question and search – Yuriy S Aug 4 '16 at 21:11
• @You'reInMyEye MSE strongly recommends ( in some documentation ) to avoid $\texttt{displaystyle}$ in the title. – Felix Marin Aug 4 '16 at 23:35
• Is $\ln^2 x$ a standard notation? – StubbornAtom Aug 5 '16 at 4:48

We have $$\int_{0}^{1}\frac{\log^{2}\left(1-x\right)}{x}dx\stackrel{x\rightarrow1-x}{=}\int_{0}^{1}\frac{\log^{2}\left(x\right)}{1-x}dx$$ $$\stackrel{DCT}{=} \sum_{k\geq0}\int_{0}^{1}\log^{2}\left(x\right)x^{k}dx\stackrel{IBP}{=} 2\sum_{k\geq0}\frac{1}{\left(k+1\right)^{3}}=\color{red}{2\zeta\left(3\right)}.$$

• Can you please tell me what $DCT$ means. – Ahmed S. Attaalla Aug 4 '16 at 23:44
• @AhmedS.Attaalla I believe it's the dominated convergence theorem which allows him to switch the integral sign with the sum, since he used a geometric series representation of $\frac{1}{1-x}$. – mike van der naald Aug 5 '16 at 0:14

I thought it might be instructive to present a way forward that exploits the Polylogarithm Functions. To that end, we proceed.

Note that integrating by parts with $u=\log^2(1-x)$ and $v=\log(x)$, we have

\begin{align} \int_0^1 \frac{\log^2(1-x)}{x}\,dx=2\int_0^1 \frac{\log(1-x)\log(x)}{1-x}\,dx \tag 1 \end{align}

Integrating by parts the right-hand side of $(1)$ with $u=\log(1-x)$ and $v=\text{Li}_2(1-x)$ yields

\begin{align} 2\int_0^1 \frac{\log(1-x)\log(x)}{1-x}\,dx&=2\int_0^1 \frac{\text{Li}_2(1-x)}{1-x}\,dx\\\\ &=2\int_0^1 \frac{\text{Li}_2(x)}{x}\,dx\\\\ &=2\text{Li}_3(1)\\\\ &=2\zeta(3) \end{align}

as expected!


1. This one is $\ul{slightly\ different}$ of the straightforward @Dr. MV answer: \begin{align} \color{#f00}{{1 \over 16}\int_{0}^{1}{\ln^{2}\pars{1 - x} \over x}\,\dd x} &\,\,\, \stackrel{x\ \mapsto\ \pars{1 - x}}{=}\,\,\, {1 \over 16}\int_{0}^{1}{\ln^{2}\pars{x} \over 1 - x}\,\dd x \end{align}
Integrating by Parts a few times ( the main purpose is to 'sit' a $\ds{\ln\pars{1 - x}}$-factor in the integrand numerator ): \begin{align} \color{#f00}{{1 \over 16}\int_{0}^{1}{\ln^{2}\pars{1 - x} \over x}\,\dd x} & = {1 \over 16}\int_{0}^{1}\ln\pars{1 - x} \bracks{2\ln\pars{x}\,{1 \over x}}\,\dd x = -\,{1 \over 8}\int_{0}^{1}\Li{2}'\pars{x}\ln\pars{x}\,\dd x \\[5mm] & = {1 \over 8}\int_{0}^{1}\Li{2}\pars{x}\,{1 \over x}\,\dd x = {1 \over 8}\int_{0}^{1}\Li{3}'\pars{x}\,\dd x = {1 \over 8}\,\Li{3}\pars{1} \\[5mm] & = \color{#f00}{{1 \over 8}\,\zeta\pars{3}} \end{align}
2. Another approach uses the Beta Function $\ds{\mrm{B}\pars{\mu,\nu} = \int_{0}^{1}x^{\mu - 1}\,\pars{1 - x}^{\nu - 1}\,\,\dd x = {\Gamma\pars{\mu}\Gamma\pars{\nu} \over \Gamma\pars{\mu + \nu}}}$ with $\ds{\Re\pars{\mu} > 0\,,\ \Re\pars{\nu} > 0}$. $\ds{\Gamma\,}$: Gamma Function. \begin{align} &\color{#f00}{{1 \over 16}\int_{0}^{1}{\ln^{2}\pars{1 - x} \over x}\,\dd x} = {1 \over 16}\,\lim_{\mu \to 0}\,\,\partiald[2]{}{\mu} \int_{0}^{1}{\pars{1 - x}^{\mu} - 1 \over x}\,\dd x \\[5mm] & = {1 \over 16}\,\lim_{\mu \to 0}\,\,\partiald[2]{}{\mu}\bracks{\mu \int_{0}^{1}\ln\pars{x}\pars{1 - x}^{\mu - 1}\,\dd x} = {1 \over 16}\,\lim_{\mu \to 0 \atop \nu \to 0}\,\,{\partial^{3} \over \partial\mu^{2}\,\partial\nu} \bracks{\mu\int_{0}^{1}x^{\nu}\pars{1 - x}^{\mu - 1}\,\dd x} \\[5mm] & = {1 \over 16}\,\lim_{\mu \to 0 \atop \nu \to 0}\,\,{\partial^{3} \over \partial\mu^{2}\,\partial\nu}\bracks{\mu\,{\Gamma\pars{\nu + 1}\Gamma\pars{\mu} \over \Gamma\pars{\mu + \nu + 1}}} = {1 \over 16}\,\lim_{\mu \to 0 \atop \nu \to 0}\,\,{\partial^{3} \over \partial\mu^{2}\,\partial\nu}\bracks{\Gamma\pars{\nu + 1}\Gamma\pars{\mu + 1} \over \Gamma\pars{\mu + \nu + 1}} \\[5mm] & = \color{#f00}{{1 \over 8}\,\zeta\pars{3}} \end{align}

Here is an approach that makes use of an Euler sum.

We will first find a Maclaurin series expansion for $$\ln^2 (1 - x)$$. As $$\ln (1 - x) = - \sum_{n = 1}^\infty \frac{x^n}{n},$$ we have \begin{align*} \ln^2 (1 - x) &= \left (- \sum_{n = 1}^\infty \frac{x^n}{n} \right ) \cdot \left (- \sum_{n = 1}^\infty \frac{x^n}{n} \right ). \end{align*} Shifting the summation index $$n \mapsto n + 1$$ gives \begin{align*} \ln^2 (1 - x) &= x^2 \left (- \sum_{n = 0}^\infty \frac{x^n}{n + 1} \right ) \cdot \left (- \sum_{n = 0}^\infty \frac{x^n}{n + 1} \right )\\ &= \sum_{n = 0}^\infty \sum_{k = 0}^n \frac{x^{n + 2}}{(k + 1)(n - k + 1)}, \end{align*} where the last line has been obtained by applying the Cauchy product.

Shifting the summation indices as follows: $$n \mapsto n - 2, k \mapsto k - 1$$ gives \begin{align*} \ln^2 (1 - x) &= \sum_{n = 2}^\infty \sum_{k = 1}^{n - 1} \frac{x^n}{k(n - k)}\\ &= \sum_{n = 2}^\infty \sum_{k = 1}^{n - 1} \left (\frac{1}{nk} + \frac{1}{n(n - k)} \right ) x^n\\ &= 2 \sum_{n = 2}^\infty \frac{x^n}{n} \sum_{k = 1}^{n - 1} \frac{1}{k}\\ &= 2 \sum_{n = 2}^\infty \frac{H_{n - 1} x^n}{n}, \end{align*} where $$H_n$$ is the $$n$$th harmonic number.

Now evaluating the integral. From the above Maclaurin series expansion for $$\ln^2 (1 - x)$$ the integral can be written as \begin{align*} \int_0^1 \frac{\ln^2 (1 - x)}{x} \, dx &= 2 \sum_{n = 2}^\infty \frac{H_{n - 1}}{n} \int_0^1 x^{n - 1} \, dx = 2 \sum_{n = 2}^\infty \frac{H_{n - 1}}{n^2}. \end{align*}

From properties of the harmonic numbers we have $$H_n = H_{n - 1} + \frac{1}{n},$$ thus \begin{align*} \int_0^1 \frac{\ln^2 (1 - x)}{x} \, dx &= 2 \sum_{n = 2}^\infty \frac{H_n}{n^2} - 2 \sum_{n = 2}^\infty \frac{1}{n^3} = 2 \sum_{n = 1}^\infty \frac{H_n}{n^2} - 2 \sum_{n = 1}^\infty \frac{1}{n^3}. \end{align*}

Each sum can be readily found. They are: $$\sum_{n = 1}^\infty \frac{1}{n^3} = \zeta (3) \quad \text{and} \quad \sum_{n = 1}^\infty \frac{H_n}{n^2} = 2 \zeta (3).$$ A proof of the result for the second sum containing the harmonic number can, for example, be found here. Thus $$\int_0^1 \frac{\ln^2 (1 - x)}{x} \, dx = 4 \zeta (3) - 2 \zeta (3) = 2 \zeta (3),$$ as required.

Everything you did is good. Indeed, it suffices to show that $I_n:=\int_0^1 x^n \ln^2 x = \frac{2}{(n+1)^3}$ to conclude. The interversion $\int / \Sigma$ is possible as everything here is positive.

To compute $I_n$, I tried an integration by parts (using that a primitive of $\ln^2 x$ is $x(\ln^2 x-2\ln x)$) to obtain the relation $$I_n = \frac{-2}{n+1}\int_0^1 x^n\ln x.$$ Let us call this latter integral $J_n$. Once again with an integration by parts, you can show that $J_n = \frac{-1}{(n+1)^2}$, and thus conclude.