\(\int \frac {-40-80 e^x-40 e^{2 x}+e^{2 x+x^2} (-240+e^x (-120-240 x)-240 x)}{9+9 e^{4 x+2 x^2}-6 x+x^2+e^{2 x} (9-6 x+x^2)+e^x (18-12 x+2 x^2)+e^{2 x+x^2} (-18+6 x+e^x (-18+6 x))} \, dx\) [6792]

   Optimal result
   Rubi [F]
   Mathematica [A] (verified)
   Maple [A] (verified)
   Fricas [A] (verification not implemented)
   Sympy [A] (verification not implemented)
   Maxima [A] (verification not implemented)
   Giac [A] (verification not implemented)
   Mupad [F(-1)]

Optimal result

Integrand size = 114, antiderivative size = 25 \[ \int \frac {-40-80 e^x-40 e^{2 x}+e^{2 x+x^2} \left (-240+e^x (-120-240 x)-240 x\right )}{9+9 e^{4 x+2 x^2}-6 x+x^2+e^{2 x} \left (9-6 x+x^2\right )+e^x \left (18-12 x+2 x^2\right )+e^{2 x+x^2} \left (-18+6 x+e^x (-18+6 x)\right )} \, dx=\frac {40}{3 \left (-1+\frac {e^{x (2+x)}}{1+e^x}\right )+x} \]

[Out]

10/(3/4*exp(x*(2+x))/(exp(x)+1)-3/4+1/4*x)

Rubi [F]

\[ \int \frac {-40-80 e^x-40 e^{2 x}+e^{2 x+x^2} \left (-240+e^x (-120-240 x)-240 x\right )}{9+9 e^{4 x+2 x^2}-6 x+x^2+e^{2 x} \left (9-6 x+x^2\right )+e^x \left (18-12 x+2 x^2\right )+e^{2 x+x^2} \left (-18+6 x+e^x (-18+6 x)\right )} \, dx=\int \frac {-40-80 e^x-40 e^{2 x}+e^{2 x+x^2} \left (-240+e^x (-120-240 x)-240 x\right )}{9+9 e^{4 x+2 x^2}-6 x+x^2+e^{2 x} \left (9-6 x+x^2\right )+e^x \left (18-12 x+2 x^2\right )+e^{2 x+x^2} \left (-18+6 x+e^x (-18+6 x)\right )} \, dx \]

[In]

Int[(-40 - 80*E^x - 40*E^(2*x) + E^(2*x + x^2)*(-240 + E^x*(-120 - 240*x) - 240*x))/(9 + 9*E^(4*x + 2*x^2) - 6
*x + x^2 + E^(2*x)*(9 - 6*x + x^2) + E^x*(18 - 12*x + 2*x^2) + E^(2*x + x^2)*(-18 + 6*x + E^x*(-18 + 6*x))),x]

[Out]

-40*Defer[Int][(-3 - 3*E^x + 3*E^(x*(2 + x)) + x + E^x*x)^(-2), x] - 80*Defer[Int][E^x/(-3 - 3*E^x + 3*E^(x*(2
 + x)) + x + E^x*x)^2, x] - 40*Defer[Int][E^(2*x)/(-3 - 3*E^x + 3*E^(x*(2 + x)) + x + E^x*x)^2, x] - 240*Defer
[Int][E^(2*x + x^2)/(-3 - 3*E^x + 3*E^(x*(2 + x)) + x + E^x*x)^2, x] - 120*Defer[Int][E^(3*x + x^2)/(-3 - 3*E^
x + 3*E^(x*(2 + x)) + x + E^x*x)^2, x] - 240*Defer[Int][(E^(2*x + x^2)*x)/(-3 - 3*E^x + 3*E^(x*(2 + x)) + x +
E^x*x)^2, x] - 240*Defer[Int][(E^(3*x + x^2)*x)/(-3 - 3*E^x + 3*E^(x*(2 + x)) + x + E^x*x)^2, x]

