\(\int \sqrt {a+b x+c x^2} (d+e x+f x^2)^2 \, dx\) [135]

Optimal result
Mathematica [A] (verified)
Rubi [A] (verified)
Maple [A] (verified)
Fricas [A] (verification not implemented)
Sympy [B] (verification not implemented)
Maxima [F(-2)]
Giac [A] (verification not implemented)
Mupad [B] (verification not implemented)
Reduce [F]

Optimal result

Integrand size = 27, antiderivative size = 436 \[ \int \sqrt {a+b x+c x^2} \left (d+e x+f x^2\right )^2 \, dx=\frac {\left (128 c^4 d^2+21 b^4 f^2-56 b^2 c f (b e+a f)-32 c^3 \left (4 b d e+a \left (e^2+2 d f\right )\right )+8 c^2 \left (12 a b e f+2 a^2 f^2+5 b^2 \left (e^2+2 d f\right )\right )\right ) (b+2 c x) \sqrt {a+b x+c x^2}}{512 c^5}+\frac {\left (640 c^3 d e-105 b^3 f^2+28 b c f (10 b e+7 a f)-8 c^2 \left (32 a e f+25 b \left (e^2+2 d f\right )\right )\right ) \left (a+b x+c x^2\right )^{3/2}}{960 c^4}+\frac {\left (21 b^2 f^2-4 c f (14 b e+5 a f)+40 c^2 \left (e^2+2 d f\right )\right ) x \left (a+b x+c x^2\right )^{3/2}}{160 c^3}+\frac {f (8 c e-3 b f) x^2 \left (a+b x+c x^2\right )^{3/2}}{20 c^2}+\frac {f^2 x^3 \left (a+b x+c x^2\right )^{3/2}}{6 c}-\frac {\left (b^2-4 a c\right ) \left (128 c^4 d^2+21 b^4 f^2-56 b^2 c f (b e+a f)-32 c^3 \left (4 b d e+a \left (e^2+2 d f\right )\right )+8 c^2 \left (12 a b e f+2 a^2 f^2+5 b^2 \left (e^2+2 d f\right )\right )\right ) \text {arctanh}\left (\frac {b+2 c x}{2 \sqrt {c} \sqrt {a+b x+c x^2}}\right )}{1024 c^{11/2}} \] Output:

1/512*(128*c^4*d^2+21*b^4*f^2-56*b^2*c*f*(a*f+b*e)-32*c^3*(4*b*d*e+a*(2*d* 
f+e^2))+8*c^2*(12*a*b*e*f+2*a^2*f^2+5*b^2*(2*d*f+e^2)))*(2*c*x+b)*(c*x^2+b 
*x+a)^(1/2)/c^5+1/960*(640*c^3*d*e-105*b^3*f^2+28*b*c*f*(7*a*f+10*b*e)-8*c 
^2*(32*a*e*f+25*b*(2*d*f+e^2)))*(c*x^2+b*x+a)^(3/2)/c^4+1/160*(21*b^2*f^2- 
4*c*f*(5*a*f+14*b*e)+40*c^2*(2*d*f+e^2))*x*(c*x^2+b*x+a)^(3/2)/c^3+1/20*f* 
(-3*b*f+8*c*e)*x^2*(c*x^2+b*x+a)^(3/2)/c^2+1/6*f^2*x^3*(c*x^2+b*x+a)^(3/2) 
/c-1/1024*(-4*a*c+b^2)*(128*c^4*d^2+21*b^4*f^2-56*b^2*c*f*(a*f+b*e)-32*c^3 
*(4*b*d*e+a*(2*d*f+e^2))+8*c^2*(12*a*b*e*f+2*a^2*f^2+5*b^2*(2*d*f+e^2)))*a 
rctanh(1/2*(2*c*x+b)/c^(1/2)/(c*x^2+b*x+a)^(1/2))/c^(11/2)
 

Mathematica [A] (verified)

Time = 8.94 (sec) , antiderivative size = 459, normalized size of antiderivative = 1.05 \[ \int \sqrt {a+b x+c x^2} \left (d+e x+f x^2\right )^2 \, dx=\frac {\sqrt {c} \sqrt {a+x (b+c x)} \left (315 b^5 f^2-210 b^4 c f (4 e+f x)-16 b^2 c^2 \left (-2 a f (115 e+28 f x)+c \left (120 d e+25 e^2 x+50 d f x+28 e f x^2+9 f^2 x^3\right )\right )+8 b^3 c \left (-210 a f^2+c \left (75 e^2+70 e f x+3 f \left (50 d+7 f x^2\right )\right )\right )+16 b c^2 \left (113 a^2 f^2-2 a c \left (65 e^2+58 e f x+f \left (130 d+17 f x^2\right )\right )+4 c^2 \left (30 d^2+10 d x (2 e+f x)+x^2 \left (5 e^2+6 e f x+2 f^2 x^2\right )\right )\right )-32 c^3 \left (a^2 f (64 e+15 f x)-2 a c \left (80 d e+15 e^2 x+30 d f x+16 e f x^2+5 f^2 x^3\right )-4 c^2 x \left (30 d^2+10 d x (4 e+3 f x)+x^2 \left (15 e^2+24 e f x+10 f^2 x^2\right )\right )\right )\right )-15 \left (b^2-4 a c\right ) \left (128 c^4 d^2+21 b^4 f^2-56 b^2 c f (b e+a f)-32 c^3 \left (4 b d e+a \left (e^2+2 d f\right )\right )+8 c^2 \left (12 a b e f+2 a^2 f^2+5 b^2 \left (e^2+2 d f\right )\right )\right ) \text {arctanh}\left (\frac {\sqrt {c} x}{-\sqrt {a}+\sqrt {a+x (b+c x)}}\right )}{7680 c^{11/2}} \] Input:

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

