\(\int \frac {A+B x+C x^2+D x^3}{(c+d x) (c^2-d^2 x^2)^{3/2}} \, dx\) [181]

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

Optimal result

Integrand size = 39, antiderivative size = 155 \[ \int \frac {A+B x+C x^2+D x^3}{(c+d x) \left (c^2-d^2 x^2\right )^{3/2}} \, dx=-\frac {c^2 C d-B c d^2+A d^3-c^3 D}{3 c d^4 (c+d x) \sqrt {c^2-d^2 x^2}}+\frac {3 c^3 (C d-c D)-d \left (c^2 C d-B c d^2-2 A d^3-4 c^3 D\right ) x}{3 c^3 d^4 \sqrt {c^2-d^2 x^2}}-\frac {D \arctan \left (\frac {d x}{\sqrt {c^2-d^2 x^2}}\right )}{d^4} \] Output:

-1/3*(A*d^3-B*c*d^2+C*c^2*d-D*c^3)/c/d^4/(d*x+c)/(-d^2*x^2+c^2)^(1/2)+1/3* 
(3*c^3*(C*d-D*c)-d*(-2*A*d^3-B*c*d^2+C*c^2*d-4*D*c^3)*x)/c^3/d^4/(-d^2*x^2 
+c^2)^(1/2)-D*arctan(d*x/(-d^2*x^2+c^2)^(1/2))/d^4
 

Mathematica [A] (verified)

Time = 0.94 (sec) , antiderivative size = 156, normalized size of antiderivative = 1.01 \[ \int \frac {A+B x+C x^2+D x^3}{(c+d x) \left (c^2-d^2 x^2\right )^{3/2}} \, dx=\frac {\frac {\sqrt {c^2-d^2 x^2} \left (-2 c^5 D+2 A d^5 x^2+c d^4 x (2 A+B x)+c^4 d (2 C+D x)-c^2 d^3 (A+x (-B+C x))+c^3 d^2 (B+2 x (C+2 D x))\right )}{c^3 (c-d x) (c+d x)^2}+6 D \arctan \left (\frac {d x}{\sqrt {c^2}-\sqrt {c^2-d^2 x^2}}\right )}{3 d^4} \] Input:

Integrate[(A + B*x + C*x^2 + D*x^3)/((c + d*x)*(c^2 - d^2*x^2)^(3/2)),x]
 

Output:

((Sqrt[c^2 - d^2*x^2]*(-2*c^5*D + 2*A*d^5*x^2 + c*d^4*x*(2*A + B*x) + c^4* 
d*(2*C + D*x) - c^2*d^3*(A + x*(-B + C*x)) + c^3*d^2*(B + 2*x*(C + 2*D*x)) 
))/(c^3*(c - d*x)*(c + d*x)^2) + 6*D*ArcTan[(d*x)/(Sqrt[c^2] - Sqrt[c^2 - 
d^2*x^2])])/(3*d^4)
 

Rubi [A] (verified)

Time = 0.79 (sec) , antiderivative size = 229, normalized size of antiderivative = 1.48, number of steps used = 2, number of rules used = 2, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.051, Rules used = {2168, 2009}

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+B x+C x^2+D x^3}{(c+d x) \left (c^2-d^2 x^2\right )^{3/2}} \, dx\)

\(\Big \downarrow \) 2168

\(\displaystyle \int \left (\frac {A d^3-B c d^2+c^3 (-D)+c^2 C d}{d^3 (c+d x) \left (c^2-d^2 x^2\right )^{3/2}}+\frac {B d^2+c^2 D-c C d}{d^3 \left (c^2-d^2 x^2\right )^{3/2}}+\frac {x (C d-c D)}{d^2 \left (c^2-d^2 x^2\right )^{3/2}}+\frac {D x^2}{d \left (c^2-d^2 x^2\right )^{3/2}}\right )dx\)

\(\Big \downarrow \) 2009

