3.98.97 \(\int \frac {16-2 e^{\frac {2 x}{-4+2 x}}-16 x+4 x^2+16 x^3-16 x^4+4 x^5}{4-4 x+x^2} \, dx\)

Optimal. Leaf size=19 \[ e^{\frac {2 x}{-4+2 x}}+4 x+x^4 \]

________________________________________________________________________________________

Rubi [A]  time = 0.14, antiderivative size = 20, normalized size of antiderivative = 1.05, number of steps used = 5, number of rules used = 4, integrand size = 50, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.080, Rules used = {27, 6688, 2230, 2209} \begin {gather*} x^4+4 x+e^{1-\frac {2}{2-x}} \end {gather*}

Antiderivative was successfully verified.

[In]

Int[(16 - 2*E^((2*x)/(-4 + 2*x)) - 16*x + 4*x^2 + 16*x^3 - 16*x^4 + 4*x^5)/(4 - 4*x + x^2),x]

[Out]

E^(1 - 2/(2 - x)) + 4*x + x^4

Rule 27

Int[(u_.)*((a_) + (b_.)*(x_) + (c_.)*(x_)^2)^(p_.), x_Symbol] :> Int[u*Cancel[(b/2 + c*x)^(2*p)/c^p], x] /; Fr
eeQ[{a, b, c}, x] && EqQ[b^2 - 4*a*c, 0] && IntegerQ[p]

Rule 2209

Int[(F_)^((a_.) + (b_.)*((c_.) + (d_.)*(x_))^(n_))*((e_.) + (f_.)*(x_))^(m_.), x_Symbol] :> Simp[((e + f*x)^n*
F^(a + b*(c + d*x)^n))/(b*f*n*(c + d*x)^n*Log[F]), x] /; FreeQ[{F, a, b, c, d, e, f, n}, x] && EqQ[m, n - 1] &
& EqQ[d*e - c*f, 0]

Rule 2230

Int[(F_)^((e_.) + ((f_.)*((a_.) + (b_.)*(x_)))/((c_.) + (d_.)*(x_)))*((g_.) + (h_.)*(x_))^(m_.), x_Symbol] :>
Int[(g + h*x)^m*F^((d*e + b*f)/d - (f*(b*c - a*d))/(d*(c + d*x))), x] /; FreeQ[{F, a, b, c, d, e, f, g, h, m},
 x] && NeQ[b*c - a*d, 0] && EqQ[d*g - c*h, 0]

Rule 6688

Int[u_, x_Symbol] :> With[{v = SimplifyIntegrand[u, x]}, Int[v, x] /; SimplerIntegrandQ[v, u, x]]

Rubi steps

\begin {gather*} \begin {aligned} \text {integral} &=\int \frac {16-2 e^{\frac {2 x}{-4+2 x}}-16 x+4 x^2+16 x^3-16 x^4+4 x^5}{(-2+x)^2} \, dx\\ &=\int \left (4-\frac {2 e^{\frac {x}{-2+x}}}{(-2+x)^2}+4 x^3\right ) \, dx\\ &=4 x+x^4-2 \int \frac {e^{\frac {x}{-2+x}}}{(-2+x)^2} \, dx\\ &=4 x+x^4-2 \int \frac {e^{1+\frac {2}{-2+x}}}{(-2+x)^2} \, dx\\ &=e^{1-\frac {2}{2-x}}+4 x+x^4\\ \end {aligned} \end {gather*}

________________________________________________________________________________________

Mathematica [A]  time = 0.02, size = 16, normalized size = 0.84 \begin {gather*} e^{\frac {x}{-2+x}}+4 x+x^4 \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[(16 - 2*E^((2*x)/(-4 + 2*x)) - 16*x + 4*x^2 + 16*x^3 - 16*x^4 + 4*x^5)/(4 - 4*x + x^2),x]

[Out]

E^(x/(-2 + x)) + 4*x + x^4

________________________________________________________________________________________

fricas [A]  time = 0.69, size = 15, normalized size = 0.79 \begin {gather*} x^{4} + 4 \, x + e^{\left (\frac {x}{x - 2}\right )} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((-2*exp(x/(2*x-4))^2+4*x^5-16*x^4+16*x^3+4*x^2-16*x+16)/(x^2-4*x+4),x, algorithm="fricas")

[Out]

x^4 + 4*x + e^(x/(x - 2))

________________________________________________________________________________________

