\(\int \frac {\sqrt {d+e x}}{(f+g x)^3 \sqrt {a d e+(c d^2+a e^2) x+c d e x^2}} \, dx\) [40]

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

Optimal result

Integrand size = 46, antiderivative size = 213 \[ \int \frac {\sqrt {d+e x}}{(f+g x)^3 \sqrt {a d e+\left (c d^2+a e^2\right ) x+c d e x^2}} \, dx=\frac {\sqrt {a d e+\left (c d^2+a e^2\right ) x+c d e x^2}}{2 (c d f-a e g) \sqrt {d+e x} (f+g x)^2}+\frac {3 c d \sqrt {a d e+\left (c d^2+a e^2\right ) x+c d e x^2}}{4 (c d f-a e g)^2 \sqrt {d+e x} (f+g x)}-\frac {3 c^2 d^2 \arctan \left (\frac {\sqrt {c d f-a e g} \sqrt {d+e x}}{\sqrt {g} \sqrt {a d e+\left (c d^2+a e^2\right ) x+c d e x^2}}\right )}{4 \sqrt {g} (c d f-a e g)^{5/2}} \] Output:

1/2*(a*d*e+(a*e^2+c*d^2)*x+c*d*e*x^2)^(1/2)/(-a*e*g+c*d*f)/(e*x+d)^(1/2)/( 
g*x+f)^2+3/4*c*d*(a*d*e+(a*e^2+c*d^2)*x+c*d*e*x^2)^(1/2)/(-a*e*g+c*d*f)^2/ 
(e*x+d)^(1/2)/(g*x+f)-3/4*c^2*d^2*arctan(1/g^(1/2)/(a*d*e+(a*e^2+c*d^2)*x+ 
c*d*e*x^2)^(1/2)*(-a*e*g+c*d*f)^(1/2)*(e*x+d)^(1/2))/g^(1/2)/(-a*e*g+c*d*f 
)^(5/2)
 

Mathematica [A] (verified)

Time = 0.48 (sec) , antiderivative size = 163, normalized size of antiderivative = 0.77 \[ \int \frac {\sqrt {d+e x}}{(f+g x)^3 \sqrt {a d e+\left (c d^2+a e^2\right ) x+c d e x^2}} \, dx=\frac {\sqrt {d+e x} \left (\sqrt {g} \sqrt {c d f-a e g} (a e+c d x) (-2 a e g+c d (5 f+3 g x))+3 c^2 d^2 \sqrt {a e+c d x} (f+g x)^2 \arctan \left (\frac {\sqrt {g} \sqrt {a e+c d x}}{\sqrt {c d f-a e g}}\right )\right )}{4 \sqrt {g} (c d f-a e g)^{5/2} \sqrt {(a e+c d x) (d+e x)} (f+g x)^2} \] Input:

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

Output:

(Sqrt[d + e*x]*(Sqrt[g]*Sqrt[c*d*f - a*e*g]*(a*e + c*d*x)*(-2*a*e*g + c*d* 
(5*f + 3*g*x)) + 3*c^2*d^2*Sqrt[a*e + c*d*x]*(f + g*x)^2*ArcTan[(Sqrt[g]*S 
qrt[a*e + c*d*x])/Sqrt[c*d*f - a*e*g]]))/(4*Sqrt[g]*(c*d*f - a*e*g)^(5/2)* 
Sqrt[(a*e + c*d*x)*(d + e*x)]*(f + g*x)^2)
 

Rubi [A] (verified)

Time = 0.81 (sec) , antiderivative size = 220, normalized size of antiderivative = 1.03, number of steps used = 5, number of rules used = 4, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.087, Rules used = {1254, 1254, 1255, 218}

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 \frac {\sqrt {d+e x}}{(f+g x)^3 \sqrt {x \left (a e^2+c d^2\right )+a d e+c d e x^2}} \, dx\)

\(\Big \downarrow \) 1254

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

\(\Big \downarrow \) 1254

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

\(\Big \downarrow \) 1255

\(\displaystyle \frac {3 c d \left (\frac {c d e^2 \int \frac {1}{(c d f-a e g) e^2+\frac {g \left (c d e x^2+\left (c d^2+a e^2\right ) x+a d e\right ) e^2}{d+e x}}d\frac {\sqrt {c d e x^2+\left (c d^2+a e^2\right ) x+a d e}}{\sqrt {d+e x}}}{c d f-a e g}+\frac {\sqrt {x \left (a e^2+c d^2\right )+a d e+c d e x^2}}{\sqrt {d+e x} (f+g x) (c d f-a e g)}\right )}{4 (c d f-a e g)}+\frac {\sqrt {x \left (a e^2+c d^2\right )+a d e+c d e x^2}}{2 \sqrt {d+e x} (f+g x)^2 (c d f-a e g)}\)

