How do I find the integral int(ln(x))^2dx ?

1 Answer
Jul 31, 2014

Our objective is to reduce the power of ln x so that the integral is easier to evaluate.

We can accomplish this by using integration by parts. Keep in mind the IBP formula:

int u dv = uv - int v du

Now, we will let u = (lnx)^2, and dv = dx.

Therefore,

du = (2lnx)/x dx

and

v = x.

Now, assembling the pieces together, we get:

int (ln x)^2 dx = x(ln x)^2 - int (2xlnx)/x dx

This new integral looks a lot better! Simplifying a bit, and bringing the constant out front, yields:

int (ln x)^2 dx = x(ln x)^2 - 2 int lnx dx

Now, to get rid of this next integral, we will do a second integration by parts, letting u = ln x and dv = dx.

Thus, du = 1/x dx and v = x.

Assembling gives us:

int (ln x)^2 dx = x(ln x)^2 - 2(xlnx - int x/x dx)

Now, all that's left to do is simplify, keeping in mind to add the constant of integration:

int (ln x)^2 dx = x(ln x)^2 - 2xlnx + 2x + C

And there we have it. Remember, integration by parts is all about picking u so that messy things get eliminated from the integrand. In this case we brought (ln x)^2 down to ln x, and then down to 1/x. In the end, some x's canceled off, and it became easier to integrate.