Output:

(Sqrt[c]*Sqrt[a + x*(b + c*x)]*(315*b^5*f^2 - 210*b^4*c*f*(4*e + f*x) - 16 
*b^2*c^2*(-2*a*f*(115*e + 28*f*x) + c*(120*d*e + 25*e^2*x + 50*d*f*x + 28* 
e*f*x^2 + 9*f^2*x^3)) + 8*b^3*c*(-210*a*f^2 + c*(75*e^2 + 70*e*f*x + 3*f*( 
50*d + 7*f*x^2))) + 16*b*c^2*(113*a^2*f^2 - 2*a*c*(65*e^2 + 58*e*f*x + f*( 
130*d + 17*f*x^2)) + 4*c^2*(30*d^2 + 10*d*x*(2*e + f*x) + x^2*(5*e^2 + 6*e 
*f*x + 2*f^2*x^2))) - 32*c^3*(a^2*f*(64*e + 15*f*x) - 2*a*c*(80*d*e + 15*e 
^2*x + 30*d*f*x + 16*e*f*x^2 + 5*f^2*x^3) - 4*c^2*x*(30*d^2 + 10*d*x*(4*e 
+ 3*f*x) + x^2*(15*e^2 + 24*e*f*x + 10*f^2*x^2)))) - 15*(b^2 - 4*a*c)*(128 
*c^4*d^2 + 21*b^4*f^2 - 56*b^2*c*f*(b*e + a*f) - 32*c^3*(4*b*d*e + a*(e^2 
+ 2*d*f)) + 8*c^2*(12*a*b*e*f + 2*a^2*f^2 + 5*b^2*(e^2 + 2*d*f)))*ArcTanh[ 
(Sqrt[c]*x)/(-Sqrt[a] + Sqrt[a + x*(b + c*x)])])/(7680*c^(11/2))
 

Rubi [A] (verified)

Time = 0.97 (sec) , antiderivative size = 383, normalized size of antiderivative = 0.88, number of steps used = 11, number of rules used = 10, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.370, Rules used = {2192, 27, 2192, 27, 2192, 27, 1160, 1087, 1092, 219}

Below are the steps used by Rubi to obtain the solution. The rule number used for the transformation is given above next to the arrow. The rules definitions used are listed below.

\(\displaystyle \int \sqrt {a+b x+c x^2} \left (d+e x+f x^2\right )^2 \, dx\)

\(\Big \downarrow \) 2192

\(\displaystyle \frac {\int \frac {3}{2} \sqrt {c x^2+b x+a} \left (f (8 c e-3 b f) x^3-2 \left (a f^2-2 c \left (e^2+2 d f\right )\right ) x^2+8 c d e x+4 c d^2\right )dx}{6 c}+\frac {f^2 x^3 \left (a+b x+c x^2\right )^{3/2}}{6 c}\)

\(\Big \downarrow \) 27

\(\displaystyle \frac {\int \sqrt {c x^2+b x+a} \left (f (8 c e-3 b f) x^3-2 \left (a f^2-2 c \left (e^2+2 d f\right )\right ) x^2+8 c d e x+4 c d^2\right )dx}{4 c}+\frac {f^2 x^3 \left (a+b x+c x^2\right )^{3/2}}{6 c}\)

\(\Big \downarrow \) 2192

\(\displaystyle \frac {\frac {\int \frac {1}{2} \sqrt {c x^2+b x+a} \left (40 c^2 d^2+\left (40 \left (e^2+2 d f\right ) c^2-4 f (14 b e+5 a f) c+21 b^2 f^2\right ) x^2+4 \left (20 d e c^2-8 a e f c+3 a b f^2\right ) x\right )dx}{5 c}+\frac {f x^2 \left (a+b x+c x^2\right )^{3/2} (8 c e-3 b f)}{5 c}}{4 c}+\frac {f^2 x^3 \left (a+b x+c x^2\right )^{3/2}}{6 c}\)

\(\Big \downarrow \) 27

\(\displaystyle \frac {\frac {\int \sqrt {c x^2+b x+a} \left (40 c^2 d^2+\left (40 \left (e^2+2 d f\right ) c^2-4 f (14 b e+5 a f) c+21 b^2 f^2\right ) x^2+4 \left (20 d e c^2-8 a e f c+3 a b f^2\right ) x\right )dx}{10 c}+\frac {f x^2 \left (a+b x+c x^2\right )^{3/2} (8 c e-3 b f)}{5 c}}{4 c}+\frac {f^2 x^3 \left (a+b x+c x^2\right )^{3/2}}{6 c}\)

\(\Big \downarrow \) 2192

\(\displaystyle \frac {\frac {\frac {\int \frac {1}{2} \left (320 d^2 c^3-80 a \left (e^2+2 d f\right ) c^2+8 a f (14 b e+5 a f) c-42 a b^2 f^2+\left (-105 f^2 b^3+28 c f (10 b e+7 a f) b+640 c^3 d e-8 c^2 \left (32 a e f+25 b \left (e^2+2 d f\right )\right )\right ) x\right ) \sqrt {c x^2+b x+a}dx}{4 c}+\frac {x \left (a+b x+c x^2\right )^{3/2} \left (-4 c f (5 a f+14 b e)+21 b^2 f^2+40 c^2 \left (2 d f+e^2\right )\right )}{4 c}}{10 c}+\frac {f x^2 \left (a+b x+c x^2\right )^{3/2} (8 c e-3 b f)}{5 c}}{4 c}+\frac {f^2 x^3 \left (a+b x+c x^2\right )^{3/2}}{6 c}\)

