Optimal. Leaf size=19 \[ 9+e^{2 x-x^2}+\log \left (x+x^2\right ) \]
________________________________________________________________________________________
Rubi [A] time = 0.36, antiderivative size = 18, normalized size of antiderivative = 0.95, number of steps used = 6, number of rules used = 4, integrand size = 34, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.118, Rules used = {1593, 6742, 2236, 72} \begin {gather*} e^{2 x-x^2}+\log (x)+\log (x+1) \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 72
Rule 1593
Rule 2236
Rule 6742
Rubi steps
\begin {gather*} \begin {aligned} \text {integral} &=\int \frac {1+2 x+e^{2 x-x^2} \left (2 x-2 x^3\right )}{x (1+x)} \, dx\\ &=\int \left (2 e^{2 x-x^2} (1-x)+\frac {1+2 x}{x (1+x)}\right ) \, dx\\ &=2 \int e^{2 x-x^2} (1-x) \, dx+\int \frac {1+2 x}{x (1+x)} \, dx\\ &=e^{2 x-x^2}+\int \left (\frac {1}{x}+\frac {1}{1+x}\right ) \, dx\\ &=e^{2 x-x^2}+\log (x)+\log (1+x)\\ \end {aligned} \end {gather*}
________________________________________________________________________________________
Mathematica [A] time = 0.36, size = 15, normalized size = 0.79 \begin {gather*} e^{-((-2+x) x)}+\log (x)+\log (1+x) \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
fricas [A] time = 0.76, size = 17, normalized size = 0.89 \begin {gather*} e^{\left (-x^{2} + 2 \, x\right )} + \log \left (x^{2} + x\right ) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
giac [A] time = 0.26, size = 17, normalized size = 0.89 \begin {gather*} e^{\left (-x^{2} + 2 \, x\right )} + \log \left (x + 1\right ) + \log \relax (x) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maple [A] time = 0.38, size = 15, normalized size = 0.79
method | result | size |
risch | \(\ln \left (x^{2}+x \right )+{\mathrm e}^{-\left (x -2\right ) x}\) | \(15\) |
default | \({\mathrm e}^{-x^{2}+2 x}+\ln \left (\left (x +1\right ) x \right )\) | \(18\) |
norman | \({\mathrm e}^{-x^{2}+2 x}+\ln \left (x +1\right )+\ln \relax (x )\) | \(18\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maxima [A] time = 0.54, size = 17, normalized size = 0.89 \begin {gather*} e^{\left (-x^{2} + 2 \, x\right )} + \log \left (x + 1\right ) + \log \relax (x) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
mupad [B] time = 1.30, size = 17, normalized size = 0.89 \begin {gather*} \ln \left (x+1\right )+{\mathrm {e}}^{2\,x-x^2}+\ln \relax (x) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
sympy [A] time = 0.13, size = 14, normalized size = 0.74 \begin {gather*} e^{- x^{2} + 2 x} + \log {\left (x^{2} + x \right )} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________