### 3.371 $$\int \frac{(d+e x)^m (2+x+3 x^2-5 x^3+4 x^4)}{(3+2 x+5 x^2)^2} \, dx$$

Optimal. Leaf size=377 $\frac{\left (i \sqrt{14} \left (6565 d^2-2 d e (1313-3206 m)+e^2 (3939-98 m)\right )+80360 d^2-5922 d e m-32144 d e+19138 e^2 m+48216 e^2\right ) (d+e x)^{m+1} \, _2F_1\left (1,m+1;m+2;\frac{5 (d+e x)}{5 d+i \sqrt{14} e-e}\right )}{19600 (m+1) \left (5 d+i \left (\sqrt{14}+i\right ) e\right ) \left (5 d^2-2 d e+3 e^2\right )}+\frac{\left (-i \sqrt{14} \left (6565 d^2-2 d e (1313-3206 m)+e^2 (3939-98 m)\right )+80360 d^2-5922 d e m-32144 d e+19138 e^2 m+48216 e^2\right ) (d+e x)^{m+1} \, _2F_1\left (1,m+1;m+2;\frac{5 (d+e x)}{5 d-\left (1+i \sqrt{14}\right ) e}\right )}{19600 (m+1) \left (5 d-\left (1+i \sqrt{14}\right ) e\right ) \left (5 d^2-2 d e+3 e^2\right )}-\frac{(x (423 d-1367 e)+1367 d-293 e) (d+e x)^{m+1}}{700 \left (5 x^2+2 x+3\right ) \left (5 d^2-2 d e+3 e^2\right )}+\frac{4 (d+e x)^{m+1}}{25 e (m+1)}$

[Out]

(4*(d + e*x)^(1 + m))/(25*e*(1 + m)) - ((1367*d - 293*e + (423*d - 1367*e)*x)*(d + e*x)^(1 + m))/(700*(5*d^2 -
2*d*e + 3*e^2)*(3 + 2*x + 5*x^2)) + ((80360*d^2 - 32144*d*e + 48216*e^2 + I*Sqrt[14]*(6565*d^2 - 2*d*e*(1313
- 3206*m) + e^2*(3939 - 98*m)) - 5922*d*e*m + 19138*e^2*m)*(d + e*x)^(1 + m)*Hypergeometric2F1[1, 1 + m, 2 + m
, (5*(d + e*x))/(5*d - e + I*Sqrt[14]*e)])/(19600*(5*d + I*(I + Sqrt[14])*e)*(5*d^2 - 2*d*e + 3*e^2)*(1 + m))
+ ((80360*d^2 - 32144*d*e + 48216*e^2 - I*Sqrt[14]*(6565*d^2 - 2*d*e*(1313 - 3206*m) + e^2*(3939 - 98*m)) - 59
22*d*e*m + 19138*e^2*m)*(d + e*x)^(1 + m)*Hypergeometric2F1[1, 1 + m, 2 + m, (5*(d + e*x))/(5*d - (1 + I*Sqrt[
14])*e)])/(19600*(5*d - (1 + I*Sqrt[14])*e)*(5*d^2 - 2*d*e + 3*e^2)*(1 + m))

________________________________________________________________________________________

Rubi [A]  time = 0.899862, antiderivative size = 377, normalized size of antiderivative = 1., number of steps used = 5, number of rules used = 3, integrand size = 38, $$\frac{\text{number of rules}}{\text{integrand size}}$$ = 0.079, Rules used = {1648, 1628, 68} $\frac{\left (i \sqrt{14} \left (6565 d^2-2 d e (1313-3206 m)+e^2 (3939-98 m)\right )+80360 d^2-5922 d e m-32144 d e+19138 e^2 m+48216 e^2\right ) (d+e x)^{m+1} \, _2F_1\left (1,m+1;m+2;\frac{5 (d+e x)}{5 d+i \sqrt{14} e-e}\right )}{19600 (m+1) \left (5 d+i \left (\sqrt{14}+i\right ) e\right ) \left (5 d^2-2 d e+3 e^2\right )}+\frac{\left (-i \sqrt{14} \left (6565 d^2-2 d e (1313-3206 m)+e^2 (3939-98 m)\right )+80360 d^2-5922 d e m-32144 d e+19138 e^2 m+48216 e^2\right ) (d+e x)^{m+1} \, _2F_1\left (1,m+1;m+2;\frac{5 (d+e x)}{5 d-\left (1+i \sqrt{14}\right ) e}\right )}{19600 (m+1) \left (5 d-\left (1+i \sqrt{14}\right ) e\right ) \left (5 d^2-2 d e+3 e^2\right )}-\frac{(x (423 d-1367 e)+1367 d-293 e) (d+e x)^{m+1}}{700 \left (5 x^2+2 x+3\right ) \left (5 d^2-2 d e+3 e^2\right )}+\frac{4 (d+e x)^{m+1}}{25 e (m+1)}$