Rubi steps \begin{align*} \text {integral}& = \int \frac {40 \left (-1-2 e^x-e^{2 x}-6 e^{x (2+x)} (1+x)-e^{x (3+x)} (3+6 x)\right )}{\left (3-3 e^{x (2+x)}-e^x (-3+x)-x\right )^2} \, dx \\ & = 40 \int \frac {-1-2 e^x-e^{2 x}-6 e^{x (2+x)} (1+x)-e^{x (3+x)} (3+6 x)}{\left (3-3 e^{x (2+x)}-e^x (-3+x)-x\right )^2} \, dx \\ & = 40 \int \left (\frac {3 e^{3 x+x^2} (-1-2 x)}{\left (3+3 e^x-3 e^{x (2+x)}-x-e^x x\right )^2}+\frac {6 e^{2 x+x^2} (-1-x)}{\left (3+3 e^x-3 e^{x (2+x)}-x-e^x x\right )^2}-\frac {1}{\left (-3-3 e^x+3 e^{x (2+x)}+x+e^x x\right )^2}-\frac {2 e^x}{\left (-3-3 e^x+3 e^{x (2+x)}+x+e^x x\right )^2}-\frac {e^{2 x}}{\left (-3-3 e^x+3 e^{x (2+x)}+x+e^x x\right )^2}\right ) \, dx \\ & = -\left (40 \int \frac {1}{\left (-3-3 e^x+3 e^{x (2+x)}+x+e^x x\right )^2} \, dx\right )-40 \int \frac {e^{2 x}}{\left (-3-3 e^x+3 e^{x (2+x)}+x+e^x x\right )^2} \, dx-80 \int \frac {e^x}{\left (-3-3 e^x+3 e^{x (2+x)}+x+e^x x\right )^2} \, dx+120 \int \frac {e^{3 x+x^2} (-1-2 x)}{\left (3+3 e^x-3 e^{x (2+x)}-x-e^x x\right )^2} \, dx+240 \int \frac {e^{2 x+x^2} (-1-x)}{\left (3+3 e^x-3 e^{x (2+x)}-x-e^x x\right )^2} \, dx \\ & = -\left (40 \int \frac {1}{\left (-3-3 e^x+3 e^{x (2+x)}+x+e^x x\right )^2} \, dx\right )-40 \int \frac {e^{2 x}}{\left (-3-3 e^x+3 e^{x (2+x)}+x+e^x x\right )^2} \, dx-80 \int \frac {e^x}{\left (-3-3 e^x+3 e^{x (2+x)}+x+e^x x\right )^2} \, dx+120 \int \left (-\frac {e^{3 x+x^2}}{\left (-3-3 e^x+3 e^{x (2+x)}+x+e^x x\right )^2}-\frac {2 e^{3 x+x^2} x}{\left (-3-3 e^x+3 e^{x (2+x)}+x+e^x x\right )^2}\right ) \, dx+240 \int \left (-\frac {e^{2 x+x^2}}{\left (-3-3 e^x+3 e^{x (2+x)}+x+e^x x\right )^2}-\frac {e^{2 x+x^2} x}{\left (-3-3 e^x+3 e^{x (2+x)}+x+e^x x\right )^2}\right ) \, dx \\ & = -\left (40 \int \frac {1}{\left (-3-3 e^x+3 e^{x (2+x)}+x+e^x x\right )^2} \, dx\right )-40 \int \frac {e^{2 x}}{\left (-3-3 e^x+3 e^{x (2+x)}+x+e^x x\right )^2} \, dx-80 \int \frac {e^x}{\left (-3-3 e^x+3 e^{x (2+x)}+x+e^x x\right )^2} \, dx-120 \int \frac {e^{3 x+x^2}}{\left (-3-3 e^x+3 e^{x (2+x)}+x+e^x x\right )^2} \, dx-240 \int \frac {e^{2 x+x^2}}{\left (-3-3 e^x+3 e^{x (2+x)}+x+e^x x\right )^2} \, dx-240 \int \frac {e^{2 x+x^2} x}{\left (-3-3 e^x+3 e^{x (2+x)}+x+e^x x\right )^2} \, dx-240 \int \frac {e^{3 x+x^2} x}{\left (-3-3 e^x+3 e^{x (2+x)}+x+e^x x\right )^2} \, dx \\ \end{align*}

Mathematica [A] (verified)

Time = 5.04 (sec) , antiderivative size = 28, normalized size of antiderivative = 1.12 \[ \int \frac {-40-80 e^x-40 e^{2 x}+e^{2 x+x^2} \left (-240+e^x (-120-240 x)-240 x\right )}{9+9 e^{4 x+2 x^2}-6 x+x^2+e^{2 x} \left (9-6 x+x^2\right )+e^x \left (18-12 x+2 x^2\right )+e^{2 x+x^2} \left (-18+6 x+e^x (-18+6 x)\right )} \, dx=\frac {40 \left (1+e^x\right )}{-3+3 e^{x (2+x)}+e^x (-3+x)+x} \]

[In]

Integrate[(-40 - 80*E^x - 40*E^(2*x) + E^(2*x + x^2)*(-240 + E^x*(-120 - 240*x) - 240*x))/(9 + 9*E^(4*x + 2*x^
2) - 6*x + x^2 + E^(2*x)*(9 - 6*x + x^2) + E^x*(18 - 12*x + 2*x^2) + E^(2*x + x^2)*(-18 + 6*x + E^x*(-18 + 6*x
))),x]

