3.454 \(\int (d+e x+f \sqrt{a+\frac{e^2 x^2}{f^2}})^3 \, dx\)

Optimal. Leaf size=175 \[ -\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} \]

[Out]

-(a*d^3*f^2)/(2*e*(e*x + f*Sqrt[a + (e^2*x^2)/f^2])) + (a*d*f^2*(e*x + f*Sqrt[a + (e^2*x^2)/f^2]))/e + (a*f^2*
(d + e*x + f*Sqrt[a + (e^2*x^2)/f^2])^2)/(4*e) + (d + e*x + f*Sqrt[a + (e^2*x^2)/f^2])^4/(8*e) + (3*a*d^2*f^2*
Log[e*x + f*Sqrt[a + (e^2*x^2)/f^2]])/(2*e)

________________________________________________________________________________________

Rubi [A]  time = 0.133334, antiderivative size = 175, normalized size of antiderivative = 1., number of steps used = 3, number of rules used = 2, integrand size = 25, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.08, Rules used = {2117, 893} \[ -\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} \]

Antiderivative was successfully verified.

[In]

Int[(d + e*x + f*Sqrt[a + (e^2*x^2)/f^2])^3,x]

[Out]

-(a*d^3*f^2)/(2*e*(e*x + f*Sqrt[a + (e^2*x^2)/f^2])) + (a*d*f^2*(e*x + f*Sqrt[a + (e^2*x^2)/f^2]))/e + (a*f^2*
(d + e*x + f*Sqrt[a + (e^2*x^2)/f^2])^2)/(4*e) + (d + e*x + f*Sqrt[a + (e^2*x^2)/f^2])^4/(8*e) + (3*a*d^2*f^2*
Log[e*x + f*Sqrt[a + (e^2*x^2)/f^2]])/(2*e)

Rule 2117

Int[((g_.) + (h_.)*((d_.) + (e_.)*(x_) + (f_.)*Sqrt[(a_) + (c_.)*(x_)^2])^(n_))^(p_.), x_Symbol] :> Dist[1/(2*
e), Subst[Int[((g + h*x^n)^p*(d^2 + a*f^2 - 2*d*x + x^2))/(d - x)^2, x], x, d + e*x + f*Sqrt[a + c*x^2]], x] /
; FreeQ[{a, c, d, e, f, g, h, n}, x] && EqQ[e^2 - c*f^2, 0] && IntegerQ[p]

Rule 893

Int[((d_.) + (e_.)*(x_))^(m_)*((f_.) + (g_.)*(x_))^(n_)*((a_.) + (b_.)*(x_) + (c_.)*(x_)^2)^(p_.), x_Symbol] :
> Int[ExpandIntegrand[(d + e*x)^m*(f + g*x)^n*(a + b*x + c*x^2)^p, x], x] /; FreeQ[{a, b, c, d, e, f, g}, x] &
& NeQ[e*f - d*g, 0] && NeQ[b^2 - 4*a*c, 0] && NeQ[c*d^2 - b*d*e + a*e^2, 0] && IntegerQ[p] && ((EqQ[p, 1] && I
ntegersQ[m, n]) || (ILtQ[m, 0] && ILtQ[n, 0]))

Rubi steps

