Optimal. Leaf size=175 \[ -\frac {a d^3 f^2}{2 e \left (e x+f \sqrt {a+\frac {e^2 x^2}{f^2}}\right )}+\frac {a d f^2 \left (e x+f \sqrt {a+\frac {e^2 x^2}{f^2}}\right )}{e}+\frac {a f^2 \left (d+e x+f \sqrt {a+\frac {e^2 x^2}{f^2}}\right )^2}{4 e}+\frac {\left (d+e x+f \sqrt {a+\frac {e^2 x^2}{f^2}}\right )^4}{8 e}+\frac {3 a d^2 f^2 \log \left (e x+f \sqrt {a+\frac {e^2 x^2}{f^2}}\right )}{2 e} \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.09, antiderivative size = 175, normalized size of antiderivative = 1.00, number of steps
used = 3, number of rules used = 2, integrand size = 25, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.080, Rules used = {2142, 907}
\begin {gather*} -\frac {a d^3 f^2}{2 e \left (f \sqrt {a+\frac {e^2 x^2}{f^2}}+e x\right )}+\frac {3 a d^2 f^2 \log \left (f \sqrt {a+\frac {e^2 x^2}{f^2}}+e x\right )}{2 e}+\frac {\left (f \sqrt {a+\frac {e^2 x^2}{f^2}}+d+e x\right )^4}{8 e}+\frac {a f^2 \left (f \sqrt {a+\frac {e^2 x^2}{f^2}}+d+e x\right )^2}{4 e}+\frac {a d f^2 \left (f \sqrt {a+\frac {e^2 x^2}{f^2}}+e x\right )}{e} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 907
Rule 2142
Rubi steps
\begin {align*} \int \left (d+e x+f \sqrt {a+\frac {e^2 x^2}{f^2}}\right )^3 \, dx &=\frac {\text {Subst}\left (\int \frac {x^3 \left (d^2+a f^2-2 d x+x^2\right )}{(d-x)^2} \, dx,x,d+e x+f \sqrt {a+\frac {e^2 x^2}{f^2}}\right )}{2 e}\\ &=\frac {\text {Subst}\left (\int \left (2 a d f^2+\frac {a d^3 f^2}{(d-x)^2}-\frac {3 a d^2 f^2}{d-x}+a f^2 x+x^3\right ) \, dx,x,d+e x+f \sqrt {a+\frac {e^2 x^2}{f^2}}\right )}{2 e}\\ &=-\frac {a d^3 f^2}{2 e \left (e x+f \sqrt {a+\frac {e^2 x^2}{f^2}}\right )}+\frac {a d f^2 \left (e x+f \sqrt {a+\frac {e^2 x^2}{f^2}}\right )}{e}+\frac {a f^2 \left (d+e x+f \sqrt {a+\frac {e^2 x^2}{f^2}}\right )^2}{4 e}+\frac {\left (d+e x+f \sqrt {a+\frac {e^2 x^2}{f^2}}\right )^4}{8 e}+\frac {3 a d^2 f^2 \log \left (e x+f \sqrt {a+\frac {e^2 x^2}{f^2}}\right )}{2 e}\\ \end {align*}
________________________________________________________________________________________
Mathematica [A]
time = 0.78, size = 159, normalized size = 0.91 \begin {gather*} \frac {1}{2} \left (x \left (2 d^3+6 a d f^2+3 d^2 e x+3 a e f^2 x+4 d e^2 x^2+2 e^3 x^3\right )+\frac {\sqrt {a+\frac {e^2 x^2}{f^2}} \left (2 a f^3 (2 d+e x)+e f x \left (3 d^2+4 d e x+2 e^2 x^2\right )\right )}{e}-\frac {3 a d^2 f \log \left (-\sqrt {\frac {e^2}{f^2}} x+\sqrt {a+\frac {e^2 x^2}{f^2}}\right )}{\sqrt {\frac {e^2}{f^2}}}\right ) \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [B] Leaf count of result is larger than twice the leaf count of optimal. \(340\) vs.
\(2(157)=314\).
time = 0.21, size = 341, normalized size = 1.95
method | result | size |
default | \(f^{3} \left (\frac {x \left (a +\frac {e^{2} x^{2}}{f^{2}}\right )^{\frac {3}{2}}}{4}+\frac {3 a \left (\frac {x \sqrt {a +\frac {e^{2} x^{2}}{f^{2}}}}{2}+\frac {a \ln \left (\frac {e^{2} x}{f^{2} \sqrt {\frac {e^{2}}{f^{2}}}}+\sqrt {a +\frac {e^{2} x^{2}}{f^{2}}}\right )}{2 \sqrt {\frac {e^{2}}{f^{2}}}}\right )}{4}\right )+3 f^{2} \left (\frac {e^{3} x^{4}}{4 f^{2}}+\frac {d \,e^{2} x^{3}}{3 f^{2}}+\frac {a e \,x^{2}}{2}+a d x \right )+3 f \left (e^{2} \left (\frac {x \left (a +\frac {e^{2} x^{2}}{f^{2}}\right )^{\frac {3}{2}} f^{2}}{4 e^{2}}-\frac {a \,f^{2} \left (\frac {x \sqrt {a +\frac {e^{2} x^{2}}{f^{2}}}}{2}+\frac {a \ln \left (\frac {e^{2} x}{f^{2} \sqrt {\frac {e^{2}}{f^{2}}}}+\sqrt {a +\frac {e^{2} x^{2}}{f^{2}}}\right )}{2 \sqrt {\frac {e^{2}}{f^{2}}}}\right )}{4 e^{2}}\right )+\frac {2 d \,f^{2} \left (\frac {e^{2} x^{2}+a \,f^{2}}{f^{2}}\right )^{\frac {3}{2}}}{3 e}+d^{2} \left (\frac {x \sqrt {a +\frac {e^{2} x^{2}}{f^{2}}}}{2}+\frac {a \ln \left (\frac {e^{2} x}{f^{2} \sqrt {\frac {e^{2}}{f^{2}}}}+\sqrt {a +\frac {e^{2} x^{2}}{f^{2}}}\right )}{2 \sqrt {\frac {e^{2}}{f^{2}}}}\right )\right )+\frac {\left (e x +d \right )^{4}}{4 e}\) | \(341\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [A]
time = 0.28, size = 252, normalized size = 1.44 \begin {gather*} \frac {3}{4} \, {\left (a + \frac {x^{2} e^{2}}{f^{2}}\right )}^{2} f^{4} e^{\left (-1\right )} + \frac {1}{4} \, x^{4} e^{3} + \frac {1}{8} \, {\left (3 \, a^{2} f \operatorname {arsinh}\left (\frac {x e}{\sqrt {a} f}\right ) e^{\left (-1\right )} + 2 \, {\left (a + \frac {x^{2} e^{2}}{f^{2}}\right )}^{\frac {3}{2}} x + 3 \, \sqrt {a + \frac {x^{2} e^{2}}{f^{2}}} a x\right )} f^{3} + d^{3} x + \frac {3}{2} \, {\left (x^{2} e + {\left (a f \operatorname {arsinh}\left (\frac {x e}{\sqrt {a} f}\right ) e^{\left (-1\right )} + \sqrt {a + \frac {x^{2} e^{2}}{f^{2}}} x\right )} f\right )} d^{2} - \frac {3}{8} \, {\left (a^{2} f^{3} \operatorname {arsinh}\left (\frac {x e}{\sqrt {a} f}\right ) e^{\left (-3\right )} - 2 \, {\left (a + \frac {x^{2} e^{2}}{f^{2}}\right )}^{\frac {3}{2}} f^{2} x e^{\left (-2\right )} + \sqrt {a + \frac {x^{2} e^{2}}{f^{2}}} a f^{2} x e^{\left (-2\right )}\right )} f e^{2} + {\left (2 \, {\left (a + \frac {x^{2} e^{2}}{f^{2}}\right )}^{\frac {3}{2}} f^{3} e^{\left (-1\right )} + x^{3} e^{2} + {\left (3 \, a x + \frac {x^{3} e^{2}}{f^{2}}\right )} f^{2}\right )} d \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A]
time = 0.36, size = 150, normalized size = 0.86 \begin {gather*} -\frac {1}{2} \, {\left (3 \, a d^{2} f^{2} \log \left (-x e + f \sqrt {\frac {a f^{2} + x^{2} e^{2}}{f^{2}}}\right ) - 2 \, x^{4} e^{4} - 4 \, d x^{3} e^{3} - 3 \, {\left (a f^{2} + d^{2}\right )} x^{2} e^{2} - 2 \, {\left (3 \, a d f^{2} + d^{3}\right )} x e - {\left (4 \, a d f^{3} + 2 \, f x^{3} e^{3} + 4 \, d f x^{2} e^{2} + {\left (2 \, a f^{3} + 3 \, d^{2} f\right )} x e\right )} \sqrt {\frac {a f^{2} + x^{2} e^{2}}{f^{2}}}\right )} e^{\left (-1\right )} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [A]
time = 5.47, size = 279, normalized size = 1.59 \begin {gather*} \frac {a^{\frac {3}{2}} f^{3} x \sqrt {1 + \frac {e^{2} x^{2}}{a f^{2}}}}{2} + \frac {a^{\frac {3}{2}} f^{3} x}{2 \sqrt {1 + \frac {e^{2} x^{2}}{a f^{2}}}} + \frac {3 \sqrt {a} d^{2} f x \sqrt {1 + \frac {e^{2} x^{2}}{a f^{2}}}}{2} + \frac {3 \sqrt {a} e^{2} f x^{3}}{2 \sqrt {1 + \frac {e^{2} x^{2}}{a f^{2}}}} + \frac {3 a d^{2} f^{2} \operatorname {asinh}{\left (\frac {e x}{\sqrt {a} f} \right )}}{2 e} + 3 a d f^{2} x + \frac {3 a e f^{2} x^{2}}{2} + d^{3} x + \frac {3 d^{2} e x^{2}}{2} + 2 d e^{2} x^{3} + 6 d e f \left (\begin {cases} \frac {\sqrt {a} x^{2}}{2} & \text {for}\: e^{2} = 0 \\\frac {f^{2} \left (a + \frac {e^{2} x^{2}}{f^{2}}\right )^{\frac {3}{2}}}{3 e^{2}} & \text {otherwise} \end {cases}\right ) + e^{3} x^{4} + \frac {e^{4} x^{5}}{\sqrt {a} f \sqrt {1 + \frac {e^{2} x^{2}}{a f^{2}}}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [A]
time = 3.64, size = 163, normalized size = 0.93 \begin {gather*} -\frac {3}{2} \, a d^{2} f {\left | f \right |} e^{\left (-1\right )} \log \left ({\left | -x e + \sqrt {a f^{2} + x^{2} e^{2}} \right |}\right ) + \frac {3}{2} \, a f^{2} x^{2} e + 3 \, a d f^{2} x + x^{4} e^{3} + 2 \, d x^{3} e^{2} + \frac {3}{2} \, d^{2} x^{2} e + d^{3} x + \frac {1}{2} \, {\left (4 \, a d f {\left | f \right |} e^{\left (-1\right )} + {\left (2 \, {\left (\frac {x {\left | f \right |} e^{2}}{f} + \frac {2 \, d {\left | f \right |} e}{f}\right )} x + \frac {{\left (2 \, a f^{4} {\left | f \right |} e^{4} + 3 \, d^{2} f^{2} {\left | f \right |} e^{4}\right )} e^{\left (-4\right )}}{f^{3}}\right )} x\right )} \sqrt {a f^{2} + x^{2} e^{2}} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [F]
time = 0.00, size = -1, normalized size = -0.01 \begin {gather*} \int {\left (d+e\,x+f\,\sqrt {a+\frac {e^2\,x^2}{f^2}}\right )}^3 \,d x \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________