<s>[INST] Evaluation of $\int_{0}^{a} \frac{\sqrt{a+x}}{\sqrt{a-x}} dx$ Evaluate : 
$\int_{0}^{a} \frac{\sqrt{a+x}}{\sqrt{a-x}} dx$ 
My approach : I multiplied both sides by $\sqrt{a+x}$ and after simplification it comes down to : 
$\int_{0}^{a} \frac{a}{\sqrt{a^{2}-x^{2}}} dx + \int_{0}^{a} \frac{x}{\sqrt{a^{2}-x^{2}}} dx$, let's denote them by $I_1$ and $I_2$ respectively.
$I_1$ can be easily solved to $a \sin ^{-1} \frac{x}{a}$. 
If I write $I_2$ as $ \frac{-1}{2}\int_{0}^{a} \frac{-2x}{\sqrt{a^{2}-x^{2}}} dx$, I get the solution as $\frac{a}{2}(\pi+1)$ but the answer given is $\frac{a}{2}(\pi+2)$. Where did I go wrong?
 [/INST] $$I_2=\frac{-1}{2} \int_0^a \frac{d(a^2-x^2)}{\sqrt{a^2-x^2}}$$
let $a^2-x^2=t$. If $x=0,$ then $t=a^2$ and if $x=a,$ then $t=0$.
Hence $$I_2=\frac{-1}{2} \int_{a^2}^0 \frac{dt}{\sqrt{t}}$$
$$\Rightarrow I_2= \int_{0}^{a^2} \frac{dt}{2\sqrt{t}}$$
$$\Rightarrow I_2=a-0=a$$
</s>