The problem asks to solve this indefinite intregral: $$I=\int{\frac{dx}{x\sqrt{x^2+1}}}$$ I did the following substitution (using $t$ as substitute value): $$x^2+1=t\implies x=\pm\sqrt{t-1}$$ $$2xdx=dt\implies dx=\frac{dt}{2\sqrt{t-1}}$$ From here I separated two cases and did some basic integration to get the following:
- $x<0$ $$I=-\int{\frac{dt}{2(t-1)\sqrt{t}}}=-\frac{1}{2}\ln\left|\frac{1+\sqrt{x^2+1}}{1-\sqrt{x^2+1}}\right|+C_1$$
- $x>0$ $$I=\int{\dfrac{dt}{2(t-1)\sqrt{t}}}=\dfrac{1}{2}\ln\left|\dfrac{1-\sqrt{x^2+1}}{1+\sqrt{x^2+1}}\right|+C_2$$
Is this the correct solution the given indefinite integral?
Here is the correct procedure to evaluate with $x^2+1=t$, $2xdx=dt$
\begin{align} \int{\frac{dx}{x\sqrt{x^2+1}}}=& \ \frac12\int{\frac{2x dx}{x^2\sqrt{x^2+1}}}=\frac12\int \frac{dt}{(t-1)\sqrt t}\\ =&\ \frac{1}{2}\ln{\frac{\sqrt{t}-1}{\sqrt{t}+1}} =\frac{1}{2}\ln{\frac{\sqrt{x^2+1}-1}{\sqrt{x^2+1}+1}} \end{align} which is valid for both $x<0$ and $x>0$.