### 3.946 $$\int (a+b x)^m (a^2-b^2 x^2)^2 \, dx$$

Optimal. Leaf size=61 $\frac{4 a^2 (a+b x)^{m+3}}{b (m+3)}-\frac{4 a (a+b x)^{m+4}}{b (m+4)}+\frac{(a+b x)^{m+5}}{b (m+5)}$

[Out]

(4*a^2*(a + b*x)^(3 + m))/(b*(3 + m)) - (4*a*(a + b*x)^(4 + m))/(b*(4 + m)) + (a + b*x)^(5 + m)/(b*(5 + m))

________________________________________________________________________________________

Rubi [A]  time = 0.0279287, antiderivative size = 61, normalized size of antiderivative = 1., number of steps used = 3, number of rules used = 2, integrand size = 22, $$\frac{\text{number of rules}}{\text{integrand size}}$$ = 0.091, Rules used = {627, 43} $\frac{4 a^2 (a+b x)^{m+3}}{b (m+3)}-\frac{4 a (a+b x)^{m+4}}{b (m+4)}+\frac{(a+b x)^{m+5}}{b (m+5)}$

Antiderivative was successfully veriﬁed.

[In]

Int[(a + b*x)^m*(a^2 - b^2*x^2)^2,x]

[Out]

(4*a^2*(a + b*x)^(3 + m))/(b*(3 + m)) - (4*a*(a + b*x)^(4 + m))/(b*(4 + m)) + (a + b*x)^(5 + m)/(b*(5 + m))

Rule 627

Int[((d_) + (e_.)*(x_))^(m_.)*((a_) + (c_.)*(x_)^2)^(p_.), x_Symbol] :> Int[(d + e*x)^(m + p)*(a/d + (c*x)/e)^
p, x] /; FreeQ[{a, c, d, e, m, p}, x] && EqQ[c*d^2 + a*e^2, 0] && (IntegerQ[p] || (GtQ[a, 0] && GtQ[d, 0] && I
ntegerQ[m + p]))

Rule 43

Int[((a_.) + (b_.)*(x_))^(m_.)*((c_.) + (d_.)*(x_))^(n_.), x_Symbol] :> Int[ExpandIntegrand[(a + b*x)^m*(c + d
*x)^n, x], x] /; FreeQ[{a, b, c, d, n}, x] && NeQ[b*c - a*d, 0] && IGtQ[m, 0] && ( !IntegerQ[n] || (EqQ[c, 0]
&& LeQ[7*m + 4*n + 4, 0]) || LtQ[9*m + 5*(n + 1), 0] || GtQ[m + n + 2, 0])

Rubi steps

\begin{align*} \int (a+b x)^m \left (a^2-b^2 x^2\right )^2 \, dx &=\int (a-b x)^2 (a+b x)^{2+m} \, dx\\ &=\int \left (4 a^2 (a+b x)^{2+m}-4 a (a+b x)^{3+m}+(a+b x)^{4+m}\right ) \, dx\\ &=\frac{4 a^2 (a+b x)^{3+m}}{b (3+m)}-\frac{4 a (a+b x)^{4+m}}{b (4+m)}+\frac{(a+b x)^{5+m}}{b (5+m)}\\ \end{align*}

Mathematica [A]  time = 0.0530235, size = 50, normalized size = 0.82 $\frac{(a+b x)^{m+3} \left (\frac{4 a^2}{m+3}-\frac{4 a (a+b x)}{m+4}+\frac{(a+b x)^2}{m+5}\right )}{b}$

Antiderivative was successfully veriﬁed.

[In]

Integrate[(a + b*x)^m*(a^2 - b^2*x^2)^2,x]

[Out]

((a + b*x)^(3 + m)*((4*a^2)/(3 + m) - (4*a*(a + b*x))/(4 + m) + (a + b*x)^2/(5 + m)))/b

________________________________________________________________________________________

Maple [A]  time = 0.046, size = 94, normalized size = 1.5 \begin{align*}{\frac{ \left ( bx+a \right ) ^{3+m} \left ({b}^{2}{m}^{2}{x}^{2}-2\,ab{m}^{2}x+7\,{b}^{2}m{x}^{2}+{a}^{2}{m}^{2}-18\,abmx+12\,{b}^{2}{x}^{2}+11\,m{a}^{2}-36\,abx+32\,{a}^{2} \right ) }{b \left ({m}^{3}+12\,{m}^{2}+47\,m+60 \right ) }} \end{align*}

Veriﬁcation of antiderivative is not currently implemented for this CAS.

[In]

int((b*x+a)^m*(-b^2*x^2+a^2)^2,x)

