3.2.88 \(\int \frac {2 e^{-x} (2-x) \sqrt {e^{2+x} x^2}}{x} \, dx\)

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

________________________________________________________________________________________

Rubi [B]  time = 0.33, antiderivative size = 52, normalized size of antiderivative = 2.60, number of steps used = 6, number of rules used = 6, integrand size = 28, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.214, Rules used = {12, 6719, 2281, 2187, 2176, 2194} \begin {gather*} \frac {8 e^{-x} \sqrt {e^{x+2} x^2}}{x}-\frac {4 e^{-x} (2-x) \sqrt {e^{x+2} x^2}}{x} \end {gather*}

Antiderivative was successfully verified.

[In]

Int[(2*(2 - x)*Sqrt[E^(2 + x)*x^2])/(E^x*x),x]

[Out]

(8*Sqrt[E^(2 + x)*x^2])/(E^x*x) - (4*(2 - x)*Sqrt[E^(2 + x)*x^2])/(E^x*x)

Rule 12

Int[(a_)*(u_), x_Symbol] :> Dist[a, Int[u, x], x] /; FreeQ[a, x] &&  !MatchQ[u, (b_)*(v_) /; FreeQ[b, x]]

Rule 2176

Int[((b_.)*(F_)^((g_.)*((e_.) + (f_.)*(x_))))^(n_.)*((c_.) + (d_.)*(x_))^(m_.), x_Symbol] :> Simp[((c + d*x)^m
*(b*F^(g*(e + f*x)))^n)/(f*g*n*Log[F]), x] - Dist[(d*m)/(f*g*n*Log[F]), Int[(c + d*x)^(m - 1)*(b*F^(g*(e + f*x
)))^n, x], x] /; FreeQ[{F, b, c, d, e, f, g, n}, x] && GtQ[m, 0] && IntegerQ[2*m] &&  !$UseGamma === True

Rule 2187

Int[((a_.) + (b_.)*((F_)^((g_.)*(v_)))^(n_.))^(p_.)*(u_)^(m_.), x_Symbol] :> Int[NormalizePowerOfLinear[u, x]^
m*(a + b*(F^(g*ExpandToSum[v, x]))^n)^p, x] /; FreeQ[{F, a, b, g, n, p}, x] && LinearQ[v, x] && PowerOfLinearQ
[u, x] &&  !(LinearMatchQ[v, x] && PowerOfLinearMatchQ[u, x]) && IntegerQ[m]

Rule 2194

Int[((F_)^((c_.)*((a_.) + (b_.)*(x_))))^(n_.), x_Symbol] :> Simp[(F^(c*(a + b*x)))^n/(b*c*n*Log[F]), x] /; Fre
eQ[{F, a, b, c, n}, x]

Rule 2281

Int[(u_.)*((a_.)*(F_)^(v_))^(n_), x_Symbol] :> Dist[(a*F^v)^n/F^(n*v), Int[u*F^(n*v), x], x] /; FreeQ[{F, a, n
}, x] &&  !IntegerQ[n]

Rule 6719

Int[(u_.)*((a_.)*(v_)^(m_.)*(w_)^(n_.))^(p_), x_Symbol] :> Dist[(a^IntPart[p]*(a*v^m*w^n)^FracPart[p])/(v^(m*F
racPart[p])*w^(n*FracPart[p])), Int[u*v^(m*p)*w^(n*p), x], x] /; FreeQ[{a, m, n, p}, x] &&  !IntegerQ[p] &&  !
FreeQ[v, x] &&  !FreeQ[w, x]

Rubi steps

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

________________________________________________________________________________________

Mathematica [A]  time = 0.01, size = 21, normalized size = 1.05 \begin {gather*} \frac {4 e^2 x^2}{\sqrt {e^{2+x} x^2}} \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[(2*(2 - x)*Sqrt[E^(2 + x)*x^2])/(E^x*x),x]

[Out]

(4*E^2*x^2)/Sqrt[E^(2 + x)*x^2]

________________________________________________________________________________________

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

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(2*(2-x)*(x^2*exp(2+x))^(1/2)/exp(x)/x,x, algorithm="fricas")

[Out]

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

________________________________________________________________________________________

giac [A]  time = 0.31, size = 11, normalized size = 0.55 \begin {gather*} 4 \, x e^{\left (-\frac {1}{2} \, x + 1\right )} \mathrm {sgn}\relax (x) \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(2*(2-x)*(x^2*exp(2+x))^(1/2)/exp(x)/x,x, algorithm="giac")

[Out]

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

________________________________________________________________________________________

maple [A]  time = 0.04, size = 17, normalized size = 0.85




method result size



gosper \(4 \sqrt {x^{2} {\mathrm e}^{2+x}}\, {\mathrm e}^{-x}\) \(17\)
risch \(4 \sqrt {x^{2} {\mathrm e}^{2+x}}\, {\mathrm e}^{-x}\) \(17\)



Verification of antiderivative is not currently implemented for this CAS.

[In]

int(2*(2-x)*(x^2*exp(2+x))^(1/2)/exp(x)/x,x,method=_RETURNVERBOSE)

[Out]

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

________________________________________________________________________________________

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

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(2*(2-x)*(x^2*exp(2+x))^(1/2)/exp(x)/x,x, algorithm="maxima")

[Out]

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

________________________________________________________________________________________

mupad [B]  time = 0.34, size = 13, normalized size = 0.65 \begin {gather*} 4\,{\mathrm {e}}^{1-\frac {x}{2}}\,\sqrt {x^2} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(-(2*exp(-x)*(x^2*exp(x + 2))^(1/2)*(x - 2))/x,x)

[Out]

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

________________________________________________________________________________________

sympy [A]  time = 67.17, size = 20, normalized size = 1.00 \begin {gather*} 4 e \sqrt {x^{2}} e^{- x} \sqrt {e^{x}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(2*(2-x)*(x**2*exp(2+x))**(1/2)/exp(x)/x,x)

[Out]

4*E*sqrt(x**2)*exp(-x)*sqrt(exp(x))

________________________________________________________________________________________