# What is int_0^pi (lnx)^2 / x^(1/2)?

Dec 16, 2015

${\int}_{0}^{\pi} {\ln}^{2} \frac{x}{\sqrt{x}} \mathrm{dx} = 2 \sqrt{\pi} \left({\ln}^{2} \left(\pi\right) - 4 \ln \left(\pi\right) + 8\right)$

#### Explanation:

First let's solve the indefinite integral $\int {\ln}^{2} \frac{x}{\sqrt{x}} \mathrm{dx}$. by applying integration by parts twice:

First Integration by Parts

Let $u = {\ln}^{2} \left(x\right)$ and $\mathrm{dv} = \frac{1}{\sqrt{x}} \mathrm{dx}$

Then $\mathrm{du} = \frac{2 \ln \left(x\right)}{x}$ and $v = 2 \sqrt{x}$

Thus

$\int {\ln}^{2} \frac{x}{\sqrt{x}} \mathrm{dx} = \int u \mathrm{dv}$

$= u v - \int v \mathrm{du}$

$= 2 \sqrt{x} {\ln}^{2} \left(x\right) - 4 \int \ln \frac{x}{\sqrt{x}} \mathrm{dx}$

Second Integration by Parts

Let $u = \ln \left(x\right)$ and $\mathrm{dv} = \frac{1}{\sqrt{x}}$

Then $\mathrm{du} = \frac{1}{x}$ and $v = 2 \sqrt{x}$

Thus

$\int \ln \frac{x}{\sqrt{x}} \mathrm{dx} = \int u \mathrm{dv}$

$= u v - \int v \mathrm{du}$

$= 2 \sqrt{x} \ln \left(x\right) - 2 \int \frac{1}{\sqrt{x}} \mathrm{dx}$

$= 2 \sqrt{x} \ln \left(x\right) - 4 \sqrt{x} + C$

Putting it together, we get

$\int {\ln}^{2} \frac{x}{\sqrt{x}} \mathrm{dx} = 2 \sqrt{x} {\ln}^{2} \left(x\right) - 4 \int \ln \frac{x}{\sqrt{x}} \mathrm{dx}$

$= 2 \sqrt{x} {\ln}^{2} \left(x\right) - 4 \left(2 \sqrt{x} \ln \left(x\right) - 4 \sqrt{x} + C\right)$

$= 2 \sqrt{x} \left({\ln}^{2} \left(x\right) - 4 \ln \left(x\right) + 8\right) + C$

Now we can evaluate the original definite integral.

${\int}_{0}^{\pi} {\ln}^{2} \frac{x}{\sqrt{x}} \mathrm{dx} = {\left[2 \sqrt{x} \left({\ln}^{2} \left(x\right) - 4 \ln \left(x\right) + 8\right)\right]}_{0}^{\pi}$

(Note that as there is a discontinuity at $0$ we must evaluate this using a limit)

$= 2 \sqrt{\pi} \left({\ln}^{2} \left(\pi\right) - 4 \ln \left(\pi\right) + 8\right) - {\lim}_{x \to 0} 2 \sqrt{x} \left({\ln}^{2} \left(x\right) - 4 \ln \left(x\right) + 8\right)$

$= 2 \sqrt{\pi} \left({\ln}^{2} \left(\pi\right) - 4 \ln \left(\pi\right) + 8\right) - 0$

$= 2 \sqrt{\pi} \left({\ln}^{2} \left(\pi\right) - 4 \ln \left(\pi\right) + 8\right)$