# Solve $\int\frac{\sqrt{x-1}}{x}dx$ by using substitution

Solve $$\int\frac{\sqrt{x-1}}{x}dx$$ by using substitution.

What I've gotten so far:

$u=\sqrt{x-1} \Rightarrow x=1+u^2$

$du=D\sqrt{x-1}dx=\frac{1}{2\sqrt{x-1}}dx\Rightarrow dx=2\sqrt{x-1}du=2u du$

Now

$$\int\frac{\sqrt{x-1}}{x}dx=\int\frac{u}{1+u^2}2udu=2\int\frac{1}{1+u^2}u^2du$$

but I get stuck here. It looks like I'm close to being able to apply the integration rule $\int\frac{1}{1+x^2}=arctanx+c$ to it but I'm not sure how to get there since I don't know how I can get rid of the $u^2$.

You're almost there, just write $$\frac{u^2}{1+u^2}=1-\frac1{1+u^2}$$
$$\ldots \begin{array}{|c|} \sqrt{x-1} = t \\ t^2 = x-1 \\ 2tdt = dx \\ x = 1+t^2 \end{array} = 2\int \frac{t^2\,dt}{1+t^2} = 2 \int \frac{t^2+1-1}{t^2+1} \, dt = 2\left( \int dt-\int\frac{dt}{t^2+1}\right) =\\ = 2t - 2\arctan t+C = \\ = 2\sqrt{x-1}-2\arctan(\sqrt{x-1})+C$$
Another way to solve the problem: Let $x=\sec^2t$. Then \begin{eqnarray} &&\int\frac{\sqrt{x-1}}{x}dx\\ &=&\int\frac{\tan t}{\sec^2t}2\sec^2 t\tan tdt\\ &=&2\int\tan^2tdt\\ &=&2\int(\sec^2t-1)dt\\ &=&2(\tan t-t)+C\\ &=&2(\sqrt{x-1}-\arctan(\sqrt{x-1}))+C \end{eqnarray}