### 3.195 $$\int \frac{\sqrt{a+b x+c x^2} (d+e x+f x^2)}{(g+h x)^6} \, dx$$

Optimal. Leaf size=824 $\frac{\left (4 c^2 \left (3 f g^2+h (2 e g-27 d h)\right ) g^2-5 h^2 \left (\left (3 f g^2+3 e h g+7 d h^2\right ) b^2-2 a h (6 f g+5 e h) b+16 a^2 f h^2\right )-2 c h \left (b g \left (16 f g^2-21 e h g-54 d h^2\right )-2 a h \left (18 f g^2-33 e h g+8 d h^2\right )\right )\right ) \left (c x^2+b x+a\right )^{3/2}}{240 h \left (c g^2-b h g+a h^2\right )^3 (g+h x)^3}+\frac{\left (2 c g \left (3 f g^2+h (2 e g-7 d h)\right )+h \left (10 a h (2 f g-e h)-b \left (13 f g^2-3 e h g-7 d h^2\right )\right )\right ) \left (c x^2+b x+a\right )^{3/2}}{40 h \left (c g^2-b h g+a h^2\right )^2 (g+h x)^4}-\frac{\left (f g^2-h (e g-d h)\right ) \left (c x^2+b x+a\right )^{3/2}}{5 h \left (c g^2-b h g+a h^2\right ) (g+h x)^5}+\frac{\left (32 c^3 d g^3-8 c^2 \left (2 b g (e g+3 d h)+a \left (f g^2-6 e h g+3 d h^2\right )\right ) g-b h \left (\left (3 f g^2+3 e h g+7 d h^2\right ) b^2-2 a h (6 f g+5 e h) b+16 a^2 f h^2\right )+2 c \left (g \left (5 f g^2+6 e h g+15 d h^2\right ) b^2-6 a h \left (3 f g^2+3 e h g-d h^2\right ) b+4 a^2 h^2 (6 f g-e h)\right )\right ) (b g-2 a h+(2 c g-b h) x) \sqrt{c x^2+b x+a}}{128 \left (c g^2-b h g+a h^2\right )^4 (g+h x)^2}-\frac{\left (b^2-4 a c\right ) \left (32 c^3 d g^3-8 c^2 \left (2 b g (e g+3 d h)+a \left (f g^2-6 e h g+3 d h^2\right )\right ) g-b h \left (\left (3 f g^2+3 e h g+7 d h^2\right ) b^2-2 a h (6 f g+5 e h) b+16 a^2 f h^2\right )+2 c \left (g \left (5 f g^2+6 e h g+15 d h^2\right ) b^2-6 a h \left (3 f g^2+3 e h g-d h^2\right ) b+4 a^2 h^2 (6 f g-e h)\right )\right ) \tanh ^{-1}\left (\frac{b g-2 a h+(2 c g-b h) x}{2 \sqrt{c g^2-b h g+a h^2} \sqrt{c x^2+b x+a}}\right )}{256 \left (c g^2-b h g+a h^2\right )^{9/2}}$

[Out]

((32*c^3*d*g^3 - 8*c^2*g*(2*b*g*(e*g + 3*d*h) + a*(f*g^2 - 6*e*g*h + 3*d*h^2)) - b*h*(16*a^2*f*h^2 - 2*a*b*h*(
6*f*g + 5*e*h) + b^2*(3*f*g^2 + 3*e*g*h + 7*d*h^2)) + 2*c*(4*a^2*h^2*(6*f*g - e*h) - 6*a*b*h*(3*f*g^2 + 3*e*g*
h - d*h^2) + b^2*g*(5*f*g^2 + 6*e*g*h + 15*d*h^2)))*(b*g - 2*a*h + (2*c*g - b*h)*x)*Sqrt[a + b*x + c*x^2])/(12
8*(c*g^2 - b*g*h + a*h^2)^4*(g + h*x)^2) - ((f*g^2 - h*(e*g - d*h))*(a + b*x + c*x^2)^(3/2))/(5*h*(c*g^2 - b*g
*h + a*h^2)*(g + h*x)^5) + ((2*c*g*(3*f*g^2 + h*(2*e*g - 7*d*h)) + h*(10*a*h*(2*f*g - e*h) - b*(13*f*g^2 - 3*e
*g*h - 7*d*h^2)))*(a + b*x + c*x^2)^(3/2))/(40*h*(c*g^2 - b*g*h + a*h^2)^2*(g + h*x)^4) + ((4*c^2*g^2*(3*f*g^2
+ h*(2*e*g - 27*d*h)) - 5*h^2*(16*a^2*f*h^2 - 2*a*b*h*(6*f*g + 5*e*h) + b^2*(3*f*g^2 + 3*e*g*h + 7*d*h^2)) -
2*c*h*(b*g*(16*f*g^2 - 21*e*g*h - 54*d*h^2) - 2*a*h*(18*f*g^2 - 33*e*g*h + 8*d*h^2)))*(a + b*x + c*x^2)^(3/2))
/(240*h*(c*g^2 - b*g*h + a*h^2)^3*(g + h*x)^3) - ((b^2 - 4*a*c)*(32*c^3*d*g^3 - 8*c^2*g*(2*b*g*(e*g + 3*d*h) +
a*(f*g^2 - 6*e*g*h + 3*d*h^2)) - b*h*(16*a^2*f*h^2 - 2*a*b*h*(6*f*g + 5*e*h) + b^2*(3*f*g^2 + 3*e*g*h + 7*d*h
^2)) + 2*c*(4*a^2*h^2*(6*f*g - e*h) - 6*a*b*h*(3*f*g^2 + 3*e*g*h - d*h^2) + b^2*g*(5*f*g^2 + 6*e*g*h + 15*d*h^
2)))*ArcTanh[(b*g - 2*a*h + (2*c*g - b*h)*x)/(2*Sqrt[c*g^2 - b*g*h + a*h^2]*Sqrt[a + b*x + c*x^2])])/(256*(c*g
^2 - b*g*h + a*h^2)^(9/2))

