\[ \int \frac {(-2 a b+(3 a-b) x) \left (-a^3+3 a^2 x-3 a x^2+x^3\right )}{x (-b+x) \sqrt [4]{x^2 (-a+x) (-b+x)} \left (a^3-3 a^2 x+(3 a-b d) x^2+(-1+d) x^3\right )} \, dx \]
Optimal antiderivative \[ -\frac {4 \left (a b \,x^{2}+\left (-a -b \right ) x^{3}+x^{4}\right )^{\frac {3}{4}}}{x^{2} \left (-b +x \right )}+2 d^{\frac {1}{4}} \arctan \left (\frac {d^{\frac {1}{4}} \left (a b \,x^{2}+\left (-a -b \right ) x^{3}+x^{4}\right )^{\frac {1}{4}}}{a -x}\right )-2 d^{\frac {1}{4}} \arctanh \left (\frac {d^{\frac {1}{4}} \left (a b \,x^{2}+\left (-a -b \right ) x^{3}+x^{4}\right )^{\frac {1}{4}}}{a -x}\right ) \]
command
Integrate[((-2*a*b + (3*a - b)*x)*(-a^3 + 3*a^2*x - 3*a*x^2 + x^3))/(x*(-b + x)*(x^2*(-a + x)*(-b + x))^(1/4)*(a^3 - 3*a^2*x + (3*a - b*d)*x^2 + (-1 + d)*x^3)),x]
Mathematica 13.1 output
\[ \frac {4 (a-x)}{\sqrt [4]{x^2 (-a+x) (-b+x)}}+\frac {\sqrt [4]{d} x \sqrt [4]{\frac {-b+x}{a-x}} \left (\text {ArcTan}\left (\frac {a-x \left (1+\sqrt {d} \sqrt {\frac {-b+x}{a-x}}\right )}{\sqrt {2} \sqrt [4]{d} \sqrt {\frac {x}{a-x}} (-a+x) \sqrt [4]{\frac {-b+x}{a-x}}}\right )-\tanh ^{-1}\left (\frac {\sqrt [4]{d} x \sqrt [4]{\frac {-b+x}{a-x}}}{\sqrt {\frac {x}{2 a-2 x}} \left (a+x \left (-1+\sqrt {d} \sqrt {\frac {-b+x}{a-x}}\right )\right )}\right )\right )}{\sqrt {\frac {x}{2 a-2 x}} \sqrt [4]{x^2 (-a+x) (-b+x)}} \]
Mathematica 12.3 output
\[ \int \frac {(-2 a b+(3 a-b) x) \left (-a^3+3 a^2 x-3 a x^2+x^3\right )}{x (-b+x) \sqrt [4]{x^2 (-a+x) (-b+x)} \left (a^3-3 a^2 x+(3 a-b d) x^2+(-1+d) x^3\right )} \, dx \]________________________________________________________________________________________