\(\int \frac {4 a q x-3 b p x^2+a p x^4}{\sqrt {q+p x^3} (b^2 c+d q+2 a b c x^2+d p x^3+a^2 c x^4)} \, dx\) [572]

Optimal result
Mathematica [C] (warning: unable to verify)
Rubi [F]
Maple [C] (warning: unable to verify)
Fricas [B] (verification not implemented)
Sympy [F(-1)]
Maxima [F]
Giac [F(-1)]
Mupad [B] (verification not implemented)
Reduce [F]

Optimal result

Integrand size = 64, antiderivative size = 44 \[ \int \frac {4 a q x-3 b p x^2+a p x^4}{\sqrt {q+p x^3} \left (b^2 c+d q+2 a b c x^2+d p x^3+a^2 c x^4\right )} \, dx=-\frac {2 \arctan \left (\frac {\sqrt {d} \sqrt {q+p x^3}}{\sqrt {c} \left (b+a x^2\right )}\right )}{\sqrt {c} \sqrt {d}} \] Output:

-2*arctan(d^(1/2)*(p*x^3+q)^(1/2)/c^(1/2)/(a*x^2+b))/c^(1/2)/d^(1/2)
 

Mathematica [C] (warning: unable to verify)

Result contains higher order function than in optimal. Order 9 vs. order 3 in optimal.

Time = 16.85 (sec) , antiderivative size = 8031, normalized size of antiderivative = 182.52 \[ \int \frac {4 a q x-3 b p x^2+a p x^4}{\sqrt {q+p x^3} \left (b^2 c+d q+2 a b c x^2+d p x^3+a^2 c x^4\right )} \, dx=\text {Result too large to show} \] Input:

Integrate[(4*a*q*x - 3*b*p*x^2 + a*p*x^4)/(Sqrt[q + p*x^3]*(b^2*c + d*q + 
2*a*b*c*x^2 + d*p*x^3 + a^2*c*x^4)),x]
 

Output:

Result too large to show
 

Rubi [F]

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 {a p x^4+4 a q x-3 b p x^2}{\sqrt {p x^3+q} \left (a^2 c x^4+2 a b c x^2+b^2 c+d p x^3+d q\right )} \, dx\)

\(\Big \downarrow \) 2028

\(\displaystyle \int \frac {x \left (a p x^3+4 a q-3 b p x\right )}{\sqrt {p x^3+q} \left (a^2 c x^4+2 a b c x^2+b^2 c+d p x^3+d q\right )}dx\)

\(\Big \downarrow \) 7293

\(\displaystyle \int \left (\frac {p}{a c \sqrt {p x^3+q}}-\frac {-4 a^2 c q x+5 a b c p x^2+p \left (b^2 c+d q\right )+d p^2 x^3}{a c \sqrt {p x^3+q} \left (a^2 c x^4+2 a b c x^2+b^2 c+d p x^3+d q\right )}\right )dx\)

\(\Big \downarrow \) 2009

\(\displaystyle -\frac {d p^2 \int \frac {x^3}{\sqrt {p x^3+q} \left (a^2 c x^4+d p x^3+2 a b c x^2+b^2 c+d q\right )}dx}{a c}-\frac {p \left (b^2 c+d q\right ) \int \frac {1}{\sqrt {p x^3+q} \left (a^2 c x^4+d p x^3+2 a b c x^2+b^2 c+d q\right )}dx}{a c}-5 b p \int \frac {x^2}{\sqrt {p x^3+q} \left (a^2 c x^4+d p x^3+2 a b c x^2+b^2 c+d q\right )}dx+4 a q \int \frac {x}{\sqrt {p x^3+q} \left (a^2 c x^4+d p x^3+2 a b c x^2+b^2 c+d q\right )}dx+\frac {2 \sqrt {2+\sqrt {3}} p^{2/3} \left (\sqrt [3]{p} x+\sqrt [3]{q}\right ) \sqrt {\frac {p^{2/3} x^2-\sqrt [3]{p} \sqrt [3]{q} x+q^{2/3}}{\left (\sqrt [3]{p} x+\left (1+\sqrt {3}\right ) \sqrt [3]{q}\right )^2}} \operatorname {EllipticF}\left (\arcsin \left (\frac {\sqrt [3]{p} x+\left (1-\sqrt {3}\right ) \sqrt [3]{q}}{\sqrt [3]{p} x+\left (1+\sqrt {3}\right ) \sqrt [3]{q}}\right ),-7-4 \sqrt {3}\right )}{\sqrt [4]{3} a c \sqrt {\frac {\sqrt [3]{q} \left (\sqrt [3]{p} x+\sqrt [3]{q}\right )}{\left (\sqrt [3]{p} x+\left (1+\sqrt {3}\right ) \sqrt [3]{q}\right )^2}} \sqrt {p x^3+q}}\)

