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