### 3.1947 $$\int \frac{(d+e x)^2}{\sqrt{a d e+(c d^2+a e^2) x+c d e x^2}} \, dx$$

Optimal. Leaf size=195 $\frac{3 \left (c d^2-a e^2\right ) \sqrt{x \left (a e^2+c d^2\right )+a d e+c d e x^2}}{4 c^2 d^2}+\frac{3 \left (c d^2-a e^2\right )^2 \tanh ^{-1}\left (\frac{a e^2+c d^2+2 c d e x}{2 \sqrt{c} \sqrt{d} \sqrt{e} \sqrt{x \left (a e^2+c d^2\right )+a d e+c d e x^2}}\right )}{8 c^{5/2} d^{5/2} \sqrt{e}}+\frac{(d+e x) \sqrt{x \left (a e^2+c d^2\right )+a d e+c d e x^2}}{2 c d}$

[Out]

(3*(c*d^2 - a*e^2)*Sqrt[a*d*e + (c*d^2 + a*e^2)*x + c*d*e*x^2])/(4*c^2*d^2) + ((d + e*x)*Sqrt[a*d*e + (c*d^2 +
a*e^2)*x + c*d*e*x^2])/(2*c*d) + (3*(c*d^2 - a*e^2)^2*ArcTanh[(c*d^2 + a*e^2 + 2*c*d*e*x)/(2*Sqrt[c]*Sqrt[d]*
Sqrt[e]*Sqrt[a*d*e + (c*d^2 + a*e^2)*x + c*d*e*x^2])])/(8*c^(5/2)*d^(5/2)*Sqrt[e])

________________________________________________________________________________________

Rubi [A]  time = 0.115318, antiderivative size = 195, normalized size of antiderivative = 1., number of steps used = 4, number of rules used = 4, integrand size = 37, $$\frac{\text{number of rules}}{\text{integrand size}}$$ = 0.108, Rules used = {670, 640, 621, 206} $\frac{3 \left (c d^2-a e^2\right ) \sqrt{x \left (a e^2+c d^2\right )+a d e+c d e x^2}}{4 c^2 d^2}+\frac{3 \left (c d^2-a e^2\right )^2 \tanh ^{-1}\left (\frac{a e^2+c d^2+2 c d e x}{2 \sqrt{c} \sqrt{d} \sqrt{e} \sqrt{x \left (a e^2+c d^2\right )+a d e+c d e x^2}}\right )}{8 c^{5/2} d^{5/2} \sqrt{e}}+\frac{(d+e x) \sqrt{x \left (a e^2+c d^2\right )+a d e+c d e x^2}}{2 c d}$

Antiderivative was successfully veriﬁed.

[In]

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

[Out]

(3*(c*d^2 - a*e^2)*Sqrt[a*d*e + (c*d^2 + a*e^2)*x + c*d*e*x^2])/(4*c^2*d^2) + ((d + e*x)*Sqrt[a*d*e + (c*d^2 +
a*e^2)*x + c*d*e*x^2])/(2*c*d) + (3*(c*d^2 - a*e^2)^2*ArcTanh[(c*d^2 + a*e^2 + 2*c*d*e*x)/(2*Sqrt[c]*Sqrt[d]*
Sqrt[e]*Sqrt[a*d*e + (c*d^2 + a*e^2)*x + c*d*e*x^2])])/(8*c^(5/2)*d^(5/2)*Sqrt[e])

Rule 670

Int[((d_.) + (e_.)*(x_))^(m_)*((a_.) + (b_.)*(x_) + (c_.)*(x_)^2)^(p_), x_Symbol] :> Simp[(e*(d + e*x)^(m - 1)
*(a + b*x + c*x^2)^(p + 1))/(c*(m + 2*p + 1)), x] + Dist[((m + p)*(2*c*d - b*e))/(c*(m + 2*p + 1)), Int[(d + e
*x)^(m - 1)*(a + b*x + c*x^2)^p, x], x] /; FreeQ[{a, b, c, d, e, p}, x] && NeQ[b^2 - 4*a*c, 0] && EqQ[c*d^2 -
b*d*e + a*e^2, 0] && GtQ[m, 1] && NeQ[m + 2*p + 1, 0] && IntegerQ[2*p]

Rule 640

Int[((d_.) + (e_.)*(x_))*((a_.) + (b_.)*(x_) + (c_.)*(x_)^2)^(p_), x_Symbol] :> Simp[(e*(a + b*x + c*x^2)^(p +
1))/(2*c*(p + 1)), x] + Dist[(2*c*d - b*e)/(2*c), Int[(a + b*x + c*x^2)^p, x], x] /; FreeQ[{a, b, c, d, e, p}
, x] && NeQ[2*c*d - b*e, 0] && NeQ[p, -1]