Input:

Int[(4*a*q*x - 3*b*p*x^2 + a*p*x^4)/(Sqrt[q + p*x^3]*(b^2*c + d*q + 2*a*b* 
c*x^2 + d*p*x^3 + a^2*c*x^4)),x]
 

Output:

$Aborted
 
Maple [C] (warning: unable to verify)

Result contains higher order function than in optimal. Order 9 vs. order 3.

Time = 1.74 (sec) , antiderivative size = 3170, normalized size of antiderivative = 72.05

method result size
default \(\text {Expression too large to display}\) \(3170\)
elliptic \(\text {Expression too large to display}\) \(3170\)

Input:

int((a*p*x^4-3*b*p*x^2+4*a*q*x)/(p*x^3+q)^(1/2)/(a^2*c*x^4+2*a*b*c*x^2+d*p 
*x^3+b^2*c+d*q),x,method=_RETURNVERBOSE)
 

Output:

-2/3*I/a/c*3^(1/2)*(-q*p^2)^(1/3)*(I*(x+1/2/p*(-q*p^2)^(1/3)-1/2*I*3^(1/2) 
/p*(-q*p^2)^(1/3))*3^(1/2)*p/(-q*p^2)^(1/3))^(1/2)*((x-1/p*(-q*p^2)^(1/3)) 
/(-3/2/p*(-q*p^2)^(1/3)+1/2*I*3^(1/2)/p*(-q*p^2)^(1/3)))^(1/2)*(-I*(x+1/2/ 
p*(-q*p^2)^(1/3)+1/2*I*3^(1/2)/p*(-q*p^2)^(1/3))*3^(1/2)*p/(-q*p^2)^(1/3)) 
^(1/2)/(p*x^3+q)^(1/2)*EllipticF(1/3*3^(1/2)*(I*(x+1/2/p*(-q*p^2)^(1/3)-1/ 
2*I*3^(1/2)/p*(-q*p^2)^(1/3))*3^(1/2)*p/(-q*p^2)^(1/3))^(1/2),(I*3^(1/2)/p 
*(-q*p^2)^(1/3)/(-3/2/p*(-q*p^2)^(1/3)+1/2*I*3^(1/2)/p*(-q*p^2)^(1/3)))^(1 
/2))-I/a/c^2/p^2*2^(1/2)*sum((_alpha^3*d*p^2+5*_alpha^2*a*b*c*p-4*_alpha*a 
^2*c*q+b^2*c*p+d*p*q)/_alpha/(4*_alpha^2*a^2*c+3*_alpha*d*p+4*a*b*c)/(a^6* 
q^4+2*a^3*b^3*p^2*q^2+b^6*p^4)*(-q*p^2)^(1/3)*(1/2*I*p*(2*x+1/p*(-I*3^(1/2 
)*(-q*p^2)^(1/3)+(-q*p^2)^(1/3)))/(-q*p^2)^(1/3))^(1/2)*(p*(x-1/p*(-q*p^2) 
^(1/3))/(-3*(-q*p^2)^(1/3)+I*3^(1/2)*(-q*p^2)^(1/3)))^(1/2)*(-1/2*I*p*(2*x 
+1/p*(I*3^(1/2)*(-q*p^2)^(1/3)+(-q*p^2)^(1/3)))/(-q*p^2)^(1/3))^(1/2)/(p*x 
^3+q)^(1/2)*((-q*p^2)^(2/3)*b^4*d*p^4+I*(-q*p^2)^(1/3)*3^(1/2)*a^4*d*q^3*p 
^2-2*I*(-q*p^2)^(1/3)*p^4*3^(1/2)*a*b^5*c+2*p^2*(2*_alpha^3*a^5*b*c*p*q^2- 
_alpha^3*a^2*b^4*c*p^3+_alpha^2*a^6*c*q^3-2*_alpha^2*a^3*b^3*c*p^2*q+2*_al 
pha^2*a^3*b*d*p^2*q^2-_alpha^2*b^4*d*p^4+_alpha*a^4*b^2*c*p*q^2-2*_alpha*a 
*b^5*c*p^3+_alpha*a^4*d*p*q^3-2*_alpha*a*b^3*d*p^3*q-3*a^2*b^4*c*p^2*q-3*a 
^2*b^2*d*p^2*q^2)-(-q*p^2)^(2/3)*a^6*c*q^3+2*(-q*p^2)^(1/3)*a*b^5*c*p^4-(- 
q*p^2)^(1/3)*a^4*d*p^2*q^3+(-q*p^2)^(1/3)*_alpha*b^4*d*p^5+I*(-q*p^2)^(...
 

Fricas [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 94 vs. \(2 (34) = 68\).

Time = 2.23 (sec) , antiderivative size = 471, normalized size of antiderivative = 10.70 \[ \int \frac {4 a q x-3 b p x^2+a p x^4}{\sqrt {q+p x^3} \left (b^2 c+d q+2 a b c x^2+d p x^3+a^2 c x^4\right )} \, dx=\left [-\frac {\sqrt {-c d} \log \left (\frac {a^{4} c^{2} x^{8} - 6 \, a^{2} c d p x^{7} - 12 \, a b c d p x^{5} + {\left (4 \, a^{3} b c^{2} + d^{2} p^{2}\right )} x^{6} + b^{4} c^{2} - 6 \, b^{2} c d q + 6 \, {\left (a^{2} b^{2} c^{2} - a^{2} c d q\right )} x^{4} + d^{2} q^{2} - 2 \, {\left (3 \, b^{2} c d p - d^{2} p q\right )} x^{3} + 4 \, {\left (a b^{3} c^{2} - 3 \, a b c d q\right )} x^{2} - 4 \, {\left (a^{3} c x^{6} + 3 \, a^{2} b c x^{4} - a d p x^{5} - b d p x^{3} + b^{3} c - b d q + {\left (3 \, a b^{2} c - a d q\right )} x^{2}\right )} \sqrt {p x^{3} + q} \sqrt {-c d}}{a^{4} c^{2} x^{8} + 2 \, a^{2} c d p x^{7} + 4 \, a b c d p x^{5} + {\left (4 \, a^{3} b c^{2} + d^{2} p^{2}\right )} x^{6} + b^{4} c^{2} + 2 \, b^{2} c d q + 2 \, {\left (3 \, a^{2} b^{2} c^{2} + a^{2} c d q\right )} x^{4} + d^{2} q^{2} + 2 \, {\left (b^{2} c d p + d^{2} p q\right )} x^{3} + 4 \, {\left (a b^{3} c^{2} + a b c d q\right )} x^{2}}\right )}{2 \, c d}, \frac {\sqrt {c d} \arctan \left (\frac {{\left (a^{2} c x^{4} + 2 \, a b c x^{2} - d p x^{3} + b^{2} c - d q\right )} \sqrt {p x^{3} + q} \sqrt {c d}}{2 \, {\left (a c d p x^{5} + b c d p x^{3} + a c d q x^{2} + b c d q\right )}}\right )}{c d}\right ] \] Input:

integrate((a*p*x^4-3*b*p*x^2+4*a*q*x)/(p*x^3+q)^(1/2)/(a^2*c*x^4+2*a*b*c*x 
^2+d*p*x^3+b^2*c+d*q),x, algorithm="fricas")
 

Output:

[-1/2*sqrt(-c*d)*log((a^4*c^2*x^8 - 6*a^2*c*d*p*x^7 - 12*a*b*c*d*p*x^5 + ( 
4*a^3*b*c^2 + d^2*p^2)*x^6 + b^4*c^2 - 6*b^2*c*d*q + 6*(a^2*b^2*c^2 - a^2* 
c*d*q)*x^4 + d^2*q^2 - 2*(3*b^2*c*d*p - d^2*p*q)*x^3 + 4*(a*b^3*c^2 - 3*a* 
b*c*d*q)*x^2 - 4*(a^3*c*x^6 + 3*a^2*b*c*x^4 - a*d*p*x^5 - b*d*p*x^3 + b^3* 
c - b*d*q + (3*a*b^2*c - a*d*q)*x^2)*sqrt(p*x^3 + q)*sqrt(-c*d))/(a^4*c^2* 
x^8 + 2*a^2*c*d*p*x^7 + 4*a*b*c*d*p*x^5 + (4*a^3*b*c^2 + d^2*p^2)*x^6 + b^ 
4*c^2 + 2*b^2*c*d*q + 2*(3*a^2*b^2*c^2 + a^2*c*d*q)*x^4 + d^2*q^2 + 2*(b^2 
*c*d*p + d^2*p*q)*x^3 + 4*(a*b^3*c^2 + a*b*c*d*q)*x^2))/(c*d), sqrt(c*d)*a 
rctan(1/2*(a^2*c*x^4 + 2*a*b*c*x^2 - d*p*x^3 + b^2*c - d*q)*sqrt(p*x^3 + q 
)*sqrt(c*d)/(a*c*d*p*x^5 + b*c*d*p*x^3 + a*c*d*q*x^2 + b*c*d*q))/(c*d)]
 

Sympy [F(-1)]

Timed out. \[ \int \frac {4 a q x-3 b p x^2+a p x^4}{\sqrt {q+p x^3} \left (b^2 c+d q+2 a b c x^2+d p x^3+a^2 c x^4\right )} \, dx=\text {Timed out} \] Input:

integrate((a*p*x**4-3*b*p*x**2+4*a*q*x)/(p*x**3+q)**(1/2)/(a**2*c*x**4+2*a 
*b*c*x**2+d*p*x**3+b**2*c+d*q),x)
 

Output:

Timed out
 

Maxima [F]

\[ \int \frac {4 a q x-3 b p x^2+a p x^4}{\sqrt {q+p x^3} \left (b^2 c+d q+2 a b c x^2+d p x^3+a^2 c x^4\right )} \, dx=\int { \frac {a p x^{4} - 3 \, b p x^{2} + 4 \, a q x}{{\left (a^{2} c x^{4} + 2 \, a b c x^{2} + d p x^{3} + b^{2} c + d q\right )} \sqrt {p x^{3} + q}} \,d x } \] Input:

integrate((a*p*x^4-3*b*p*x^2+4*a*q*x)/(p*x^3+q)^(1/2)/(a^2*c*x^4+2*a*b*c*x 
^2+d*p*x^3+b^2*c+d*q),x, algorithm="maxima")
 

Output:

integrate((a*p*x^4 - 3*b*p*x^2 + 4*a*q*x)/((a^2*c*x^4 + 2*a*b*c*x^2 + d*p* 
x^3 + b^2*c + d*q)*sqrt(p*x^3 + q)), x)
 

Giac [F(-1)]

Timed out. \[ \int \frac {4 a q x-3 b p x^2+a p x^4}{\sqrt {q+p x^3} \left (b^2 c+d q+2 a b c x^2+d p x^3+a^2 c x^4\right )} \, dx=\text {Timed out} \] Input:

integrate((a*p*x^4-3*b*p*x^2+4*a*q*x)/(p*x^3+q)^(1/2)/(a^2*c*x^4+2*a*b*c*x 
^2+d*p*x^3+b^2*c+d*q),x, algorithm="giac")
 

Output:

Timed out
 

Mupad [B] (verification not implemented)

Time = 97.16 (sec) , antiderivative size = 1058, normalized size of antiderivative = 24.05 \[ \int \frac {4 a q x-3 b p x^2+a p x^4}{\sqrt {q+p x^3} \left (b^2 c+d q+2 a b c x^2+d p x^3+a^2 c x^4\right )} \, dx =\text {Too large to display} \] Input:

int((a*p*x^4 - 3*b*p*x^2 + 4*a*q*x)/((q + p*x^3)^(1/2)*(d*q + b^2*c + d*p* 
x^3 + a^2*c*x^4 + 2*a*b*c*x^2)),x)
 

Output:

(log(((a^2*c*x^2*1i + a*b*c*1i - d*p*x*1i - 2*a*c^(1/2)*d^(1/2)*(q + p*x^3 
)^(1/2))*(a^4*b^2*c^2*q*1i + a^6*c^2*q*x^4*1i - b^2*d^2*p^3*x*1i + a^4*c*d 
*q^2*4i + a*b^3*c*d*p^2*1i + a^3*b^3*c^2*p*x*1i + a^5*b*c^2*p*x^5*1i + a*b 
*d^2*p^3*x^3*1i + a^5*b*c^2*q*x^2*2i + a^4*b^2*c^2*p*x^3*2i + a^2*d^2*p^2* 
q*x^2*1i - a^2*b^2*c*d*p^2*x^2*1i + a^4*c*d*p*q*x^3*2i + 2*a*b^2*c^(1/2)*d 
^(3/2)*p^2*(q + p*x^3)^(1/2) + a^3*b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+ 2...
 

Reduce [F]

\[ \int \frac {4 a q x-3 b p x^2+a p x^4}{\sqrt {q+p x^3} \left (b^2 c+d q+2 a b c x^2+d p x^3+a^2 c x^4\right )} \, dx=\left (\int \frac {\sqrt {p \,x^{3}+q}\, x^{4}}{a^{2} c p \,x^{7}+2 a b c p \,x^{5}+d \,p^{2} x^{6}+a^{2} c q \,x^{4}+b^{2} c p \,x^{3}+2 a b c q \,x^{2}+2 d p q \,x^{3}+b^{2} c q +d \,q^{2}}d x \right ) a p -3 \left (\int \frac {\sqrt {p \,x^{3}+q}\, x^{2}}{a^{2} c p \,x^{7}+2 a b c p \,x^{5}+d \,p^{2} x^{6}+a^{2} c q \,x^{4}+b^{2} c p \,x^{3}+2 a b c q \,x^{2}+2 d p q \,x^{3}+b^{2} c q +d \,q^{2}}d x \right ) b p +4 \left (\int \frac {\sqrt {p \,x^{3}+q}\, x}{a^{2} c p \,x^{7}+2 a b c p \,x^{5}+d \,p^{2} x^{6}+a^{2} c q \,x^{4}+b^{2} c p \,x^{3}+2 a b c q \,x^{2}+2 d p q \,x^{3}+b^{2} c q +d \,q^{2}}d x \right ) a q \] Input:

int((a*p*x^4-3*b*p*x^2+4*a*q*x)/(p*x^3+q)^(1/2)/(a^2*c*x^4+2*a*b*c*x^2+d*p 
*x^3+b^2*c+d*q),x)
 

Output:

int((sqrt(p*x**3 + q)*x**4)/(a**2*c*p*x**7 + a**2*c*q*x**4 + 2*a*b*c*p*x** 
5 + 2*a*b*c*q*x**2 + b**2*c*p*x**3 + b**2*c*q + d*p**2*x**6 + 2*d*p*q*x**3 
 + d*q**2),x)*a*p - 3*int((sqrt(p*x**3 + q)*x**2)/(a**2*c*p*x**7 + a**2*c* 
q*x**4 + 2*a*b*c*p*x**5 + 2*a*b*c*q*x**2 + b**2*c*p*x**3 + b**2*c*q + d*p* 
*2*x**6 + 2*d*p*q*x**3 + d*q**2),x)*b*p + 4*int((sqrt(p*x**3 + q)*x)/(a**2 
*c*p*x**7 + a**2*c*q*x**4 + 2*a*b*c*p*x**5 + 2*a*b*c*q*x**2 + b**2*c*p*x** 
3 + b**2*c*q + d*p**2*x**6 + 2*d*p*q*x**3 + d*q**2),x)*a*q