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

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

[Out]

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

________________________________________________________________________________________

Rubi [A]  time = 0.42881, antiderivative size = 312, normalized size of antiderivative = 1., number of steps used = 5, number of rules used = 5, integrand size = 29, $$\frac{\text{number of rules}}{\text{integrand size}}$$ = 0.172, Rules used = {1651, 807, 721, 725, 206} $-\frac{\sqrt{a+c x^2} (a h-c g x) \left (4 a^2 f h^2-a c \left (f g^2-h (5 e g-d h)\right )+4 c^2 d g^2\right )}{8 (g+h x)^2 \left (a h^2+c g^2\right )^3}-\frac{a c \tanh ^{-1}\left (\frac{a h-c g x}{\sqrt{a+c x^2} \sqrt{a h^2+c g^2}}\right ) \left (4 a^2 f h^2-a c \left (f g^2-h (5 e g-d h)\right )+4 c^2 d g^2\right )}{8 \left (a h^2+c g^2\right )^{7/2}}+\frac{\left (a+c x^2\right )^{3/2} \left (4 a h^2 (2 f g-e h)+c g h (e g-5 d h)+3 c f g^3\right )}{12 h (g+h x)^3 \left (a h^2+c g^2\right )^2}-\frac{\left (a+c x^2\right )^{3/2} \left (d h^2-e g h+f g^2\right )}{4 h (g+h x)^4 \left (a h^2+c g^2\right )}$

Antiderivative was successfully veriﬁed.

[In]

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

[Out]

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

Rule 1651

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

Rule 807

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

Rule 721

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

Rule 725

Int[1/(((d_) + (e_.)*(x_))*Sqrt[(a_) + (c_.)*(x_)^2]), x_Symbol] :> -Subst[Int[1/(c*d^2 + a*e^2 - x^2), x], x,
(a*e - c*d*x)/Sqrt[a + c*x^2]] /; FreeQ[{a, c, d, e}, x]

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+c x^2} \left (d+e x+f x^2\right )}{(g+h x)^5} \, dx &=-\frac{\left (f g^2-e g h+d h^2\right ) \left (a+c x^2\right )^{3/2}}{4 h \left (c g^2+a h^2\right ) (g+h x)^4}-\frac{\int \frac{\left (-4 (c d g-a f g+a e h)-\left (4 a f h+c \left (e g+\frac{3 f g^2}{h}-d h\right )\right ) x\right ) \sqrt{a+c x^2}}{(g+h x)^4} \, dx}{4 \left (c g^2+a h^2\right )}\\ &=-\frac{\left (f g^2-e g h+d h^2\right ) \left (a+c x^2\right )^{3/2}}{4 h \left (c g^2+a h^2\right ) (g+h x)^4}+\frac{\left (3 c f g^3+c g h (e g-5 d h)+4 a h^2 (2 f g-e h)\right ) \left (a+c x^2\right )^{3/2}}{12 h \left (c g^2+a h^2\right )^2 (g+h x)^3}+\frac{\left (4 c^2 d g^2+4 a^2 f h^2-a c \left (f g^2-h (5 e g-d h)\right )\right ) \int \frac{\sqrt{a+c x^2}}{(g+h x)^3} \, dx}{4 \left (c g^2+a h^2\right )^2}\\ &=-\frac{\left (4 c^2 d g^2+4 a^2 f h^2-a c \left (f g^2-h (5 e g-d h)\right )\right ) (a h-c g x) \sqrt{a+c x^2}}{8 \left (c g^2+a h^2\right )^3 (g+h x)^2}-\frac{\left (f g^2-e g h+d h^2\right ) \left (a+c x^2\right )^{3/2}}{4 h \left (c g^2+a h^2\right ) (g+h x)^4}+\frac{\left (3 c f g^3+c g h (e g-5 d h)+4 a h^2 (2 f g-e h)\right ) \left (a+c x^2\right )^{3/2}}{12 h \left (c g^2+a h^2\right )^2 (g+h x)^3}+\frac{\left (a c \left (4 c^2 d g^2+4 a^2 f h^2-a c \left (f g^2-h (5 e g-d h)\right )\right )\right ) \int \frac{1}{(g+h x) \sqrt{a+c x^2}} \, dx}{8 \left (c g^2+a h^2\right )^3}\\ &=-\frac{\left (4 c^2 d g^2+4 a^2 f h^2-a c \left (f g^2-h (5 e g-d h)\right )\right ) (a h-c g x) \sqrt{a+c x^2}}{8 \left (c g^2+a h^2\right )^3 (g+h x)^2}-\frac{\left (f g^2-e g h+d h^2\right ) \left (a+c x^2\right )^{3/2}}{4 h \left (c g^2+a h^2\right ) (g+h x)^4}+\frac{\left (3 c f g^3+c g h (e g-5 d h)+4 a h^2 (2 f g-e h)\right ) \left (a+c x^2\right )^{3/2}}{12 h \left (c g^2+a h^2\right )^2 (g+h x)^3}-\frac{\left (a c \left (4 c^2 d g^2+4 a^2 f h^2-a c \left (f g^2-h (5 e g-d h)\right )\right )\right ) \operatorname{Subst}\left (\int \frac{1}{c g^2+a h^2-x^2} \, dx,x,\frac{a h-c g x}{\sqrt{a+c x^2}}\right )}{8 \left (c g^2+a h^2\right )^3}\\ &=-\frac{\left (4 c^2 d g^2+4 a^2 f h^2-a c \left (f g^2-h (5 e g-d h)\right )\right ) (a h-c g x) \sqrt{a+c x^2}}{8 \left (c g^2+a h^2\right )^3 (g+h x)^2}-\frac{\left (f g^2-e g h+d h^2\right ) \left (a+c x^2\right )^{3/2}}{4 h \left (c g^2+a h^2\right ) (g+h x)^4}+\frac{\left (3 c f g^3+c g h (e g-5 d h)+4 a h^2 (2 f g-e h)\right ) \left (a+c x^2\right )^{3/2}}{12 h \left (c g^2+a h^2\right )^2 (g+h x)^3}-\frac{a c \left (4 c^2 d g^2+4 a^2 f h^2-a c \left (f g^2-h (5 e g-d h)\right )\right ) \tanh ^{-1}\left (\frac{a h-c g x}{\sqrt{c g^2+a h^2} \sqrt{a+c x^2}}\right )}{8 \left (c g^2+a h^2\right )^{7/2}}\\ \end{align*}

