Optimal. Leaf size=20 \[ 4 e^{-x} \sqrt {e^{2+x} x^2} \]
[Out]
________________________________________________________________________________________
Rubi [B] Leaf count is larger than twice the leaf count of optimal. \(52\) vs. \(2(20)=40\).
time = 0.22, 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, 6851, 2319,
2218, 2207, 2225} \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]
[Out]
Rule 12
Rule 2207
Rule 2218
Rule 2225
Rule 2319
Rule 6851
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.05, 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]
[Out]
________________________________________________________________________________________
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]
[Out]
________________________________________________________________________________________
Maxima [A]
time = 0.29, 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]
[Out]
________________________________________________________________________________________
Fricas [A]
time = 0.32, 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]
[Out]
________________________________________________________________________________________
Sympy [A]
time = 46.40, size = 17, normalized size = 0.85 \begin {gather*} 4 e \sqrt {x^{2} e^{x}} e^{- x} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [A]
time = 0.43, size = 24, normalized size = 1.20 \begin {gather*} 4 \, {\left (x - 2\right )} e^{\left (-\frac {1}{2} \, x + 1\right )} \mathrm {sgn}\left (x\right ) + 8 \, e^{\left (-\frac {1}{2} \, x + 1\right )} \mathrm {sgn}\left (x\right ) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
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]
[Out]
________________________________________________________________________________________