<s>[INST] I am having trouble with this integral from the 2012 MIT Integration Bee: $\int\frac{dx}{(1+\sqrt{x})\sqrt{x-x^2}}$ $$\int\frac{dx}{(1+\sqrt{x})\sqrt{x-x^2}} $$
Could someone explain to me how to integrate this integral.
Thank you and cheers.
 [/INST] $\displaystyle{\int\frac{dx}{(1+\sqrt{x})\sqrt{x-x^2}}}$
Let's put $x=\sin^{2}t$, then 
\begin{align*}
\int\frac{dx}{(1+\sqrt{x})\sqrt{x-x^2}}&=\int{\frac{2\sin t\cos t dt}{(1+\sin t)\sqrt{\sin^2 t-\sin^4 t}}} \\
&=\int{\frac{2\sin t\cos t dt}{(1+\sin t)\sqrt{\sin^2 t(1-\sin^2 t)}}}\\
&=\int{\frac{2\sin t\cos t dt}{(1+\sin t)\sin t\cos t}}\\
&=\int{\frac{2dt}{1+\sin t}}\\
&=\int{\frac{2(1-\sin t)dt}{\cos^2 t}}=2\int{\sec^2 tdt}-2\int{\sec t\tan tdt}\\
&=2\tan t - 2\sec t + C\\
&=\frac{2(\sin t - 1)}{\cos t} + C\\
&=\frac{2(\sqrt{x}-1)}{\sqrt{1-x}}+C
\end{align*}
</s>