Optimal. Leaf size=23 \[ 2+x-\log \left (\frac {1}{-4+(-2+x)^2 \left (-e^2+x\right )}\right ) \]
________________________________________________________________________________________
Rubi [A] time = 0.27, antiderivative size = 33, normalized size of antiderivative = 1.43, number of steps used = 4, number of rules used = 3, integrand size = 53, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.057, Rules used = {6741, 6742, 1587} \begin {gather*} \log \left (-x^3+\left (4+e^2\right ) x^2-4 \left (1+e^2\right ) x+4 \left (1+e^2\right )\right )+x \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 1587
Rule 6741
Rule 6742
Rubi steps
\begin {gather*} \begin {aligned} \text {integral} &=\int \frac {x \left (2 \left (2-e^2\right )+\left (1+e^2\right ) x-x^2\right )}{4 \left (1+e^2\right )-4 \left (1+e^2\right ) x+\left (4+e^2\right ) x^2-x^3} \, dx\\ &=\int \left (1-\frac {4 \left (1+e^2\right )-2 \left (4+e^2\right ) x+3 x^2}{4 \left (1+e^2\right )-4 \left (1+e^2\right ) x+\left (4+e^2\right ) x^2-x^3}\right ) \, dx\\ &=x-\int \frac {4 \left (1+e^2\right )-2 \left (4+e^2\right ) x+3 x^2}{4 \left (1+e^2\right )-4 \left (1+e^2\right ) x+\left (4+e^2\right ) x^2-x^3} \, dx\\ &=x+\log \left (4 \left (1+e^2\right )-4 \left (1+e^2\right ) x+\left (4+e^2\right ) x^2-x^3\right )\\ \end {aligned} \end {gather*}
________________________________________________________________________________________
Mathematica [A] time = 0.03, size = 36, normalized size = 1.57 \begin {gather*} x+\log \left (4+4 e^2-4 x-4 e^2 x+4 x^2+e^2 x^2-x^3\right ) \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
fricas [A] time = 0.67, size = 28, normalized size = 1.22 \begin {gather*} x + \log \left (x^{3} - 4 \, x^{2} - {\left (x^{2} - 4 \, x + 4\right )} e^{2} + 4 \, x - 4\right ) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
giac [A] time = 0.15, size = 33, normalized size = 1.43 \begin {gather*} x + \log \left ({\left | x^{3} - x^{2} e^{2} - 4 \, x^{2} + 4 \, x e^{2} + 4 \, x - 4 \, e^{2} - 4 \right |}\right ) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maple [A] time = 0.05, size = 31, normalized size = 1.35
method | result | size |
risch | \(x +\ln \left (x^{3}+\left (-{\mathrm e}^{2}-4\right ) x^{2}+\left (4 \,{\mathrm e}^{2}+4\right ) x -4 \,{\mathrm e}^{2}-4\right )\) | \(31\) |
default | \(x +\ln \left (-4+x^{3}-4 x^{2}+4 x -x^{2} {\mathrm e}^{2}+4 \,{\mathrm e}^{2} x -4 \,{\mathrm e}^{2}\right )\) | \(33\) |
norman | \(x +\ln \left (x^{2} {\mathrm e}^{2}-x^{3}-4 \,{\mathrm e}^{2} x +4 x^{2}+4 \,{\mathrm e}^{2}-4 x +4\right )\) | \(34\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maxima [A] time = 0.36, size = 28, normalized size = 1.22 \begin {gather*} x + \log \left (x^{3} - x^{2} {\left (e^{2} + 4\right )} + 4 \, x {\left (e^{2} + 1\right )} - 4 \, e^{2} - 4\right ) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
mupad [B] time = 0.22, size = 29, normalized size = 1.26 \begin {gather*} x+\ln \left (x^3+\left (-{\mathrm {e}}^2-4\right )\,x^2+\left (4\,{\mathrm {e}}^2+4\right )\,x-4\,{\mathrm {e}}^2-4\right ) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
sympy [A] time = 0.43, size = 31, normalized size = 1.35 \begin {gather*} x + \log {\left (x^{3} + x^{2} \left (- e^{2} - 4\right ) + x \left (4 + 4 e^{2}\right ) - 4 e^{2} - 4 \right )} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________