Mathematica [A]  time = 1.31562, size = 439, normalized size = 1.4 $\frac{1}{24} \left (-\frac{\sqrt{a+c x^2} \left ((g+h x)^2 \left (a h^2+c g^2\right ) \left (12 a^2 f h^4+a c h^2 \left (h (3 d h-7 e g)+35 f g^2\right )+2 c^2 \left (9 f g^4-g^2 h (d h+e g)\right )\right )-c (g+h x)^3 \left (4 a^2 h^4 (7 f g-2 e h)+a c g h^2 \left (h (9 e g-13 d h)+19 f g^2\right )+2 c^2 \left (g^3 h (d h+e g)+3 f g^5\right )\right )-2 (g+h x) \left (a h^2+c g^2\right )^2 \left (-4 a h^2 (e h-2 f g)+c g h (d h-5 e g)+9 c f g^3\right )+6 \left (a h^2+c g^2\right )^3 \left (h (d h-e g)+f g^2\right )\right )}{(g+h x)^4 \left (a h^3+c g^2 h\right )^3}-\frac{3 a c \log \left (\sqrt{a+c x^2} \sqrt{a h^2+c g^2}+a h-c g x\right ) \left (4 a^2 f h^2-a c \left (h (d h-5 e g)+f g^2\right )+4 c^2 d g^2\right )}{\left (a h^2+c g^2\right )^{7/2}}+\frac{3 a c \log (g+h x) \left (4 a^2 f h^2-a c \left (h (d h-5 e g)+f g^2\right )+4 c^2 d g^2\right )}{\left (a h^2+c g^2\right )^{7/2}}\right )$

Antiderivative was successfully veriﬁed.

[In]

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

[Out]

(-((Sqrt[a + c*x^2]*(6*(c*g^2 + a*h^2)^3*(f*g^2 + h*(-(e*g) + d*h)) - 2*(c*g^2 + a*h^2)^2*(9*c*f*g^3 + c*g*h*(
-5*e*g + d*h) - 4*a*h^2*(-2*f*g + e*h))*(g + h*x) + (c*g^2 + a*h^2)*(12*a^2*f*h^4 + 2*c^2*(9*f*g^4 - g^2*h*(e*
g + d*h)) + a*c*h^2*(35*f*g^2 + h*(-7*e*g + 3*d*h)))*(g + h*x)^2 - c*(4*a^2*h^4*(7*f*g - 2*e*h) + a*c*g*h^2*(1
9*f*g^2 + h*(9*e*g - 13*d*h)) + 2*c^2*(3*f*g^5 + g^3*h*(e*g + d*h)))*(g + h*x)^3))/((c*g^2*h + a*h^3)^3*(g + h
*x)^4)) + (3*a*c*(4*c^2*d*g^2 + 4*a^2*f*h^2 - a*c*(f*g^2 + h*(-5*e*g + d*h)))*Log[g + h*x])/(c*g^2 + a*h^2)^(7
/2) - (3*a*c*(4*c^2*d*g^2 + 4*a^2*f*h^2 - a*c*(f*g^2 + h*(-5*e*g + d*h)))*Log[a*h - c*g*x + Sqrt[c*g^2 + a*h^2
]*Sqrt[a + c*x^2]])/(c*g^2 + a*h^2)^(7/2))/24