\(\Big \downarrow \) 27

\(\displaystyle \frac {\frac {\frac {\int \left (2 \left (160 d^2 c^3-40 a \left (e^2+2 d f\right ) c^2+4 a f (14 b e+5 a f) c-21 a b^2 f^2\right )+\left (-105 f^2 b^3+28 c f (10 b e+7 a f) b+640 c^3 d e-8 c^2 \left (32 a e f+25 b \left (e^2+2 d f\right )\right )\right ) x\right ) \sqrt {c x^2+b x+a}dx}{8 c}+\frac {x \left (a+b x+c x^2\right )^{3/2} \left (-4 c f (5 a f+14 b e)+21 b^2 f^2+40 c^2 \left (2 d f+e^2\right )\right )}{4 c}}{10 c}+\frac {f x^2 \left (a+b x+c x^2\right )^{3/2} (8 c e-3 b f)}{5 c}}{4 c}+\frac {f^2 x^3 \left (a+b x+c x^2\right )^{3/2}}{6 c}\)

\(\Big \downarrow \) 1160

\(\displaystyle \frac {\frac {\frac {\frac {5 \left (8 c^2 \left (2 a^2 f^2+12 a b e f+5 b^2 \left (2 d f+e^2\right )\right )-56 b^2 c f (a f+b e)-32 c^3 \left (a \left (2 d f+e^2\right )+4 b d e\right )+21 b^4 f^2+128 c^4 d^2\right ) \int \sqrt {c x^2+b x+a}dx}{2 c}+\frac {\left (a+b x+c x^2\right )^{3/2} \left (-8 c^2 \left (32 a e f+25 b \left (2 d f+e^2\right )\right )+28 b c f (7 a f+10 b e)-105 b^3 f^2+640 c^3 d e\right )}{3 c}}{8 c}+\frac {x \left (a+b x+c x^2\right )^{3/2} \left (-4 c f (5 a f+14 b e)+21 b^2 f^2+40 c^2 \left (2 d f+e^2\right )\right )}{4 c}}{10 c}+\frac {f x^2 \left (a+b x+c x^2\right )^{3/2} (8 c e-3 b f)}{5 c}}{4 c}+\frac {f^2 x^3 \left (a+b x+c x^2\right )^{3/2}}{6 c}\)

\(\Big \downarrow \) 1087

\(\displaystyle \frac {\frac {\frac {\frac {5 \left (8 c^2 \left (2 a^2 f^2+12 a b e f+5 b^2 \left (2 d f+e^2\right )\right )-56 b^2 c f (a f+b e)-32 c^3 \left (a \left (2 d f+e^2\right )+4 b d e\right )+21 b^4 f^2+128 c^4 d^2\right ) \left (\frac {(b+2 c x) \sqrt {a+b x+c x^2}}{4 c}-\frac {\left (b^2-4 a c\right ) \int \frac {1}{\sqrt {c x^2+b x+a}}dx}{8 c}\right )}{2 c}+\frac {\left (a+b x+c x^2\right )^{3/2} \left (-8 c^2 \left (32 a e f+25 b \left (2 d f+e^2\right )\right )+28 b c f (7 a f+10 b e)-105 b^3 f^2+640 c^3 d e\right )}{3 c}}{8 c}+\frac {x \left (a+b x+c x^2\right )^{3/2} \left (-4 c f (5 a f+14 b e)+21 b^2 f^2+40 c^2 \left (2 d f+e^2\right )\right )}{4 c}}{10 c}+\frac {f x^2 \left (a+b x+c x^2\right )^{3/2} (8 c e-3 b f)}{5 c}}{4 c}+\frac {f^2 x^3 \left (a+b x+c x^2\right )^{3/2}}{6 c}\)

\(\Big \downarrow \) 1092

\(\displaystyle \frac {\frac {\frac {\frac {5 \left (8 c^2 \left (2 a^2 f^2+12 a b e f+5 b^2 \left (2 d f+e^2\right )\right )-56 b^2 c f (a f+b e)-32 c^3 \left (a \left (2 d f+e^2\right )+4 b d e\right )+21 b^4 f^2+128 c^4 d^2\right ) \left (\frac {(b+2 c x) \sqrt {a+b x+c x^2}}{4 c}-\frac {\left (b^2-4 a c\right ) \int \frac {1}{4 c-\frac {(b+2 c x)^2}{c x^2+b x+a}}d\frac {b+2 c x}{\sqrt {c x^2+b x+a}}}{4 c}\right )}{2 c}+\frac {\left (a+b x+c x^2\right )^{3/2} \left (-8 c^2 \left (32 a e f+25 b \left (2 d f+e^2\right )\right )+28 b c f (7 a f+10 b e)-105 b^3 f^2+640 c^3 d e\right )}{3 c}}{8 c}+\frac {x \left (a+b x+c x^2\right )^{3/2} \left (-4 c f (5 a f+14 b e)+21 b^2 f^2+40 c^2 \left (2 d f+e^2\right )\right )}{4 c}}{10 c}+\frac {f x^2 \left (a+b x+c x^2\right )^{3/2} (8 c e-3 b f)}{5 c}}{4 c}+\frac {f^2 x^3 \left (a+b x+c x^2\right )^{3/2}}{6 c}\)

\(\Big \downarrow \) 219