giac [B]  time = 0.22, size = 153, normalized size = 8.05 \begin {gather*} \frac {\frac {4 \, x e^{\left (\frac {x}{x - 2}\right )}}{x - 2} - \frac {6 \, x^{2} e^{\left (\frac {x}{x - 2}\right )}}{{\left (x - 2\right )}^{2}} + \frac {4 \, x^{3} e^{\left (\frac {x}{x - 2}\right )}}{{\left (x - 2\right )}^{3}} - \frac {x^{4} e^{\left (\frac {x}{x - 2}\right )}}{{\left (x - 2\right )}^{4}} - \frac {88 \, x}{x - 2} + \frac {120 \, x^{2}}{{\left (x - 2\right )}^{2}} - \frac {72 \, x^{3}}{{\left (x - 2\right )}^{3}} - e^{\left (\frac {x}{x - 2}\right )} + 24}{\frac {4 \, x}{x - 2} - \frac {6 \, x^{2}}{{\left (x - 2\right )}^{2}} + \frac {4 \, x^{3}}{{\left (x - 2\right )}^{3}} - \frac {x^{4}}{{\left (x - 2\right )}^{4}} - 1} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((-2*exp(x/(2*x-4))^2+4*x^5-16*x^4+16*x^3+4*x^2-16*x+16)/(x^2-4*x+4),x, algorithm="giac")

[Out]

(4*x*e^(x/(x - 2))/(x - 2) - 6*x^2*e^(x/(x - 2))/(x - 2)^2 + 4*x^3*e^(x/(x - 2))/(x - 2)^3 - x^4*e^(x/(x - 2))
/(x - 2)^4 - 88*x/(x - 2) + 120*x^2/(x - 2)^2 - 72*x^3/(x - 2)^3 - e^(x/(x - 2)) + 24)/(4*x/(x - 2) - 6*x^2/(x
 - 2)^2 + 4*x^3/(x - 2)^3 - x^4/(x - 2)^4 - 1)

________________________________________________________________________________________

maple [A]  time = 0.13, size = 16, normalized size = 0.84




method result size



risch \(4 x +x^{4}+{\mathrm e}^{\frac {x}{x -2}}\) \(16\)
derivativedivides \(36 x -72+\left (x -2\right )^{4}+8 \left (x -2\right )^{3}+24 \left (x -2\right )^{2}+{\mathrm e}^{1+\frac {2}{x -2}}\) \(35\)
default \(36 x -72+\left (x -2\right )^{4}+8 \left (x -2\right )^{3}+24 \left (x -2\right )^{2}+{\mathrm e}^{1+\frac {2}{x -2}}\) \(35\)
norman \(\frac {x^{5}+x \,{\mathrm e}^{\frac {2 x}{2 x -4}}+4 x^{2}-2 x^{4}-2 \,{\mathrm e}^{\frac {2 x}{2 x -4}}-16}{x -2}\) \(50\)



Verification of antiderivative is not currently implemented for this CAS.

[In]

int((-2*exp(x/(2*x-4))^2+4*x^5-16*x^4+16*x^3+4*x^2-16*x+16)/(x^2-4*x+4),x,method=_RETURNVERBOSE)

[Out]

4*x+x^4+exp(x/(x-2))

________________________________________________________________________________________

maxima [A]  time = 0.38, size = 17, normalized size = 0.89 \begin {gather*} x^{4} + 4 \, x + e^{\left (\frac {2}{x - 2} + 1\right )} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((-2*exp(x/(2*x-4))^2+4*x^5-16*x^4+16*x^3+4*x^2-16*x+16)/(x^2-4*x+4),x, algorithm="maxima")

[Out]

x^4 + 4*x + e^(2/(x - 2) + 1)

________________________________________________________________________________________

mupad [B]  time = 5.80, size = 15, normalized size = 0.79 \begin {gather*} 4\,x+{\mathrm {e}}^{\frac {x}{x-2}}+x^4 \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((4*x^2 - 2*exp((2*x)/(2*x - 4)) - 16*x + 16*x^3 - 16*x^4 + 4*x^5 + 16)/(x^2 - 4*x + 4),x)

[Out]

4*x + exp(x/(x - 2)) + x^4

________________________________________________________________________________________

sympy [A]  time = 0.14, size = 15, normalized size = 0.79 \begin {gather*} x^{4} + 4 x + e^{\frac {2 x}{2 x - 4}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((-2*exp(x/(2*x-4))**2+4*x**5-16*x**4+16*x**3+4*x**2-16*x+16)/(x**2-4*x+4),x)

[Out]

x**4 + 4*x + exp(2*x/(2*x - 4))

________________________________________________________________________________________