\(\Big \downarrow \) 218

\(\displaystyle \frac {3 c d \left (\frac {c d \arctan \left (\frac {\sqrt {g} \sqrt {x \left (a e^2+c d^2\right )+a d e+c d e x^2}}{\sqrt {d+e x} \sqrt {c d f-a e g}}\right )}{\sqrt {g} (c d f-a e g)^{3/2}}+\frac {\sqrt {x \left (a e^2+c d^2\right )+a d e+c d e x^2}}{\sqrt {d+e x} (f+g x) (c d f-a e g)}\right )}{4 (c d f-a e g)}+\frac {\sqrt {x \left (a e^2+c d^2\right )+a d e+c d e x^2}}{2 \sqrt {d+e x} (f+g x)^2 (c d f-a e g)}\)

Input:

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

Output:

Sqrt[a*d*e + (c*d^2 + a*e^2)*x + c*d*e*x^2]/(2*(c*d*f - a*e*g)*Sqrt[d + e* 
x]*(f + g*x)^2) + (3*c*d*(Sqrt[a*d*e + (c*d^2 + a*e^2)*x + c*d*e*x^2]/((c* 
d*f - a*e*g)*Sqrt[d + e*x]*(f + g*x)) + (c*d*ArcTan[(Sqrt[g]*Sqrt[a*d*e + 
(c*d^2 + a*e^2)*x + c*d*e*x^2])/(Sqrt[c*d*f - a*e*g]*Sqrt[d + e*x])])/(Sqr 
t[g]*(c*d*f - a*e*g)^(3/2))))/(4*(c*d*f - a*e*g))
 

Defintions of rubi rules used

rule 218
Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(Rt[a/b, 2]/a)*ArcTan[x/R 
t[a/b, 2]], x] /; FreeQ[{a, b}, x] && PosQ[a/b]
 

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

rule 1255
Int[Sqrt[(d_) + (e_.)*(x_)]/(((f_.) + (g_.)*(x_))*Sqrt[(a_.) + (b_.)*(x_) + 
 (c_.)*(x_)^2]), x_Symbol] :> Simp[2*e^2   Subst[Int[1/(c*(e*f + d*g) - b*e 
*g + e^2*g*x^2), x], x, Sqrt[a + b*x + c*x^2]/Sqrt[d + e*x]], x] /; FreeQ[{ 
a, b, c, d, e, f, g}, x] && EqQ[c*d^2 - b*d*e + a*e^2, 0]
 
Maple [A] (verified)

Time = 2.90 (sec) , antiderivative size = 275, normalized size of antiderivative = 1.29

method result size
default \(-\frac {\sqrt {\left (e x +d \right ) \left (c d x +a e \right )}\, \left (3 \,\operatorname {arctanh}\left (\frac {g \sqrt {c d x +a e}}{\sqrt {\left (a e g -d f c \right ) g}}\right ) c^{2} d^{2} g^{2} x^{2}+6 \,\operatorname {arctanh}\left (\frac {g \sqrt {c d x +a e}}{\sqrt {\left (a e g -d f c \right ) g}}\right ) c^{2} d^{2} f g x +3 \,\operatorname {arctanh}\left (\frac {g \sqrt {c d x +a e}}{\sqrt {\left (a e g -d f c \right ) g}}\right ) c^{2} d^{2} f^{2}-3 c d g x \sqrt {c d x +a e}\, \sqrt {\left (a e g -d f c \right ) g}+2 \sqrt {\left (a e g -d f c \right ) g}\, \sqrt {c d x +a e}\, a e g -5 \sqrt {\left (a e g -d f c \right ) g}\, \sqrt {c d x +a e}\, c d f \right )}{4 \sqrt {e x +d}\, \sqrt {c d x +a e}\, \left (a e g -d f c \right )^{2} \left (g x +f \right )^{2} \sqrt {\left (a e g -d f c \right ) g}}\) \(275\)

Input:

int((e*x+d)^(1/2)/(g*x+f)^3/(a*d*e+(a*e^2+c*d^2)*x+c*d*x^2*e)^(1/2),x,meth 
od=_RETURNVERBOSE)
 

