<s>[INST] Need help with integration Can anyone help me with this:
$$ \int \sqrt\frac{e^x-1}{e^x+1}\, \mathrm{d}x$$
I can't think of a good substitution, any hint is welcome :) 
Thanks.
 [/INST] You can write
$$\frac {e^x-1}{e^x+1}=\frac {e^{x/2}-e^{-x/2}}{e^{x/2}+e^{-x/2}}=\tanh \frac x2$$
Thus, if
$$u=\sqrt{\frac {e^x-1}{e^x+1}}=\sqrt{\tanh \frac x2}$$
$$x = 2\arg \tanh u^2$$
$$\mathrm{d}x = \frac{4u\mathrm{d}u}{1-u^4}$$
Now,
$$\int \sqrt{\frac {e^x-1}{e^x+1}} \mathrm{d}x=\int \frac{4u^2\mathrm{d}u}{1-u^4}$$
And you can expand in partial fractions:
$$\frac{2u^2}{1-u^4}=\frac{2u^2-2+2}{(1+u^2)(1-u^2)}=\frac{2}{(1+u^2)(1-u^2)}-\frac{2}{1+u^2}$$
$$=\frac{1}{1-u^2}+\frac{1}{1+u^2}-\frac{2}{1+u^2}=\frac{1}{1-u^2}-\frac{1}{1+u^2}$$
And
$$\int \frac{1}{1-u^2}-\frac{1}{1+u^2} \mathrm{d}u=\arg \tanh u - \arctan u$$
Thus
$$\int \sqrt{\frac {e^x-1}{e^x+1}} \mathrm{d}x=2\arg \tanh \left( \sqrt{\tanh \frac x2}\right) - 2\arctan \left( \sqrt{\tanh \frac x2}\right)$$
</s>