Integrand size = 28, antiderivative size = 130 \[ \int \frac {x^3 \left (A+B x+C x^2+D x^3\right )}{a+b x^2} \, dx=-\frac {a (b B-a D) x}{b^3}+\frac {(A b-a C) x^2}{2 b^2}+\frac {(b B-a D) x^3}{3 b^2}+\frac {C x^4}{4 b}+\frac {D x^5}{5 b}+\frac {a^{3/2} (b B-a D) \arctan \left (\frac {\sqrt {b} x}{\sqrt {a}}\right )}{b^{7/2}}-\frac {a (A b-a C) \log \left (a+b x^2\right )}{2 b^3} \] Output:
-a*(B*b-D*a)*x/b^3+1/2*(A*b-C*a)*x^2/b^2+1/3*(B*b-D*a)*x^3/b^2+1/4*C*x^4/b +1/5*D*x^5/b+a^(3/2)*(B*b-D*a)*arctan(b^(1/2)*x/a^(1/2))/b^(7/2)-1/2*a*(A* b-C*a)*ln(b*x^2+a)/b^3
Time = 0.10 (sec) , antiderivative size = 114, normalized size of antiderivative = 0.88 \[ \int \frac {x^3 \left (A+B x+C x^2+D x^3\right )}{a+b x^2} \, dx=-\frac {a^{3/2} (-b B+a D) \arctan \left (\frac {\sqrt {b} x}{\sqrt {a}}\right )}{b^{7/2}}+\frac {x \left (60 a^2 D-10 a b (6 B+x (3 C+2 D x))+b^2 x (30 A+x (20 B+3 x (5 C+4 D x)))\right )+30 a (-A b+a C) \log \left (a+b x^2\right )}{60 b^3} \] Input:
Integrate[(x^3*(A + B*x + C*x^2 + D*x^3))/(a + b*x^2),x]
Output:
-((a^(3/2)*(-(b*B) + a*D)*ArcTan[(Sqrt[b]*x)/Sqrt[a]])/b^(7/2)) + (x*(60*a ^2*D - 10*a*b*(6*B + x*(3*C + 2*D*x)) + b^2*x*(30*A + x*(20*B + 3*x*(5*C + 4*D*x)))) + 30*a*(-(A*b) + a*C)*Log[a + b*x^2])/(60*b^3)
Time = 0.36 (sec) , antiderivative size = 130, normalized size of antiderivative = 1.00, number of steps used = 2, number of rules used = 2, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.071, Rules used = {2333, 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 {x^3 \left (A+B x+C x^2+D x^3\right )}{a+b x^2} \, dx\) |
\(\Big \downarrow \) 2333 |
\(\displaystyle \int \left (\frac {a^2 (b B-a D)-a b x (A b-a C)}{b^3 \left (a+b x^2\right )}+\frac {x (A b-a C)}{b^2}-\frac {a (b B-a D)}{b^3}+\frac {x^2 (b B-a D)}{b^2}+\frac {C x^3}{b}+\frac {D x^4}{b}\right )dx\) |
\(\Big \downarrow \) 2009 |
\(\displaystyle \frac {a^{3/2} \arctan \left (\frac {\sqrt {b} x}{\sqrt {a}}\right ) (b B-a D)}{b^{7/2}}-\frac {a (A b-a C) \log \left (a+b x^2\right )}{2 b^3}+\frac {x^2 (A b-a C)}{2 b^2}-\frac {a x (b B-a D)}{b^3}+\frac {x^3 (b B-a D)}{3 b^2}+\frac {C x^4}{4 b}+\frac {D x^5}{5 b}\) |
Input:
Int[(x^3*(A + B*x + C*x^2 + D*x^3))/(a + b*x^2),x]
Output:
-((a*(b*B - a*D)*x)/b^3) + ((A*b - a*C)*x^2)/(2*b^2) + ((b*B - a*D)*x^3)/( 3*b^2) + (C*x^4)/(4*b) + (D*x^5)/(5*b) + (a^(3/2)*(b*B - a*D)*ArcTan[(Sqrt [b]*x)/Sqrt[a]])/b^(7/2) - (a*(A*b - a*C)*Log[a + b*x^2])/(2*b^3)
Int[(Pq_)*((c_.)*(x_))^(m_.)*((a_) + (b_.)*(x_)^2)^(p_.), x_Symbol] :> Int[ ExpandIntegrand[(c*x)^m*Pq*(a + b*x^2)^p, x], x] /; FreeQ[{a, b, c, m}, x] && PolyQ[Pq, x] && IGtQ[p, -2]
Time = 0.45 (sec) , antiderivative size = 128, normalized size of antiderivative = 0.98
method | result | size |
default | \(\frac {\frac {1}{5} D x^{5} b^{2}+\frac {1}{4} C \,b^{2} x^{4}+\frac {1}{3} B \,b^{2} x^{3}-\frac {1}{3} D a b \,x^{3}+\frac {1}{2} A \,b^{2} x^{2}-\frac {1}{2} x^{2} a C b -B a b x +D a^{2} x}{b^{3}}-\frac {a \left (\frac {\left (b^{2} A -C a b \right ) \ln \left (b \,x^{2}+a \right )}{2 b}+\frac {\left (-a b B +D a^{2}\right ) \arctan \left (\frac {b x}{\sqrt {a b}}\right )}{\sqrt {a b}}\right )}{b^{3}}\) | \(128\) |
Input:
int(x^3*(D*x^3+C*x^2+B*x+A)/(b*x^2+a),x,method=_RETURNVERBOSE)
Output:
1/b^3*(1/5*D*x^5*b^2+1/4*C*b^2*x^4+1/3*B*b^2*x^3-1/3*D*a*b*x^3+1/2*A*b^2*x ^2-1/2*x^2*a*C*b-B*a*b*x+D*a^2*x)-a/b^3*(1/2*(A*b^2-C*a*b)/b*ln(b*x^2+a)+( -B*a*b+D*a^2)/(a*b)^(1/2)*arctan(b*x/(a*b)^(1/2)))
Time = 0.10 (sec) , antiderivative size = 270, normalized size of antiderivative = 2.08 \[ \int \frac {x^3 \left (A+B x+C x^2+D x^3\right )}{a+b x^2} \, dx=\left [\frac {12 \, D b^{2} x^{5} + 15 \, C b^{2} x^{4} - 20 \, {\left (D a b - B b^{2}\right )} x^{3} - 30 \, {\left (C a b - A b^{2}\right )} x^{2} - 30 \, {\left (D a^{2} - B a b\right )} \sqrt {-\frac {a}{b}} \log \left (\frac {b x^{2} + 2 \, b x \sqrt {-\frac {a}{b}} - a}{b x^{2} + a}\right ) + 60 \, {\left (D a^{2} - B a b\right )} x + 30 \, {\left (C a^{2} - A a b\right )} \log \left (b x^{2} + a\right )}{60 \, b^{3}}, \frac {12 \, D b^{2} x^{5} + 15 \, C b^{2} x^{4} - 20 \, {\left (D a b - B b^{2}\right )} x^{3} - 30 \, {\left (C a b - A b^{2}\right )} x^{2} - 60 \, {\left (D a^{2} - B a b\right )} \sqrt {\frac {a}{b}} \arctan \left (\frac {b x \sqrt {\frac {a}{b}}}{a}\right ) + 60 \, {\left (D a^{2} - B a b\right )} x + 30 \, {\left (C a^{2} - A a b\right )} \log \left (b x^{2} + a\right )}{60 \, b^{3}}\right ] \] Input:
integrate(x^3*(D*x^3+C*x^2+B*x+A)/(b*x^2+a),x, algorithm="fricas")
Output:
[1/60*(12*D*b^2*x^5 + 15*C*b^2*x^4 - 20*(D*a*b - B*b^2)*x^3 - 30*(C*a*b - A*b^2)*x^2 - 30*(D*a^2 - B*a*b)*sqrt(-a/b)*log((b*x^2 + 2*b*x*sqrt(-a/b) - a)/(b*x^2 + a)) + 60*(D*a^2 - B*a*b)*x + 30*(C*a^2 - A*a*b)*log(b*x^2 + a ))/b^3, 1/60*(12*D*b^2*x^5 + 15*C*b^2*x^4 - 20*(D*a*b - B*b^2)*x^3 - 30*(C *a*b - A*b^2)*x^2 - 60*(D*a^2 - B*a*b)*sqrt(a/b)*arctan(b*x*sqrt(a/b)/a) + 60*(D*a^2 - B*a*b)*x + 30*(C*a^2 - A*a*b)*log(b*x^2 + a))/b^3]
Leaf count of result is larger than twice the leaf count of optimal. 274 vs. \(2 (116) = 232\).
Time = 0.69 (sec) , antiderivative size = 274, normalized size of antiderivative = 2.11 \[ \int \frac {x^3 \left (A+B x+C x^2+D x^3\right )}{a+b x^2} \, dx=\frac {C x^{4}}{4 b} + \frac {D x^{5}}{5 b} + x^{3} \left (\frac {B}{3 b} - \frac {D a}{3 b^{2}}\right ) + x^{2} \left (\frac {A}{2 b} - \frac {C a}{2 b^{2}}\right ) + x \left (- \frac {B a}{b^{2}} + \frac {D a^{2}}{b^{3}}\right ) + \left (\frac {a \left (- A b + C a\right )}{2 b^{3}} - \frac {\sqrt {- a^{3} b^{7}} \left (- B b + D a\right )}{2 b^{7}}\right ) \log {\left (x + \frac {- A a b + C a^{2} - 2 b^{3} \left (\frac {a \left (- A b + C a\right )}{2 b^{3}} - \frac {\sqrt {- a^{3} b^{7}} \left (- B b + D a\right )}{2 b^{7}}\right )}{- B a b + D a^{2}} \right )} + \left (\frac {a \left (- A b + C a\right )}{2 b^{3}} + \frac {\sqrt {- a^{3} b^{7}} \left (- B b + D a\right )}{2 b^{7}}\right ) \log {\left (x + \frac {- A a b + C a^{2} - 2 b^{3} \left (\frac {a \left (- A b + C a\right )}{2 b^{3}} + \frac {\sqrt {- a^{3} b^{7}} \left (- B b + D a\right )}{2 b^{7}}\right )}{- B a b + D a^{2}} \right )} \] Input:
integrate(x**3*(D*x**3+C*x**2+B*x+A)/(b*x**2+a),x)
Output:
C*x**4/(4*b) + D*x**5/(5*b) + x**3*(B/(3*b) - D*a/(3*b**2)) + x**2*(A/(2*b ) - C*a/(2*b**2)) + x*(-B*a/b**2 + D*a**2/b**3) + (a*(-A*b + C*a)/(2*b**3) - sqrt(-a**3*b**7)*(-B*b + D*a)/(2*b**7))*log(x + (-A*a*b + C*a**2 - 2*b* *3*(a*(-A*b + C*a)/(2*b**3) - sqrt(-a**3*b**7)*(-B*b + D*a)/(2*b**7)))/(-B *a*b + D*a**2)) + (a*(-A*b + C*a)/(2*b**3) + sqrt(-a**3*b**7)*(-B*b + D*a) /(2*b**7))*log(x + (-A*a*b + C*a**2 - 2*b**3*(a*(-A*b + C*a)/(2*b**3) + sq rt(-a**3*b**7)*(-B*b + D*a)/(2*b**7)))/(-B*a*b + D*a**2))
Time = 0.11 (sec) , antiderivative size = 127, normalized size of antiderivative = 0.98 \[ \int \frac {x^3 \left (A+B x+C x^2+D x^3\right )}{a+b x^2} \, dx=\frac {{\left (C a^{2} - A a b\right )} \log \left (b x^{2} + a\right )}{2 \, b^{3}} - \frac {{\left (D a^{3} - B a^{2} b\right )} \arctan \left (\frac {b x}{\sqrt {a b}}\right )}{\sqrt {a b} b^{3}} + \frac {12 \, D b^{2} x^{5} + 15 \, C b^{2} x^{4} - 20 \, {\left (D a b - B b^{2}\right )} x^{3} - 30 \, {\left (C a b - A b^{2}\right )} x^{2} + 60 \, {\left (D a^{2} - B a b\right )} x}{60 \, b^{3}} \] Input:
integrate(x^3*(D*x^3+C*x^2+B*x+A)/(b*x^2+a),x, algorithm="maxima")
Output:
1/2*(C*a^2 - A*a*b)*log(b*x^2 + a)/b^3 - (D*a^3 - B*a^2*b)*arctan(b*x/sqrt (a*b))/(sqrt(a*b)*b^3) + 1/60*(12*D*b^2*x^5 + 15*C*b^2*x^4 - 20*(D*a*b - B *b^2)*x^3 - 30*(C*a*b - A*b^2)*x^2 + 60*(D*a^2 - B*a*b)*x)/b^3
Time = 0.12 (sec) , antiderivative size = 137, normalized size of antiderivative = 1.05 \[ \int \frac {x^3 \left (A+B x+C x^2+D x^3\right )}{a+b x^2} \, dx=\frac {{\left (C a^{2} - A a b\right )} \log \left (b x^{2} + a\right )}{2 \, b^{3}} - \frac {{\left (D a^{3} - B a^{2} b\right )} \arctan \left (\frac {b x}{\sqrt {a b}}\right )}{\sqrt {a b} b^{3}} + \frac {12 \, D b^{4} x^{5} + 15 \, C b^{4} x^{4} - 20 \, D a b^{3} x^{3} + 20 \, B b^{4} x^{3} - 30 \, C a b^{3} x^{2} + 30 \, A b^{4} x^{2} + 60 \, D a^{2} b^{2} x - 60 \, B a b^{3} x}{60 \, b^{5}} \] Input:
integrate(x^3*(D*x^3+C*x^2+B*x+A)/(b*x^2+a),x, algorithm="giac")
Output:
1/2*(C*a^2 - A*a*b)*log(b*x^2 + a)/b^3 - (D*a^3 - B*a^2*b)*arctan(b*x/sqrt (a*b))/(sqrt(a*b)*b^3) + 1/60*(12*D*b^4*x^5 + 15*C*b^4*x^4 - 20*D*a*b^3*x^ 3 + 20*B*b^4*x^3 - 30*C*a*b^3*x^2 + 30*A*b^4*x^2 + 60*D*a^2*b^2*x - 60*B*a *b^3*x)/b^5
Timed out. \[ \int \frac {x^3 \left (A+B x+C x^2+D x^3\right )}{a+b x^2} \, dx=\int \frac {x^3\,\left (A+B\,x+C\,x^2+x^3\,D\right )}{b\,x^2+a} \,d x \] Input:
int((x^3*(A + B*x + C*x^2 + x^3*D))/(a + b*x^2),x)
Output:
int((x^3*(A + B*x + C*x^2 + x^3*D))/(a + b*x^2), x)
Time = 0.16 (sec) , antiderivative size = 151, normalized size of antiderivative = 1.16 \[ \int \frac {x^3 \left (A+B x+C x^2+D x^3\right )}{a+b x^2} \, dx=\frac {-60 \sqrt {b}\, \sqrt {a}\, \mathit {atan} \left (\frac {b x}{\sqrt {b}\, \sqrt {a}}\right ) a^{2} d +60 \sqrt {b}\, \sqrt {a}\, \mathit {atan} \left (\frac {b x}{\sqrt {b}\, \sqrt {a}}\right ) a \,b^{2}-30 \,\mathrm {log}\left (b \,x^{2}+a \right ) a^{2} b^{2}+30 \,\mathrm {log}\left (b \,x^{2}+a \right ) a^{2} b c +60 a^{2} b d x +30 a \,b^{3} x^{2}-60 a \,b^{3} x -30 a \,b^{2} c \,x^{2}-20 a \,b^{2} d \,x^{3}+20 b^{4} x^{3}+15 b^{3} c \,x^{4}+12 b^{3} d \,x^{5}}{60 b^{4}} \] Input:
int(x^3*(D*x^3+C*x^2+B*x+A)/(b*x^2+a),x)
Output:
( - 60*sqrt(b)*sqrt(a)*atan((b*x)/(sqrt(b)*sqrt(a)))*a**2*d + 60*sqrt(b)*s qrt(a)*atan((b*x)/(sqrt(b)*sqrt(a)))*a*b**2 - 30*log(a + b*x**2)*a**2*b**2 + 30*log(a + b*x**2)*a**2*b*c + 60*a**2*b*d*x + 30*a*b**3*x**2 - 60*a*b** 3*x - 30*a*b**2*c*x**2 - 20*a*b**2*d*x**3 + 20*b**4*x**3 + 15*b**3*c*x**4 + 12*b**3*d*x**5)/(60*b**4)