________________________________________________________________________________________

Rubi [A]  time = 2.33474, antiderivative size = 826, normalized size of antiderivative = 1., number of steps used = 6, number of rules used = 6, integrand size = 32, $$\frac{\text{number of rules}}{\text{integrand size}}$$ = 0.188, Rules used = {1650, 834, 806, 720, 724, 206} $\frac{\left (4 \left (3 f g^4+h (2 e g-27 d h) g^2\right ) c^2-2 h \left (b g \left (16 f g^2-21 e h g-54 d h^2\right )-2 a h \left (18 f g^2-33 e h g+8 d h^2\right )\right ) c-5 h^2 \left (\left (3 f g^2+3 e h g+7 d h^2\right ) b^2-2 a h (6 f g+5 e h) b+16 a^2 f h^2\right )\right ) \left (c x^2+b x+a\right )^{3/2}}{240 h \left (c g^2-b h g+a h^2\right )^3 (g+h x)^3}+\frac{\left (6 c f g^3+2 c h (2 e g-7 d h) g+10 a h^2 (2 f g-e h)-b h \left (13 f g^2-h (3 e g+7 d h)\right )\right ) \left (c x^2+b x+a\right )^{3/2}}{40 h \left (c g^2-b h g+a h^2\right )^2 (g+h x)^4}-\frac{\left (f g^2-h (e g-d h)\right ) \left (c x^2+b x+a\right )^{3/2}}{5 h \left (c g^2-b h g+a h^2\right ) (g+h x)^5}+\frac{\left (32 c^3 d g^3-8 c^2 \left (a f g^2+2 b (e g+3 d h) g-3 a h (2 e g-d h)\right ) g+2 c \left (\left (5 f g^3+3 h (2 e g+5 d h) g\right ) b^2-6 a h \left (3 f g^2+h (3 e g-d h)\right ) b+4 a^2 h^2 (6 f g-e h)\right )-b h \left (\left (3 f g^2+h (3 e g+7 d h)\right ) b^2-2 a h (6 f g+5 e h) b+16 a^2 f h^2\right )\right ) (b g-2 a h+(2 c g-b h) x) \sqrt{c x^2+b x+a}}{128 \left (c g^2-b h g+a h^2\right )^4 (g+h x)^2}-\frac{\left (b^2-4 a c\right ) \left (32 c^3 d g^3-8 c^2 \left (a f g^2+2 b (e g+3 d h) g-3 a h (2 e g-d h)\right ) g+2 c \left (\left (5 f g^3+3 h (2 e g+5 d h) g\right ) b^2-6 a h \left (3 f g^2+h (3 e g-d h)\right ) b+4 a^2 h^2 (6 f g-e h)\right )-b h \left (\left (3 f g^2+h (3 e g+7 d h)\right ) b^2-2 a h (6 f g+5 e h) b+16 a^2 f h^2\right )\right ) \tanh ^{-1}\left (\frac{b g-2 a h+(2 c g-b h) x}{2 \sqrt{c g^2-b h g+a h^2} \sqrt{c x^2+b x+a}}\right )}{256 \left (c g^2-b h g+a h^2\right )^{9/2}}$

