Optimal. Leaf size=24 \[ x-\frac {1}{4} e^{4-x^2} \left (5-\frac {x}{5}+\log (4)\right ) \]
________________________________________________________________________________________
Rubi [A] time = 0.24, antiderivative size = 33, normalized size of antiderivative = 1.38, number of steps used = 8, number of rules used = 6, integrand size = 37, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.162, Rules used = {6, 12, 6742, 2205, 2212, 2209} \begin {gather*} \frac {1}{20} e^{4-x^2} x-\frac {1}{4} e^{4-x^2} (5+\log (4))+x \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 6
Rule 12
Rule 2205
Rule 2209
Rule 2212
Rule 6742
Rubi steps
\begin {gather*} \begin {aligned} \text {integral} &=\int \frac {1}{20} e^{4-x^2} \left (1+20 e^{-4+x^2}-2 x^2+x (50+10 \log (4))\right ) \, dx\\ &=\frac {1}{20} \int e^{4-x^2} \left (1+20 e^{-4+x^2}-2 x^2+x (50+10 \log (4))\right ) \, dx\\ &=\frac {1}{20} \int \left (20+e^{4-x^2}-2 e^{4-x^2} x^2+10 e^{4-x^2} x (5+\log (4))\right ) \, dx\\ &=x+\frac {1}{20} \int e^{4-x^2} \, dx-\frac {1}{10} \int e^{4-x^2} x^2 \, dx+\frac {1}{2} (5+\log (4)) \int e^{4-x^2} x \, dx\\ &=x+\frac {1}{20} e^{4-x^2} x+\frac {1}{40} e^4 \sqrt {\pi } \text {erf}(x)-\frac {1}{4} e^{4-x^2} (5+\log (4))-\frac {1}{20} \int e^{4-x^2} \, dx\\ &=x+\frac {1}{20} e^{4-x^2} x-\frac {1}{4} e^{4-x^2} (5+\log (4))\\ \end {aligned} \end {gather*}
________________________________________________________________________________________
Mathematica [A] time = 0.04, size = 33, normalized size = 1.38 \begin {gather*} x+\frac {1}{20} e^{4-x^2} x-\frac {1}{4} e^{4-x^2} (5+\log (4)) \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
fricas [A] time = 0.56, size = 34, normalized size = 1.42 \begin {gather*} \frac {1}{5} \, {\left (5 \, x e^{\left (x^{2} + 2 \, \log \relax (2) - 4\right )} + x - 10 \, \log \relax (2) - 25\right )} e^{\left (-x^{2} - 2 \, \log \relax (2) + 4\right )} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
giac [A] time = 0.17, size = 19, normalized size = 0.79 \begin {gather*} \frac {1}{20} \, {\left (x - 10 \, \log \relax (2) - 25\right )} e^{\left (-x^{2} + 4\right )} + x \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maple [A] time = 0.03, size = 21, normalized size = 0.88
method | result | size |
risch | \(x +\frac {\left (-10 \ln \relax (2)-25+x \right ) {\mathrm e}^{-\left (x -2\right ) \left (2+x \right )}}{20}\) | \(21\) |
norman | \(\frac {\left (x \,{\mathrm e}^{2 \ln \relax (2)+x^{2}-4}+\frac {x}{5}-2 \ln \relax (2)-5\right ) {\mathrm e}^{-x^{2}+4}}{4}\) | \(35\) |
default | \(x +\frac {{\mathrm e}^{4} \sqrt {\pi }\, \erf \relax (x )}{40}-\frac {5 \,{\mathrm e}^{-x^{2}} {\mathrm e}^{4}}{4}-\frac {{\mathrm e}^{4} \left (-\frac {x \,{\mathrm e}^{-x^{2}}}{2}+\frac {\sqrt {\pi }\, \erf \relax (x )}{4}\right )}{10}-\frac {{\mathrm e}^{4} \ln \relax (2) {\mathrm e}^{-x^{2}}}{2}\) | \(63\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maxima [A] time = 0.36, size = 35, normalized size = 1.46 \begin {gather*} \frac {1}{20} \, x e^{\left (-x^{2} + 4\right )} - \frac {1}{2} \, e^{\left (-x^{2} + 4\right )} \log \relax (2) + x - \frac {5}{4} \, e^{\left (-x^{2} + 4\right )} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
mupad [B] time = 0.15, size = 35, normalized size = 1.46 \begin {gather*} x-\frac {5\,{\mathrm {e}}^{4-x^2}}{4}-\frac {{\mathrm {e}}^{4-x^2}\,\ln \relax (2)}{2}+\frac {x\,{\mathrm {e}}^{4-x^2}}{20} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
sympy [A] time = 0.14, size = 17, normalized size = 0.71 \begin {gather*} x + \frac {\left (x - 25 - 10 \log {\relax (2 )}\right ) e^{4 - x^{2}}}{20} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________