\begin{align*} \int \left (d+e x+f \sqrt{a+\frac{e^2 x^2}{f^2}}\right )^3 \, dx &=\frac{\operatorname{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{\operatorname{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.32916, size = 158, normalized size = 0.9 \[ \frac{-\frac{4 a d^3 f^2}{f \sqrt{a+\frac{e^2 x^2}{f^2}}+e x}+12 a d^2 f^2 \log \left (f \sqrt{a+\frac{e^2 x^2}{f^2}}+e x\right )+\left (f \sqrt{a+\frac{e^2 x^2}{f^2}}+d+e x\right )^4+2 a f^2 \left (f \sqrt{a+\frac{e^2 x^2}{f^2}}+d+e x\right )^2+8 a d f^2 \left (f \sqrt{a+\frac{e^2 x^2}{f^2}}+e x\right )}{8 e} \]

Antiderivative was successfully verified.

[In]

Integrate[(d + e*x + f*Sqrt[a + (e^2*x^2)/f^2])^3,x]

[Out]

((-4*a*d^3*f^2)/(e*x + f*Sqrt[a + (e^2*x^2)/f^2]) + 8*a*d*f^2*(e*x + f*Sqrt[a + (e^2*x^2)/f^2]) + 2*a*f^2*(d +
 e*x + f*Sqrt[a + (e^2*x^2)/f^2])^2 + (d + e*x + f*Sqrt[a + (e^2*x^2)/f^2])^4 + 12*a*d^2*f^2*Log[e*x + f*Sqrt[
a + (e^2*x^2)/f^2]])/(8*e)

________________________________________________________________________________________

Maple [A]  time = 0.01, size = 175, normalized size = 1. \begin{align*}{f}^{3}x \left ( a+{\frac{{e}^{2}{x}^{2}}{{f}^{2}}} \right ) ^{{\frac{3}{2}}}+{e}^{3}{x}^{4}+2\,d{e}^{2}{x}^{3}+{\frac{3\,{f}^{2}ae{x}^{2}}{2}}+3\,{f}^{2}adx+2\,{\frac{d{f}^{3}}{e} \left ({\frac{{e}^{2}{x}^{2}+a{f}^{2}}{{f}^{2}}} \right ) ^{3/2}}+{\frac{3\,f{d}^{2}x}{2}\sqrt{a+{\frac{{e}^{2}{x}^{2}}{{f}^{2}}}}}+{\frac{3\,f{d}^{2}a}{2}\ln \left ({\frac{{e}^{2}x}{{f}^{2}}{\frac{1}{\sqrt{{\frac{{e}^{2}}{{f}^{2}}}}}}}+\sqrt{a+{\frac{{e}^{2}{x}^{2}}{{f}^{2}}}} \right ){\frac{1}{\sqrt{{\frac{{e}^{2}}{{f}^{2}}}}}}}+{\frac{3\,e{x}^{2}{d}^{2}}{2}}+x{d}^{3}+{\frac{{d}^{4}}{4\,e}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((d+e*x+f*(a+e^2*x^2/f^2)^(1/2))^3,x)

[Out]

f^3*x*(a+e^2*x^2/f^2)^(3/2)+e^3*x^4+2*d*e^2*x^3+3/2*f^2*a*e*x^2+3*f^2*a*d*x+2*d/e*f^3*((e^2*x^2+a*f^2)/f^2)^(3
/2)+3/2*f*d^2*x*(a+e^2*x^2/f^2)^(1/2)+3/2*f*d^2*a*ln(e^2*x/f^2/(e^2/f^2)^(1/2)+(a+e^2*x^2/f^2)^(1/2))/(e^2/f^2
)^(1/2)+3/2*e*x^2*d^2+x*d^3+1/4*d^4/e

________________________________________________________________________________________

Maxima [F(-2)]  time = 0., size = 0, normalized size = 0. \begin{align*} \text{Exception raised: ValueError} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((d+e*x+f*(a+e^2*x^2/f^2)^(1/2))^3,x, algorithm="maxima")

[Out]

Exception raised: ValueError

________________________________________________________________________________________

Fricas [A]  time = 0.997505, size = 333, normalized size = 1.9 \begin{align*} \frac{2 \, e^{4} x^{4} + 4 \, d e^{3} x^{3} - 3 \, a d^{2} f^{2} \log \left (-e x + f \sqrt{\frac{e^{2} x^{2} + a f^{2}}{f^{2}}}\right ) + 3 \,{\left (a e^{2} f^{2} + d^{2} e^{2}\right )} x^{2} + 2 \,{\left (3 \, a d e f^{2} + d^{3} e\right )} x +{\left (2 \, e^{3} f x^{3} + 4 \, d e^{2} f x^{2} + 4 \, a d f^{3} +{\left (2 \, a e f^{3} + 3 \, d^{2} e f\right )} x\right )} \sqrt{\frac{e^{2} x^{2} + a f^{2}}{f^{2}}}}{2 \, e} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((d+e*x+f*(a+e^2*x^2/f^2)^(1/2))^3,x, algorithm="fricas")

[Out]

1/2*(2*e^4*x^4 + 4*d*e^3*x^3 - 3*a*d^2*f^2*log(-e*x + f*sqrt((e^2*x^2 + a*f^2)/f^2)) + 3*(a*e^2*f^2 + d^2*e^2)
*x^2 + 2*(3*a*d*e*f^2 + d^3*e)*x + (2*e^3*f*x^3 + 4*d*e^2*f*x^2 + 4*a*d*f^3 + (2*a*e*f^3 + 3*d^2*e*f)*x)*sqrt(
(e^2*x^2 + a*f^2)/f^2))/e

________________________________________________________________________________________

Sympy [A]  time = 9.46108, size = 279, normalized size = 1.59 \begin{align*} \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{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((d+e*x+f*(a+e**2*x**2/f**2)**(1/2))**3,x)

[Out]

a**(3/2)*f**3*x*sqrt(1 + e**2*x**2/(a*f**2))/2 + a**(3/2)*f**3*x/(2*sqrt(1 + e**2*x**2/(a*f**2))) + 3*sqrt(a)*
d**2*f*x*sqrt(1 + e**2*x**2/(a*f**2))/2 + 3*sqrt(a)*e**2*f*x**3/(2*sqrt(1 + e**2*x**2/(a*f**2))) + 3*a*d**2*f*
*2*asinh(e*x/(sqrt(a)*f))/(2*e) + 3*a*d*f**2*x + 3*a*e*f**2*x**2/2 + d**3*x + 3*d**2*e*x**2/2 + 2*d*e**2*x**3
+ 6*d*e*f*Piecewise((sqrt(a)*x**2/2, Eq(e**2, 0)), (f**2*(a + e**2*x**2/f**2)**(3/2)/(3*e**2), True)) + e**3*x
**4 + e**4*x**5/(sqrt(a)*f*sqrt(1 + e**2*x**2/(a*f**2)))

________________________________________________________________________________________

Giac [A]  time = 1.23474, size = 220, normalized size = 1.26 \begin{align*} -\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{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((d+e*x+f*(a+e^2*x^2/f^2)^(1/2))^3,x, algorithm="giac")

[Out]

-3/2*a*d^2*f*abs(f)*e^(-1)*log(abs(-x*e + sqrt(a*f^2 + x^2*e^2))) + 3/2*a*f^2*x^2*e + 3*a*d*f^2*x + x^4*e^3 +
2*d*x^3*e^2 + 3/2*d^2*x^2*e + d^3*x + 1/2*(4*a*d*f*abs(f)*e^(-1) + (2*(x*abs(f)*e^2/f + 2*d*abs(f)*e/f)*x + (2
*a*f^4*abs(f)*e^4 + 3*d^2*f^2*abs(f)*e^4)*e^(-4)/f^3)*x)*sqrt(a*f^2 + x^2*e^2)