Antiderivative was successfully veriﬁed.

[In]

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

[Out]

((32*c^3*d*g^3 - 8*c^2*g*(a*f*g^2 - 3*a*h*(2*e*g - d*h) + 2*b*g*(e*g + 3*d*h)) + 2*c*(4*a^2*h^2*(6*f*g - e*h)
- 6*a*b*h*(3*f*g^2 + h*(3*e*g - d*h)) + b^2*(5*f*g^3 + 3*g*h*(2*e*g + 5*d*h))) - b*h*(16*a^2*f*h^2 - 2*a*b*h*(
6*f*g + 5*e*h) + b^2*(3*f*g^2 + h*(3*e*g + 7*d*h))))*(b*g - 2*a*h + (2*c*g - b*h)*x)*Sqrt[a + b*x + c*x^2])/(1
28*(c*g^2 - b*g*h + a*h^2)^4*(g + h*x)^2) - ((f*g^2 - h*(e*g - d*h))*(a + b*x + c*x^2)^(3/2))/(5*h*(c*g^2 - b*
g*h + a*h^2)*(g + h*x)^5) + ((6*c*f*g^3 + 2*c*g*h*(2*e*g - 7*d*h) + 10*a*h^2*(2*f*g - e*h) - b*h*(13*f*g^2 - h
*(3*e*g + 7*d*h)))*(a + b*x + c*x^2)^(3/2))/(40*h*(c*g^2 - b*g*h + a*h^2)^2*(g + h*x)^4) + ((4*c^2*(3*f*g^4 +
g^2*h*(2*e*g - 27*d*h)) - 5*h^2*(16*a^2*f*h^2 - 2*a*b*h*(6*f*g + 5*e*h) + b^2*(3*f*g^2 + 3*e*g*h + 7*d*h^2)) -
2*c*h*(b*g*(16*f*g^2 - 21*e*g*h - 54*d*h^2) - 2*a*h*(18*f*g^2 - 33*e*g*h + 8*d*h^2)))*(a + b*x + c*x^2)^(3/2)
)/(240*h*(c*g^2 - b*g*h + a*h^2)^3*(g + h*x)^3) - ((b^2 - 4*a*c)*(32*c^3*d*g^3 - 8*c^2*g*(a*f*g^2 - 3*a*h*(2*e
*g - d*h) + 2*b*g*(e*g + 3*d*h)) + 2*c*(4*a^2*h^2*(6*f*g - e*h) - 6*a*b*h*(3*f*g^2 + h*(3*e*g - d*h)) + b^2*(5
*f*g^3 + 3*g*h*(2*e*g + 5*d*h))) - b*h*(16*a^2*f*h^2 - 2*a*b*h*(6*f*g + 5*e*h) + b^2*(3*f*g^2 + h*(3*e*g + 7*d
*h))))*ArcTanh[(b*g - 2*a*h + (2*c*g - b*h)*x)/(2*Sqrt[c*g^2 - b*g*h + a*h^2]*Sqrt[a + b*x + c*x^2])])/(256*(c
*g^2 - b*g*h + a*h^2)^(9/2))

Rule 1650

Int[(Pq_)*((d_.) + (e_.)*(x_))^(m_)*((a_.) + (b_.)*(x_) + (c_.)*(x_)^2)^(p_), x_Symbol] :> With[{Q = Polynomia
lQuotient[Pq, d + e*x, x], R = PolynomialRemainder[Pq, d + e*x, x]}, Simp[(e*R*(d + e*x)^(m + 1)*(a + b*x + c*
x^2)^(p + 1))/((m + 1)*(c*d^2 - b*d*e + a*e^2)), x] + Dist[1/((m + 1)*(c*d^2 - b*d*e + a*e^2)), Int[(d + e*x)^
(m + 1)*(a + b*x + c*x^2)^p*ExpandToSum[(m + 1)*(c*d^2 - b*d*e + a*e^2)*Q + c*d*R*(m + 1) - b*e*R*(m + p + 2)
- c*e*R*(m + 2*p + 3)*x, x], x], x]] /; FreeQ[{a, b, c, d, e, p}, x] && PolyQ[Pq, x] && NeQ[b^2 - 4*a*c, 0] &&
NeQ[c*d^2 - b*d*e + a*e^2, 0] && LtQ[m, -1]

Rule 834

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

Rule 806

