<s>[INST] Calculate integral $\int_0^{\pi/2} \frac{\cos^3x}{\sin^2x + \cos^3x}dx$. 
Calculate integral $$\int_0^{\pi/2} \frac{\cos^3x}{\sin^2x + \cos^3x}dx.$$

My direction: Since this integral can't calculate normally, I tried to use the property following:$$\int_{a}^{b}f(x)dx = \int_{a}^{b}f(a+b-x)dx.$$
Then, I have
$$I=\int_0^{\pi/2} \frac{\cos^3x}{\sin^2x + \cos^3x}dx = \int_0^{\pi/2} \frac{\sin^3x}{\cos^2x + \sin^3x}dx.$$
Therefore
$$2I = \int_0^{\pi/2} \left(\frac{\cos^3x}{\sin^2x + \cos^3x} + \frac{\sin^3x}{\cos^2x + \sin^3x}\right) dx.$$
I stucked here.
 [/INST] Rewrite the integral with $t=\tan\frac x2$
$$I=\frac\pi2-\int_0^{\pi/2} \frac{\sin^2x}{\sin^2x + \cos^3x}dx
=\frac\pi2 +8 \int_0^1 \frac{t^2}{t^6-7t^4-t^2-1} dt$$
Note that $t^6-7t^4-t^2-1$ is cubic in $t^2$, with one real root $r=7.159$ (analytically solvable with the Cadano’s formula). Then, factorize
$$ t^6-7t^4-t^2-1 =(t^2-r)[t^4+(r-7)t^2+1/r]$$
and partially-fractionalize the integrand to proceed
\begin{align}
I &= \frac\pi2+ \frac8{2r^3-7r^2+1}\int_0^1 \left( \frac{r^2}{t^2-r} 
+\frac{1-r^2t^2}{ t^4+(r-7)t^2+1/r}\right) dt\\
&= \frac\pi2 +\frac8{2r^3-7r^2+1} \left(- r^{3/2}\coth^{-1} \sqrt{r}
-\frac{r^2-\sqrt r}{2\sqrt{ \frac2{\sqrt r}+r-7 }}  \cot^{-1} \frac{\frac1{\sqrt r} -1}{\sqrt{ \frac2{\sqrt r}+r-7 }}\\
 + \frac{r^2+\sqrt r}{ 2\sqrt{ \frac2{\sqrt r}-r+7 }}\coth^{-1} \frac{\frac1{\sqrt r} +1}{\sqrt{ \frac2{\sqrt r}-r+7 }}\right)\\
\end{align}
where, as mentioned above
$$r= \frac13\left( 7 + \sqrt[3]{388 +12\sqrt{69}}+ \sqrt[3]{388 -12\sqrt{69}}\right)
$$
</s>