\(\int x^2 (a+b x^2)^p (c+d x^2)^q \, dx\) [1642]

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

Optimal result

Integrand size = 22, antiderivative size = 84 \[ \int x^2 \left (a+b x^2\right )^p \left (c+d x^2\right )^q \, dx=\frac {1}{3} x^3 \left (a+b x^2\right )^p \left (1+\frac {b x^2}{a}\right )^{-p} \left (c+d x^2\right )^q \left (1+\frac {d x^2}{c}\right )^{-q} \operatorname {AppellF1}\left (\frac {3}{2},-p,-q,\frac {5}{2},-\frac {b x^2}{a},-\frac {d x^2}{c}\right ) \] Output:

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

Mathematica [A] (verified)

Time = 0.10 (sec) , antiderivative size = 86, normalized size of antiderivative = 1.02 \[ \int x^2 \left (a+b x^2\right )^p \left (c+d x^2\right )^q \, dx=\frac {1}{3} x^3 \left (a+b x^2\right )^p \left (\frac {a+b x^2}{a}\right )^{-p} \left (c+d x^2\right )^q \left (\frac {c+d x^2}{c}\right )^{-q} \operatorname {AppellF1}\left (\frac {3}{2},-p,-q,\frac {5}{2},-\frac {b x^2}{a},-\frac {d x^2}{c}\right ) \] Input:

Integrate[x^2*(a + b*x^2)^p*(c + d*x^2)^q,x]
 

Output:

(x^3*(a + b*x^2)^p*(c + d*x^2)^q*AppellF1[3/2, -p, -q, 5/2, -((b*x^2)/a), 
-((d*x^2)/c)])/(3*((a + b*x^2)/a)^p*((c + d*x^2)/c)^q)
 

Rubi [A] (verified)

Time = 0.22 (sec) , antiderivative size = 84, normalized size of antiderivative = 1.00, number of steps used = 3, number of rules used = 3, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.136, Rules used = {395, 395, 394}

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

\(\Big \downarrow \) 395

\(\displaystyle \left (a+b x^2\right )^p \left (\frac {b x^2}{a}+1\right )^{-p} \int x^2 \left (\frac {b x^2}{a}+1\right )^p \left (d x^2+c\right )^qdx\)

\(\Big \downarrow \) 395

\(\displaystyle \left (a+b x^2\right )^p \left (\frac {b x^2}{a}+1\right )^{-p} \left (c+d x^2\right )^q \left (\frac {d x^2}{c}+1\right )^{-q} \int x^2 \left (\frac {b x^2}{a}+1\right )^p \left (\frac {d x^2}{c}+1\right )^qdx\)

\(\Big \downarrow \) 394

\(\displaystyle \frac {1}{3} x^3 \left (a+b x^2\right )^p \left (\frac {b x^2}{a}+1\right )^{-p} \left (c+d x^2\right )^q \left (\frac {d x^2}{c}+1\right )^{-q} \operatorname {AppellF1}\left (\frac {3}{2},-p,-q,\frac {5}{2},-\frac {b x^2}{a},-\frac {d x^2}{c}\right )\)

Input:

Int[x^2*(a + b*x^2)^p*(c + d*x^2)^q,x]
 

Output:

(x^3*(a + b*x^2)^p*(c + d*x^2)^q*AppellF1[3/2, -p, -q, 5/2, -((b*x^2)/a), 
-((d*x^2)/c)])/(3*(1 + (b*x^2)/a)^p*(1 + (d*x^2)/c)^q)
 

Defintions of rubi rules used

rule 394
Int[((e_.)*(x_))^(m_.)*((a_) + (b_.)*(x_)^2)^(p_)*((c_) + (d_.)*(x_)^2)^(q_ 
), x_Symbol] :> Simp[a^p*c^q*((e*x)^(m + 1)/(e*(m + 1)))*AppellF1[(m + 1)/2 
, -p, -q, 1 + (m + 1)/2, (-b)*(x^2/a), (-d)*(x^2/c)], x] /; FreeQ[{a, b, c, 
 d, e, m, p, q}, x] && NeQ[b*c - a*d, 0] && NeQ[m, -1] && NeQ[m, 1] && (Int 
egerQ[p] || GtQ[a, 0]) && (IntegerQ[q] || GtQ[c, 0])
 

rule 395
Int[((e_.)*(x_))^(m_.)*((a_) + (b_.)*(x_)^2)^(p_)*((c_) + (d_.)*(x_)^2)^(q_ 
), x_Symbol] :> Simp[a^IntPart[p]*((a + b*x^2)^FracPart[p]/(1 + b*(x^2/a))^ 
FracPart[p])   Int[(e*x)^m*(1 + b*(x^2/a))^p*(c + d*x^2)^q, x], x] /; FreeQ 
[{a, b, c, d, e, m, p, q}, x] && NeQ[b*c - a*d, 0] && NeQ[m, -1] && NeQ[m, 
1] &&  !(IntegerQ[p] || GtQ[a, 0])
 
Maple [F]