Int[((d_.) + (e_.)*(x_))^(m_)*((f_.) + (g_.)*(x_))*((a_.) + (b_.)*(x_) + (c_.)*(x_)^2)^(p_.), x_Symbol] :> -Si
mp[((e*f - d*g)*(d + e*x)^(m + 1)*(a + b*x + c*x^2)^(p + 1))/(2*(p + 1)*(c*d^2 - b*d*e + a*e^2)), x] - Dist[(b
*(e*f + d*g) - 2*(c*d*f + a*e*g))/(2*(c*d^2 - b*d*e + a*e^2)), Int[(d + e*x)^(m + 1)*(a + b*x + c*x^2)^p, x],
x] /; FreeQ[{a, b, c, d, e, f, g, m, p}, x] && NeQ[b^2 - 4*a*c, 0] && NeQ[c*d^2 - b*d*e + a*e^2, 0] && EqQ[Sim
plify[m + 2*p + 3], 0]

Rule 720

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

Rule 724

Int[1/(((d_.) + (e_.)*(x_))*Sqrt[(a_.) + (b_.)*(x_) + (c_.)*(x_)^2]), x_Symbol] :> Dist[-2, Subst[Int[1/(4*c*d
^2 - 4*b*d*e + 4*a*e^2 - x^2), x], x, (2*a*e - b*d - (2*c*d - b*e)*x)/Sqrt[a + b*x + c*x^2]], x] /; FreeQ[{a,
b, c, d, e}, x] && NeQ[b^2 - 4*a*c, 0] && NeQ[2*c*d - b*e, 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{\sqrt{a+b x+c x^2} \left (d+e x+f x^2\right )}{(g+h x)^6} \, dx &=-\frac{\left (f g^2-h (e g-d h)\right ) \left (a+b x+c x^2\right )^{3/2}}{5 h \left (c g^2-b g h+a h^2\right ) (g+h x)^5}-\frac{\int \frac{\left (\frac{1}{2} \left (-10 c d g+3 b e g+10 a f g-\frac{3 b f g^2}{h}+7 b d h-10 a e h\right )-\left (2 c e g-5 b f g+\frac{3 c f g^2}{h}-2 c d h+5 a f h\right ) x\right ) \sqrt{a+b x+c x^2}}{(g+h x)^5} \, dx}{5 \left (c g^2-b g h+a h^2\right )}\\ &=-\frac{\left (f g^2-h (e g-d h)\right ) \left (a+b x+c x^2\right )^{3/2}}{5 h \left (c g^2-b g h+a h^2\right ) (g+h x)^5}+\frac{\left (6 c f g^3+2 c g h (2 e g-7 d h)+10 a h^2 (2 f g-e h)-b h \left (13 f g^2-h (3 e g+7 d h)\right )\right ) \left (a+b x+c x^2\right )^{3/2}}{40 h \left (c g^2-b g h+a h^2\right )^2 (g+h x)^4}+\frac{\int \frac{\left (\frac{1}{4} \left (80 c^2 d g^2+80 a^2 f h^2-2 b c g \left (18 e g-\frac{3 f g^2}{h}+47 d h\right )-10 a b h (6 f g+5 e h)-16 a c \left (2 f g^2-h (7 e g-2 d h)\right )+5 b^2 \left (3 f g^2+h (3 e g+7 d h)\right )\right )+\frac{c \left (6 c f g^3+2 c g h (2 e g-7 d h)+10 a h^2 (2 f g-e h)-b h \left (13 f g^2-h (3 e g+7 d h)\right )\right ) x}{2 h}\right ) \sqrt{a+b x+c x^2}}{(g+h x)^4} \, dx}{20 \left (c g^2-b g h+a h^2\right )^2}\\ &=-\frac{\left (f g^2-h (e g-d h)\right ) \left (a+b x+c x^2\right )^{3/2}}{5 h \left (c g^2-b g h+a h^2\right ) (g+h x)^5}+\frac{\left (6 c f g^3+2 c g h (2 e g-7 d h)+10 a h^2 (2 f g-e h)-b h \left (13 f g^2-h (3 e g+7 d h)\right )\right ) \left (a+b x+c x^2\right )^{3/2}}{40 h \left (c g^2-b g h+a h^2\right )^2 (g+h x)^4}+\frac{\left (4 c^2 \left (3 f g^4+g^2 h (2 e g-27 d h)\right )-5 h^2 \left (16 a^2 f h^2-2 a b h (6 f g+5 e h)+b^2 \left (3 f g^2+3 e g h+7 d h^2\right )\right )-2 c h \left (b g \left (16 f g^2-21 e g h-54 d h^2\right )-2 a h \left (18 f g^2-33 e g h+8 d h^2\right )\right )\right ) \left (a+b x+c x^2\right )^{3/2}}{240 h \left (c g^2-b g h+a h^2\right )^3 (g+h x)^3}+\frac{\left (32 c^3 d g^3-8 c^2 g \left (a f g^2-3 a h (2 e g-d h)+2 b g (e g+3 d h)\right )+2 c \left (4 a^2 h^2 (6 f g-e h)-6 a b h \left (3 f g^2+h (3 e g-d h)\right )+b^2 \left (5 f g^3+3 g h (2 e g+5 d h)\right )\right )-b h \left (16 a^2 f h^2-2 a b h (6 f g+5 e h)+b^2 \left (3 f g^2+h (3 e g+7 d h)\right )\right )\right ) \int \frac{\sqrt{a+b x+c x^2}}{(g+h x)^3} \, dx}{32 \left (c g^2-b g h+a h^2\right )^3}\\ &=\frac{\left (32 c^3 d g^3-8 c^2 g \left (a f g^2-3 a h (2 e g-d h)+2 b g (e g+3 d h)\right )+2 c \left (4 a^2 h^2 (6 f g-e h)-6 a b h \left (3 f g^2+h (3 e g-d h)\right )+b^2 \left (5 f g^3+3 g h (2 e g+5 d h)\right )\right )-b h \left (16 a^2 f h^2-2 a b h (6 f g+5 e h)+b^2 \left (3 f g^2+h (3 e g+7 d h)\right )\right )\right ) (b g-2 a h+(2 c g-b h) x) \sqrt{a+b x+c x^2}}{128 \left (c g^2-b g h+a h^2\right )^4 (g+h x)^2}-\frac{\left (f g^2-h (e g-d h)\right ) \left (a+b x+c x^2\right )^{3/2}}{5 h \left (c g^2-b g h+a h^2\right ) (g+h x)^5}+\frac{\left (6 c f g^3+2 c g h (2 e g-7 d h)+10 a h^2 (2 f g-e h)-b h \left (13 f g^2-h (3 e g+7 d h)\right )\right ) \left (a+b x+c x^2\right )^{3/2}}{40 h \left (c g^2-b g h+a h^2\right )^2 (g+h x)^4}+\frac{\left (4 c^2 \left (3 f g^4+g^2 h (2 e g-27 d h)\right )-5 h^2 \left (16 a^2 f h^2-2 a b h (6 f g+5 e h)+b^2 \left (3 f g^2+3 e g h+7 d h^2\right )\right )-2 c h \left (b g \left (16 f g^2-21 e g h-54 d h^2\right )-2 a h \left (18 f g^2-33 e g h+8 d h^2\right )\right )\right ) \left (a+b x+c x^2\right )^{3/2}}{240 h \left (c g^2-b g h+a h^2\right )^3 (g+h x)^3}-\frac{\left (\left (b^2-4 a c\right ) \left (32 c^3 d g^3-8 c^2 g \left (a f g^2-3 a h (2 e g-d h)+2 b g (e g+3 d h)\right )+2 c \left (4 a^2 h^2 (6 f g-e h)-6 a b h \left (3 f g^2+h (3 e g-d h)\right )+b^2 \left (5 f g^3+3 g h (2 e g+5 d h)\right )\right )-b h \left (16 a^2 f h^2-2 a b h (6 f g+5 e h)+b^2 \left (3 f g^2+h (3 e g+7 d h)\right )\right )\right )\right ) \int \frac{1}{(g+h x) \sqrt{a+b x+c x^2}} \, dx}{256 \left (c g^2-b g h+a h^2\right )^4}\\ &=\frac{\left (32 c^3 d g^3-8 c^2 g \left (a f g^2-3 a h (2 e g-d h)+2 b g (e g+3 d h)\right )+2 c \left (4 a^2 h^2 (6 f g-e h)-6 a b h \left (3 f g^2+h (3 e g-d h)\right )+b^2 \left (5 f g^3+3 g h (2 e g+5 d h)\right )\right )-b h \left (16 a^2 f h^2-2 a b h (6 f g+5 e h)+b^2 \left (3 f g^2+h (3 e g+7 d h)\right )\right )\right ) (b g-2 a h+(2 c g-b h) x) \sqrt{a+b x+c x^2}}{128 \left (c g^2-b g h+a h^2\right )^4 (g+h x)^2}-\frac{\left (f g^2-h (e g-d h)\right ) \left (a+b x+c x^2\right )^{3/2}}{5 h \left (c g^2-b g h+a h^2\right ) (g+h x)^5}+\frac{\left (6 c f g^3+2 c g h (2 e g-7 d h)+10 a h^2 (2 f g-e h)-b h \left (13 f g^2-h (3 e g+7 d h)\right )\right ) \left (a+b x+c x^2\right )^{3/2}}{40 h \left (c g^2-b g h+a h^2\right )^2 (g+h x)^4}+\frac{\left (4 c^2 \left (3 f g^4+g^2 h (2 e g-27 d h)\right )-5 h^2 \left (16 a^2 f h^2-2 a b h (6 f g+5 e h)+b^2 \left (3 f g^2+3 e g h+7 d h^2\right )\right )-2 c h \left (b g \left (16 f g^2-21 e g h-54 d h^2\right )-2 a h \left (18 f g^2-33 e g h+8 d h^2\right )\right )\right ) \left (a+b x+c x^2\right )^{3/2}}{240 h \left (c g^2-b g h+a h^2\right )^3 (g+h x)^3}+\frac{\left (\left (b^2-4 a c\right ) \left (32 c^3 d g^3-8 c^2 g \left (a f g^2-3 a h (2 e g-d h)+2 b g (e g+3 d h)\right )+2 c \left (4 a^2 h^2 (6 f g-e h)-6 a b h \left (3 f g^2+h (3 e g-d h)\right )+b^2 \left (5 f g^3+3 g h (2 e g+5 d h)\right )\right )-b h \left (16 a^2 f h^2-2 a b h (6 f g+5 e h)+b^2 \left (3 f g^2+h (3 e g+7 d h)\right )\right )\right )\right ) \operatorname{Subst}\left (\int \frac{1}{4 c g^2-4 b g h+4 a h^2-x^2} \, dx,x,\frac{-b g+2 a h-(2 c g-b h) x}{\sqrt{a+b x+c x^2}}\right )}{128 \left (c g^2-b g h+a h^2\right )^4}\\ &=\frac{\left (32 c^3 d g^3-8 c^2 g \left (a f g^2-3 a h (2 e g-d h)+2 b g (e g+3 d h)\right )+2 c \left (4 a^2 h^2 (6 f g-e h)-6 a b h \left (3 f g^2+h (3 e g-d h)\right )+b^2 \left (5 f g^3+3 g h (2 e g+5 d h)\right )\right )-b h \left (16 a^2 f h^2-2 a b h (6 f g+5 e h)+b^2 \left (3 f g^2+h (3 e g+7 d h)\right )\right )\right ) (b g-2 a h+(2 c g-b h) x) \sqrt{a+b x+c x^2}}{128 \left (c g^2-b g h+a h^2\right )^4 (g+h x)^2}-\frac{\left (f g^2-h (e g-d h)\right ) \left (a+b x+c x^2\right )^{3/2}}{5 h \left (c g^2-b g h+a h^2\right ) (g+h x)^5}+\frac{\left (6 c f g^3+2 c g h (2 e g-7 d h)+10 a h^2 (2 f g-e h)-b h \left (13 f g^2-h (3 e g+7 d h)\right )\right ) \left (a+b x+c x^2\right )^{3/2}}{40 h \left (c g^2-b g h+a h^2\right )^2 (g+h x)^4}+\frac{\left (4 c^2 \left (3 f g^4+g^2 h (2 e g-27 d h)\right )-5 h^2 \left (16 a^2 f h^2-2 a b h (6 f g+5 e h)+b^2 \left (3 f g^2+3 e g h+7 d h^2\right )\right )-2 c h \left (b g \left (16 f g^2-21 e g h-54 d h^2\right )-2 a h \left (18 f g^2-33 e g h+8 d h^2\right )\right )\right ) \left (a+b x+c x^2\right )^{3/2}}{240 h \left (c g^2-b g h+a h^2\right )^3 (g+h x)^3}-\frac{\left (b^2-4 a c\right ) \left (32 c^3 d g^3-8 c^2 g \left (a f g^2-3 a h (2 e g-d h)+2 b g (e g+3 d h)\right )+2 c \left (4 a^2 h^2 (6 f g-e h)-6 a b h \left (3 f g^2+h (3 e g-d h)\right )+b^2 \left (5 f g^3+3 g h (2 e g+5 d h)\right )\right )-b h \left (16 a^2 f h^2-2 a b h (6 f g+5 e h)+b^2 \left (3 f g^2+h (3 e g+7 d h)\right )\right )\right ) \tanh ^{-1}\left (\frac{b g-2 a h+(2 c g-b h) x}{2 \sqrt{c g^2-b g h+a h^2} \sqrt{a+b x+c x^2}}\right )}{256 \left (c g^2-b g h+a h^2\right )^{9/2}}\\ \end{align*}

Mathematica [A]  time = 6.32801, size = 1129, normalized size = 1.37 $\frac{\sqrt{a+x (b+c x)} \left (-\frac{\left (\frac{1}{2} h (3 b f g+4 c d h-10 a f h)-\frac{1}{2} g (6 c f g+4 c e h-7 b f h)\right ) \left (c x^2+b x+a\right )^{3/2}}{5 \left (c g^2-b h g+a h^2\right ) (g+h x)^5}-\frac{-\frac{\left (2 c g \left (3 c f g^2-5 f h (b g-a h)+2 c h (e g-d h)\right )-c h \left (3 b f g^2-b h (3 e g+7 d h)+10 h (c d g-a f g+a e h)\right )\right ) \left (c x^2+b x+a\right )^{3/2}}{4 \left (c g^2-b h g+a h^2\right ) (g+h x)^4}-\frac{-\frac{\left (\frac{1}{2} c h \left (5 h \left (3 f g^2+h (3 e g+7 d h)\right ) b^2+2 \left (3 c f g^3-c h (18 e g+47 d h) g-5 a h^2 (6 f g+5 e h)\right ) b+16 h \left (5 c^2 d g^2+5 a^2 f h^2-a c \left (2 f g^2-h (7 e g-2 d h)\right )\right )\right )-c^2 g \left (6 c f g^3+2 c h (2 e g-7 d h) g+10 a h^2 (2 f g-e h)-b h \left (13 f g^2-h (3 e g+7 d h)\right )\right )\right ) \left (c x^2+b x+a\right )^{3/2}}{3 \left (c g^2-b h g+a h^2\right ) (g+h x)^3}-\frac{\left (b \left (g \left (6 c f g^3+2 c h (2 e g-7 d h) g+10 a h^2 (2 f g-e h)-b h \left (13 f g^2-h (3 e g+7 d h)\right )\right ) c^2+\frac{1}{2} h \left (5 h \left (3 f g^2+h (3 e g+7 d h)\right ) b^2+2 \left (3 c f g^3-c h (18 e g+47 d h) g-5 a h^2 (6 f g+5 e h)\right ) b+16 h \left (5 c^2 d g^2+5 a^2 f h^2-a c \left (2 f g^2-h (7 e g-2 d h)\right )\right )\right ) c\right )-2 \left (a h \left (6 c f g^3+2 c h (2 e g-7 d h) g+10 a h^2 (2 f g-e h)-b h \left (13 f g^2-h (3 e g+7 d h)\right )\right ) c^2+\frac{1}{2} g \left (5 h \left (3 f g^2+h (3 e g+7 d h)\right ) b^2+2 \left (3 c f g^3-c h (18 e g+47 d h) g-5 a h^2 (6 f g+5 e h)\right ) b+16 h \left (5 c^2 d g^2+5 a^2 f h^2-a c \left (2 f g^2-h (7 e g-2 d h)\right )\right )\right ) c^2\right )\right ) \left (\frac{\sqrt{c x^2+b x+a} (b g-2 a h+(2 c g-b h) x)}{4 \left (c g^2-b h g+a h^2\right ) (g+h x)^2}+\frac{\left (b^2-4 a c\right ) \tanh ^{-1}\left (\frac{-b g+2 a h-(2 c g-b h) x}{2 \sqrt{c g^2-b h g+a h^2} \sqrt{c x^2+b x+a}}\right )}{2 \sqrt{c g^2-b h g+a h^2} \left (4 c g^2-4 b h g+4 a h^2\right )}\right )}{2 \left (c g^2-b h g+a h^2\right )}}{4 \left (c g^2-b h g+a h^2\right )}}{5 \left (c g^2-b h g+a h^2\right )}\right )}{2 c h \sqrt{c x^2+b x+a}}-\frac{f \left (c x^2+b x+a\right ) \sqrt{a+x (b+c x)}}{2 c h (g+h x)^5}$

Antiderivative was successfully veriﬁed.

[In]

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

[Out]

-(f*(a + b*x + c*x^2)*Sqrt[a + x*(b + c*x)])/(2*c*h*(g + h*x)^5) + (Sqrt[a + x*(b + c*x)]*(-(((h*(3*b*f*g + 4*
c*d*h - 10*a*f*h))/2 - (g*(6*c*f*g + 4*c*e*h - 7*b*f*h))/2)*(a + b*x + c*x^2)^(3/2))/(5*(c*g^2 - b*g*h + a*h^2
)*(g + h*x)^5) - (-((2*c*g*(3*c*f*g^2 - 5*f*h*(b*g - a*h) + 2*c*h*(e*g - d*h)) - c*h*(3*b*f*g^2 - b*h*(3*e*g +
7*d*h) + 10*h*(c*d*g - a*f*g + a*e*h)))*(a + b*x + c*x^2)^(3/2))/(4*(c*g^2 - b*g*h + a*h^2)*(g + h*x)^4) - (-
((-(c^2*g*(6*c*f*g^3 + 2*c*g*h*(2*e*g - 7*d*h) + 10*a*h^2*(2*f*g - e*h) - b*h*(13*f*g^2 - h*(3*e*g + 7*d*h))))
+ (c*h*(5*b^2*h*(3*f*g^2 + h*(3*e*g + 7*d*h)) + 2*b*(3*c*f*g^3 - c*g*h*(18*e*g + 47*d*h) - 5*a*h^2*(6*f*g + 5
*e*h)) + 16*h*(5*c^2*d*g^2 + 5*a^2*f*h^2 - a*c*(2*f*g^2 - h*(7*e*g - 2*d*h)))))/2)*(a + b*x + c*x^2)^(3/2))/(3
*(c*g^2 - b*g*h + a*h^2)*(g + h*x)^3) - ((-2*(a*c^2*h*(6*c*f*g^3 + 2*c*g*h*(2*e*g - 7*d*h) + 10*a*h^2*(2*f*g -
e*h) - b*h*(13*f*g^2 - h*(3*e*g + 7*d*h))) + (c^2*g*(5*b^2*h*(3*f*g^2 + h*(3*e*g + 7*d*h)) + 2*b*(3*c*f*g^3 -
c*g*h*(18*e*g + 47*d*h) - 5*a*h^2*(6*f*g + 5*e*h)) + 16*h*(5*c^2*d*g^2 + 5*a^2*f*h^2 - a*c*(2*f*g^2 - h*(7*e*
g - 2*d*h)))))/2) + b*(c^2*g*(6*c*f*g^3 + 2*c*g*h*(2*e*g - 7*d*h) + 10*a*h^2*(2*f*g - e*h) - b*h*(13*f*g^2 - h
*(3*e*g + 7*d*h))) + (c*h*(5*b^2*h*(3*f*g^2 + h*(3*e*g + 7*d*h)) + 2*b*(3*c*f*g^3 - c*g*h*(18*e*g + 47*d*h) -
5*a*h^2*(6*f*g + 5*e*h)) + 16*h*(5*c^2*d*g^2 + 5*a^2*f*h^2 - a*c*(2*f*g^2 - h*(7*e*g - 2*d*h)))))/2))*(((b*g -
2*a*h + (2*c*g - b*h)*x)*Sqrt[a + b*x + c*x^2])/(4*(c*g^2 - b*g*h + a*h^2)*(g + h*x)^2) + ((b^2 - 4*a*c)*ArcT
anh[(-(b*g) + 2*a*h - (2*c*g - b*h)*x)/(2*Sqrt[c*g^2 - b*g*h + a*h^2]*Sqrt[a + b*x + c*x^2])])/(2*Sqrt[c*g^2 -
b*g*h + a*h^2]*(4*c*g^2 - 4*b*g*h + 4*a*h^2))))/(2*(c*g^2 - b*g*h + a*h^2)))/(4*(c*g^2 - b*g*h + a*h^2)))/(5*
(c*g^2 - b*g*h + a*h^2))))/(2*c*h*Sqrt[a + b*x + c*x^2])

________________________________________________________________________________________

Maple [B]  time = 0.292, size = 40336, normalized size = 49. \begin{align*} \text{output too large to display} \end{align*}

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

[In]

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

[Out]

result too large to display

________________________________________________________________________________________

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((f*x^2+e*x+d)*(c*x^2+b*x+a)^(1/2)/(h*x+g)^6,x, algorithm="maxima")

[Out]

Exception raised: ValueError

________________________________________________________________________________________

Fricas [F(-1)]  time = 0., size = 0, normalized size = 0. \begin{align*} \text{Timed out} \end{align*}

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

[In]

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

[Out]

Timed out

________________________________________________________________________________________

Sympy [F(-1)]  time = 0., size = 0, normalized size = 0. \begin{align*} \text{Timed out} \end{align*}

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

[In]

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

[Out]

Timed out

________________________________________________________________________________________

Giac [F(-1)]  time = 0., size = 0, normalized size = 0. \begin{align*} \text{Timed out} \end{align*}

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

[In]

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

[Out]

Timed out