\[ \int \frac {\left (-1+x^6\right )^{2/3} \left (1+x^6\right ) \left (-1-x^3+x^6\right )}{x^6 \left (-1+x^3+x^6\right )} \, dx \]
Optimal antiderivative \[ \frac {\left (x^{6}-1\right )^{\frac {2}{3}} \left (x^{6}-5 x^{3}-1\right )}{5 x^{5}}-\frac {2 \arctan \left (\frac {\sqrt {3}\, x}{-x +2 \left (x^{6}-1\right )^{\frac {1}{3}}}\right ) \sqrt {3}}{3}-\frac {2 \ln \left (x +\left (x^{6}-1\right )^{\frac {1}{3}}\right )}{3}+\frac {\ln \left (x^{2}-x \left (x^{6}-1\right )^{\frac {1}{3}}+\left (x^{6}-1\right )^{\frac {2}{3}}\right )}{3} \]
command
Integrate[((-1 + x^6)^(2/3)*(1 + x^6)*(-1 - x^3 + x^6))/(x^6*(-1 + x^3 + x^6)),x]
Mathematica 13.1 output
\[ \frac {\left (-1+x^6\right )^{2/3} \left (-1-5 x^3+x^6\right )}{5 x^5}-\frac {2 \text {ArcTan}\left (\frac {\sqrt {3} x}{-x+2 \sqrt [3]{-1+x^6}}\right )}{\sqrt {3}}-\frac {2}{3} \log \left (x+\sqrt [3]{-1+x^6}\right )+\frac {1}{3} \log \left (x^2-x \sqrt [3]{-1+x^6}+\left (-1+x^6\right )^{2/3}\right ) \]
Mathematica 12.3 output
\[ \int \frac {\left (-1+x^6\right )^{2/3} \left (1+x^6\right ) \left (-1-x^3+x^6\right )}{x^6 \left (-1+x^3+x^6\right )} \, dx \]________________________________________________________________________________________