Antiderivative was successfully veriﬁed.

[In]

Int[((d + e*x)^m*(2 + x + 3*x^2 - 5*x^3 + 4*x^4))/(3 + 2*x + 5*x^2)^2,x]

[Out]

(4*(d + e*x)^(1 + m))/(25*e*(1 + m)) - ((1367*d - 293*e + (423*d - 1367*e)*x)*(d + e*x)^(1 + m))/(700*(5*d^2 -
2*d*e + 3*e^2)*(3 + 2*x + 5*x^2)) + ((80360*d^2 - 32144*d*e + 48216*e^2 + I*Sqrt[14]*(6565*d^2 - 2*d*e*(1313
- 3206*m) + e^2*(3939 - 98*m)) - 5922*d*e*m + 19138*e^2*m)*(d + e*x)^(1 + m)*Hypergeometric2F1[1, 1 + m, 2 + m
, (5*(d + e*x))/(5*d - e + I*Sqrt[14]*e)])/(19600*(5*d + I*(I + Sqrt[14])*e)*(5*d^2 - 2*d*e + 3*e^2)*(1 + m))
+ ((80360*d^2 - 32144*d*e + 48216*e^2 - I*Sqrt[14]*(6565*d^2 - 2*d*e*(1313 - 3206*m) + e^2*(3939 - 98*m)) - 59
22*d*e*m + 19138*e^2*m)*(d + e*x)^(1 + m)*Hypergeometric2F1[1, 1 + m, 2 + m, (5*(d + e*x))/(5*d - (1 + I*Sqrt[
14])*e)])/(19600*(5*d - (1 + I*Sqrt[14])*e)*(5*d^2 - 2*d*e + 3*e^2)*(1 + m))

Rule 1648

Int[(Pq_)*((d_.) + (e_.)*(x_))^(m_.)*((a_.) + (b_.)*(x_) + (c_.)*(x_)^2)^(p_), x_Symbol] :> With[{Q = Polynomi
alQuotient[Pq, a + b*x + c*x^2, x], f = Coeff[PolynomialRemainder[Pq, a + b*x + c*x^2, x], x, 0], g = Coeff[Po
lynomialRemainder[Pq, a + b*x + c*x^2, x], x, 1]}, Simp[((d + e*x)^(m + 1)*(a + b*x + c*x^2)^(p + 1)*(f*(b*c*d
- b^2*e + 2*a*c*e) - a*g*(2*c*d - b*e) + c*(f*(2*c*d - b*e) - g*(b*d - 2*a*e))*x))/((p + 1)*(b^2 - 4*a*c)*(c*
d^2 - b*d*e + a*e^2)), x] + Dist[1/((p + 1)*(b^2 - 4*a*c)*(c*d^2 - b*d*e + a*e^2)), Int[(d + e*x)^m*(a + b*x +
c*x^2)^(p + 1)*ExpandToSum[(p + 1)*(b^2 - 4*a*c)*(c*d^2 - b*d*e + a*e^2)*Q + f*(b*c*d*e*(2*p - m + 2) + b^2*e
^2*(p + m + 2) - 2*c^2*d^2*(2*p + 3) - 2*a*c*e^2*(m + 2*p + 3)) - g*(a*e*(b*e - 2*c*d*m + b*e*m) - b*d*(3*c*d
- b*e + 2*c*d*p - b*e*p)) + c*e*(g*(b*d - 2*a*e) - f*(2*c*d - b*e))*(m + 2*p + 4)*x, x], x], x]] /; FreeQ[{a,
b, c, d, e, m}, x] && PolyQ[Pq, x] && NeQ[b^2 - 4*a*c, 0] && NeQ[c*d^2 - b*d*e + a*e^2, 0] && LtQ[p, -1] &&  !
(IGtQ[m, 0] && RationalQ[a, b, c, d, e] && (IntegerQ[p] || ILtQ[p + 1/2, 0]))

Rule 1628

