<s>[INST] How to evaluate $\int \frac{\sqrt{1+x}+\sqrt{1-x}}{\sqrt{1+x}-\sqrt{1-x}} dx$? I am trying to evaluate
$$\int \frac{\sqrt{1+x}+\sqrt{1-x}}{\sqrt{1+x}-\sqrt{1-x}} dx \quad (1)$$

The typical way to confront this kind of integrals are the conjugates i.e:
$$\int \frac{\sqrt{1+x}+\sqrt{1-x}}{\sqrt{1+x}-\sqrt{1-x}} dx  = $$
$$ \int \left(\frac{\sqrt{1+x}+\sqrt{1-x}}{\sqrt{1+x}-\sqrt{1-x}}\right)\left(\frac{\sqrt{1+x}+\sqrt{1-x}}{\sqrt{1+x}+\sqrt{1-x}}\right)\left(\frac{\sqrt{1+x}-\sqrt{1-x}}{\sqrt{1+x}-\sqrt{1-x}}\right) dx = $$
$$\int \left(\frac{(\sqrt{1+x})^2-(\sqrt{1-x})^2}{(\sqrt{1+x})^2-(\sqrt{1-x})^2}\right)\left(\frac{\sqrt{1+x}-\sqrt{1-x}}{\sqrt{1+x}+\sqrt{1-x}}\right)dx = $$
$$\int 1*\left(\frac{\sqrt{1+x}-\sqrt{1-x}}{\sqrt{1+x}+\sqrt{1-x}}\right)dx $$
That's a dead end.

I also tried other conjugate approaches (only the numerator, only the denominator etc) with no better luck.
Any ideas?
 [/INST] Let $\sqrt{\frac{1+x}{1-x}}=t.$
Thus, $$x=\frac{t^2-1}{t^2+1},$$ $$dx=\frac{2t(t^2+1)-(t^2-1)2t}{(t^2+1)^2}dt=\frac{4tdt}{(t^2+1)^2}$$ and we need to calculate $$\int\frac{4t(t+1)}{(t-1)(t^2+1)^2}dt.$$
Now, easy to show that:
$$\int\frac{4t(t+1)}{(t-1)(t^2+1)^2}dt=\frac{2t}{t^2+1}+\ln\frac{(t-1)^2}{t^2+1}+C.$$
Can you end it now?
</s>