Home » Blog » Find the integral of x log2x

Find the integral of x log2x

Evaluate the following integral:

    \[ \int x \log^2 x \, dx. \]


To evaluate this integral we use integration by parts, defining

    \begin{align*}  u &= \log^2 x & du &= \frac{2 \log x}{x} \, dx \\ dv &= x \, dx & v &= \frac{1}{2}x^2. \end{align*}

Then we have

    \begin{align*}  \int x \log^2 x \, dx &= \int u \, dv \\  &= uv - \int v \, du \\  &= \frac{1}{2}x^2 \log^2 |x| - \int x \log x \, dx. \end{align*}

From the previous exercise (Section 6.9, #18) we know

    \[ \int x \log x \, dx = \frac{1}{x^2} \log |x| - \frac{1}{4} x^2 + C. \]

Therefore,

    \begin{align*}  \int x \log^2 x \, dx &= \frac{1}{2}x^2 \log^2 |x| - \int x \log x \, dx \\   &= \frac{1}{2} x^2 \log^2 |x| - \frac{1}{2} x^2 \log |x| + \frac{1}{4}x^2 + C. \end{align*}

Point out an error, ask a question, offer an alternative solution (to use Latex type [latexpage] at the top of your comment):