Rule 621

Int[1/Sqrt[(a_) + (b_.)*(x_) + (c_.)*(x_)^2], x_Symbol] :> Dist[2, Subst[Int[1/(4*c - x^2), x], x, (b + 2*c*x)
/Sqrt[a + b*x + c*x^2]], x] /; FreeQ[{a, b, c}, x] && NeQ[b^2 - 4*a*c, 0]

Rule 206

Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(1*ArcTanh[(Rt[-b, 2]*x)/Rt[a, 2]])/(Rt[a, 2]*Rt[-b, 2]), x]
/; FreeQ[{a, b}, x] && NegQ[a/b] && (GtQ[a, 0] || LtQ[b, 0])

Rubi steps

\begin{align*} \int \frac{(d+e x)^2}{\sqrt{a d e+\left (c d^2+a e^2\right ) x+c d e x^2}} \, dx &=\frac{(d+e x) \sqrt{a d e+\left (c d^2+a e^2\right ) x+c d e x^2}}{2 c d}+\frac{\left (3 \left (d^2-\frac{a e^2}{c}\right )\right ) \int \frac{d+e x}{\sqrt{a d e+\left (c d^2+a e^2\right ) x+c d e x^2}} \, dx}{4 d}\\ &=\frac{3 \left (c d^2-a e^2\right ) \sqrt{a d e+\left (c d^2+a e^2\right ) x+c d e x^2}}{4 c^2 d^2}+\frac{(d+e x) \sqrt{a d e+\left (c d^2+a e^2\right ) x+c d e x^2}}{2 c d}+\frac{\left (3 \left (d^2-\frac{a e^2}{c}\right )^2\right ) \int \frac{1}{\sqrt{a d e+\left (c d^2+a e^2\right ) x+c d e x^2}} \, dx}{8 d^2}\\ &=\frac{3 \left (c d^2-a e^2\right ) \sqrt{a d e+\left (c d^2+a e^2\right ) x+c d e x^2}}{4 c^2 d^2}+\frac{(d+e x) \sqrt{a d e+\left (c d^2+a e^2\right ) x+c d e x^2}}{2 c d}+\frac{\left (3 \left (d^2-\frac{a e^2}{c}\right )^2\right ) \operatorname{Subst}\left (\int \frac{1}{4 c d e-x^2} \, dx,x,\frac{c d^2+a e^2+2 c d e x}{\sqrt{a d e+\left (c d^2+a e^2\right ) x+c d e x^2}}\right )}{4 d^2}\\ &=\frac{3 \left (c d^2-a e^2\right ) \sqrt{a d e+\left (c d^2+a e^2\right ) x+c d e x^2}}{4 c^2 d^2}+\frac{(d+e x) \sqrt{a d e+\left (c d^2+a e^2\right ) x+c d e x^2}}{2 c d}+\frac{3 \left (c d^2-a e^2\right )^2 \tanh ^{-1}\left (\frac{c d^2+a e^2+2 c d e x}{2 \sqrt{c} \sqrt{d} \sqrt{e} \sqrt{a d e+\left (c d^2+a e^2\right ) x+c d e x^2}}\right )}{8 c^{5/2} d^{5/2} \sqrt{e}}\\ \end{align*}

Mathematica [A]  time = 0.546682, size = 182, normalized size = 0.93 $\frac{\sqrt{(d+e x) (a e+c d x)} \left (\frac{3 \sqrt{c d} \left (c d^2-a e^2\right )^{3/2} \sinh ^{-1}\left (\frac{\sqrt{c} \sqrt{d} \sqrt{e} \sqrt{a e+c d x}}{\sqrt{c d} \sqrt{c d^2-a e^2}}\right )}{\sqrt{e} \sqrt{a e+c d x} \sqrt{\frac{c d (d+e x)}{c d^2-a e^2}}}+\sqrt{c} \sqrt{d} \left (c d (5 d+2 e x)-3 a e^2\right )\right )}{4 c^{5/2} d^{5/2}}$

Antiderivative was successfully veriﬁed.

[In]

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

[Out]