Int[(Pq_)*((d_.) + (e_.)*(x_))^(m_.)*((a_.) + (b_.)*(x_) + (c_.)*(x_)^2)^(p_.), x_Symbol] :> Int[ExpandIntegra
nd[(d + e*x)^m*Pq*(a + b*x + c*x^2)^p, x], x] /; FreeQ[{a, b, c, d, e, m}, x] && PolyQ[Pq, x] && IGtQ[p, -2]

Rule 68

Int[((a_) + (b_.)*(x_))^(m_)*((c_) + (d_.)*(x_))^(n_), x_Symbol] :> Simp[((b*c - a*d)^n*(a + b*x)^(m + 1)*Hype
rgeometric2F1[-n, m + 1, m + 2, -((d*(a + b*x))/(b*c - a*d))])/(b^(n + 1)*(m + 1)), x] /; FreeQ[{a, b, c, d, m
}, x] && NeQ[b*c - a*d, 0] &&  !IntegerQ[m] && IntegerQ[n]

Rubi steps

\begin{align*} \int \frac{(d+e x)^m \left (2+x+3 x^2-5 x^3+4 x^4\right )}{\left (3+2 x+5 x^2\right )^2} \, dx &=-\frac{(1367 d-293 e+(423 d-1367 e) x) (d+e x)^{1+m}}{700 \left (5 d^2-2 d e+3 e^2\right ) \left (3+2 x+5 x^2\right )}+\frac{\int \frac{(d+e x)^m \left (\frac{2}{25} \left (1845 d^2-d e (738-1367 m)+e^2 (1107-293 m)\right )-\frac{2}{25} \left (4620 d^2-3 d e (616+141 m)+e^2 (2772+1367 m)\right ) x+\frac{224}{5} \left (5 d^2-2 d e+3 e^2\right ) x^2\right )}{3+2 x+5 x^2} \, dx}{56 \left (5 d^2-2 d e+3 e^2\right )}\\ &=-\frac{(1367 d-293 e+(423 d-1367 e) x) (d+e x)^{1+m}}{700 \left (5 d^2-2 d e+3 e^2\right ) \left (3+2 x+5 x^2\right )}+\frac{\int \left (\frac{224}{25} \left (5 d^2-2 d e+3 e^2\right ) (d+e x)^m+\frac{\left (-\frac{2296 d^2}{5}+\frac{4592 d e}{25}-\frac{6888 e^2}{25}+\frac{846 d e m}{25}-\frac{2734 e^2 m}{25}-\frac{1}{25} i \sqrt{\frac{2}{7}} \left (6565 d^2-2626 d e+3939 e^2+6412 d e m-98 e^2 m\right )\right ) (d+e x)^m}{2-2 i \sqrt{14}+10 x}+\frac{\left (-\frac{2296 d^2}{5}+\frac{4592 d e}{25}-\frac{6888 e^2}{25}+\frac{846 d e m}{25}-\frac{2734 e^2 m}{25}+\frac{1}{25} i \sqrt{\frac{2}{7}} \left (6565 d^2-2626 d e+3939 e^2+6412 d e m-98 e^2 m\right )\right ) (d+e x)^m}{2+2 i \sqrt{14}+10 x}\right ) \, dx}{56 \left (5 d^2-2 d e+3 e^2\right )}\\ &=\frac{4 (d+e x)^{1+m}}{25 e (1+m)}-\frac{(1367 d-293 e+(423 d-1367 e) x) (d+e x)^{1+m}}{700 \left (5 d^2-2 d e+3 e^2\right ) \left (3+2 x+5 x^2\right )}-\frac{\left (80360 d^2-32144 d e+48216 e^2-i \sqrt{14} \left (6565 d^2-2 d e (1313-3206 m)+e^2 (3939-98 m)\right )-5922 d e m+19138 e^2 m\right ) \int \frac{(d+e x)^m}{2+2 i \sqrt{14}+10 x} \, dx}{9800 \left (5 d^2-2 d e+3 e^2\right )}-\frac{\left (80360 d^2-32144 d e+48216 e^2+i \sqrt{14} \left (6565 d^2-2 d e (1313-3206 m)+e^2 (3939-98 m)\right )-5922 d e m+19138 e^2 m\right ) \int \frac{(d+e x)^m}{2-2 i \sqrt{14}+10 x} \, dx}{9800 \left (5 d^2-2 d e+3 e^2\right )}\\ &=\frac{4 (d+e x)^{1+m}}{25 e (1+m)}-\frac{(1367 d-293 e+(423 d-1367 e) x) (d+e x)^{1+m}}{700 \left (5 d^2-2 d e+3 e^2\right ) \left (3+2 x+5 x^2\right )}+\frac{\left (80360 d^2-32144 d e+48216 e^2+i \sqrt{14} \left (6565 d^2-2 d e (1313-3206 m)+e^2 (3939-98 m)\right )-5922 d e m+19138 e^2 m\right ) (d+e x)^{1+m} \, _2F_1\left (1,1+m;2+m;\frac{5 (d+e x)}{5 d-e+i \sqrt{14} e}\right )}{19600 \left (5 d+i \left (i+\sqrt{14}\right ) e\right ) \left (5 d^2-2 d e+3 e^2\right ) (1+m)}+\frac{\left (80360 d^2-32144 d e+48216 e^2-i \sqrt{14} \left (6565 d^2-2 d e (1313-3206 m)+e^2 (3939-98 m)\right )-5922 d e m+19138 e^2 m\right ) (d+e x)^{1+m} \, _2F_1\left (1,1+m;2+m;\frac{5 (d+e x)}{5 d-\left (1+i \sqrt{14}\right ) e}\right )}{19600 \left (5 d-\left (1+i \sqrt{14}\right ) e\right ) \left (5 d^2-2 d e+3 e^2\right ) (1+m)}\\ \end{align*}

