Lời giải:
Ta có:
\(P=\int \frac{x^2-1}{x\sqrt{x^3+x}}dx=\int \frac{\frac{x^2-1}{x^2}}{\frac{\sqrt{x^3+x}}{x}}dx\)
\(=\int \frac{(1-\frac{1}{x^2})dx}{\frac{\sqrt{x^3+x}}{x}}=\int \frac{d\left(x+\frac{1}{x}\right)}{\frac{\sqrt{x^3+x}}{x}}\)
Đặt \(\frac{\sqrt{x^3+x}}{x}=t\Rightarrow t^2=\frac{x^3+x}{x^2}=x+\frac{1}{x}\)
Khi đó: \(P=\int \frac{d(t^2)}{t}=\int \frac{2tdt}{t}=\int 2dt=2t+c=\frac{2\sqrt{x^3+x}}{x}+c\)