________________________________________________________________________________________

Maple [B]  time = 0.25, size = 7237, normalized size = 23.1 \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+a)^(1/2)/(h*x+g)^5,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+a)^(1/2)/(h*x+g)^5,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+a)^(1/2)/(h*x+g)^5,x, algorithm="fricas")

[Out]

Timed out

________________________________________________________________________________________

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

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

[In]

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

[Out]

Integral(sqrt(a + c*x**2)*(d + e*x + f*x**2)/(g + h*x)**5, x)

________________________________________________________________________________________

Giac [B]  time = 3.61287, size = 2869, normalized size = 9.17 \begin{align*} \text{result too large to display} \end{align*}

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

[In]

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

[Out]

-1/24*((6*c^(9/2)*f*g^7*h^9*abs(h) + 2*c^(9/2)*d*g^5*h^11*abs(h) + 25*a*c^(7/2)*f*g^5*h^11*abs(h) - 11*a*c^(7/
2)*d*g^3*h^13*abs(h) + 47*a^2*c^(5/2)*f*g^3*h^13*abs(h) - 13*a^2*c^(5/2)*d*g*h^15*abs(h) + 28*a^3*c^(3/2)*f*g*
h^15*abs(h) + 2*c^(9/2)*g^6*h^10*abs(h)*e + 11*a*c^(7/2)*g^4*h^12*abs(h)*e + a^2*c^(5/2)*g^2*h^14*abs(h)*e - 8
*a^3*c^(3/2)*h^16*abs(h)*e - 12*sqrt(c*g^2 + a*h^2)*a*c^3*d*g^2*h^14*log(abs(c^(3/2)*g^2*abs(h) + a*sqrt(c)*h^
2*abs(h) - sqrt(c*g^2 + a*h^2)*c*g*h)) + 3*sqrt(c*g^2 + a*h^2)*a^2*c^2*f*g^2*h^14*log(abs(c^(3/2)*g^2*abs(h) +
a*sqrt(c)*h^2*abs(h) - sqrt(c*g^2 + a*h^2)*c*g*h)) + 3*sqrt(c*g^2 + a*h^2)*a^2*c^2*d*h^16*log(abs(c^(3/2)*g^2
*abs(h) + a*sqrt(c)*h^2*abs(h) - sqrt(c*g^2 + a*h^2)*c*g*h)) - 12*sqrt(c*g^2 + a*h^2)*a^3*c*f*h^16*log(abs(c^(
3/2)*g^2*abs(h) + a*sqrt(c)*h^2*abs(h) - sqrt(c*g^2 + a*h^2)*c*g*h)) - 15*sqrt(c*g^2 + a*h^2)*a^2*c^2*g*h^15*e
*log(abs(c^(3/2)*g^2*abs(h) + a*sqrt(c)*h^2*abs(h) - sqrt(c*g^2 + a*h^2)*c*g*h)))*sgn(1/(h*x + g))*sgn(h)/(c^5
*g^10*abs(h) + 5*a*c^4*g^8*h^2*abs(h) + 10*a^2*c^3*g^6*h^4*abs(h) + 10*a^3*c^2*g^4*h^6*abs(h) + 5*a^4*c*g^2*h^
8*abs(h) + a^5*h^10*abs(h)) - sqrt(c - 2*c*g/(h*x + g) + c*g^2/(h*x + g)^2 + a*h^2/(h*x + g)^2)*((6*c^3*f*g^5*
h^17*sgn(1/(h*x + g))*sgn(h) + 2*c^3*d*g^3*h^19*sgn(1/(h*x + g))*sgn(h) + 19*a*c^2*f*g^3*h^19*sgn(1/(h*x + g))
*sgn(h) - 13*a*c^2*d*g*h^21*sgn(1/(h*x + g))*sgn(h) + 28*a^2*c*f*g*h^21*sgn(1/(h*x + g))*sgn(h) + 2*c^3*g^4*h^
18*e*sgn(1/(h*x + g))*sgn(h) + 9*a*c^2*g^2*h^20*e*sgn(1/(h*x + g))*sgn(h) - 8*a^2*c*h^22*e*sgn(1/(h*x + g))*sg
n(h))/(c^4*g^8*h^8 + 4*a*c^3*g^6*h^10 + 6*a^2*c^2*g^4*h^12 + 4*a^3*c*g^2*h^14 + a^4*h^16) - ((18*c^3*f*g^6*h^1
8*sgn(1/(h*x + g))*sgn(h) - 2*c^3*d*g^4*h^20*sgn(1/(h*x + g))*sgn(h) + 53*a*c^2*f*g^4*h^20*sgn(1/(h*x + g))*sg
n(h) + a*c^2*d*g^2*h^22*sgn(1/(h*x + g))*sgn(h) + 47*a^2*c*f*g^2*h^22*sgn(1/(h*x + g))*sgn(h) + 3*a^2*c*d*h^24
*sgn(1/(h*x + g))*sgn(h) + 12*a^3*f*h^24*sgn(1/(h*x + g))*sgn(h) - 2*c^3*g^5*h^19*e*sgn(1/(h*x + g))*sgn(h) -
9*a*c^2*g^3*h^21*e*sgn(1/(h*x + g))*sgn(h) - 7*a^2*c*g*h^23*e*sgn(1/(h*x + g))*sgn(h))/(c^4*g^8*h^8 + 4*a*c^3*
g^6*h^10 + 6*a^2*c^2*g^4*h^12 + 4*a^3*c*g^2*h^14 + a^4*h^16) - 2*((9*c^3*f*g^7*h^19*sgn(1/(h*x + g))*sgn(h) +
c^3*d*g^5*h^21*sgn(1/(h*x + g))*sgn(h) + 26*a*c^2*f*g^5*h^21*sgn(1/(h*x + g))*sgn(h) + 2*a*c^2*d*g^3*h^23*sgn(
1/(h*x + g))*sgn(h) + 25*a^2*c*f*g^3*h^23*sgn(1/(h*x + g))*sgn(h) + a^2*c*d*g*h^25*sgn(1/(h*x + g))*sgn(h) + 8
*a^3*f*g*h^25*sgn(1/(h*x + g))*sgn(h) - 5*c^3*g^6*h^20*e*sgn(1/(h*x + g))*sgn(h) - 14*a*c^2*g^4*h^22*e*sgn(1/(
h*x + g))*sgn(h) - 13*a^2*c*g^2*h^24*e*sgn(1/(h*x + g))*sgn(h) - 4*a^3*h^26*e*sgn(1/(h*x + g))*sgn(h))/(c^4*g^
8*h^8 + 4*a*c^3*g^6*h^10 + 6*a^2*c^2*g^4*h^12 + 4*a^3*c*g^2*h^14 + a^4*h^16) - 3*(c^3*f*g^8*h^20*sgn(1/(h*x +
g))*sgn(h) + c^3*d*g^6*h^22*sgn(1/(h*x + g))*sgn(h) + 3*a*c^2*f*g^6*h^22*sgn(1/(h*x + g))*sgn(h) + 3*a*c^2*d*g
^4*h^24*sgn(1/(h*x + g))*sgn(h) + 3*a^2*c*f*g^4*h^24*sgn(1/(h*x + g))*sgn(h) + 3*a^2*c*d*g^2*h^26*sgn(1/(h*x +
g))*sgn(h) + a^3*f*g^2*h^26*sgn(1/(h*x + g))*sgn(h) + a^3*d*h^28*sgn(1/(h*x + g))*sgn(h) - c^3*g^7*h^21*e*sgn
(1/(h*x + g))*sgn(h) - 3*a*c^2*g^5*h^23*e*sgn(1/(h*x + g))*sgn(h) - 3*a^2*c*g^3*h^25*e*sgn(1/(h*x + g))*sgn(h)
- a^3*g*h^27*e*sgn(1/(h*x + g))*sgn(h))/((c^4*g^8*h^8 + 4*a*c^3*g^6*h^10 + 6*a^2*c^2*g^4*h^12 + 4*a^3*c*g^2*h
^14 + a^4*h^16)*(h*x + g)*h))/((h*x + g)*h))/((h*x + g)*h)) + 3*(4*a*c^3*d*g^2*h^14*sgn(1/(h*x + g))*sgn(h) -
a^2*c^2*f*g^2*h^14*sgn(1/(h*x + g))*sgn(h) - a^2*c^2*d*h^16*sgn(1/(h*x + g))*sgn(h) + 4*a^3*c*f*h^16*sgn(1/(h*
x + g))*sgn(h) + 5*a^2*c^2*g*h^15*e*sgn(1/(h*x + g))*sgn(h))*sqrt(c*g^2 + a*h^2)*log(abs(-sqrt(c*g^2 + a*h^2)*
c*g*h + (c*g^2 + a*h^2)*(sqrt(c - 2*c*g/(h*x + g) + c*g^2/(h*x + g)^2 + a*h^2/(h*x + g)^2) + sqrt(c*g^2*h^2 +
a*h^4)/((h*x + g)*h))*abs(h)))/((c^5*g^10 + 5*a*c^4*g^8*h^2 + 10*a^2*c^3*g^6*h^4 + 10*a^3*c^2*g^4*h^6 + 5*a^4*
c*g^2*h^8 + a^5*h^10)*abs(h)))*h^2