Two different ways of substitution leads to two different results for $\int\frac{x\ln x^2+1}{x^2+1}dx$, how's that?

84 Views Asked by At

I was working on a solution for $$\int\frac{x\ln (x^2+1)}{x^2+1}dx$$ and my approach was the following:

first substituting $u = x^2+1$, which means $du = 2x dx$, and therefore: $$\int\frac{\ln u}{2u}du$$

and then substituting $v=\ln u$, which means $dv = \frac{1}{u} du$, and therefore: $$\frac{1}{2}\int dv = \frac{v}{2} + c = \frac{\ln u}{2} +c = \frac{\ln (x^2+1)}{2}+c$$

However verifying this online from various sources, they indicate that the solution is in fact: $$\int\frac{x\ln (x^2+1)}{x^2+1}dx = \frac{\ln(x^2+1)^2}{4}+c$$ because they substitute $u = \ln(x^2+1)$ which gives $du = \frac{2x}{x^2+1} dx$, which is clairly a shorter path.

But my question is, why does both of these substitution techniques not yield the same result? Where lies my error?

2

There are 2 best solutions below

6
On

When you get$$\int\frac{\ln u}{2u}\,\mathrm du$$and you do $v=\ln u$ and $\mathrm dv=\frac1u\,\mathrm du$, what you should have obtained was$$\int\frac v2\,\mathrm dv=\frac{v^2}4+c=\frac{\ln^2u}4+c=\frac{\ln^2(x^2+1)}4+c,$$instead of $\frac12\int\,\mathrm dv$.

0
On

$$I=\int\frac{x\ln(x^2+1)}{x^2+1}dx$$ $$u=x^2+1$$ $$dx=\frac{du}{2x}$$ $$I=\frac{1}{2}\int\frac{\ln(u)}{u}du$$ $$v=\ln(u)$$ $$du=udv$$ $$I=\frac{1}{2}\int vdv=\frac{v^2}{4}+C=\frac{\ln^2(u)}{4}+C=\frac{\ln^2(x^2+1)}{4}+C$$