Mathematica [A]  time = 1.75703, size = 441, normalized size = 1.17 $\frac{(d+e x)^{m+1} \left (-\frac{\sqrt{14} \left (\frac{\left (2115 d^2+d e \left (-846+\left (-6412+423 i \sqrt{14}\right ) m\right )+e^2 \left (1269+\left (98-1367 i \sqrt{14}\right ) m\right )\right ) \, _2F_1\left (1,m+1;m+2;\frac{5 (d+e x)}{5 d+\left (-1-i \sqrt{14}\right ) e}\right )}{5 i d+\left (\sqrt{14}-i\right ) e}-\frac{\left (2115 d^2-d e \left (846+\left (6412+423 i \sqrt{14}\right ) m\right )+e^2 \left (1269+\left (98+1367 i \sqrt{14}\right ) m\right )\right ) \, _2F_1\left (1,m+1;m+2;\frac{5 (d+e x)}{5 d+i \left (i+\sqrt{14}\right ) e}\right )}{5 i d-\left (\sqrt{14}+i\right ) e}\right )}{(m+1) \left (5 d^2-2 d e+3 e^2\right )}-\frac{28 (d (423 x+1367)-e (1367 x+293))}{\left (5 x^2+2 x+3\right ) \left (5 d^2-2 d e+3 e^2\right )}+\frac{56 \left (31 \sqrt{14}+287 i\right ) \, _2F_1\left (1,m+1;m+2;\frac{5 (d+e x)}{5 d+\left (-1-i \sqrt{14}\right ) e}\right )}{(m+1) \left (5 i d+\left (\sqrt{14}-i\right ) e\right )}+\frac{56 \left (31 \sqrt{14}-287 i\right ) \, _2F_1\left (1,m+1;m+2;\frac{5 (d+e x)}{5 d+i \left (i+\sqrt{14}\right ) e}\right )}{(m+1) \left (\left (\sqrt{14}+i\right ) e-5 i d\right )}+\frac{3136}{e m+e}\right )}{19600}$

Antiderivative was successfully veriﬁed.

[In]

Integrate[((d + e*x)^m*(2 + x + 3*x^2 - 5*x^3 + 4*x^4))/(3 + 2*x + 5*x^2)^2,x]

[Out]