\(\displaystyle \frac {2 x \left (A d^3-B c d^2+c^3 (-D)+c^2 C d\right )}{3 c^3 d^3 \sqrt {c^2-d^2 x^2}}-\frac {A d^3-B c d^2+c^3 (-D)+c^2 C d}{3 c d^4 (c+d x) \sqrt {c^2-d^2 x^2}}-\frac {D \arctan \left (\frac {d x}{\sqrt {c^2-d^2 x^2}}\right )}{d^4}-\frac {x \left (-B d^2+c^2 (-D)+c C d\right )}{c^2 d^3 \sqrt {c^2-d^2 x^2}}+\frac {C d-c D}{d^4 \sqrt {c^2-d^2 x^2}}+\frac {D x}{d^3 \sqrt {c^2-d^2 x^2}}\)

Input:

Int[(A + B*x + C*x^2 + D*x^3)/((c + d*x)*(c^2 - d^2*x^2)^(3/2)),x]
 

Output:

(C*d - c*D)/(d^4*Sqrt[c^2 - d^2*x^2]) + (D*x)/(d^3*Sqrt[c^2 - d^2*x^2]) - 
((c*C*d - B*d^2 - c^2*D)*x)/(c^2*d^3*Sqrt[c^2 - d^2*x^2]) + (2*(c^2*C*d - 
B*c*d^2 + A*d^3 - c^3*D)*x)/(3*c^3*d^3*Sqrt[c^2 - d^2*x^2]) - (c^2*C*d - B 
*c*d^2 + A*d^3 - c^3*D)/(3*c*d^4*(c + d*x)*Sqrt[c^2 - d^2*x^2]) - (D*ArcTa 
n[(d*x)/Sqrt[c^2 - d^2*x^2]])/d^4
 

Defintions of rubi rules used

rule 2009
Int[u_, x_Symbol] :> Simp[IntSum[u, x], x] /; SumQ[u]
 

rule 2168
Int[(Pq_)*((d_) + (e_.)*(x_))^(m_)*((a_) + (b_.)*(x_)^2)^(p_), x_Symbol] :> 
 Int[ExpandIntegrand[(a + b*x^2)^p, (d + e*x)^m*Pq, x], x] /; FreeQ[{a, b, 
d, e}, x] && PolyQ[Pq, x] && EqQ[b*d^2 + a*e^2, 0] && EqQ[m + Expon[Pq, x] 
+ 2*p + 1, 0] && ILtQ[m, 0]
 
Maple [A] (verified)

Time = 0.44 (sec) , antiderivative size = 280, normalized size of antiderivative = 1.81

method result size
default \(\frac {\frac {B \,d^{2} x}{c^{2} \sqrt {-d^{2} x^{2}+c^{2}}}+\frac {D x}{\sqrt {-d^{2} x^{2}+c^{2}}}+\frac {C d -D c}{d \sqrt {-d^{2} x^{2}+c^{2}}}+D d^{2} \left (\frac {x}{\sqrt {-d^{2} x^{2}+c^{2}}\, d^{2}}-\frac {\arctan \left (\frac {\sqrt {d^{2}}\, x}{\sqrt {-d^{2} x^{2}+c^{2}}}\right )}{d^{2} \sqrt {d^{2}}}\right )-\frac {C d x}{c \sqrt {-d^{2} x^{2}+c^{2}}}}{d^{3}}+\frac {\left (A \,d^{3}-B c \,d^{2}+C \,c^{2} d -D c^{3}\right ) \left (-\frac {1}{3 c d \left (x +\frac {c}{d}\right ) \sqrt {-d^{2} \left (x +\frac {c}{d}\right )^{2}+2 c d \left (x +\frac {c}{d}\right )}}-\frac {-2 d^{2} \left (x +\frac {c}{d}\right )+2 c d}{3 d \,c^{3} \sqrt {-d^{2} \left (x +\frac {c}{d}\right )^{2}+2 c d \left (x +\frac {c}{d}\right )}}\right )}{d^{4}}\) \(280\)

Input:

int((D*x^3+C*x^2+B*x+A)/(d*x+c)/(-d^2*x^2+c^2)^(3/2),x,method=_RETURNVERBO 
SE)
 

Output:

