Answer:
[tex]\displaystyle \int (\ln(x))^2\, dx=x(\ln(x)^2-2\ln(x)+2)+C[/tex]
Step-by-step explanation:
We want to evaluate the integral:
[tex]\displaystyle \int\left(\ln x\right)^2 \, dx[/tex]
We can use Integration by Parts. Rewriting the integral yields:
[tex]\displaystyle =\int 1\cdot (\ln(x))^2\, dx[/tex]
Recall that IBP is given by:
[tex]\displaystyle \int u\, dv = uv - \int v \, du[/tex]
Let u be (ln(x))². And let dv be (1) dx. Therefore:
[tex]\displaystyle du = 2\ln x \cdot \frac{1}{x}\, dx[/tex]
Simplify:
[tex]\displaystyle du=\frac{2\ln(x)}{x}\, dx[/tex]
And:
[tex]dv=(1)dx\Rightarrow v = x[/tex]
Therefore:
[tex]\displaystyle \int (\ln(x))^2\, dx=\underbrace{\ln(x)^2}_{u}\underbrace{x}_{v}-\int\underbrace{x}_{v}\cdot \underbrace{\frac{2\ln(x)}{x}\, dx}_{du}[/tex]
Simplify:
[tex]\displaystyle =x\ln(x)^2-2 \int\ln(x)\, dx[/tex]
We can perform IBP again. Let u = ln(x) and v = 1. Hence:
[tex]\displaystyle du = \frac{1}{x} \, dx[/tex]
And:
[tex]dv=(1)dx\Rightarrow v = x[/tex]
Thus:
[tex]\displaystyle =x\ln(x)^2-2\left(x\ln(x)-\int (x)\frac{1}{x}\, dx\right)[/tex]
Simplify:
[tex]\displaystyle =x\ln(x)^2-2\left(x\ln(x)-\int (1)\, dx\right)[/tex]
Evaluate:
[tex]=x\ln(x)^2-2(x\ln(x)-x)+C[/tex]
Simplify:
[tex]\displaystyle =x\ln(x)^2-2x\ln(x)+2x[/tex]
Factor:
[tex]=x(\ln(x)^2-2\ln(x)+2)[/tex]
Therefore:
[tex]\displaystyle \int (\ln(x))^2\, dx=x(\ln(x)^2-2\ln(x)+2)+C[/tex]