[Out]

(b*x+a)^(3+m)*(b^2*m^2*x^2-2*a*b*m^2*x+7*b^2*m*x^2+a^2*m^2-18*a*b*m*x+12*b^2*x^2+11*a^2*m-36*a*b*x+32*a^2)/b/(
m^3+12*m^2+47*m+60)

________________________________________________________________________________________

Maxima [F(-2)]  time = 0., size = 0, normalized size = 0. \begin{align*} \text{Exception raised: ValueError} \end{align*}

Veriﬁcation of antiderivative is not currently implemented for this CAS.

[In]

integrate((b*x+a)^m*(-b^2*x^2+a^2)^2,x, algorithm="maxima")

[Out]

Exception raised: ValueError

________________________________________________________________________________________

Fricas [B]  time = 1.96081, size = 363, normalized size = 5.95 \begin{align*} \frac{{\left (a^{5} m^{2} + 11 \, a^{5} m +{\left (b^{5} m^{2} + 7 \, b^{5} m + 12 \, b^{5}\right )} x^{5} + 32 \, a^{5} +{\left (a b^{4} m^{2} + 3 \, a b^{4} m\right )} x^{4} - 2 \,{\left (a^{2} b^{3} m^{2} + 11 \, a^{2} b^{3} m + 20 \, a^{2} b^{3}\right )} x^{3} - 2 \,{\left (a^{3} b^{2} m^{2} + 7 \, a^{3} b^{2} m\right )} x^{2} +{\left (a^{4} b m^{2} + 15 \, a^{4} b m + 60 \, a^{4} b\right )} x\right )}{\left (b x + a\right )}^{m}}{b m^{3} + 12 \, b m^{2} + 47 \, b m + 60 \, b} \end{align*}

Veriﬁcation of antiderivative is not currently implemented for this CAS.

[In]

integrate((b*x+a)^m*(-b^2*x^2+a^2)^2,x, algorithm="fricas")

[Out]

(a^5*m^2 + 11*a^5*m + (b^5*m^2 + 7*b^5*m + 12*b^5)*x^5 + 32*a^5 + (a*b^4*m^2 + 3*a*b^4*m)*x^4 - 2*(a^2*b^3*m^2
+ 11*a^2*b^3*m + 20*a^2*b^3)*x^3 - 2*(a^3*b^2*m^2 + 7*a^3*b^2*m)*x^2 + (a^4*b*m^2 + 15*a^4*b*m + 60*a^4*b)*x)
*(b*x + a)^m/(b*m^3 + 12*b*m^2 + 47*b*m + 60*b)

________________________________________________________________________________________

Sympy [A]  time = 2.48281, size = 945, normalized size = 15.49 \begin{align*} \text{result too large to display} \end{align*}

Veriﬁcation of antiderivative is not currently implemented for this CAS.

[In]

integrate((b*x+a)**m*(-b**2*x**2+a**2)**2,x)

[Out]