(Sqrt[(a*e + c*d*x)*(d + e*x)]*(Sqrt[c]*Sqrt[d]*(-3*a*e^2 + c*d*(5*d + 2*e*x)) + (3*Sqrt[c*d]*(c*d^2 - a*e^2)^
(3/2)*ArcSinh[(Sqrt[c]*Sqrt[d]*Sqrt[e]*Sqrt[a*e + c*d*x])/(Sqrt[c*d]*Sqrt[c*d^2 - a*e^2])])/(Sqrt[e]*Sqrt[a*e
+ c*d*x]*Sqrt[(c*d*(d + e*x))/(c*d^2 - a*e^2)])))/(4*c^(5/2)*d^(5/2))

________________________________________________________________________________________

Maple [A]  time = 0.051, size = 318, normalized size = 1.6 \begin{align*}{\frac{ex}{2\,cd}\sqrt{ade+ \left ( a{e}^{2}+c{d}^{2} \right ) x+cde{x}^{2}}}-{\frac{3\,a{e}^{2}}{4\,{c}^{2}{d}^{2}}\sqrt{ade+ \left ( a{e}^{2}+c{d}^{2} \right ) x+cde{x}^{2}}}+{\frac{5}{4\,c}\sqrt{ade+ \left ( a{e}^{2}+c{d}^{2} \right ) x+cde{x}^{2}}}+{\frac{3\,{a}^{2}{e}^{4}}{8\,{c}^{2}{d}^{2}}\ln \left ({ \left ({\frac{a{e}^{2}}{2}}+{\frac{c{d}^{2}}{2}}+cdex \right ){\frac{1}{\sqrt{dec}}}}+\sqrt{ade+ \left ( a{e}^{2}+c{d}^{2} \right ) x+cde{x}^{2}} \right ){\frac{1}{\sqrt{dec}}}}-{\frac{3\,a{e}^{2}}{4\,c}\ln \left ({ \left ({\frac{a{e}^{2}}{2}}+{\frac{c{d}^{2}}{2}}+cdex \right ){\frac{1}{\sqrt{dec}}}}+\sqrt{ade+ \left ( a{e}^{2}+c{d}^{2} \right ) x+cde{x}^{2}} \right ){\frac{1}{\sqrt{dec}}}}+{\frac{3\,{d}^{2}}{8}\ln \left ({ \left ({\frac{a{e}^{2}}{2}}+{\frac{c{d}^{2}}{2}}+cdex \right ){\frac{1}{\sqrt{dec}}}}+\sqrt{ade+ \left ( a{e}^{2}+c{d}^{2} \right ) x+cde{x}^{2}} \right ){\frac{1}{\sqrt{dec}}}} \end{align*}

Veriﬁcation of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

1/2*e*x/d/c*(a*d*e+(a*e^2+c*d^2)*x+c*d*e*x^2)^(1/2)-3/4*e^2/d^2/c^2*(a*d*e+(a*e^2+c*d^2)*x+c*d*e*x^2)^(1/2)*a+
5/4/c*(a*d*e+(a*e^2+c*d^2)*x+c*d*e*x^2)^(1/2)+3/8*e^4/d^2/c^2*ln((1/2*a*e^2+1/2*c*d^2+c*d*e*x)/(d*e*c)^(1/2)+(
a*d*e+(a*e^2+c*d^2)*x+c*d*e*x^2)^(1/2))/(d*e*c)^(1/2)*a^2-3/4*e^2/c*ln((1/2*a*e^2+1/2*c*d^2+c*d*e*x)/(d*e*c)^(
1/2)+(a*d*e+(a*e^2+c*d^2)*x+c*d*e*x^2)^(1/2))/(d*e*c)^(1/2)*a+3/8*d^2*ln((1/2*a*e^2+1/2*c*d^2+c*d*e*x)/(d*e*c)
^(1/2)+(a*d*e+(a*e^2+c*d^2)*x+c*d*e*x^2)^(1/2))/(d*e*c)^(1/2)

________________________________________________________________________________________

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

Veriﬁcation of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

Exception raised: ValueError

________________________________________________________________________________________

