Integrating $\int (\ln(x))^2 \, dx$ How would I integrate the following?
$$\int (\ln(x))^2 \, dx$$
I did 
$$u=(\ln(x))^2, \hspace{5mm} du= \frac{2 \ln(x)}{x}, \hspace{5mm} dv=1$$
to get
\begin{align}
\int (\ln(x))^2 \, dx &= \ln(x)^2(x) - 2 \int \frac{x \, \ln(x)}{x} \, dx \\
&= -2 \, \int \ln(x) \, dx \\
&= \ln(x)^2(x)-2\left[x \, \ln(x)-\int dx \right] \\ 
&= \ln(x)^2(x) - 2[x \, \ln(x) - x + c]
\end{align}
 A: Nice work. You've got the correct answer! Just remember is showing your work to include $\,dx$ at the close of an integrals, and putting $\,dv = 1$ (it should be $\,dv = \,dx \implies v = x)$.
I'd simply suggest expressing the result of the integration by parts as follows:
$$x(\ln x)^2-2[x\ln(x)-x] + C$$ We might even want to factor out $x$ from each term:
$$x\Big((\ln x)^2 - 2\ln x + 2\Big) + C$$
But your work and result are indeed correct.
A: \begin{align}
?
&=
\int\left\lbrack\ln\left(x\right)\right\rbrack^{2}\,{\rm d}x
=
\lim_{n \to 0}
{\partial^{2} \over \partial n^{2}}\int x^{n}\,{\rm d}x
=
\lim_{n \to 0}{\partial^{2} \over \partial n^{2}}
\left({x^{n + 1} \over n + 1}\right)
\\[3mm]&=
\lim_{n \to 0}\left\lbrace%
x^{n + 1}\left\lbrack\ln\left(x\right)\right\rbrack^{2}\,{1 \over n + 1}
+
2x^{n + 1}\ln\left(x\right)\,{-1 \over \left(n + 1\right)^{2}}
+
x^{n + 1}\,{2 \over \left(n + 1\right)^{3}}
\right\rbrace
\\[3mm]&=
x\left\lbrack\ln\left(x\right)\right\rbrack^{2}
-
2x\ln\left(x\right)
+
2x
=
\color{#ff0000}{\large%
x\left\lbrace%
\left\lbrack\ln\left(x\right)\right\rbrack^{2}
-
2\ln\left(x\right)
+
2\right\rbrace}
\end{align}
${\large +\ \mbox{a constant}}$