\(\displaystyle \frac {\frac {\frac {\frac {5 \left (\frac {(b+2 c x) \sqrt {a+b x+c x^2}}{4 c}-\frac {\left (b^2-4 a c\right ) \text {arctanh}\left (\frac {b+2 c x}{2 \sqrt {c} \sqrt {a+b x+c x^2}}\right )}{8 c^{3/2}}\right ) \left (8 c^2 \left (2 a^2 f^2+12 a b e f+5 b^2 \left (2 d f+e^2\right )\right )-56 b^2 c f (a f+b e)-32 c^3 \left (a \left (2 d f+e^2\right )+4 b d e\right )+21 b^4 f^2+128 c^4 d^2\right )}{2 c}+\frac {\left (a+b x+c x^2\right )^{3/2} \left (-8 c^2 \left (32 a e f+25 b \left (2 d f+e^2\right )\right )+28 b c f (7 a f+10 b e)-105 b^3 f^2+640 c^3 d e\right )}{3 c}}{8 c}+\frac {x \left (a+b x+c x^2\right )^{3/2} \left (-4 c f (5 a f+14 b e)+21 b^2 f^2+40 c^2 \left (2 d f+e^2\right )\right )}{4 c}}{10 c}+\frac {f x^2 \left (a+b x+c x^2\right )^{3/2} (8 c e-3 b f)}{5 c}}{4 c}+\frac {f^2 x^3 \left (a+b x+c x^2\right )^{3/2}}{6 c}\)

Input:

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

Output:

(f^2*x^3*(a + b*x + c*x^2)^(3/2))/(6*c) + ((f*(8*c*e - 3*b*f)*x^2*(a + b*x 
 + c*x^2)^(3/2))/(5*c) + (((21*b^2*f^2 - 4*c*f*(14*b*e + 5*a*f) + 40*c^2*( 
e^2 + 2*d*f))*x*(a + b*x + c*x^2)^(3/2))/(4*c) + (((640*c^3*d*e - 105*b^3* 
f^2 + 28*b*c*f*(10*b*e + 7*a*f) - 8*c^2*(32*a*e*f + 25*b*(e^2 + 2*d*f)))*( 
a + b*x + c*x^2)^(3/2))/(3*c) + (5*(128*c^4*d^2 + 21*b^4*f^2 - 56*b^2*c*f* 
(b*e + a*f) - 32*c^3*(4*b*d*e + a*(e^2 + 2*d*f)) + 8*c^2*(12*a*b*e*f + 2*a 
^2*f^2 + 5*b^2*(e^2 + 2*d*f)))*(((b + 2*c*x)*Sqrt[a + b*x + c*x^2])/(4*c) 
- ((b^2 - 4*a*c)*ArcTanh[(b + 2*c*x)/(2*Sqrt[c]*Sqrt[a + b*x + c*x^2])])/( 
8*c^(3/2))))/(2*c))/(8*c))/(10*c))/(4*c)
 

Defintions of rubi rules used

rule 27
Int[(a_)*(Fx_), x_Symbol] :> Simp[a   Int[Fx, x], x] /; FreeQ[a, x] &&  !Ma 
tchQ[Fx, (b_)*(Gx_) /; FreeQ[b, x]]
 

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

rule 1087
Int[((a_.) + (b_.)*(x_) + (c_.)*(x_)^2)^(p_), x_Symbol] :> Simp[(b + 2*c*x) 
*((a + b*x + c*x^2)^p/(2*c*(2*p + 1))), x] - Simp[p*((b^2 - 4*a*c)/(2*c*(2* 
p + 1)))   Int[(a + b*x + c*x^2)^(p - 1), x], x] /; FreeQ[{a, b, c}, x] && 
GtQ[p, 0] && (IntegerQ[4*p] || IntegerQ[3*p])
 

rule 1092
Int[1/Sqrt[(a_) + (b_.)*(x_) + (c_.)*(x_)^2], x_Symbol] :> Simp[2   Subst[I 
nt[1/(4*c - x^2), x], x, (b + 2*c*x)/Sqrt[a + b*x + c*x^2]], x] /; FreeQ[{a 
, b, c}, x]
 