Piecewise((a**4*a**m*x, Eq(b, 0)), (3*a**2*log(a/b + x)/(3*a**2*b + 6*a*b**2*x + 3*b**3*x**2) + a**2/(3*a**2*b
+ 6*a*b**2*x + 3*b**3*x**2) + 6*a*b*x*log(a/b + x)/(3*a**2*b + 6*a*b**2*x + 3*b**3*x**2) + 2*a*b*x/(3*a**2*b
+ 6*a*b**2*x + 3*b**3*x**2) + 3*b**2*x**2*log(a/b + x)/(3*a**2*b + 6*a*b**2*x + 3*b**3*x**2) - 5*b**2*x**2/(3*
a**2*b + 6*a*b**2*x + 3*b**3*x**2), Eq(m, -5)), (-12*a**2*log(a/b + x)/(3*a*b + 3*b**2*x) - 11*a**2/(3*a*b + 3
*b**2*x) - 12*a*b*x*log(a/b + x)/(3*a*b + 3*b**2*x) + 4*a*b*x/(3*a*b + 3*b**2*x) + 3*b**2*x**2/(3*a*b + 3*b**2
*x), Eq(m, -4)), (4*a**2*log(a/b + x)/b - 3*a*x + b*x**2/2, Eq(m, -3)), (a**5*m**2*(a + b*x)**m/(b*m**3 + 12*b
*m**2 + 47*b*m + 60*b) + 11*a**5*m*(a + b*x)**m/(b*m**3 + 12*b*m**2 + 47*b*m + 60*b) + 32*a**5*(a + b*x)**m/(b
*m**3 + 12*b*m**2 + 47*b*m + 60*b) + a**4*b*m**2*x*(a + b*x)**m/(b*m**3 + 12*b*m**2 + 47*b*m + 60*b) + 15*a**4
*b*m*x*(a + b*x)**m/(b*m**3 + 12*b*m**2 + 47*b*m + 60*b) + 60*a**4*b*x*(a + b*x)**m/(b*m**3 + 12*b*m**2 + 47*b
*m + 60*b) - 2*a**3*b**2*m**2*x**2*(a + b*x)**m/(b*m**3 + 12*b*m**2 + 47*b*m + 60*b) - 14*a**3*b**2*m*x**2*(a
+ b*x)**m/(b*m**3 + 12*b*m**2 + 47*b*m + 60*b) - 2*a**2*b**3*m**2*x**3*(a + b*x)**m/(b*m**3 + 12*b*m**2 + 47*b
*m + 60*b) - 22*a**2*b**3*m*x**3*(a + b*x)**m/(b*m**3 + 12*b*m**2 + 47*b*m + 60*b) - 40*a**2*b**3*x**3*(a + b*
x)**m/(b*m**3 + 12*b*m**2 + 47*b*m + 60*b) + a*b**4*m**2*x**4*(a + b*x)**m/(b*m**3 + 12*b*m**2 + 47*b*m + 60*b
) + 3*a*b**4*m*x**4*(a + b*x)**m/(b*m**3 + 12*b*m**2 + 47*b*m + 60*b) + b**5*m**2*x**5*(a + b*x)**m/(b*m**3 +
12*b*m**2 + 47*b*m + 60*b) + 7*b**5*m*x**5*(a + b*x)**m/(b*m**3 + 12*b*m**2 + 47*b*m + 60*b) + 12*b**5*x**5*(a
+ b*x)**m/(b*m**3 + 12*b*m**2 + 47*b*m + 60*b), True))

________________________________________________________________________________________

Giac [B]  time = 1.28296, size = 389, normalized size = 6.38 \begin{align*} \frac{{\left (b x + a\right )}^{m} b^{5} m^{2} x^{5} +{\left (b x + a\right )}^{m} a b^{4} m^{2} x^{4} + 7 \,{\left (b x + a\right )}^{m} b^{5} m x^{5} - 2 \,{\left (b x + a\right )}^{m} a^{2} b^{3} m^{2} x^{3} + 3 \,{\left (b x + a\right )}^{m} a b^{4} m x^{4} + 12 \,{\left (b x + a\right )}^{m} b^{5} x^{5} - 2 \,{\left (b x + a\right )}^{m} a^{3} b^{2} m^{2} x^{2} - 22 \,{\left (b x + a\right )}^{m} a^{2} b^{3} m x^{3} +{\left (b x + a\right )}^{m} a^{4} b m^{2} x - 14 \,{\left (b x + a\right )}^{m} a^{3} b^{2} m x^{2} - 40 \,{\left (b x + a\right )}^{m} a^{2} b^{3} x^{3} +{\left (b x + a\right )}^{m} a^{5} m^{2} + 15 \,{\left (b x + a\right )}^{m} a^{4} b m x + 11 \,{\left (b x + a\right )}^{m} a^{5} m + 60 \,{\left (b x + a\right )}^{m} a^{4} b x + 32 \,{\left (b x + a\right )}^{m} a^{5}}{b m^{3} + 12 \, b m^{2} + 47 \, b m + 60 \, b} \end{align*}

Veriﬁcation of antiderivative is not currently implemented for this CAS.

[In]

integrate((b*x+a)^m*(-b^2*x^2+a^2)^2,x, algorithm="giac")

[Out]

((b*x + a)^m*b^5*m^2*x^5 + (b*x + a)^m*a*b^4*m^2*x^4 + 7*(b*x + a)^m*b^5*m*x^5 - 2*(b*x + a)^m*a^2*b^3*m^2*x^3
+ 3*(b*x + a)^m*a*b^4*m*x^4 + 12*(b*x + a)^m*b^5*x^5 - 2*(b*x + a)^m*a^3*b^2*m^2*x^2 - 22*(b*x + a)^m*a^2*b^3
*m*x^3 + (b*x + a)^m*a^4*b*m^2*x - 14*(b*x + a)^m*a^3*b^2*m*x^2 - 40*(b*x + a)^m*a^2*b^3*x^3 + (b*x + a)^m*a^5
*m^2 + 15*(b*x + a)^m*a^4*b*m*x + 11*(b*x + a)^m*a^5*m + 60*(b*x + a)^m*a^4*b*x + 32*(b*x + a)^m*a^5)/(b*m^3 +
12*b*m^2 + 47*b*m + 60*b)