[Out]

(40*(1 + E^x))/(-3 + 3*E^(x*(2 + x)) + E^x*(-3 + x) + x)

Maple [A] (verified)

Time = 0.16 (sec) , antiderivative size = 28, normalized size of antiderivative = 1.12

method result size
risch \(\frac {40 \,{\mathrm e}^{x}+40}{{\mathrm e}^{x} x -3 \,{\mathrm e}^{x}+3 \,{\mathrm e}^{x \left (2+x \right )}+x -3}\) \(28\)
norman \(\frac {40 \,{\mathrm e}^{x}+40}{{\mathrm e}^{x} x -3 \,{\mathrm e}^{x}+3 \,{\mathrm e}^{x^{2}+2 x}+x -3}\) \(31\)
parallelrisch \(\frac {120+120 \,{\mathrm e}^{x}}{3 \,{\mathrm e}^{x} x -9 \,{\mathrm e}^{x}+9 \,{\mathrm e}^{x^{2}+2 x}+3 x -9}\) \(32\)

[In]

int((((-240*x-120)*exp(x)-240*x-240)*exp(x^2+2*x)-40*exp(x)^2-80*exp(x)-40)/(9*exp(x^2+2*x)^2+((6*x-18)*exp(x)
+6*x-18)*exp(x^2+2*x)+(x^2-6*x+9)*exp(x)^2+(2*x^2-12*x+18)*exp(x)+x^2-6*x+9),x,method=_RETURNVERBOSE)

[Out]

40*(exp(x)+1)/(exp(x)*x-3*exp(x)+3*exp(x*(2+x))+x-3)

Fricas [A] (verification not implemented)

none

Time = 0.24 (sec) , antiderivative size = 27, normalized size of antiderivative = 1.08 \[ \int \frac {-40-80 e^x-40 e^{2 x}+e^{2 x+x^2} \left (-240+e^x (-120-240 x)-240 x\right )}{9+9 e^{4 x+2 x^2}-6 x+x^2+e^{2 x} \left (9-6 x+x^2\right )+e^x \left (18-12 x+2 x^2\right )+e^{2 x+x^2} \left (-18+6 x+e^x (-18+6 x)\right )} \, dx=\frac {40 \, {\left (e^{x} + 1\right )}}{{\left (x - 3\right )} e^{x} + x + 3 \, e^{\left (x^{2} + 2 \, x\right )} - 3} \]

[In]

integrate((((-240*x-120)*exp(x)-240*x-240)*exp(x^2+2*x)-40*exp(x)^2-80*exp(x)-40)/(9*exp(x^2+2*x)^2+((6*x-18)*
exp(x)+6*x-18)*exp(x^2+2*x)+(x^2-6*x+9)*exp(x)^2+(2*x^2-12*x+18)*exp(x)+x^2-6*x+9),x, algorithm="fricas")

[Out]

40*(e^x + 1)/((x - 3)*e^x + x + 3*e^(x^2 + 2*x) - 3)

Sympy [A] (verification not implemented)

Time = 0.14 (sec) , antiderivative size = 29, normalized size of antiderivative = 1.16 \[ \int \frac {-40-80 e^x-40 e^{2 x}+e^{2 x+x^2} \left (-240+e^x (-120-240 x)-240 x\right )}{9+9 e^{4 x+2 x^2}-6 x+x^2+e^{2 x} \left (9-6 x+x^2\right )+e^x \left (18-12 x+2 x^2\right )+e^{2 x+x^2} \left (-18+6 x+e^x (-18+6 x)\right )} \, dx=\frac {40 e^{x} + 40}{x e^{x} + x - 3 e^{x} + 3 e^{x^{2} + 2 x} - 3} \]

[In]

integrate((((-240*x-120)*exp(x)-240*x-240)*exp(x**2+2*x)-40*exp(x)**2-80*exp(x)-40)/(9*exp(x**2+2*x)**2+((6*x-
18)*exp(x)+6*x-18)*exp(x**2+2*x)+(x**2-6*x+9)*exp(x)**2+(2*x**2-12*x+18)*exp(x)+x**2-6*x+9),x)

[Out]

(40*exp(x) + 40)/(x*exp(x) + x - 3*exp(x) + 3*exp(x**2 + 2*x) - 3)

Maxima [A] (verification not implemented)

none

