Optimal. Leaf size=27 \[ -3+e^x \left (2+x \left (\frac {e^4}{x (2+x)^2}-\log (7)\right )\right ) \]
[Out]
________________________________________________________________________________________
Rubi [A]
time = 0.19, antiderivative size = 36, normalized size of antiderivative = 1.33, number of steps
used = 11, number of rules used = 6, integrand size = 62, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.097, Rules used = {6, 2230, 2208,
2209, 2207, 2225} \begin {gather*} \frac {e^{x+4}}{(x+2)^2}-e^x (x+2) \log (7)+e^x (2+\log (7))+e^x \log (7) \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 6
Rule 2207
Rule 2208
Rule 2209
Rule 2225
Rule 2230
Rubi steps
\begin {gather*} \begin {aligned} \text {integral} &=\int \frac {e^x \left (16+\left (24+e^4\right ) x+12 x^2+2 x^3+\left (-8-20 x-18 x^2-7 x^3-x^4\right ) \log (7)\right )}{8+12 x+6 x^2+x^3} \, dx\\ &=\int \left (-\frac {2 e^{4+x}}{(2+x)^3}+\frac {e^{4+x}}{(2+x)^2}-e^x (2+x) \log (7)+e^x (2+\log (7))\right ) \, dx\\ &=-\left (2 \int \frac {e^{4+x}}{(2+x)^3} \, dx\right )-\log (7) \int e^x (2+x) \, dx+(2+\log (7)) \int e^x \, dx+\int \frac {e^{4+x}}{(2+x)^2} \, dx\\ &=\frac {e^{4+x}}{(2+x)^2}-\frac {e^{4+x}}{2+x}-e^x (2+x) \log (7)+e^x (2+\log (7))+\log (7) \int e^x \, dx-\int \frac {e^{4+x}}{(2+x)^2} \, dx+\int \frac {e^{4+x}}{2+x} \, dx\\ &=\frac {e^{4+x}}{(2+x)^2}+e^2 \text {Ei}(2+x)+e^x \log (7)-e^x (2+x) \log (7)+e^x (2+\log (7))-\int \frac {e^{4+x}}{2+x} \, dx\\ &=\frac {e^{4+x}}{(2+x)^2}+e^x \log (7)-e^x (2+x) \log (7)+e^x (2+\log (7))\\ \end {aligned} \end {gather*}
________________________________________________________________________________________
Mathematica [A]
time = 0.32, size = 37, normalized size = 1.37 \begin {gather*} -\frac {e^x \left (-8-e^4+x^3 \log (7)+x (-8+\log (2401))+x^2 (-2+\log (2401))\right )}{(2+x)^2} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A]
time = 0.15, size = 25, normalized size = 0.93
method | result | size |
default | \(\frac {{\mathrm e}^{4} {\mathrm e}^{x}}{\left (2+x \right )^{2}}+2 \,{\mathrm e}^{x}-{\mathrm e}^{x} x \ln \left (7\right )\) | \(25\) |
risch | \(\frac {\left (-\ln \left (7\right ) x^{3}-4 x^{2} \ln \left (7\right )+{\mathrm e}^{4}-4 x \ln \left (7\right )+2 x^{2}+8 x +8\right ) {\mathrm e}^{x}}{\left (2+x \right )^{2}}\) | \(40\) |
gosper | \(\frac {\left (-\ln \left (7\right ) x^{3}-4 x^{2} \ln \left (7\right )+{\mathrm e}^{4}-4 x \ln \left (7\right )+2 x^{2}+8 x +8\right ) {\mathrm e}^{x}}{x^{2}+4 x +4}\) | \(47\) |
norman | \(\frac {\left ({\mathrm e}^{4}+8\right ) {\mathrm e}^{x}+\left (-4 \ln \left (7\right )+2\right ) x^{2} {\mathrm e}^{x}+\left (-4 \ln \left (7\right )+8\right ) x \,{\mathrm e}^{x}-\ln \left (7\right ) x^{3} {\mathrm e}^{x}}{\left (2+x \right )^{2}}\) | \(48\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [F]
time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \text {Failed to integrate} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A]
time = 0.38, size = 41, normalized size = 1.52 \begin {gather*} \frac {{\left (2 \, x^{2} - {\left (x^{3} + 4 \, x^{2} + 4 \, x\right )} \log \left (7\right ) + 8 \, x + e^{4} + 8\right )} e^{x}}{x^{2} + 4 \, x + 4} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [B] Leaf count of result is larger than twice the leaf count of optimal. 46 vs.
\(2 (20) = 40\).
time = 0.08, size = 46, normalized size = 1.70 \begin {gather*} \frac {\left (- x^{3} \log {\left (7 \right )} - 4 x^{2} \log {\left (7 \right )} + 2 x^{2} - 4 x \log {\left (7 \right )} + 8 x + 8 + e^{4}\right ) e^{x}}{x^{2} + 4 x + 4} \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. 59 vs.
\(2 (25) = 50\).
time = 0.40, size = 59, normalized size = 2.19 \begin {gather*} -\frac {x^{3} e^{x} \log \left (7\right ) + 4 \, x^{2} e^{x} \log \left (7\right ) - 2 \, x^{2} e^{x} + 4 \, x e^{x} \log \left (7\right ) - 8 \, x e^{x} - e^{\left (x + 4\right )} - 8 \, e^{x}}{x^{2} + 4 \, x + 4} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [B]
time = 2.12, size = 21, normalized size = 0.78 \begin {gather*} \frac {{\mathrm {e}}^{x+4}}{{\left (x+2\right )}^2}-{\mathrm {e}}^x\,\left (x\,\ln \left (7\right )-2\right ) \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________