Optimal. Leaf size=64 \[ -\frac {\sqrt {2} \text {ArcTan}\left (\frac {\sqrt {2} \sqrt {a} \sqrt {b} \sqrt {b^2 x+a^2 x^3}}{b^2+a^2 x^2}\right )}{\sqrt {a} \sqrt {b}} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.50, antiderivative size = 91, normalized size of antiderivative = 1.42, number of steps
used = 4, number of rules used = 4, integrand size = 32, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.125, Rules used = {2081, 6865,
1713, 211} \begin {gather*} -\frac {\sqrt {2} \sqrt {x} \sqrt {a^2 x^2+b^2} \text {ArcTan}\left (\frac {\sqrt {2} \sqrt {a} \sqrt {b} \sqrt {x}}{\sqrt {a^2 x^2+b^2}}\right )}{\sqrt {a} \sqrt {b} \sqrt {a^2 x^3+b^2 x}} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 211
Rule 1713
Rule 2081
Rule 6865
Rubi steps
\begin {align*} \int \frac {-b+a x}{(b+a x) \sqrt {b^2 x+a^2 x^3}} \, dx &=\frac {\left (\sqrt {x} \sqrt {b^2+a^2 x^2}\right ) \int \frac {-b+a x}{\sqrt {x} (b+a x) \sqrt {b^2+a^2 x^2}} \, dx}{\sqrt {b^2 x+a^2 x^3}}\\ &=\frac {\left (2 \sqrt {x} \sqrt {b^2+a^2 x^2}\right ) \text {Subst}\left (\int \frac {-b+a x^2}{\left (b+a x^2\right ) \sqrt {b^2+a^2 x^4}} \, dx,x,\sqrt {x}\right )}{\sqrt {b^2 x+a^2 x^3}}\\ &=-\frac {\left (2 b \sqrt {x} \sqrt {b^2+a^2 x^2}\right ) \text {Subst}\left (\int \frac {1}{b+2 a b^2 x^2} \, dx,x,\frac {\sqrt {x}}{\sqrt {b^2+a^2 x^2}}\right )}{\sqrt {b^2 x+a^2 x^3}}\\ &=-\frac {\sqrt {2} \sqrt {x} \sqrt {b^2+a^2 x^2} \tan ^{-1}\left (\frac {\sqrt {2} \sqrt {a} \sqrt {b} \sqrt {x}}{\sqrt {b^2+a^2 x^2}}\right )}{\sqrt {a} \sqrt {b} \sqrt {b^2 x+a^2 x^3}}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 0.38, size = 91, normalized size = 1.42 \begin {gather*} -\frac {\sqrt {2} \sqrt {x} \sqrt {b^2+a^2 x^2} \text {ArcTan}\left (\frac {\sqrt {2} \sqrt {a} \sqrt {b} \sqrt {x}}{\sqrt {b^2+a^2 x^2}}\right )}{\sqrt {a} \sqrt {b} \sqrt {x \left (b^2+a^2 x^2\right )}} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [C] Result contains higher order function than in optimal. Order 4 vs. order
3.
time = 0.48, size = 231, normalized size = 3.61
method | result | size |
default | \(\frac {i b \sqrt {-\frac {i \left (x +\frac {i b}{a}\right ) a}{b}}\, \sqrt {2}\, \sqrt {\frac {i \left (x -\frac {i b}{a}\right ) a}{b}}\, \sqrt {\frac {i x a}{b}}\, \EllipticF \left (\sqrt {-\frac {i \left (x +\frac {i b}{a}\right ) a}{b}}, \frac {\sqrt {2}}{2}\right )}{a \sqrt {a^{2} x^{3}+b^{2} x}}-\frac {2 i b^{2} \sqrt {-\frac {i \left (x +\frac {i b}{a}\right ) a}{b}}\, \sqrt {2}\, \sqrt {\frac {i \left (x -\frac {i b}{a}\right ) a}{b}}\, \sqrt {\frac {i x a}{b}}\, \EllipticPi \left (\sqrt {-\frac {i \left (x +\frac {i b}{a}\right ) a}{b}}, -\frac {i b}{a \left (-\frac {i b}{a}+\frac {b}{a}\right )}, \frac {\sqrt {2}}{2}\right )}{a^{2} \sqrt {a^{2} x^{3}+b^{2} x}\, \left (-\frac {i b}{a}+\frac {b}{a}\right )}\) | \(231\) |
elliptic | \(\frac {i b \sqrt {-\frac {i \left (x +\frac {i b}{a}\right ) a}{b}}\, \sqrt {2}\, \sqrt {\frac {i \left (x -\frac {i b}{a}\right ) a}{b}}\, \sqrt {\frac {i x a}{b}}\, \EllipticF \left (\sqrt {-\frac {i \left (x +\frac {i b}{a}\right ) a}{b}}, \frac {\sqrt {2}}{2}\right )}{a \sqrt {a^{2} x^{3}+b^{2} x}}-\frac {2 i b^{2} \sqrt {-\frac {i \left (x +\frac {i b}{a}\right ) a}{b}}\, \sqrt {2}\, \sqrt {\frac {i \left (x -\frac {i b}{a}\right ) a}{b}}\, \sqrt {\frac {i x a}{b}}\, \EllipticPi \left (\sqrt {-\frac {i \left (x +\frac {i b}{a}\right ) a}{b}}, -\frac {i b}{a \left (-\frac {i b}{a}+\frac {b}{a}\right )}, \frac {\sqrt {2}}{2}\right )}{a^{2} \sqrt {a^{2} x^{3}+b^{2} x}\, \left (-\frac {i b}{a}+\frac {b}{a}\right )}\) | \(231\) |
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*} \text {Failed to integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A]
time = 0.41, size = 213, normalized size = 3.33 \begin {gather*} \left [\frac {1}{4} \, \sqrt {2} \sqrt {-\frac {1}{a b}} \log \left (\frac {a^{4} x^{4} - 12 \, a^{3} b x^{3} + 6 \, a^{2} b^{2} x^{2} - 12 \, a b^{3} x + b^{4} + 4 \, \sqrt {2} {\left (a^{3} b x^{2} - 2 \, a^{2} b^{2} x + a b^{3}\right )} \sqrt {a^{2} x^{3} + b^{2} x} \sqrt {-\frac {1}{a b}}}{a^{4} x^{4} + 4 \, a^{3} b x^{3} + 6 \, a^{2} b^{2} x^{2} + 4 \, a b^{3} x + b^{4}}\right ), -\frac {1}{2} \, \sqrt {2} \sqrt {\frac {1}{a b}} \arctan \left (\frac {2 \, \sqrt {2} \sqrt {a^{2} x^{3} + b^{2} x} a b \sqrt {\frac {1}{a b}}}{a^{2} x^{2} - 2 \, a b x + b^{2}}\right )\right ] \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 {a x - b}{\sqrt {x \left (a^{2} x^{2} + b^{2}\right )} \left (a x + b\right )}\, dx \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*} \text {could not integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [F(-1)]
time = 0.00, size = -1, normalized size = -0.02 \begin {gather*} \text {Hanged} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________