How to derive a reduction formula for $\int(\ln x)^m\, dx$ where $m$ is a natural number?
I took $(\ln x)^m$ as the first function and $1$ as the second function.
I am getting the final result $x (\ln x)^m -mx\ln x +mx + C$. But it does not satisfies, for example, $\int(lnx)^4 \,dx$
Where did I go wrong? Please derive the formula.
Well, we have that:
$$\mathscr{I}_\text{n}:=\int\ln^\text{n}\left(x\right)\space\text{d}x\tag1$$
Using integration by parts:
$$\int\text{f}\left(x\right)\cdot\text{g}\space'\left(x\right)\space\text{d}x=\text{f}\left(x\right)\cdot\text{g}\space\left(x\right)-\int\text{f}\space'\left(x\right)\cdot\text{g}\left(x\right)\space\text{d}x\tag2$$
So, we set:
So, we get:
$$\mathscr{I}_\text{n}:=\int\ln^\text{n}\left(x\right)\space\text{d}x=x\ln^\text{n}\left(x\right)-\int\frac{\text{n}}{x}\cdot\ln^{\text{n}-1}\left(x\right)\cdot x\space\text{d}x=$$ $$x\ln^\text{n}\left(x\right)-\text{n}\int\ln^{\text{n}-1}\left(x\right)\space\text{d}x=x\ln^\text{n}\left(x\right)-\text{n}\cdot\mathscr{I}_{\text{n}-1}\tag5$$
So, we get:
$$\mathscr{I}_\text{n}=x\ln^\text{n}\left(x\right)-\text{n}\cdot\mathscr{I}_{\text{n}-1}\space\Longleftrightarrow\space\mathscr{I}_\text{n}+\text{n}\cdot\mathscr{I}_{\text{n}-1}=x\ln^\text{n}\left(x\right)\tag6$$