Optimal. Leaf size=543 \[ \frac {\left (\sqrt [3]{d}-i \sqrt {3} \sqrt [3]{d}\right ) \log \left (\sqrt [3]{-1} (b-x) (b d-a d)^{2/3}-\sqrt [3]{d} (a-b)^{2/3} \sqrt [3]{x \left (2 a b+b^2\right )-a b^2+x^2 (-a-2 b)+x^3}\right )}{2 \sqrt [3]{a-b} (-(d (a-b)))^{2/3}}+\frac {\sqrt {-3-3 i \sqrt {3}} \sqrt [3]{d} \tan ^{-1}\left (\frac {\sqrt {3} \sqrt [3]{d} (a-b)^{2/3} \sqrt [3]{x \left (2 a b+b^2\right )-a b^2+x^2 (-a-2 b)+x^3}}{\sqrt [3]{d} (a-b)^{2/3} \sqrt [3]{x \left (2 a b+b^2\right )-a b^2+x^2 (-a-2 b)+x^3}-2 \sqrt [3]{-1} x (b d-a d)^{2/3}+2 \sqrt [3]{-1} b (b d-a d)^{2/3}}\right )}{\sqrt {2} \sqrt [3]{a-b} (-(d (a-b)))^{2/3}}+\frac {i \left (\sqrt {3} \sqrt [3]{d}+i \sqrt [3]{d}\right ) \log \left (-d^{2/3} (a-b)^{4/3} \left (x \left (2 a b+b^2\right )-a b^2+x^2 (-a-2 b)+x^3\right )^{2/3}+\sqrt [3]{-1} \sqrt [3]{d} (a-b)^{2/3} (x-b) (b d-a d)^{2/3} \sqrt [3]{x \left (2 a b+b^2\right )-a b^2+x^2 (-a-2 b)+x^3}+(-1)^{2/3} d \sqrt [3]{b d-a d} \left (a b^2-2 a b x+a x^2-b^3+2 b^2 x-b x^2\right )\right )}{4 \sqrt [3]{a-b} (-(d (a-b)))^{2/3}} \]
________________________________________________________________________________________
Rubi [A] time = 0.67, antiderivative size = 377, normalized size of antiderivative = 0.69, number of steps used = 3, number of rules used = 3, integrand size = 31, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.097, Rules used = {2081, 2077, 91} \begin {gather*} \frac {\left ((a-b)^2 (b-x)\right )^{2/3} \sqrt [3]{(a-b)^2 (x-a)} \log (a-b d+(d-1) x)}{2 \sqrt [3]{d} (a-b)^3 \sqrt [3]{-a b^2+x^2 (-a-2 b)+b x (2 a+b)+x^3}}-\frac {3 \left ((a-b)^2 (b-x)\right )^{2/3} \sqrt [3]{(a-b)^2 (x-a)} \log \left (-\frac {\sqrt [3]{\frac {2}{3}} \sqrt [3]{(a-b)^2 (x-a)}}{\sqrt [3]{d}}-\sqrt [3]{\frac {2}{3}} \sqrt [3]{(a-b)^2 (b-x)}\right )}{2 \sqrt [3]{d} (a-b)^3 \sqrt [3]{-a b^2+x^2 (-a-2 b)+b x (2 a+b)+x^3}}-\frac {\sqrt {3} \left ((a-b)^2 (b-x)\right )^{2/3} \sqrt [3]{(a-b)^2 (x-a)} \tan ^{-1}\left (\frac {1}{\sqrt {3}}-\frac {2 \sqrt [3]{(a-b)^2 (x-a)}}{\sqrt {3} \sqrt [3]{d} \sqrt [3]{(a-b)^2 (b-x)}}\right )}{\sqrt [3]{d} (a-b)^3 \sqrt [3]{-a b^2+x^2 (-a-2 b)+b x (2 a+b)+x^3}} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 91
Rule 2077
Rule 2081
Rubi steps
\begin {align*} \int \frac {1}{\sqrt [3]{(-a+x) (-b+x)^2} (a-b d+(-1+d) x)} \, dx &=\operatorname {Subst}\left (\int \frac {1}{\left (\frac {1}{3} (-((-a-2 b) (-1+d))+3 (a-b d))+(-1+d) x\right ) \sqrt [3]{-\frac {2}{27} (a-b)^3-\frac {1}{3} (a-b)^2 x+x^3}} \, dx,x,\frac {1}{3} (-a-2 b)+x\right )\\ &=\frac {\left (2^{2/3} \sqrt [3]{-(a-b)^2 (a-x)} \left ((a-b)^2 (b-x)\right )^{2/3}\right ) \operatorname {Subst}\left (\int \frac {1}{\left (-\frac {2}{9} (a-b)^3-\frac {2}{3} (a-b)^2 x\right )^{2/3} \sqrt [3]{-\frac {2}{9} (a-b)^3+\frac {1}{3} (a-b)^2 x} \left (\frac {1}{3} (-((-a-2 b) (-1+d))+3 (a-b d))+(-1+d) x\right )} \, dx,x,\frac {1}{3} (-a-2 b)+x\right )}{3 \sqrt [3]{-a b^2+b (2 a+b) x-(a+2 b) x^2+x^3}}\\ &=-\frac {\sqrt {3} \sqrt [3]{-(a-b)^2 (a-x)} \left ((a-b)^2 (b-x)\right )^{2/3} \tan ^{-1}\left (\frac {1}{\sqrt {3}}-\frac {2 \sqrt [3]{-(a-b)^2 (a-x)}}{\sqrt {3} \sqrt [3]{d} \sqrt [3]{(a-b)^2 (b-x)}}\right )}{(a-b)^3 \sqrt [3]{d} \sqrt [3]{-a b^2+b (2 a+b) x-(a+2 b) x^2+x^3}}-\frac {3 \sqrt [3]{-(a-b)^2 (a-x)} \left ((a-b)^2 (b-x)\right )^{2/3} \log \left (\sqrt [3]{-(a-b)^2 (a-x)}+\sqrt [3]{d} \sqrt [3]{(a-b)^2 (b-x)}\right )}{2 (a-b)^3 \sqrt [3]{d} \sqrt [3]{-a b^2+b (2 a+b) x-(a+2 b) x^2+x^3}}+\frac {\sqrt [3]{-(a-b)^2 (a-x)} \left ((a-b)^2 (b-x)\right )^{2/3} \log (a-b d-(1-d) x)}{2 (a-b)^3 \sqrt [3]{d} \sqrt [3]{-a b^2+b (2 a+b) x-(a+2 b) x^2+x^3}}\\ \end {align*}
________________________________________________________________________________________
Mathematica [C] time = 0.04, size = 53, normalized size = 0.10 \begin {gather*} \frac {3 (x-b) \, _2F_1\left (\frac {1}{3},1;\frac {4}{3};\frac {d (b-x)}{a-x}\right )}{(a-b) \sqrt [3]{(x-a) (b-x)^2}} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
IntegrateAlgebraic [A] time = 7.72, size = 703, normalized size = 1.29 \begin {gather*} \frac {\sqrt {-3-3 i \sqrt {3}} \sqrt [3]{d} \tan ^{-1}\left (\frac {\sqrt {3} (a-b)^{2/3} \sqrt [3]{d} \sqrt [3]{-a b^2+\left (2 a b+b^2\right ) x+(-a-2 b) x^2+x^3}}{b (-a d+b d)^{2/3}+i \sqrt {3} b (-a d+b d)^{2/3}+\left (-(-a d+b d)^{2/3}-i \sqrt {3} (-a d+b d)^{2/3}\right ) x+(a-b)^{2/3} \sqrt [3]{d} \sqrt [3]{-a b^2+\left (2 a b+b^2\right ) x+(-a-2 b) x^2+x^3}}\right )}{\sqrt {2} \sqrt [3]{a-b} (-((a-b) d))^{2/3}}+\frac {\left (\sqrt [3]{d}-i \sqrt {3} \sqrt [3]{d}\right ) \log \left ((-a d+b d)^{2/3} \left (-b+\sqrt {3} (-i b+i x)+x\right )+2 (a-b)^{2/3} \sqrt [3]{d} \sqrt [3]{-a b^2+\left (2 a b+b^2\right ) x+(-a-2 b) x^2+x^3}\right )}{2 \sqrt [3]{a-b} (-((a-b) d))^{2/3}}+\frac {i \left (i \sqrt [3]{d}+\sqrt {3} \sqrt [3]{d}\right ) \log \left (2 (a-b)^{4/3} d^{2/3} \left (-a b^2+\left (2 a b+b^2\right ) x+(-a-2 b) x^2+x^3\right )^{2/3}+\sqrt [3]{-a d+b d} \left (d \left (a b^2-b^3-2 a b x+2 b^2 x+a x^2-b x^2\right )+\sqrt {3} d \left (-i a b^2+i b^3+2 i a b x-2 i b^2 x-i a x^2+i b x^2\right )\right )+(-a d+b d)^{2/3} \left ((a-b)^{2/3} \sqrt [3]{d} (b-x) \sqrt [3]{-a b^2+\left (2 a b+b^2\right ) x+(-a-2 b) x^2+x^3}+\sqrt {3} (a-b)^{2/3} \sqrt [3]{d} (i b-i x) \sqrt [3]{-a b^2+\left (2 a b+b^2\right ) x+(-a-2 b) x^2+x^3}\right )\right )}{4 \sqrt [3]{a-b} (-((a-b) d))^{2/3}} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
fricas [A] time = 0.68, size = 662, normalized size = 1.22 \begin {gather*} \left [-\frac {\sqrt {3} d \sqrt {-\frac {1}{d^{\frac {2}{3}}}} \log \left (-\frac {b^{2} d + {\left (d + 2\right )} x^{2} + 2 \, a b + 3 \, {\left (-a b^{2} - {\left (a + 2 \, b\right )} x^{2} + x^{3} + {\left (2 \, a b + b^{2}\right )} x\right )}^{\frac {1}{3}} {\left (b - x\right )} d^{\frac {2}{3}} - 2 \, {\left (b d + a + b\right )} x + \sqrt {3} {\left ({\left (-a b^{2} - {\left (a + 2 \, b\right )} x^{2} + x^{3} + {\left (2 \, a b + b^{2}\right )} x\right )}^{\frac {1}{3}} {\left (b d - d x\right )} - {\left (b^{2} d - 2 \, b d x + d x^{2}\right )} d^{\frac {1}{3}} + 2 \, {\left (-a b^{2} - {\left (a + 2 \, b\right )} x^{2} + x^{3} + {\left (2 \, a b + b^{2}\right )} x\right )}^{\frac {2}{3}} d^{\frac {2}{3}}\right )} \sqrt {-\frac {1}{d^{\frac {2}{3}}}}}{b^{2} d + {\left (d - 1\right )} x^{2} - a b - {\left (2 \, b d - a - b\right )} x}\right ) - d^{\frac {2}{3}} \log \left (-\frac {{\left (-a b^{2} - {\left (a + 2 \, b\right )} x^{2} + x^{3} + {\left (2 \, a b + b^{2}\right )} x\right )}^{\frac {1}{3}} {\left (b - x\right )} d^{\frac {1}{3}} - {\left (b^{2} - 2 \, b x + x^{2}\right )} d^{\frac {2}{3}} - {\left (-a b^{2} - {\left (a + 2 \, b\right )} x^{2} + x^{3} + {\left (2 \, a b + b^{2}\right )} x\right )}^{\frac {2}{3}}}{b^{2} - 2 \, b x + x^{2}}\right ) + 2 \, d^{\frac {2}{3}} \log \left (-\frac {{\left (b - x\right )} d^{\frac {1}{3}} + {\left (-a b^{2} - {\left (a + 2 \, b\right )} x^{2} + x^{3} + {\left (2 \, a b + b^{2}\right )} x\right )}^{\frac {1}{3}}}{b - x}\right )}{2 \, {\left (a - b\right )} d}, -\frac {2 \, \sqrt {3} d^{\frac {2}{3}} \arctan \left (\frac {\sqrt {3} {\left ({\left (b - x\right )} d^{\frac {1}{3}} - 2 \, {\left (-a b^{2} - {\left (a + 2 \, b\right )} x^{2} + x^{3} + {\left (2 \, a b + b^{2}\right )} x\right )}^{\frac {1}{3}}\right )}}{3 \, {\left (b - x\right )} d^{\frac {1}{3}}}\right ) - d^{\frac {2}{3}} \log \left (-\frac {{\left (-a b^{2} - {\left (a + 2 \, b\right )} x^{2} + x^{3} + {\left (2 \, a b + b^{2}\right )} x\right )}^{\frac {1}{3}} {\left (b - x\right )} d^{\frac {1}{3}} - {\left (b^{2} - 2 \, b x + x^{2}\right )} d^{\frac {2}{3}} - {\left (-a b^{2} - {\left (a + 2 \, b\right )} x^{2} + x^{3} + {\left (2 \, a b + b^{2}\right )} x\right )}^{\frac {2}{3}}}{b^{2} - 2 \, b x + x^{2}}\right ) + 2 \, d^{\frac {2}{3}} \log \left (-\frac {{\left (b - x\right )} d^{\frac {1}{3}} + {\left (-a b^{2} - {\left (a + 2 \, b\right )} x^{2} + x^{3} + {\left (2 \, a b + b^{2}\right )} x\right )}^{\frac {1}{3}}}{b - x}\right )}{2 \, {\left (a - b\right )} d}\right ] \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
giac [F] time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \int -\frac {1}{\left (-{\left (a - x\right )} {\left (b - x\right )}^{2}\right )^{\frac {1}{3}} {\left (b d - {\left (d - 1\right )} x - a\right )}}\,{d x} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maple [F] time = 0.01, size = 0, normalized size = 0.00 \[\int \frac {1}{\left (\left (-a +x \right ) \left (-b +x \right )^{2}\right )^{\frac {1}{3}} \left (a -b d +\left (-1+d \right ) x \right )}\, dx\]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maxima [F] time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} -\int \frac {1}{\left (-{\left (a - x\right )} {\left (b - x\right )}^{2}\right )^{\frac {1}{3}} {\left (b d - {\left (d - 1\right )} x - a\right )}}\,{d x} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
mupad [F] time = 0.00, size = -1, normalized size = -0.00 \begin {gather*} \int \frac {1}{{\left (-\left (a-x\right )\,{\left (b-x\right )}^2\right )}^{1/3}\,\left (a-b\,d+x\,\left (d-1\right )\right )} \,d x \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
sympy [F] time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \int \frac {1}{\sqrt [3]{\left (- a + x\right ) \left (- b + x\right )^{2}} \left (a - b d + d x - x\right )}\, dx \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________