# What is the integral of ln(x^2)?

It's $2 x \ln \left(x\right) - 2 x + C$

By integral I'm assuming it's meant the indefinite integral.

Using the fundamental proprety of logarithms that

${\log}_{c} \left({a}^{b}\right) = b {\log}_{c} \left(a\right)$

We get

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

Integrating by parts, chosing $\mathrm{dv} = 1$ and $u = \ln \left(x\right)$ we get

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

(we take the constant to be $\frac{C}{2}$ for convinience, and we can do this because the integration constant is taken arbitrarily)

Therefore,

$\int \ln \left({x}^{2}\right) \mathrm{dx} = 2 x \ln \left(x\right) - 2 x + C$