rule 1160
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] + Simp[(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[p, -1]
 

rule 2192
Int[(Pq_)*((a_.) + (b_.)*(x_) + (c_.)*(x_)^2)^(p_), x_Symbol] :> With[{q = 
Expon[Pq, x], e = Coeff[Pq, x, Expon[Pq, x]]}, Simp[e*x^(q - 1)*((a + b*x + 
 c*x^2)^(p + 1)/(c*(q + 2*p + 1))), x] + Simp[1/(c*(q + 2*p + 1))   Int[(a 
+ b*x + c*x^2)^p*ExpandToSum[c*(q + 2*p + 1)*Pq - a*e*(q - 1)*x^(q - 2) - b 
*e*(q + p)*x^(q - 1) - c*e*(q + 2*p + 1)*x^q, x], x], x]] /; FreeQ[{a, b, c 
, p}, x] && PolyQ[Pq, x] && NeQ[b^2 - 4*a*c, 0] &&  !LeQ[p, -1]
 
Maple [A] (verified)

Time = 2.42 (sec) , antiderivative size = 645, normalized size of antiderivative = 1.48

method result size
risch \(\frac {\left (1280 f^{2} c^{5} x^{5}+128 b \,c^{4} f^{2} x^{4}+3072 c^{5} e f \,x^{4}+320 a \,c^{4} f^{2} x^{3}-144 b^{2} c^{3} f^{2} x^{3}+384 b \,c^{4} e f \,x^{3}+3840 c^{5} d f \,x^{3}+1920 c^{5} e^{2} x^{3}-544 a b \,c^{3} f^{2} x^{2}+1024 a \,c^{4} e f \,x^{2}+168 b^{3} c^{2} f^{2} x^{2}-448 b^{2} c^{3} e f \,x^{2}+640 b \,c^{4} d f \,x^{2}+320 b \,c^{4} e^{2} x^{2}+5120 c^{5} d e \,x^{2}-480 a^{2} c^{3} f^{2} x +896 a \,b^{2} c^{2} f^{2} x -1856 a b \,c^{3} e f x +1920 a \,c^{4} d f x +960 a \,c^{4} e^{2} x -210 b^{4} c \,f^{2} x +560 b^{3} c^{2} e f x -800 b^{2} c^{3} d f x -400 b^{2} c^{3} e^{2} x +1280 b \,c^{4} d e x +3840 c^{5} d^{2} x +1808 a^{2} b \,c^{2} f^{2}-2048 a^{2} c^{3} e f -1680 a \,b^{3} c \,f^{2}+3680 a \,b^{2} c^{2} e f -4160 a b \,c^{3} d f -2080 a b \,c^{3} e^{2}+5120 a \,c^{4} d e +315 b^{5} f^{2}-840 b^{4} c e f +1200 b^{3} c^{2} d f +600 b^{3} c^{2} e^{2}-1920 b^{2} c^{3} d e +1920 b \,c^{4} d^{2}\right ) \sqrt {c \,x^{2}+b x +a}}{7680 c^{5}}+\frac {\left (64 a^{3} c^{3} f^{2}-240 a^{2} b^{2} c^{2} f^{2}+384 a^{2} b \,c^{3} e f -256 a^{2} c^{4} d f -128 a^{2} c^{4} e^{2}+140 a \,b^{4} c \,f^{2}-320 a \,b^{3} c^{2} e f +384 a \,b^{2} c^{3} d f +192 a \,b^{2} c^{3} e^{2}-512 a b \,c^{4} d e +512 a \,c^{5} d^{2}-21 b^{6} f^{2}+56 b^{5} c e f -80 b^{4} c^{2} d f -40 b^{4} c^{2} e^{2}+128 b^{3} c^{3} d e -128 c^{4} b^{2} d^{2}\right ) \ln \left (\frac {\frac {b}{2}+c x}{\sqrt {c}}+\sqrt {c \,x^{2}+b x +a}\right )}{1024 c^{\frac {11}{2}}}\) \(645\)
default \(\text {Expression too large to display}\) \(1186\)

Input:

int((c*x^2+b*x+a)^(1/2)*(f*x^2+e*x+d)^2,x,method=_RETURNVERBOSE)
 

Output:

1/7680*(1280*c^5*f^2*x^5+128*b*c^4*f^2*x^4+3072*c^5*e*f*x^4+320*a*c^4*f^2* 
x^3-144*b^2*c^3*f^2*x^3+384*b*c^4*e*f*x^3+3840*c^5*d*f*x^3+1920*c^5*e^2*x^ 
3-544*a*b*c^3*f^2*x^2+1024*a*c^4*e*f*x^2+168*b^3*c^2*f^2*x^2-448*b^2*c^3*e 
*f*x^2+640*b*c^4*d*f*x^2+320*b*c^4*e^2*x^2+5120*c^5*d*e*x^2-480*a^2*c^3*f^ 
2*x+896*a*b^2*c^2*f^2*x-1856*a*b*c^3*e*f*x+1920*a*c^4*d*f*x+960*a*c^4*e^2* 
x-210*b^4*c*f^2*x+560*b^3*c^2*e*f*x-800*b^2*c^3*d*f*x-400*b^2*c^3*e^2*x+12 
80*b*c^4*d*e*x+3840*c^5*d^2*x+1808*a^2*b*c^2*f^2-2048*a^2*c^3*e*f-1680*a*b 
^3*c*f^2+3680*a*b^2*c^2*e*f-4160*a*b*c^3*d*f-2080*a*b*c^3*e^2+5120*a*c^4*d 
*e+315*b^5*f^2-840*b^4*c*e*f+1200*b^3*c^2*d*f+600*b^3*c^2*e^2-1920*b^2*c^3 
*d*e+1920*b*c^4*d^2)/c^5*(c*x^2+b*x+a)^(1/2)+1/1024*(64*a^3*c^3*f^2-240*a^ 
2*b^2*c^2*f^2+384*a^2*b*c^3*e*f-256*a^2*c^4*d*f-128*a^2*c^4*e^2+140*a*b^4* 
c*f^2-320*a*b^3*c^2*e*f+384*a*b^2*c^3*d*f+192*a*b^2*c^3*e^2-512*a*b*c^4*d* 
e+512*a*c^5*d^2-21*b^6*f^2+56*b^5*c*e*f-80*b^4*c^2*d*f-40*b^4*c^2*e^2+128* 
b^3*c^3*d*e-128*b^2*c^4*d^2)/c^(11/2)*ln((1/2*b+c*x)/c^(1/2)+(c*x^2+b*x+a) 
^(1/2))
 

Fricas [A] (verification not implemented)

Time = 0.24 (sec) , antiderivative size = 1269, normalized size of antiderivative = 2.91 \[ \int \sqrt {a+b x+c x^2} \left (d+e x+f x^2\right )^2 \, dx=\text {Too large to display} \] Input:

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

Output:

[-1/30720*(15*(128*(b^2*c^4 - 4*a*c^5)*d^2 - 128*(b^3*c^3 - 4*a*b*c^4)*d*e 
 + 8*(5*b^4*c^2 - 24*a*b^2*c^3 + 16*a^2*c^4)*e^2 + (21*b^6 - 140*a*b^4*c + 
 240*a^2*b^2*c^2 - 64*a^3*c^3)*f^2 + 8*(2*(5*b^4*c^2 - 24*a*b^2*c^3 + 16*a 
^2*c^4)*d - (7*b^5*c - 40*a*b^3*c^2 + 48*a^2*b*c^3)*e)*f)*sqrt(c)*log(-8*c 
^2*x^2 - 8*b*c*x - b^2 - 4*sqrt(c*x^2 + b*x + a)*(2*c*x + b)*sqrt(c) - 4*a 
*c) - 4*(1280*c^6*f^2*x^5 + 1920*b*c^5*d^2 + 128*(24*c^6*e*f + b*c^5*f^2)* 
x^4 + 16*(120*c^6*e^2 - (9*b^2*c^4 - 20*a*c^5)*f^2 + 24*(10*c^6*d + b*c^5* 
e)*f)*x^3 - 640*(3*b^2*c^4 - 8*a*c^5)*d*e + 40*(15*b^3*c^3 - 52*a*b*c^4)*e 
^2 + (315*b^5*c - 1680*a*b^3*c^2 + 1808*a^2*b*c^3)*f^2 + 8*(640*c^6*d*e + 
40*b*c^5*e^2 + (21*b^3*c^3 - 68*a*b*c^4)*f^2 + 8*(10*b*c^5*d - (7*b^2*c^4 
- 16*a*c^5)*e)*f)*x^2 + 8*(10*(15*b^3*c^3 - 52*a*b*c^4)*d - (105*b^4*c^2 - 
 460*a*b^2*c^3 + 256*a^2*c^4)*e)*f + 2*(1920*c^6*d^2 + 640*b*c^5*d*e - 40* 
(5*b^2*c^4 - 12*a*c^5)*e^2 - (105*b^4*c^2 - 448*a*b^2*c^3 + 240*a^2*c^4)*f 
^2 - 8*(10*(5*b^2*c^4 - 12*a*c^5)*d - (35*b^3*c^3 - 116*a*b*c^4)*e)*f)*x)* 
sqrt(c*x^2 + b*x + a))/c^6, 1/15360*(15*(128*(b^2*c^4 - 4*a*c^5)*d^2 - 128 
*(b^3*c^3 - 4*a*b*c^4)*d*e + 8*(5*b^4*c^2 - 24*a*b^2*c^3 + 16*a^2*c^4)*e^2 
 + (21*b^6 - 140*a*b^4*c + 240*a^2*b^2*c^2 - 64*a^3*c^3)*f^2 + 8*(2*(5*b^4 
*c^2 - 24*a*b^2*c^3 + 16*a^2*c^4)*d - (7*b^5*c - 40*a*b^3*c^2 + 48*a^2*b*c 
^3)*e)*f)*sqrt(-c)*arctan(1/2*sqrt(c*x^2 + b*x + a)*(2*c*x + b)*sqrt(-c)/( 
c^2*x^2 + b*c*x + a*c)) + 2*(1280*c^6*f^2*x^5 + 1920*b*c^5*d^2 + 128*(2...
 

Sympy [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 1544 vs. \(2 (444) = 888\).

Time = 0.82 (sec) , antiderivative size = 1544, normalized size of antiderivative = 3.54 \[ \int \sqrt {a+b x+c x^2} \left (d+e x+f x^2\right )^2 \, dx=\text {Too large to display} \] Input:

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

Output:

Piecewise((sqrt(a + b*x + c*x**2)*(f**2*x**5/6 + x**4*(b*f**2/12 + 2*c*e*f 
)/(5*c) + x**3*(a*f**2/6 + 2*b*e*f - 9*b*(b*f**2/12 + 2*c*e*f)/(10*c) + 2* 
c*d*f + c*e**2)/(4*c) + x**2*(2*a*e*f - 4*a*(b*f**2/12 + 2*c*e*f)/(5*c) + 
2*b*d*f + b*e**2 - 7*b*(a*f**2/6 + 2*b*e*f - 9*b*(b*f**2/12 + 2*c*e*f)/(10 
*c) + 2*c*d*f + c*e**2)/(8*c) + 2*c*d*e)/(3*c) + x*(2*a*d*f + a*e**2 - 3*a 
*(a*f**2/6 + 2*b*e*f - 9*b*(b*f**2/12 + 2*c*e*f)/(10*c) + 2*c*d*f + c*e**2 
)/(4*c) + 2*b*d*e - 5*b*(2*a*e*f - 4*a*(b*f**2/12 + 2*c*e*f)/(5*c) + 2*b*d 
*f + b*e**2 - 7*b*(a*f**2/6 + 2*b*e*f - 9*b*(b*f**2/12 + 2*c*e*f)/(10*c) + 
 2*c*d*f + c*e**2)/(8*c) + 2*c*d*e)/(6*c) + c*d**2)/(2*c) + (2*a*d*e - 2*a 
*(2*a*e*f - 4*a*(b*f**2/12 + 2*c*e*f)/(5*c) + 2*b*d*f + b*e**2 - 7*b*(a*f* 
*2/6 + 2*b*e*f - 9*b*(b*f**2/12 + 2*c*e*f)/(10*c) + 2*c*d*f + c*e**2)/(8*c 
) + 2*c*d*e)/(3*c) + b*d**2 - 3*b*(2*a*d*f + a*e**2 - 3*a*(a*f**2/6 + 2*b* 
e*f - 9*b*(b*f**2/12 + 2*c*e*f)/(10*c) + 2*c*d*f + c*e**2)/(4*c) + 2*b*d*e 
 - 5*b*(2*a*e*f - 4*a*(b*f**2/12 + 2*c*e*f)/(5*c) + 2*b*d*f + b*e**2 - 7*b 
*(a*f**2/6 + 2*b*e*f - 9*b*(b*f**2/12 + 2*c*e*f)/(10*c) + 2*c*d*f + c*e**2 
)/(8*c) + 2*c*d*e)/(6*c) + c*d**2)/(4*c))/c) + (a*d**2 - a*(2*a*d*f + a*e* 
*2 - 3*a*(a*f**2/6 + 2*b*e*f - 9*b*(b*f**2/12 + 2*c*e*f)/(10*c) + 2*c*d*f 
+ c*e**2)/(4*c) + 2*b*d*e - 5*b*(2*a*e*f - 4*a*(b*f**2/12 + 2*c*e*f)/(5*c) 
 + 2*b*d*f + b*e**2 - 7*b*(a*f**2/6 + 2*b*e*f - 9*b*(b*f**2/12 + 2*c*e*f)/ 
(10*c) + 2*c*d*f + c*e**2)/(8*c) + 2*c*d*e)/(6*c) + c*d**2)/(2*c) - b*(...
 

Maxima [F(-2)]

Exception generated. \[ \int \sqrt {a+b x+c x^2} \left (d+e x+f x^2\right )^2 \, dx=\text {Exception raised: ValueError} \] Input:

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

Output:

Exception raised: ValueError >> Computation failed since Maxima requested 
additional constraints; using the 'assume' command before evaluation *may* 
 help (example of legal syntax is 'assume(4*a*c-b^2>0)', see `assume?` for 
 more deta
 

Giac [A] (verification not implemented)

Time = 0.13 (sec) , antiderivative size = 627, normalized size of antiderivative = 1.44 \[ \int \sqrt {a+b x+c x^2} \left (d+e x+f x^2\right )^2 \, dx=\frac {1}{7680} \, \sqrt {c x^{2} + b x + a} {\left (2 \, {\left (4 \, {\left (2 \, {\left (8 \, {\left (10 \, f^{2} x + \frac {24 \, c^{5} e f + b c^{4} f^{2}}{c^{5}}\right )} x + \frac {120 \, c^{5} e^{2} + 240 \, c^{5} d f + 24 \, b c^{4} e f - 9 \, b^{2} c^{3} f^{2} + 20 \, a c^{4} f^{2}}{c^{5}}\right )} x + \frac {640 \, c^{5} d e + 40 \, b c^{4} e^{2} + 80 \, b c^{4} d f - 56 \, b^{2} c^{3} e f + 128 \, a c^{4} e f + 21 \, b^{3} c^{2} f^{2} - 68 \, a b c^{3} f^{2}}{c^{5}}\right )} x + \frac {1920 \, c^{5} d^{2} + 640 \, b c^{4} d e - 200 \, b^{2} c^{3} e^{2} + 480 \, a c^{4} e^{2} - 400 \, b^{2} c^{3} d f + 960 \, a c^{4} d f + 280 \, b^{3} c^{2} e f - 928 \, a b c^{3} e f - 105 \, b^{4} c f^{2} + 448 \, a b^{2} c^{2} f^{2} - 240 \, a^{2} c^{3} f^{2}}{c^{5}}\right )} x + \frac {1920 \, b c^{4} d^{2} - 1920 \, b^{2} c^{3} d e + 5120 \, a c^{4} d e + 600 \, b^{3} c^{2} e^{2} - 2080 \, a b c^{3} e^{2} + 1200 \, b^{3} c^{2} d f - 4160 \, a b c^{3} d f - 840 \, b^{4} c e f + 3680 \, a b^{2} c^{2} e f - 2048 \, a^{2} c^{3} e f + 315 \, b^{5} f^{2} - 1680 \, a b^{3} c f^{2} + 1808 \, a^{2} b c^{2} f^{2}}{c^{5}}\right )} + \frac {{\left (128 \, b^{2} c^{4} d^{2} - 512 \, a c^{5} d^{2} - 128 \, b^{3} c^{3} d e + 512 \, a b c^{4} d e + 40 \, b^{4} c^{2} e^{2} - 192 \, a b^{2} c^{3} e^{2} + 128 \, a^{2} c^{4} e^{2} + 80 \, b^{4} c^{2} d f - 384 \, a b^{2} c^{3} d f + 256 \, a^{2} c^{4} d f - 56 \, b^{5} c e f + 320 \, a b^{3} c^{2} e f - 384 \, a^{2} b c^{3} e f + 21 \, b^{6} f^{2} - 140 \, a b^{4} c f^{2} + 240 \, a^{2} b^{2} c^{2} f^{2} - 64 \, a^{3} c^{3} f^{2}\right )} \log \left ({\left | 2 \, {\left (\sqrt {c} x - \sqrt {c x^{2} + b x + a}\right )} \sqrt {c} + b \right |}\right )}{1024 \, c^{\frac {11}{2}}} \] Input:

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

Output:

1/7680*sqrt(c*x^2 + b*x + a)*(2*(4*(2*(8*(10*f^2*x + (24*c^5*e*f + b*c^4*f 
^2)/c^5)*x + (120*c^5*e^2 + 240*c^5*d*f + 24*b*c^4*e*f - 9*b^2*c^3*f^2 + 2 
0*a*c^4*f^2)/c^5)*x + (640*c^5*d*e + 40*b*c^4*e^2 + 80*b*c^4*d*f - 56*b^2* 
c^3*e*f + 128*a*c^4*e*f + 21*b^3*c^2*f^2 - 68*a*b*c^3*f^2)/c^5)*x + (1920* 
c^5*d^2 + 640*b*c^4*d*e - 200*b^2*c^3*e^2 + 480*a*c^4*e^2 - 400*b^2*c^3*d* 
f + 960*a*c^4*d*f + 280*b^3*c^2*e*f - 928*a*b*c^3*e*f - 105*b^4*c*f^2 + 44 
8*a*b^2*c^2*f^2 - 240*a^2*c^3*f^2)/c^5)*x + (1920*b*c^4*d^2 - 1920*b^2*c^3 
*d*e + 5120*a*c^4*d*e + 600*b^3*c^2*e^2 - 2080*a*b*c^3*e^2 + 1200*b^3*c^2* 
d*f - 4160*a*b*c^3*d*f - 840*b^4*c*e*f + 3680*a*b^2*c^2*e*f - 2048*a^2*c^3 
*e*f + 315*b^5*f^2 - 1680*a*b^3*c*f^2 + 1808*a^2*b*c^2*f^2)/c^5) + 1/1024* 
(128*b^2*c^4*d^2 - 512*a*c^5*d^2 - 128*b^3*c^3*d*e + 512*a*b*c^4*d*e + 40* 
b^4*c^2*e^2 - 192*a*b^2*c^3*e^2 + 128*a^2*c^4*e^2 + 80*b^4*c^2*d*f - 384*a 
*b^2*c^3*d*f + 256*a^2*c^4*d*f - 56*b^5*c*e*f + 320*a*b^3*c^2*e*f - 384*a^ 
2*b*c^3*e*f + 21*b^6*f^2 - 140*a*b^4*c*f^2 + 240*a^2*b^2*c^2*f^2 - 64*a^3* 
c^3*f^2)*log(abs(2*(sqrt(c)*x - sqrt(c*x^2 + b*x + a))*sqrt(c) + b))/c^(11 
/2)
 

Mupad [B] (verification not implemented)

Time = 17.45 (sec) , antiderivative size = 1299, normalized size of antiderivative = 2.98 \[ \int \sqrt {a+b x+c x^2} \left (d+e x+f x^2\right )^2 \, dx=\text {Too large to display} \] Input:

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

Output:

d^2*(x/2 + b/(4*c))*(a + b*x + c*x^2)^(1/2) + (e^2*x*(a + b*x + c*x^2)^(3/ 
2))/(4*c) + (a*f^2*((5*b*((log((b + 2*c*x)/c^(1/2) + 2*(a + b*x + c*x^2)^( 
1/2))*(b^3 - 4*a*b*c))/(16*c^(5/2)) + ((8*c*(a + c*x^2) - 3*b^2 + 2*b*c*x) 
*(a + b*x + c*x^2)^(1/2))/(24*c^2)))/(8*c) - (x*(a + b*x + c*x^2)^(3/2))/( 
4*c) + (a*((x/2 + b/(4*c))*(a + b*x + c*x^2)^(1/2) + (log((b/2 + c*x)/c^(1 
/2) + (a + b*x + c*x^2)^(1/2))*(a*c - b^2/4))/(2*c^(3/2))))/(4*c)))/(2*c) 
- (3*b*f^2*((7*b*((5*b*((log((b + 2*c*x)/c^(1/2) + 2*(a + b*x + c*x^2)^(1/ 
2))*(b^3 - 4*a*b*c))/(16*c^(5/2)) + ((8*c*(a + c*x^2) - 3*b^2 + 2*b*c*x)*( 
a + b*x + c*x^2)^(1/2))/(24*c^2)))/(8*c) - (x*(a + b*x + c*x^2)^(3/2))/(4* 
c) + (a*((x/2 + b/(4*c))*(a + b*x + c*x^2)^(1/2) + (log((b/2 + c*x)/c^(1/2 
) + (a + b*x + c*x^2)^(1/2))*(a*c - b^2/4))/(2*c^(3/2))))/(4*c)))/(10*c) - 
 (2*a*((log((b + 2*c*x)/c^(1/2) + 2*(a + b*x + c*x^2)^(1/2))*(b^3 - 4*a*b* 
c))/(16*c^(5/2)) + ((8*c*(a + c*x^2) - 3*b^2 + 2*b*c*x)*(a + b*x + c*x^2)^ 
(1/2))/(24*c^2)))/(5*c) + (x^2*(a + b*x + c*x^2)^(3/2))/(5*c)))/(4*c) + (f 
^2*x^3*(a + b*x + c*x^2)^(3/2))/(6*c) - (a*e^2*((x/2 + b/(4*c))*(a + b*x + 
 c*x^2)^(1/2) + (log((b/2 + c*x)/c^(1/2) + (a + b*x + c*x^2)^(1/2))*(a*c - 
 b^2/4))/(2*c^(3/2))))/(4*c) + (d^2*log((b/2 + c*x)/c^(1/2) + (a + b*x + c 
*x^2)^(1/2))*(a*c - b^2/4))/(2*c^(3/2)) - (5*b*e^2*((log((b + 2*c*x)/c^(1/ 
2) + 2*(a + b*x + c*x^2)^(1/2))*(b^3 - 4*a*b*c))/(16*c^(5/2)) + ((8*c*(a + 
 c*x^2) - 3*b^2 + 2*b*c*x)*(a + b*x + c*x^2)^(1/2))/(24*c^2)))/(8*c) - ...
 

Reduce [F]

\[ \int \sqrt {a+b x+c x^2} \left (d+e x+f x^2\right )^2 \, dx=\int \sqrt {c \,x^{2}+b x +a}\, \left (f \,x^{2}+e x +d \right )^{2}d x \] Input:

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

Output:

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