1/d^3*(B*d^2*x/c^2/(-d^2*x^2+c^2)^(1/2)+D*x/(-d^2*x^2+c^2)^(1/2)+1/d*(C*d- 
D*c)/(-d^2*x^2+c^2)^(1/2)+D*d^2*(1/(-d^2*x^2+c^2)^(1/2)/d^2*x-1/d^2/(d^2)^ 
(1/2)*arctan((d^2)^(1/2)*x/(-d^2*x^2+c^2)^(1/2)))-C/c*d*x/(-d^2*x^2+c^2)^( 
1/2))+(A*d^3-B*c*d^2+C*c^2*d-D*c^3)/d^4*(-1/3/c/d/(x+c/d)/(-d^2*(x+c/d)^2+ 
2*c*d*(x+c/d))^(1/2)-1/3/d/c^3*(-2*d^2*(x+c/d)+2*c*d)/(-d^2*(x+c/d)^2+2*c* 
d*(x+c/d))^(1/2))
 

Fricas [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 366 vs. \(2 (145) = 290\).

Time = 0.11 (sec) , antiderivative size = 366, normalized size of antiderivative = 2.36 \[ \int \frac {A+B x+C x^2+D x^3}{(c+d x) \left (c^2-d^2 x^2\right )^{3/2}} \, dx=\frac {2 \, D c^{6} - 2 \, C c^{5} d - B c^{4} d^{2} + A c^{3} d^{3} - {\left (2 \, D c^{3} d^{3} - 2 \, C c^{2} d^{4} - B c d^{5} + A d^{6}\right )} x^{3} - {\left (2 \, D c^{4} d^{2} - 2 \, C c^{3} d^{3} - B c^{2} d^{4} + A c d^{5}\right )} x^{2} + {\left (2 \, D c^{5} d - 2 \, C c^{4} d^{2} - B c^{3} d^{3} + A c^{2} d^{4}\right )} x + 6 \, {\left (D c^{3} d^{3} x^{3} + D c^{4} d^{2} x^{2} - D c^{5} d x - D c^{6}\right )} \arctan \left (-\frac {c - \sqrt {-d^{2} x^{2} + c^{2}}}{d x}\right ) + {\left (2 \, D c^{5} - 2 \, C c^{4} d - B c^{3} d^{2} + A c^{2} d^{3} - {\left (4 \, D c^{3} d^{2} - C c^{2} d^{3} + B c d^{4} + 2 \, A d^{5}\right )} x^{2} - {\left (D c^{4} d + 2 \, C c^{3} d^{2} + B c^{2} d^{3} + 2 \, A c d^{4}\right )} x\right )} \sqrt {-d^{2} x^{2} + c^{2}}}{3 \, {\left (c^{3} d^{7} x^{3} + c^{4} d^{6} x^{2} - c^{5} d^{5} x - c^{6} d^{4}\right )}} \] Input:

integrate((D*x^3+C*x^2+B*x+A)/(d*x+c)/(-d^2*x^2+c^2)^(3/2),x, algorithm="f 
ricas")
 

Output:

1/3*(2*D*c^6 - 2*C*c^5*d - B*c^4*d^2 + A*c^3*d^3 - (2*D*c^3*d^3 - 2*C*c^2* 
d^4 - B*c*d^5 + A*d^6)*x^3 - (2*D*c^4*d^2 - 2*C*c^3*d^3 - B*c^2*d^4 + A*c* 
d^5)*x^2 + (2*D*c^5*d - 2*C*c^4*d^2 - B*c^3*d^3 + A*c^2*d^4)*x + 6*(D*c^3* 
d^3*x^3 + D*c^4*d^2*x^2 - D*c^5*d*x - D*c^6)*arctan(-(c - sqrt(-d^2*x^2 + 
c^2))/(d*x)) + (2*D*c^5 - 2*C*c^4*d - B*c^3*d^2 + A*c^2*d^3 - (4*D*c^3*d^2 
 - C*c^2*d^3 + B*c*d^4 + 2*A*d^5)*x^2 - (D*c^4*d + 2*C*c^3*d^2 + B*c^2*d^3 
 + 2*A*c*d^4)*x)*sqrt(-d^2*x^2 + c^2))/(c^3*d^7*x^3 + c^4*d^6*x^2 - c^5*d^ 
5*x - c^6*d^4)
 

Sympy [F]

\[ \int \frac {A+B x+C x^2+D x^3}{(c+d x) \left (c^2-d^2 x^2\right )^{3/2}} \, dx=\int \frac {A + B x + C x^{2} + D x^{3}}{\left (- \left (- c + d x\right ) \left (c + d x\right )\right )^{\frac {3}{2}} \left (c + d x\right )}\, dx \] Input:

integrate((D*x**3+C*x**2+B*x+A)/(d*x+c)/(-d**2*x**2+c**2)**(3/2),x)
 

Output:

Integral((A + B*x + C*x**2 + D*x**3)/((-(-c + d*x)*(c + d*x))**(3/2)*(c + 
d*x)), x)
 

Maxima [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 337 vs. \(2 (145) = 290\).

Time = 0.13 (sec) , antiderivative size = 337, normalized size of antiderivative = 2.17 \[ \int \frac {A+B x+C x^2+D x^3}{(c+d x) \left (c^2-d^2 x^2\right )^{3/2}} \, dx=\frac {D c^{3}}{3 \, {\left (\sqrt {-d^{2} x^{2} + c^{2}} c d^{5} x + \sqrt {-d^{2} x^{2} + c^{2}} c^{2} d^{4}\right )}} - \frac {C c^{2}}{3 \, {\left (\sqrt {-d^{2} x^{2} + c^{2}} c d^{4} x + \sqrt {-d^{2} x^{2} + c^{2}} c^{2} d^{3}\right )}} + \frac {B c}{3 \, {\left (\sqrt {-d^{2} x^{2} + c^{2}} c d^{3} x + \sqrt {-d^{2} x^{2} + c^{2}} c^{2} d^{2}\right )}} - \frac {A}{3 \, {\left (\sqrt {-d^{2} x^{2} + c^{2}} c d^{2} x + \sqrt {-d^{2} x^{2} + c^{2}} c^{2} d\right )}} + \frac {2 \, A x}{3 \, \sqrt {-d^{2} x^{2} + c^{2}} c^{3}} + \frac {4 \, D x}{3 \, \sqrt {-d^{2} x^{2} + c^{2}} d^{3}} - \frac {C x}{3 \, \sqrt {-d^{2} x^{2} + c^{2}} c d^{2}} + \frac {B x}{3 \, \sqrt {-d^{2} x^{2} + c^{2}} c^{2} d} - \frac {D \arcsin \left (\frac {d x}{c}\right )}{d^{4}} - \frac {D c}{\sqrt {-d^{2} x^{2} + c^{2}} d^{4}} + \frac {C}{\sqrt {-d^{2} x^{2} + c^{2}} d^{3}} \] Input:

integrate((D*x^3+C*x^2+B*x+A)/(d*x+c)/(-d^2*x^2+c^2)^(3/2),x, algorithm="m 
axima")
 

Output:

1/3*D*c^3/(sqrt(-d^2*x^2 + c^2)*c*d^5*x + sqrt(-d^2*x^2 + c^2)*c^2*d^4) - 
1/3*C*c^2/(sqrt(-d^2*x^2 + c^2)*c*d^4*x + sqrt(-d^2*x^2 + c^2)*c^2*d^3) + 
1/3*B*c/(sqrt(-d^2*x^2 + c^2)*c*d^3*x + sqrt(-d^2*x^2 + c^2)*c^2*d^2) - 1/ 
3*A/(sqrt(-d^2*x^2 + c^2)*c*d^2*x + sqrt(-d^2*x^2 + c^2)*c^2*d) + 2/3*A*x/ 
(sqrt(-d^2*x^2 + c^2)*c^3) + 4/3*D*x/(sqrt(-d^2*x^2 + c^2)*d^3) - 1/3*C*x/ 
(sqrt(-d^2*x^2 + c^2)*c*d^2) + 1/3*B*x/(sqrt(-d^2*x^2 + c^2)*c^2*d) - D*ar 
csin(d*x/c)/d^4 - D*c/(sqrt(-d^2*x^2 + c^2)*d^4) + C/(sqrt(-d^2*x^2 + c^2) 
*d^3)
 

Giac [F]

\[ \int \frac {A+B x+C x^2+D x^3}{(c+d x) \left (c^2-d^2 x^2\right )^{3/2}} \, dx=\int { \frac {D x^{3} + C x^{2} + B x + A}{{\left (-d^{2} x^{2} + c^{2}\right )}^{\frac {3}{2}} {\left (d x + c\right )}} \,d x } \] Input:

integrate((D*x^3+C*x^2+B*x+A)/(d*x+c)/(-d^2*x^2+c^2)^(3/2),x, algorithm="g 
iac")
 

Output:

integrate((D*x^3 + C*x^2 + B*x + A)/((-d^2*x^2 + c^2)^(3/2)*(d*x + c)), x)
 

Mupad [F(-1)]

Timed out. \[ \int \frac {A+B x+C x^2+D x^3}{(c+d x) \left (c^2-d^2 x^2\right )^{3/2}} \, dx=\int \frac {A+B\,x+C\,x^2+x^3\,D}{{\left (c^2-d^2\,x^2\right )}^{3/2}\,\left (c+d\,x\right )} \,d x \] Input:

int((A + B*x + C*x^2 + x^3*D)/((c^2 - d^2*x^2)^(3/2)*(c + d*x)),x)
 

Output:

int((A + B*x + C*x^2 + x^3*D)/((c^2 - d^2*x^2)^(3/2)*(c + d*x)), x)
 

Reduce [B] (verification not implemented)

Time = 0.19 (sec) , antiderivative size = 550, normalized size of antiderivative = 3.55 \[ \int \frac {A+B x+C x^2+D x^3}{(c+d x) \left (c^2-d^2 x^2\right )^{3/2}} \, dx =\text {Too large to display} \] Input:

int((D*x^3+C*x^2+B*x+A)/(d*x+c)/(-d^2*x^2+c^2)^(3/2),x)
 

Output:

( - 3*sqrt(c**2 - d**2*x**2)*asin((d*x)/c)*tan(asin((d*x)/c)/2)**4*c**3 - 
6*sqrt(c**2 - d**2*x**2)*asin((d*x)/c)*tan(asin((d*x)/c)/2)**3*c**3 + 6*sq 
rt(c**2 - d**2*x**2)*asin((d*x)/c)*tan(asin((d*x)/c)/2)*c**3 + 3*sqrt(c**2 
 - d**2*x**2)*asin((d*x)/c)*c**3 + 3*sqrt(c**2 - d**2*x**2)*tan(asin((d*x) 
/c)/2)**4*a*d**2 + 3*sqrt(c**2 - d**2*x**2)*tan(asin((d*x)/c)/2)**4*c**3 - 
 6*sqrt(c**2 - d**2*x**2)*tan(asin((d*x)/c)/2)**2*a*d**2 - 6*sqrt(c**2 - d 
**2*x**2)*tan(asin((d*x)/c)/2)**2*c**3 - 8*sqrt(c**2 - d**2*x**2)*tan(asin 
((d*x)/c)/2)*a*d**2 + 8*sqrt(c**2 - d**2*x**2)*tan(asin((d*x)/c)/2)*b*c*d 
- sqrt(c**2 - d**2*x**2)*a*d**2 + 4*sqrt(c**2 - d**2*x**2)*b*c*d + 3*sqrt( 
c**2 - d**2*x**2)*c**3 + 3*tan(asin((d*x)/c)/2)**4*b*c**2*d + 3*tan(asin(( 
d*x)/c)/2)**4*c**4 + 6*tan(asin((d*x)/c)/2)**3*b*c**2*d + 6*tan(asin((d*x) 
/c)/2)**3*c**4 - 6*tan(asin((d*x)/c)/2)*b*c**2*d - 6*tan(asin((d*x)/c)/2)* 
c**4 - 3*b*c**2*d - 3*c**4)/(3*sqrt(c**2 - d**2*x**2)*c**3*d**3*(tan(asin( 
(d*x)/c)/2)**4 + 2*tan(asin((d*x)/c)/2)**3 - 2*tan(asin((d*x)/c)/2) - 1))