Optimal. Leaf size=22 \[ \frac {2 e^{2 x}}{(-4+x) \left (4+\frac {4}{x}+x\right )} \]
[Out]
________________________________________________________________________________________
Rubi [B] Leaf count is larger than twice the leaf count of optimal. \(45\) vs. \(2(22)=44\).
time = 0.51, antiderivative size = 45, normalized size of antiderivative = 2.05, number of steps
used = 13, number of rules used = 5, integrand size = 46, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.109, Rules used = {6820, 12,
6874, 2208, 2209} \begin {gather*} -\frac {2 e^{2 x}}{9 (x+2)}+\frac {2 e^{2 x}}{3 (x+2)^2}-\frac {2 e^{2 x}}{9 (4-x)} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
Rule 12
Rule 2208
Rule 2209
Rule 6820
Rule 6874
Rubi steps
\begin {gather*} \begin {aligned} \text {integral} &=\int \frac {4 e^{2 x} \left (-4-6 x-3 x^2+x^3\right )}{(4-x)^2 (2+x)^3} \, dx\\ &=4 \int \frac {e^{2 x} \left (-4-6 x-3 x^2+x^3\right )}{(4-x)^2 (2+x)^3} \, dx\\ &=4 \int \left (-\frac {e^{2 x}}{18 (-4+x)^2}+\frac {e^{2 x}}{9 (-4+x)}-\frac {e^{2 x}}{3 (2+x)^3}+\frac {7 e^{2 x}}{18 (2+x)^2}-\frac {e^{2 x}}{9 (2+x)}\right ) \, dx\\ &=-\left (\frac {2}{9} \int \frac {e^{2 x}}{(-4+x)^2} \, dx\right )+\frac {4}{9} \int \frac {e^{2 x}}{-4+x} \, dx-\frac {4}{9} \int \frac {e^{2 x}}{2+x} \, dx-\frac {4}{3} \int \frac {e^{2 x}}{(2+x)^3} \, dx+\frac {14}{9} \int \frac {e^{2 x}}{(2+x)^2} \, dx\\ &=-\frac {2 e^{2 x}}{9 (4-x)}+\frac {2 e^{2 x}}{3 (2+x)^2}-\frac {14 e^{2 x}}{9 (2+x)}+\frac {4}{9} e^8 \text {Ei}(-2 (4-x))-\frac {4 \text {Ei}(2 (2+x))}{9 e^4}-\frac {4}{9} \int \frac {e^{2 x}}{-4+x} \, dx-\frac {4}{3} \int \frac {e^{2 x}}{(2+x)^2} \, dx+\frac {28}{9} \int \frac {e^{2 x}}{2+x} \, dx\\ &=-\frac {2 e^{2 x}}{9 (4-x)}+\frac {2 e^{2 x}}{3 (2+x)^2}-\frac {2 e^{2 x}}{9 (2+x)}+\frac {8 \text {Ei}(2 (2+x))}{3 e^4}-\frac {8}{3} \int \frac {e^{2 x}}{2+x} \, dx\\ &=-\frac {2 e^{2 x}}{9 (4-x)}+\frac {2 e^{2 x}}{3 (2+x)^2}-\frac {2 e^{2 x}}{9 (2+x)}\\ \end {aligned} \end {gather*}
________________________________________________________________________________________
Mathematica [A]
time = 0.20, size = 18, normalized size = 0.82 \begin {gather*} \frac {2 e^{2 x} x}{(-4+x) (2+x)^2} \end {gather*}
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A]
time = 0.05, size = 35, normalized size = 1.59
method | result | size |
gosper | \(\frac {2 \,{\mathrm e}^{2 x} x}{x^{3}-12 x -16}\) | \(18\) |
norman | \(\frac {2 x \,{\mathrm e}^{2 x}}{\left (x -4\right ) \left (2+x \right )^{2}}\) | \(18\) |
risch | \(\frac {2 x \,{\mathrm e}^{2 x}}{\left (x -4\right ) \left (2+x \right )^{2}}\) | \(18\) |
default | \(-\frac {2 \,{\mathrm e}^{2 x}}{9 \left (2+x \right )}+\frac {2 \,{\mathrm e}^{2 x}}{9 \left (x -4\right )}+\frac {2 \,{\mathrm e}^{2 x}}{3 \left (2+x \right )^{2}}\) | \(35\) |
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [A]
time = 0.29, size = 17, normalized size = 0.77 \begin {gather*} \frac {2 \, x e^{\left (2 \, x\right )}}{x^{3} - 12 \, x - 16} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A]
time = 0.37, size = 17, normalized size = 0.77 \begin {gather*} \frac {2 \, x e^{\left (2 \, x\right )}}{x^{3} - 12 \, x - 16} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [A]
time = 0.04, size = 15, normalized size = 0.68 \begin {gather*} \frac {2 x e^{2 x}}{x^{3} - 12 x - 16} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [A]
time = 0.42, size = 17, normalized size = 0.77 \begin {gather*} \frac {2 \, x e^{\left (2 \, x\right )}}{x^{3} - 12 \, x - 16} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Mupad [B]
time = 8.23, size = 17, normalized size = 0.77 \begin {gather*} \frac {2\,x\,{\mathrm {e}}^{2\,x}}{{\left (x+2\right )}^2\,\left (x-4\right )} \end {gather*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________