Optimal. Leaf size=23 \[ \frac {1}{5} e^{-x} \left (-1+\frac {e^{4+x}}{x}+x^2\right ) \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.15, antiderivative size = 32, normalized size of antiderivative = 1.39, number of steps
used = 9, number of rules used = 4, integrand size = 33, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.121, Rules used = {12, 6874, 2225,
2207} \begin {gather*} \frac {1}{5} e^{-x} x^2-\frac {e^{-x}}{5}+\frac {e^4}{5 x} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 12
Rule 2207
Rule 2225
Rule 6874
Rubi steps
\begin {gather*} \begin {aligned} \text {integral} &=\frac {1}{5} \int \frac {e^{-x} \left (-e^{4+x}+x^2+2 x^3-x^4\right )}{x^2} \, dx\\ &=\frac {1}{5} \int \left (e^{-x}-\frac {e^4}{x^2}+2 e^{-x} x-e^{-x} x^2\right ) \, dx\\ &=\frac {e^4}{5 x}+\frac {1}{5} \int e^{-x} \, dx-\frac {1}{5} \int e^{-x} x^2 \, dx+\frac {2}{5} \int e^{-x} x \, dx\\ &=-\frac {e^{-x}}{5}+\frac {e^4}{5 x}-\frac {2 e^{-x} x}{5}+\frac {1}{5} e^{-x} x^2+\frac {2}{5} \int e^{-x} \, dx-\frac {2}{5} \int e^{-x} x \, dx\\ &=-\frac {3 e^{-x}}{5}+\frac {e^4}{5 x}+\frac {1}{5} e^{-x} x^2-\frac {2}{5} \int e^{-x} \, dx\\ &=-\frac {e^{-x}}{5}+\frac {e^4}{5 x}+\frac {1}{5} e^{-x} x^2\\ \end {aligned} \end {gather*}
________________________________________________________________________________________
Mathematica [A]
time = 0.09, size = 27, normalized size = 1.17 \begin {gather*} \frac {e^4}{5 x}-\frac {1}{5} e^{-x} \left (1-x^2\right ) \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A]
time = 0.23, size = 24, normalized size = 1.04
method | result | size |
risch | \(\frac {{\mathrm e}^{4}}{5 x}+\frac {\left (x^{2}-1\right ) {\mathrm e}^{-x}}{5}\) | \(20\) |
default | \(-\frac {{\mathrm e}^{-x}}{5}+\frac {x^{2} {\mathrm e}^{-x}}{5}+\frac {{\mathrm e}^{4}}{5 x}\) | \(24\) |
norman | \(\frac {\left (-\frac {x}{5}+\frac {x^{3}}{5}+\frac {{\mathrm e}^{4} {\mathrm e}^{x}}{5}\right ) {\mathrm e}^{-x}}{x}\) | \(24\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [A]
time = 0.28, size = 37, normalized size = 1.61 \begin {gather*} \frac {1}{5} \, {\left (x^{2} + 2 \, x + 2\right )} e^{\left (-x\right )} - \frac {2}{5} \, {\left (x + 1\right )} e^{\left (-x\right )} + \frac {e^{4}}{5 \, x} - \frac {1}{5} \, e^{\left (-x\right )} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A]
time = 0.38, size = 26, normalized size = 1.13 \begin {gather*} \frac {{\left ({\left (x^{3} - x\right )} e^{4} + e^{\left (x + 8\right )}\right )} e^{\left (-x - 4\right )}}{5 \, x} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [A]
time = 0.04, size = 15, normalized size = 0.65 \begin {gather*} \frac {\left (x^{2} - 1\right ) e^{- x}}{5} + \frac {e^{4}}{5 x} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [B] Leaf count of result is larger than twice the leaf count of optimal. 44 vs.
\(2 (19) = 38\).
time = 0.43, size = 44, normalized size = 1.91 \begin {gather*} \frac {{\left (x + 4\right )}^{3} e^{\left (-x\right )} - 12 \, {\left (x + 4\right )}^{2} e^{\left (-x\right )} + 47 \, {\left (x + 4\right )} e^{\left (-x\right )} + e^{4} - 60 \, e^{\left (-x\right )}}{5 \, x} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [B]
time = 4.12, size = 23, normalized size = 1.00 \begin {gather*} \frac {x^2\,{\mathrm {e}}^{-x}}{5}-\frac {{\mathrm {e}}^{-x}}{5}+\frac {{\mathrm {e}}^4}{5\,x} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________