Optimal. Leaf size=26 \[ -2+e^x-x-\log (5)+4 \left (-e^x+\log \left (\frac {x}{4}\right )\right ) \]
________________________________________________________________________________________
Rubi [A] time = 0.01, antiderivative size = 13, normalized size of antiderivative = 0.50, number of steps used = 5, number of rules used = 3, integrand size = 15, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.200, Rules used = {14, 2194, 43} \begin {gather*} -x-3 e^x+4 \log (x) \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 14
Rule 43
Rule 2194
Rubi steps
\begin {gather*} \begin {aligned} \text {integral} &=\int \left (-3 e^x+\frac {4-x}{x}\right ) \, dx\\ &=-\left (3 \int e^x \, dx\right )+\int \frac {4-x}{x} \, dx\\ &=-3 e^x+\int \left (-1+\frac {4}{x}\right ) \, dx\\ &=-3 e^x-x+4 \log (x)\\ \end {aligned} \end {gather*}
________________________________________________________________________________________
Mathematica [A] time = 0.01, size = 13, normalized size = 0.50 \begin {gather*} -3 e^x-x+4 \log (x) \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
fricas [A] time = 0.58, size = 12, normalized size = 0.46 \begin {gather*} -x - 3 \, e^{x} + 4 \, \log \relax (x) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
giac [A] time = 0.13, size = 12, normalized size = 0.46 \begin {gather*} -x - 3 \, e^{x} + 4 \, \log \relax (x) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maple [A] time = 0.02, size = 13, normalized size = 0.50
method | result | size |
default | \(-x +4 \ln \relax (x )-3 \,{\mathrm e}^{x}\) | \(13\) |
norman | \(-x +4 \ln \relax (x )-3 \,{\mathrm e}^{x}\) | \(13\) |
risch | \(-x +4 \ln \relax (x )-3 \,{\mathrm e}^{x}\) | \(13\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maxima [A] time = 0.37, size = 12, normalized size = 0.46 \begin {gather*} -x - 3 \, e^{x} + 4 \, \log \relax (x) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
mupad [B] time = 0.04, size = 12, normalized size = 0.46 \begin {gather*} 4\,\ln \relax (x)-3\,{\mathrm {e}}^x-x \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
sympy [A] time = 0.16, size = 10, normalized size = 0.38 \begin {gather*} - x - 3 e^{x} + 4 \log {\relax (x )} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________