Output:

-1/4/(e*x+d)^(1/2)*((e*x+d)*(c*d*x+a*e))^(1/2)*(3*arctanh(g*(c*d*x+a*e)^(1 
/2)/((a*e*g-c*d*f)*g)^(1/2))*c^2*d^2*g^2*x^2+6*arctanh(g*(c*d*x+a*e)^(1/2) 
/((a*e*g-c*d*f)*g)^(1/2))*c^2*d^2*f*g*x+3*arctanh(g*(c*d*x+a*e)^(1/2)/((a* 
e*g-c*d*f)*g)^(1/2))*c^2*d^2*f^2-3*c*d*g*x*(c*d*x+a*e)^(1/2)*((a*e*g-c*d*f 
)*g)^(1/2)+2*((a*e*g-c*d*f)*g)^(1/2)*(c*d*x+a*e)^(1/2)*a*e*g-5*((a*e*g-c*d 
*f)*g)^(1/2)*(c*d*x+a*e)^(1/2)*c*d*f)/(c*d*x+a*e)^(1/2)/(a*e*g-c*d*f)^2/(g 
*x+f)^2/((a*e*g-c*d*f)*g)^(1/2)
 

Fricas [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 622 vs. \(2 (187) = 374\).

Time = 0.12 (sec) , antiderivative size = 1284, normalized size of antiderivative = 6.03 \[ \int \frac {\sqrt {d+e x}}{(f+g x)^3 \sqrt {a d e+\left (c d^2+a e^2\right ) x+c d e x^2}} \, dx=\text {Too large to display} \] Input:

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

Output:

[-1/8*(3*(c^2*d^2*e*g^2*x^3 + c^2*d^3*f^2 + (2*c^2*d^2*e*f*g + c^2*d^3*g^2 
)*x^2 + (c^2*d^2*e*f^2 + 2*c^2*d^3*f*g)*x)*sqrt(-c*d*f*g + a*e*g^2)*log(-( 
c*d*e*g*x^2 - c*d^2*f + 2*a*d*e*g - (c*d*e*f - (c*d^2 + 2*a*e^2)*g)*x - 2* 
sqrt(c*d*e*x^2 + a*d*e + (c*d^2 + a*e^2)*x)*sqrt(-c*d*f*g + a*e*g^2)*sqrt( 
e*x + d))/(e*g*x^2 + d*f + (e*f + d*g)*x)) - 2*(5*c^2*d^2*f^2*g - 7*a*c*d* 
e*f*g^2 + 2*a^2*e^2*g^3 + 3*(c^2*d^2*f*g^2 - a*c*d*e*g^3)*x)*sqrt(c*d*e*x^ 
2 + a*d*e + (c*d^2 + a*e^2)*x)*sqrt(e*x + d))/(c^3*d^4*f^5*g - 3*a*c^2*d^3 
*e*f^4*g^2 + 3*a^2*c*d^2*e^2*f^3*g^3 - a^3*d*e^3*f^2*g^4 + (c^3*d^3*e*f^3* 
g^3 - 3*a*c^2*d^2*e^2*f^2*g^4 + 3*a^2*c*d*e^3*f*g^5 - a^3*e^4*g^6)*x^3 + ( 
2*c^3*d^3*e*f^4*g^2 - a^3*d*e^3*g^6 + (c^3*d^4 - 6*a*c^2*d^2*e^2)*f^3*g^3 
- 3*(a*c^2*d^3*e - 2*a^2*c*d*e^3)*f^2*g^4 + (3*a^2*c*d^2*e^2 - 2*a^3*e^4)* 
f*g^5)*x^2 + (c^3*d^3*e*f^5*g - 2*a^3*d*e^3*f*g^5 + (2*c^3*d^4 - 3*a*c^2*d 
^2*e^2)*f^4*g^2 - 3*(2*a*c^2*d^3*e - a^2*c*d*e^3)*f^3*g^3 + (6*a^2*c*d^2*e 
^2 - a^3*e^4)*f^2*g^4)*x), -1/4*(3*(c^2*d^2*e*g^2*x^3 + c^2*d^3*f^2 + (2*c 
^2*d^2*e*f*g + c^2*d^3*g^2)*x^2 + (c^2*d^2*e*f^2 + 2*c^2*d^3*f*g)*x)*sqrt( 
c*d*f*g - a*e*g^2)*arctan(-sqrt(c*d*e*x^2 + a*d*e + (c*d^2 + a*e^2)*x)*sqr 
t(c*d*f*g - a*e*g^2)*sqrt(e*x + d)/(c*d^2*f - a*d*e*g + (c*d*e*f - a*e^2*g 
)*x)) - (5*c^2*d^2*f^2*g - 7*a*c*d*e*f*g^2 + 2*a^2*e^2*g^3 + 3*(c^2*d^2*f* 
g^2 - a*c*d*e*g^3)*x)*sqrt(c*d*e*x^2 + a*d*e + (c*d^2 + a*e^2)*x)*sqrt(e*x 
 + d))/(c^3*d^4*f^5*g - 3*a*c^2*d^3*e*f^4*g^2 + 3*a^2*c*d^2*e^2*f^3*g^3...
 

Sympy [F]

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

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

Output:

Integral(sqrt(d + e*x)/(sqrt((d + e*x)*(a*e + c*d*x))*(f + g*x)**3), x)
 

Maxima [F]

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

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

Output:

integrate(sqrt(e*x + d)/(sqrt(c*d*e*x^2 + a*d*e + (c*d^2 + a*e^2)*x)*(g*x 
+ f)^3), x)
 

Giac [A] (verification not implemented)

Time = 0.14 (sec) , antiderivative size = 306, normalized size of antiderivative = 1.44 \[ \int \frac {\sqrt {d+e x}}{(f+g x)^3 \sqrt {a d e+\left (c d^2+a e^2\right ) x+c d e x^2}} \, dx=\frac {1}{4} \, {\left (\frac {3 \, c^{2} d^{2} \arctan \left (\frac {\sqrt {{\left (e x + d\right )} c d e - c d^{2} e + a e^{3}} g}{\sqrt {c d f g - a e g^{2}} e}\right )}{{\left (c^{2} d^{2} e f^{2} {\left | e \right |} - 2 \, a c d e^{2} f g {\left | e \right |} + a^{2} e^{3} g^{2} {\left | e \right |}\right )} \sqrt {c d f g - a e g^{2}} e} + \frac {5 \, \sqrt {{\left (e x + d\right )} c d e - c d^{2} e + a e^{3}} c^{3} d^{3} e^{2} f - 5 \, \sqrt {{\left (e x + d\right )} c d e - c d^{2} e + a e^{3}} a c^{2} d^{2} e^{3} g + 3 \, {\left ({\left (e x + d\right )} c d e - c d^{2} e + a e^{3}\right )}^{\frac {3}{2}} c^{2} d^{2} g}{{\left (c^{2} d^{2} e f^{2} {\left | e \right |} - 2 \, a c d e^{2} f g {\left | e \right |} + a^{2} e^{3} g^{2} {\left | e \right |}\right )} {\left (c d e^{2} f - a e^{3} g + {\left ({\left (e x + d\right )} c d e - c d^{2} e + a e^{3}\right )} g\right )}^{2}}\right )} e^{3} \] Input:

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

Output:

1/4*(3*c^2*d^2*arctan(sqrt((e*x + d)*c*d*e - c*d^2*e + a*e^3)*g/(sqrt(c*d* 
f*g - a*e*g^2)*e))/((c^2*d^2*e*f^2*abs(e) - 2*a*c*d*e^2*f*g*abs(e) + a^2*e 
^3*g^2*abs(e))*sqrt(c*d*f*g - a*e*g^2)*e) + (5*sqrt((e*x + d)*c*d*e - c*d^ 
2*e + a*e^3)*c^3*d^3*e^2*f - 5*sqrt((e*x + d)*c*d*e - c*d^2*e + a*e^3)*a*c 
^2*d^2*e^3*g + 3*((e*x + d)*c*d*e - c*d^2*e + a*e^3)^(3/2)*c^2*d^2*g)/((c^ 
2*d^2*e*f^2*abs(e) - 2*a*c*d*e^2*f*g*abs(e) + a^2*e^3*g^2*abs(e))*(c*d*e^2 
*f - a*e^3*g + ((e*x + d)*c*d*e - c*d^2*e + a*e^3)*g)^2))*e^3
 

Mupad [F(-1)]

Timed out. \[ \int \frac {\sqrt {d+e x}}{(f+g x)^3 \sqrt {a d e+\left (c d^2+a e^2\right ) x+c d e x^2}} \, dx=\int \frac {\sqrt {d+e\,x}}{{\left (f+g\,x\right )}^3\,\sqrt {c\,d\,e\,x^2+\left (c\,d^2+a\,e^2\right )\,x+a\,d\,e}} \,d x \] Input:

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

Output:

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

Reduce [B] (verification not implemented)

Time = 0.41 (sec) , antiderivative size = 452, normalized size of antiderivative = 2.12 \[ \int \frac {\sqrt {d+e x}}{(f+g x)^3 \sqrt {a d e+\left (c d^2+a e^2\right ) x+c d e x^2}} \, dx=\frac {-3 \sqrt {g}\, \sqrt {-a e g +c d f}\, \mathit {atan} \left (\frac {\sqrt {c d x +a e}\, g}{\sqrt {g}\, \sqrt {-a e g +c d f}}\right ) c^{2} d^{2} f^{2}-6 \sqrt {g}\, \sqrt {-a e g +c d f}\, \mathit {atan} \left (\frac {\sqrt {c d x +a e}\, g}{\sqrt {g}\, \sqrt {-a e g +c d f}}\right ) c^{2} d^{2} f g x -3 \sqrt {g}\, \sqrt {-a e g +c d f}\, \mathit {atan} \left (\frac {\sqrt {c d x +a e}\, g}{\sqrt {g}\, \sqrt {-a e g +c d f}}\right ) c^{2} d^{2} g^{2} x^{2}-2 \sqrt {c d x +a e}\, a^{2} e^{2} g^{3}+7 \sqrt {c d x +a e}\, a c d e f \,g^{2}+3 \sqrt {c d x +a e}\, a c d e \,g^{3} x -5 \sqrt {c d x +a e}\, c^{2} d^{2} f^{2} g -3 \sqrt {c d x +a e}\, c^{2} d^{2} f \,g^{2} x}{4 g \left (a^{3} e^{3} g^{5} x^{2}-3 a^{2} c d \,e^{2} f \,g^{4} x^{2}+3 a \,c^{2} d^{2} e \,f^{2} g^{3} x^{2}-c^{3} d^{3} f^{3} g^{2} x^{2}+2 a^{3} e^{3} f \,g^{4} x -6 a^{2} c d \,e^{2} f^{2} g^{3} x +6 a \,c^{2} d^{2} e \,f^{3} g^{2} x -2 c^{3} d^{3} f^{4} g x +a^{3} e^{3} f^{2} g^{3}-3 a^{2} c d \,e^{2} f^{3} g^{2}+3 a \,c^{2} d^{2} e \,f^{4} g -c^{3} d^{3} f^{5}\right )} \] Input:

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

Output:

( - 3*sqrt(g)*sqrt( - a*e*g + c*d*f)*atan((sqrt(a*e + c*d*x)*g)/(sqrt(g)*s 
qrt( - a*e*g + c*d*f)))*c**2*d**2*f**2 - 6*sqrt(g)*sqrt( - a*e*g + c*d*f)* 
atan((sqrt(a*e + c*d*x)*g)/(sqrt(g)*sqrt( - a*e*g + c*d*f)))*c**2*d**2*f*g 
*x - 3*sqrt(g)*sqrt( - a*e*g + c*d*f)*atan((sqrt(a*e + c*d*x)*g)/(sqrt(g)* 
sqrt( - a*e*g + c*d*f)))*c**2*d**2*g**2*x**2 - 2*sqrt(a*e + c*d*x)*a**2*e* 
*2*g**3 + 7*sqrt(a*e + c*d*x)*a*c*d*e*f*g**2 + 3*sqrt(a*e + c*d*x)*a*c*d*e 
*g**3*x - 5*sqrt(a*e + c*d*x)*c**2*d**2*f**2*g - 3*sqrt(a*e + c*d*x)*c**2* 
d**2*f*g**2*x)/(4*g*(a**3*e**3*f**2*g**3 + 2*a**3*e**3*f*g**4*x + a**3*e** 
3*g**5*x**2 - 3*a**2*c*d*e**2*f**3*g**2 - 6*a**2*c*d*e**2*f**2*g**3*x - 3* 
a**2*c*d*e**2*f*g**4*x**2 + 3*a*c**2*d**2*e*f**4*g + 6*a*c**2*d**2*e*f**3* 
g**2*x + 3*a*c**2*d**2*e*f**2*g**3*x**2 - c**3*d**3*f**5 - 2*c**3*d**3*f** 
4*g*x - c**3*d**3*f**3*g**2*x**2))