Time = 0.24 (sec) , antiderivative size = 27, normalized size of antiderivative = 1.08 \[ \int \frac {-40-80 e^x-40 e^{2 x}+e^{2 x+x^2} \left (-240+e^x (-120-240 x)-240 x\right )}{9+9 e^{4 x+2 x^2}-6 x+x^2+e^{2 x} \left (9-6 x+x^2\right )+e^x \left (18-12 x+2 x^2\right )+e^{2 x+x^2} \left (-18+6 x+e^x (-18+6 x)\right )} \, dx=\frac {40 \, {\left (e^{x} + 1\right )}}{{\left (x - 3\right )} e^{x} + x + 3 \, e^{\left (x^{2} + 2 \, x\right )} - 3} \]

[In]

integrate((((-240*x-120)*exp(x)-240*x-240)*exp(x^2+2*x)-40*exp(x)^2-80*exp(x)-40)/(9*exp(x^2+2*x)^2+((6*x-18)*
exp(x)+6*x-18)*exp(x^2+2*x)+(x^2-6*x+9)*exp(x)^2+(2*x^2-12*x+18)*exp(x)+x^2-6*x+9),x, algorithm="maxima")

[Out]

40*(e^x + 1)/((x - 3)*e^x + x + 3*e^(x^2 + 2*x) - 3)

Giac [A] (verification not implemented)

none

Time = 0.32 (sec) , antiderivative size = 29, normalized size of antiderivative = 1.16 \[ \int \frac {-40-80 e^x-40 e^{2 x}+e^{2 x+x^2} \left (-240+e^x (-120-240 x)-240 x\right )}{9+9 e^{4 x+2 x^2}-6 x+x^2+e^{2 x} \left (9-6 x+x^2\right )+e^x \left (18-12 x+2 x^2\right )+e^{2 x+x^2} \left (-18+6 x+e^x (-18+6 x)\right )} \, dx=\frac {40 \, {\left (e^{x} + 1\right )}}{x e^{x} + x + 3 \, e^{\left (x^{2} + 2 \, x\right )} - 3 \, e^{x} - 3} \]

[In]

integrate((((-240*x-120)*exp(x)-240*x-240)*exp(x^2+2*x)-40*exp(x)^2-80*exp(x)-40)/(9*exp(x^2+2*x)^2+((6*x-18)*
exp(x)+6*x-18)*exp(x^2+2*x)+(x^2-6*x+9)*exp(x)^2+(2*x^2-12*x+18)*exp(x)+x^2-6*x+9),x, algorithm="giac")

[Out]

40*(e^x + 1)/(x*e^x + x + 3*e^(x^2 + 2*x) - 3*e^x - 3)

Mupad [F(-1)]

Timed out. \[ \int \frac {-40-80 e^x-40 e^{2 x}+e^{2 x+x^2} \left (-240+e^x (-120-240 x)-240 x\right )}{9+9 e^{4 x+2 x^2}-6 x+x^2+e^{2 x} \left (9-6 x+x^2\right )+e^x \left (18-12 x+2 x^2\right )+e^{2 x+x^2} \left (-18+6 x+e^x (-18+6 x)\right )} \, dx=\int -\frac {40\,{\mathrm {e}}^{2\,x}+80\,{\mathrm {e}}^x+{\mathrm {e}}^{x^2+2\,x}\,\left (240\,x+{\mathrm {e}}^x\,\left (240\,x+120\right )+240\right )+40}{9\,{\mathrm {e}}^{2\,x^2+4\,x}-6\,x+{\mathrm {e}}^{x^2+2\,x}\,\left (6\,x+{\mathrm {e}}^x\,\left (6\,x-18\right )-18\right )+{\mathrm {e}}^{2\,x}\,\left (x^2-6\,x+9\right )+{\mathrm {e}}^x\,\left (2\,x^2-12\,x+18\right )+x^2+9} \,d x \]

[In]

int(-(40*exp(2*x) + 80*exp(x) + exp(2*x + x^2)*(240*x + exp(x)*(240*x + 120) + 240) + 40)/(9*exp(4*x + 2*x^2)
- 6*x + exp(2*x + x^2)*(6*x + exp(x)*(6*x - 18) - 18) + exp(2*x)*(x^2 - 6*x + 9) + exp(x)*(2*x^2 - 12*x + 18)
+ x^2 + 9),x)

[Out]

int(-(40*exp(2*x) + 80*exp(x) + exp(2*x + x^2)*(240*x + exp(x)*(240*x + 120) + 240) + 40)/(9*exp(4*x + 2*x^2)
- 6*x + exp(2*x + x^2)*(6*x + exp(x)*(6*x - 18) - 18) + exp(2*x)*(x^2 - 6*x + 9) + exp(x)*(2*x^2 - 12*x + 18)
+ x^2 + 9), x)