\[\int x^{2} \left (b \,x^{2}+a \right )^{p} \left (x^{2} d +c \right )^{q}d x\]

Input:

int(x^2*(b*x^2+a)^p*(d*x^2+c)^q,x)
 

Output:

int(x^2*(b*x^2+a)^p*(d*x^2+c)^q,x)
 

Fricas [F]

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

integrate(x^2*(b*x^2+a)^p*(d*x^2+c)^q,x, algorithm="fricas")
 

Output:

integral((b*x^2 + a)^p*(d*x^2 + c)^q*x^2, x)
 

Sympy [F(-1)]

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

integrate(x**2*(b*x**2+a)**p*(d*x**2+c)**q,x)
 

Output:

Timed out
 

Maxima [F]

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

integrate(x^2*(b*x^2+a)^p*(d*x^2+c)^q,x, algorithm="maxima")
 

Output:

integrate((b*x^2 + a)^p*(d*x^2 + c)^q*x^2, x)
 

Giac [F]

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

integrate(x^2*(b*x^2+a)^p*(d*x^2+c)^q,x, algorithm="giac")
 

Output:

integrate((b*x^2 + a)^p*(d*x^2 + c)^q*x^2, x)
 

Mupad [F(-1)]

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

int(x^2*(a + b*x^2)^p*(c + d*x^2)^q,x)
 

Output:

int(x^2*(a + b*x^2)^p*(c + d*x^2)^q, x)
 

Reduce [F]

\[ \int x^2 \left (a+b x^2\right )^p \left (c+d x^2\right )^q \, dx=\text {too large to display} \] Input:

int(x^2*(b*x^2+a)^p*(d*x^2+c)^q,x)
 

Output:

(2*(c + d*x**2)**q*(a + b*x**2)**p*a*d*p*x + 2*(c + d*x**2)**q*(a + b*x**2 
)**p*b*c*q*x + 2*(c + d*x**2)**q*(a + b*x**2)**p*b*d*p*x**3 + 2*(c + d*x** 
2)**q*(a + b*x**2)**p*b*d*q*x**3 + (c + d*x**2)**q*(a + b*x**2)**p*b*d*x** 
3 - 16*int(((c + d*x**2)**q*(a + b*x**2)**p*x**2)/(4*a*c*p**2 + 8*a*c*p*q 
+ 8*a*c*p + 4*a*c*q**2 + 8*a*c*q + 3*a*c + 4*a*d*p**2*x**2 + 8*a*d*p*q*x** 
2 + 8*a*d*p*x**2 + 4*a*d*q**2*x**2 + 8*a*d*q*x**2 + 3*a*d*x**2 + 4*b*c*p** 
2*x**2 + 8*b*c*p*q*x**2 + 8*b*c*p*x**2 + 4*b*c*q**2*x**2 + 8*b*c*q*x**2 + 
3*b*c*x**2 + 4*b*d*p**2*x**4 + 8*b*d*p*q*x**4 + 8*b*d*p*x**4 + 4*b*d*q**2* 
x**4 + 8*b*d*q*x**4 + 3*b*d*x**4),x)*a**2*d**2*p**3*q - 8*int(((c + d*x**2 
)**q*(a + b*x**2)**p*x**2)/(4*a*c*p**2 + 8*a*c*p*q + 8*a*c*p + 4*a*c*q**2 
+ 8*a*c*q + 3*a*c + 4*a*d*p**2*x**2 + 8*a*d*p*q*x**2 + 8*a*d*p*x**2 + 4*a* 
d*q**2*x**2 + 8*a*d*q*x**2 + 3*a*d*x**2 + 4*b*c*p**2*x**2 + 8*b*c*p*q*x**2 
 + 8*b*c*p*x**2 + 4*b*c*q**2*x**2 + 8*b*c*q*x**2 + 3*b*c*x**2 + 4*b*d*p**2 
*x**4 + 8*b*d*p*q*x**4 + 8*b*d*p*x**4 + 4*b*d*q**2*x**4 + 8*b*d*q*x**4 + 3 
*b*d*x**4),x)*a**2*d**2*p**3 - 32*int(((c + d*x**2)**q*(a + b*x**2)**p*x** 
2)/(4*a*c*p**2 + 8*a*c*p*q + 8*a*c*p + 4*a*c*q**2 + 8*a*c*q + 3*a*c + 4*a* 
d*p**2*x**2 + 8*a*d*p*q*x**2 + 8*a*d*p*x**2 + 4*a*d*q**2*x**2 + 8*a*d*q*x* 
*2 + 3*a*d*x**2 + 4*b*c*p**2*x**2 + 8*b*c*p*q*x**2 + 8*b*c*p*x**2 + 4*b*c* 
q**2*x**2 + 8*b*c*q*x**2 + 3*b*c*x**2 + 4*b*d*p**2*x**4 + 8*b*d*p*q*x**4 + 
 8*b*d*p*x**4 + 4*b*d*q**2*x**4 + 8*b*d*q*x**4 + 3*b*d*x**4),x)*a**2*d*...