Integrand size = 22, antiderivative size = 94 \[ \int \frac {x^m \left (a+b x^2\right )^2}{c+d x^2} \, dx=-\frac {b (b c-2 a d) x^{1+m}}{d^2 (1+m)}+\frac {b^2 x^{3+m}}{d (3+m)}+\frac {(b c-a d)^2 x^{1+m} \operatorname {Hypergeometric2F1}\left (1,\frac {1+m}{2},\frac {3+m}{2},-\frac {d x^2}{c}\right )}{c d^2 (1+m)} \] Output:
-b*(-2*a*d+b*c)*x^(1+m)/d^2/(1+m)+b^2*x^(3+m)/d/(3+m)+(-a*d+b*c)^2*x^(1+m) *hypergeom([1, 1/2+1/2*m],[3/2+1/2*m],-d*x^2/c)/c/d^2/(1+m)
Time = 0.18 (sec) , antiderivative size = 118, normalized size of antiderivative = 1.26 \[ \int \frac {x^m \left (a+b x^2\right )^2}{c+d x^2} \, dx=\frac {x^{1+m} \left (\frac {a^2 \operatorname {Hypergeometric2F1}\left (1,\frac {1+m}{2},\frac {3+m}{2},-\frac {d x^2}{c}\right )}{1+m}+b x^2 \left (\frac {2 a \operatorname {Hypergeometric2F1}\left (1,\frac {3+m}{2},\frac {5+m}{2},-\frac {d x^2}{c}\right )}{3+m}+\frac {b x^2 \operatorname {Hypergeometric2F1}\left (1,\frac {5+m}{2},\frac {7+m}{2},-\frac {d x^2}{c}\right )}{5+m}\right )\right )}{c} \] Input:
Integrate[(x^m*(a + b*x^2)^2)/(c + d*x^2),x]
Output:
(x^(1 + m)*((a^2*Hypergeometric2F1[1, (1 + m)/2, (3 + m)/2, -((d*x^2)/c)]) /(1 + m) + b*x^2*((2*a*Hypergeometric2F1[1, (3 + m)/2, (5 + m)/2, -((d*x^2 )/c)])/(3 + m) + (b*x^2*Hypergeometric2F1[1, (5 + m)/2, (7 + m)/2, -((d*x^ 2)/c)])/(5 + m))))/c
Time = 0.24 (sec) , antiderivative size = 94, 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.091, Rules used = {364, 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^m \left (a+b x^2\right )^2}{c+d x^2} \, dx\) |
\(\Big \downarrow \) 364 |
\(\displaystyle \int \left (\frac {x^m \left (a^2 d^2-2 a b c d+b^2 c^2\right )}{d^2 \left (c+d x^2\right )}-\frac {b x^m (b c-2 a d)}{d^2}+\frac {b^2 x^{m+2}}{d}\right )dx\) |
\(\Big \downarrow \) 2009 |
\(\displaystyle \frac {x^{m+1} (b c-a d)^2 \operatorname {Hypergeometric2F1}\left (1,\frac {m+1}{2},\frac {m+3}{2},-\frac {d x^2}{c}\right )}{c d^2 (m+1)}-\frac {b x^{m+1} (b c-2 a d)}{d^2 (m+1)}+\frac {b^2 x^{m+3}}{d (m+3)}\) |
Input:
Int[(x^m*(a + b*x^2)^2)/(c + d*x^2),x]
Output:
-((b*(b*c - 2*a*d)*x^(1 + m))/(d^2*(1 + m))) + (b^2*x^(3 + m))/(d*(3 + m)) + ((b*c - a*d)^2*x^(1 + m)*Hypergeometric2F1[1, (1 + m)/2, (3 + m)/2, -(( d*x^2)/c)])/(c*d^2*(1 + m))
Int[(((e_.)*(x_))^(m_.)*((a_) + (b_.)*(x_)^2)^(p_))/((c_) + (d_.)*(x_)^2), x_Symbol] :> Int[ExpandIntegrand[(e*x)^m*((a + b*x^2)^p/(c + d*x^2)), x], x ] /; FreeQ[{a, b, c, d, e, m}, x] && NeQ[b*c - a*d, 0] && IGtQ[p, 0] && (In tegerQ[m] || IGtQ[2*(m + 1), 0] || !RationalQ[m])
\[\int \frac {x^{m} \left (b \,x^{2}+a \right )^{2}}{x^{2} d +c}d x\]
Input:
int(x^m*(b*x^2+a)^2/(d*x^2+c),x)
Output:
int(x^m*(b*x^2+a)^2/(d*x^2+c),x)
\[ \int \frac {x^m \left (a+b x^2\right )^2}{c+d x^2} \, dx=\int { \frac {{\left (b x^{2} + a\right )}^{2} x^{m}}{d x^{2} + c} \,d x } \] Input:
integrate(x^m*(b*x^2+a)^2/(d*x^2+c),x, algorithm="fricas")
Output:
integral((b^2*x^4 + 2*a*b*x^2 + a^2)*x^m/(d*x^2 + c), x)
Result contains complex when optimal does not.
Time = 2.66 (sec) , antiderivative size = 292, normalized size of antiderivative = 3.11 \[ \int \frac {x^m \left (a+b x^2\right )^2}{c+d x^2} \, dx=\frac {a^{2} m x^{m + 1} \Phi \left (\frac {d x^{2} e^{i \pi }}{c}, 1, \frac {m}{2} + \frac {1}{2}\right ) \Gamma \left (\frac {m}{2} + \frac {1}{2}\right )}{4 c \Gamma \left (\frac {m}{2} + \frac {3}{2}\right )} + \frac {a^{2} x^{m + 1} \Phi \left (\frac {d x^{2} e^{i \pi }}{c}, 1, \frac {m}{2} + \frac {1}{2}\right ) \Gamma \left (\frac {m}{2} + \frac {1}{2}\right )}{4 c \Gamma \left (\frac {m}{2} + \frac {3}{2}\right )} + \frac {a b m x^{m + 3} \Phi \left (\frac {d x^{2} e^{i \pi }}{c}, 1, \frac {m}{2} + \frac {3}{2}\right ) \Gamma \left (\frac {m}{2} + \frac {3}{2}\right )}{2 c \Gamma \left (\frac {m}{2} + \frac {5}{2}\right )} + \frac {3 a b x^{m + 3} \Phi \left (\frac {d x^{2} e^{i \pi }}{c}, 1, \frac {m}{2} + \frac {3}{2}\right ) \Gamma \left (\frac {m}{2} + \frac {3}{2}\right )}{2 c \Gamma \left (\frac {m}{2} + \frac {5}{2}\right )} + \frac {b^{2} m x^{m + 5} \Phi \left (\frac {d x^{2} e^{i \pi }}{c}, 1, \frac {m}{2} + \frac {5}{2}\right ) \Gamma \left (\frac {m}{2} + \frac {5}{2}\right )}{4 c \Gamma \left (\frac {m}{2} + \frac {7}{2}\right )} + \frac {5 b^{2} x^{m + 5} \Phi \left (\frac {d x^{2} e^{i \pi }}{c}, 1, \frac {m}{2} + \frac {5}{2}\right ) \Gamma \left (\frac {m}{2} + \frac {5}{2}\right )}{4 c \Gamma \left (\frac {m}{2} + \frac {7}{2}\right )} \] Input:
integrate(x**m*(b*x**2+a)**2/(d*x**2+c),x)
Output:
a**2*m*x**(m + 1)*lerchphi(d*x**2*exp_polar(I*pi)/c, 1, m/2 + 1/2)*gamma(m /2 + 1/2)/(4*c*gamma(m/2 + 3/2)) + a**2*x**(m + 1)*lerchphi(d*x**2*exp_pol ar(I*pi)/c, 1, m/2 + 1/2)*gamma(m/2 + 1/2)/(4*c*gamma(m/2 + 3/2)) + a*b*m* x**(m + 3)*lerchphi(d*x**2*exp_polar(I*pi)/c, 1, m/2 + 3/2)*gamma(m/2 + 3/ 2)/(2*c*gamma(m/2 + 5/2)) + 3*a*b*x**(m + 3)*lerchphi(d*x**2*exp_polar(I*p i)/c, 1, m/2 + 3/2)*gamma(m/2 + 3/2)/(2*c*gamma(m/2 + 5/2)) + b**2*m*x**(m + 5)*lerchphi(d*x**2*exp_polar(I*pi)/c, 1, m/2 + 5/2)*gamma(m/2 + 5/2)/(4 *c*gamma(m/2 + 7/2)) + 5*b**2*x**(m + 5)*lerchphi(d*x**2*exp_polar(I*pi)/c , 1, m/2 + 5/2)*gamma(m/2 + 5/2)/(4*c*gamma(m/2 + 7/2))
\[ \int \frac {x^m \left (a+b x^2\right )^2}{c+d x^2} \, dx=\int { \frac {{\left (b x^{2} + a\right )}^{2} x^{m}}{d x^{2} + c} \,d x } \] Input:
integrate(x^m*(b*x^2+a)^2/(d*x^2+c),x, algorithm="maxima")
Output:
integrate((b*x^2 + a)^2*x^m/(d*x^2 + c), x)
\[ \int \frac {x^m \left (a+b x^2\right )^2}{c+d x^2} \, dx=\int { \frac {{\left (b x^{2} + a\right )}^{2} x^{m}}{d x^{2} + c} \,d x } \] Input:
integrate(x^m*(b*x^2+a)^2/(d*x^2+c),x, algorithm="giac")
Output:
integrate((b*x^2 + a)^2*x^m/(d*x^2 + c), x)
Timed out. \[ \int \frac {x^m \left (a+b x^2\right )^2}{c+d x^2} \, dx=\int \frac {x^m\,{\left (b\,x^2+a\right )}^2}{d\,x^2+c} \,d x \] Input:
int((x^m*(a + b*x^2)^2)/(c + d*x^2),x)
Output:
int((x^m*(a + b*x^2)^2)/(c + d*x^2), x)
\[ \int \frac {x^m \left (a+b x^2\right )^2}{c+d x^2} \, dx=\frac {2 x^{m} a b d m x +6 x^{m} a b d x -x^{m} b^{2} c m x -3 x^{m} b^{2} c x +x^{m} b^{2} d m \,x^{3}+x^{m} b^{2} d \,x^{3}+\left (\int \frac {x^{m}}{d \,x^{2}+c}d x \right ) a^{2} d^{2} m^{2}+4 \left (\int \frac {x^{m}}{d \,x^{2}+c}d x \right ) a^{2} d^{2} m +3 \left (\int \frac {x^{m}}{d \,x^{2}+c}d x \right ) a^{2} d^{2}-2 \left (\int \frac {x^{m}}{d \,x^{2}+c}d x \right ) a b c d \,m^{2}-8 \left (\int \frac {x^{m}}{d \,x^{2}+c}d x \right ) a b c d m -6 \left (\int \frac {x^{m}}{d \,x^{2}+c}d x \right ) a b c d +\left (\int \frac {x^{m}}{d \,x^{2}+c}d x \right ) b^{2} c^{2} m^{2}+4 \left (\int \frac {x^{m}}{d \,x^{2}+c}d x \right ) b^{2} c^{2} m +3 \left (\int \frac {x^{m}}{d \,x^{2}+c}d x \right ) b^{2} c^{2}}{d^{2} \left (m^{2}+4 m +3\right )} \] Input:
int(x^m*(b*x^2+a)^2/(d*x^2+c),x)
Output:
(2*x**m*a*b*d*m*x + 6*x**m*a*b*d*x - x**m*b**2*c*m*x - 3*x**m*b**2*c*x + x **m*b**2*d*m*x**3 + x**m*b**2*d*x**3 + int(x**m/(c + d*x**2),x)*a**2*d**2* m**2 + 4*int(x**m/(c + d*x**2),x)*a**2*d**2*m + 3*int(x**m/(c + d*x**2),x) *a**2*d**2 - 2*int(x**m/(c + d*x**2),x)*a*b*c*d*m**2 - 8*int(x**m/(c + d*x **2),x)*a*b*c*d*m - 6*int(x**m/(c + d*x**2),x)*a*b*c*d + int(x**m/(c + d*x **2),x)*b**2*c**2*m**2 + 4*int(x**m/(c + d*x**2),x)*b**2*c**2*m + 3*int(x* *m/(c + d*x**2),x)*b**2*c**2)/(d**2*(m**2 + 4*m + 3))