((d + e*x)^(1 + m)*(3136/(e + e*m) - (28*(d*(1367 + 423*x) - e*(293 + 1367*x)))/((5*d^2 - 2*d*e + 3*e^2)*(3 +
2*x + 5*x^2)) + (56*(287*I + 31*Sqrt[14])*Hypergeometric2F1[1, 1 + m, 2 + m, (5*(d + e*x))/(5*d + (-1 - I*Sqrt
[14])*e)])/(((5*I)*d + (-I + Sqrt[14])*e)*(1 + m)) + (56*(-287*I + 31*Sqrt[14])*Hypergeometric2F1[1, 1 + m, 2
+ m, (5*(d + e*x))/(5*d + I*(I + Sqrt[14])*e)])/(((-5*I)*d + (I + Sqrt[14])*e)*(1 + m)) - (Sqrt[14]*(((2115*d^
2 + d*e*(-846 + (-6412 + (423*I)*Sqrt[14])*m) + e^2*(1269 + (98 - (1367*I)*Sqrt[14])*m))*Hypergeometric2F1[1,
1 + m, 2 + m, (5*(d + e*x))/(5*d + (-1 - I*Sqrt[14])*e)])/((5*I)*d + (-I + Sqrt[14])*e) - ((2115*d^2 - d*e*(84
6 + (6412 + (423*I)*Sqrt[14])*m) + e^2*(1269 + (98 + (1367*I)*Sqrt[14])*m))*Hypergeometric2F1[1, 1 + m, 2 + m,
(5*(d + e*x))/(5*d + I*(I + Sqrt[14])*e)])/((5*I)*d - (I + Sqrt[14])*e)))/((5*d^2 - 2*d*e + 3*e^2)*(1 + m))))
/19600

________________________________________________________________________________________

Maple [F]  time = 2.375, size = 0, normalized size = 0. \begin{align*} \int{\frac{ \left ( ex+d \right ) ^{m} \left ( 4\,{x}^{4}-5\,{x}^{3}+3\,{x}^{2}+x+2 \right ) }{ \left ( 5\,{x}^{2}+2\,x+3 \right ) ^{2}}}\, dx \end{align*}

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

[In]

int((e*x+d)^m*(4*x^4-5*x^3+3*x^2+x+2)/(5*x^2+2*x+3)^2,x)

[Out]

int((e*x+d)^m*(4*x^4-5*x^3+3*x^2+x+2)/(5*x^2+2*x+3)^2,x)

________________________________________________________________________________________

Maxima [F]  time = 0., size = 0, normalized size = 0. \begin{align*} \int \frac{{\left (4 \, x^{4} - 5 \, x^{3} + 3 \, x^{2} + x + 2\right )}{\left (e x + d\right )}^{m}}{{\left (5 \, x^{2} + 2 \, x + 3\right )}^{2}}\,{d x} \end{align*}

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

[In]

integrate((e*x+d)^m*(4*x^4-5*x^3+3*x^2+x+2)/(5*x^2+2*x+3)^2,x, algorithm="maxima")

[Out]

integrate((4*x^4 - 5*x^3 + 3*x^2 + x + 2)*(e*x + d)^m/(5*x^2 + 2*x + 3)^2, x)

________________________________________________________________________________________

Fricas [F]  time = 0., size = 0, normalized size = 0. \begin{align*}{\rm integral}\left (\frac{{\left (4 \, x^{4} - 5 \, x^{3} + 3 \, x^{2} + x + 2\right )}{\left (e x + d\right )}^{m}}{25 \, x^{4} + 20 \, x^{3} + 34 \, x^{2} + 12 \, x + 9}, x\right ) \end{align*}

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

[In]

integrate((e*x+d)^m*(4*x^4-5*x^3+3*x^2+x+2)/(5*x^2+2*x+3)^2,x, algorithm="fricas")

[Out]

integral((4*x^4 - 5*x^3 + 3*x^2 + x + 2)*(e*x + d)^m/(25*x^4 + 20*x^3 + 34*x^2 + 12*x + 9), x)

________________________________________________________________________________________

Sympy [F(-1)]  time = 0., size = 0, normalized size = 0. \begin{align*} \text{Timed out} \end{align*}

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

[In]

integrate((e*x+d)**m*(4*x**4-5*x**3+3*x**2+x+2)/(5*x**2+2*x+3)**2,x)

[Out]

Timed out

________________________________________________________________________________________

Giac [F]  time = 0., size = 0, normalized size = 0. \begin{align*} \int \frac{{\left (4 \, x^{4} - 5 \, x^{3} + 3 \, x^{2} + x + 2\right )}{\left (e x + d\right )}^{m}}{{\left (5 \, x^{2} + 2 \, x + 3\right )}^{2}}\,{d x} \end{align*}

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

[In]

integrate((e*x+d)^m*(4*x^4-5*x^3+3*x^2+x+2)/(5*x^2+2*x+3)^2,x, algorithm="giac")

[Out]

integrate((4*x^4 - 5*x^3 + 3*x^2 + x + 2)*(e*x + d)^m/(5*x^2 + 2*x + 3)^2, x)