Fricas [A]  time = 2.1435, size = 900, normalized size = 4.62 \begin{align*} \left [\frac{3 \,{\left (c^{2} d^{4} - 2 \, a c d^{2} e^{2} + a^{2} e^{4}\right )} \sqrt{c d e} \log \left (8 \, c^{2} d^{2} e^{2} x^{2} + c^{2} d^{4} + 6 \, a c d^{2} e^{2} + a^{2} e^{4} + 4 \, \sqrt{c d e x^{2} + a d e +{\left (c d^{2} + a e^{2}\right )} x}{\left (2 \, c d e x + c d^{2} + a e^{2}\right )} \sqrt{c d e} + 8 \,{\left (c^{2} d^{3} e + a c d e^{3}\right )} x\right ) + 4 \,{\left (2 \, c^{2} d^{2} e^{2} x + 5 \, c^{2} d^{3} e - 3 \, a c d e^{3}\right )} \sqrt{c d e x^{2} + a d e +{\left (c d^{2} + a e^{2}\right )} x}}{16 \, c^{3} d^{3} e}, -\frac{3 \,{\left (c^{2} d^{4} - 2 \, a c d^{2} e^{2} + a^{2} e^{4}\right )} \sqrt{-c d e} \arctan \left (\frac{\sqrt{c d e x^{2} + a d e +{\left (c d^{2} + a e^{2}\right )} x}{\left (2 \, c d e x + c d^{2} + a e^{2}\right )} \sqrt{-c d e}}{2 \,{\left (c^{2} d^{2} e^{2} x^{2} + a c d^{2} e^{2} +{\left (c^{2} d^{3} e + a c d e^{3}\right )} x\right )}}\right ) - 2 \,{\left (2 \, c^{2} d^{2} e^{2} x + 5 \, c^{2} d^{3} e - 3 \, a c d e^{3}\right )} \sqrt{c d e x^{2} + a d e +{\left (c d^{2} + a e^{2}\right )} x}}{8 \, c^{3} d^{3} e}\right ] \end{align*}

Veriﬁcation of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

[1/16*(3*(c^2*d^4 - 2*a*c*d^2*e^2 + a^2*e^4)*sqrt(c*d*e)*log(8*c^2*d^2*e^2*x^2 + c^2*d^4 + 6*a*c*d^2*e^2 + a^2
*e^4 + 4*sqrt(c*d*e*x^2 + a*d*e + (c*d^2 + a*e^2)*x)*(2*c*d*e*x + c*d^2 + a*e^2)*sqrt(c*d*e) + 8*(c^2*d^3*e +
a*c*d*e^3)*x) + 4*(2*c^2*d^2*e^2*x + 5*c^2*d^3*e - 3*a*c*d*e^3)*sqrt(c*d*e*x^2 + a*d*e + (c*d^2 + a*e^2)*x))/(
c^3*d^3*e), -1/8*(3*(c^2*d^4 - 2*a*c*d^2*e^2 + a^2*e^4)*sqrt(-c*d*e)*arctan(1/2*sqrt(c*d*e*x^2 + a*d*e + (c*d^
2 + a*e^2)*x)*(2*c*d*e*x + c*d^2 + a*e^2)*sqrt(-c*d*e)/(c^2*d^2*e^2*x^2 + a*c*d^2*e^2 + (c^2*d^3*e + a*c*d*e^3
)*x)) - 2*(2*c^2*d^2*e^2*x + 5*c^2*d^3*e - 3*a*c*d*e^3)*sqrt(c*d*e*x^2 + a*d*e + (c*d^2 + a*e^2)*x))/(c^3*d^3*
e)]

________________________________________________________________________________________

Sympy [F]  time = 0., size = 0, normalized size = 0. \begin{align*} \int \frac{\left (d + e x\right )^{2}}{\sqrt{\left (d + e x\right ) \left (a e + c d x\right )}}\, dx \end{align*}

Veriﬁcation of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

Integral((d + e*x)**2/sqrt((d + e*x)*(a*e + c*d*x)), x)

________________________________________________________________________________________

Giac [A]  time = 1.37125, size = 238, normalized size = 1.22 \begin{align*} \frac{1}{4} \, \sqrt{c d x^{2} e + a d e +{\left (c d^{2} + a e^{2}\right )} x}{\left (\frac{2 \, x e}{c d} + \frac{{\left (5 \, c d^{2} e - 3 \, a e^{3}\right )} e^{\left (-1\right )}}{c^{2} d^{2}}\right )} - \frac{3 \,{\left (c^{2} d^{4} - 2 \, a c d^{2} e^{2} + a^{2} e^{4}\right )} \sqrt{c d} e^{\left (-\frac{1}{2}\right )} \log \left ({\left | -\sqrt{c d} c d^{2} e^{\frac{1}{2}} - 2 \,{\left (\sqrt{c d} x e^{\frac{1}{2}} - \sqrt{c d x^{2} e + a d e +{\left (c d^{2} + a e^{2}\right )} x}\right )} c d e - \sqrt{c d} a e^{\frac{5}{2}} \right |}\right )}{8 \, c^{3} d^{3}} \end{align*}

Veriﬁcation of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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