\(\int (1+e^{2+e^{-3 x+x^2}+x} (e^{10} (4-12 x+4 x^2+4 x^3)+e^{10-3 x+x^2} (-12 x+32 x^2-28 x^3+8 x^4))) \, dx\) [5030]

   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 [B] (verification not implemented)
   Mupad [B] (verification not implemented)

Optimal result

Integrand size = 67, antiderivative size = 22 \[ \int \left (1+e^{2+e^{-3 x+x^2}+x} \left (e^{10} \left (4-12 x+4 x^2+4 x^3\right )+e^{10-3 x+x^2} \left (-12 x+32 x^2-28 x^3+8 x^4\right )\right )\right ) \, dx=x+4 e^{12+e^{(-3+x) x}+x} (-1+x)^2 x \]

[Out]

x+4*exp(5)^2*(-1+x)^2*x*exp(x+exp(x*(-3+x))+2)

Rubi [F]

\[ \int \left (1+e^{2+e^{-3 x+x^2}+x} \left (e^{10} \left (4-12 x+4 x^2+4 x^3\right )+e^{10-3 x+x^2} \left (-12 x+32 x^2-28 x^3+8 x^4\right )\right )\right ) \, dx=\int \left (1+e^{2+e^{-3 x+x^2}+x} \left (e^{10} \left (4-12 x+4 x^2+4 x^3\right )+e^{10-3 x+x^2} \left (-12 x+32 x^2-28 x^3+8 x^4\right )\right )\right ) \, dx \]

[In]

Int[1 + E^(2 + E^(-3*x + x^2) + x)*(E^10*(4 - 12*x + 4*x^2 + 4*x^3) + E^(10 - 3*x + x^2)*(-12*x + 32*x^2 - 28*
x^3 + 8*x^4)),x]

[Out]

x + 4*Defer[Int][E^(12 + E^(-3*x + x^2) + x), x] - 12*Defer[Int][E^(12 + E^(-3*x + x^2) + x)*x, x] - 12*Defer[
Int][E^(12 + E^(-3*x + x^2) - 2*x + x^2)*x, x] + 4*Defer[Int][E^(12 + E^(-3*x + x^2) + x)*x^2, x] + 32*Defer[I
nt][E^(12 + E^(-3*x + x^2) - 2*x + x^2)*x^2, x] + 4*Defer[Int][E^(12 + E^(-3*x + x^2) + x)*x^3, x] - 28*Defer[
Int][E^(12 + E^(-3*x + x^2) - 2*x + x^2)*x^3, x] + 8*Defer[Int][E^(12 + E^(-3*x + x^2) - 2*x + x^2)*x^4, x]

Rubi steps \begin{align*} \text {integral}& = x+\int e^{2+e^{-3 x+x^2}+x} \left (e^{10} \left (4-12 x+4 x^2+4 x^3\right )+e^{10-3 x+x^2} \left (-12 x+32 x^2-28 x^3+8 x^4\right )\right ) \, dx \\ & = x+\int \left (4 e^{12+e^{-3 x+x^2}-2 x+x^2} (-1+x)^2 x (-3+2 x)+4 e^{12+e^{-3 x+x^2}+x} \left (1-3 x+x^2+x^3\right )\right ) \, dx \\ & = x+4 \int e^{12+e^{-3 x+x^2}-2 x+x^2} (-1+x)^2 x (-3+2 x) \, dx+4 \int e^{12+e^{-3 x+x^2}+x} \left (1-3 x+x^2+x^3\right ) \, dx \\ & = x+4 \int \left (e^{12+e^{-3 x+x^2}+x}-3 e^{12+e^{-3 x+x^2}+x} x+e^{12+e^{-3 x+x^2}+x} x^2+e^{12+e^{-3 x+x^2}+x} x^3\right ) \, dx+4 \int \left (-3 e^{12+e^{-3 x+x^2}-2 x+x^2} x+8 e^{12+e^{-3 x+x^2}-2 x+x^2} x^2-7 e^{12+e^{-3 x+x^2}-2 x+x^2} x^3+2 e^{12+e^{-3 x+x^2}-2 x+x^2} x^4\right ) \, dx \\ & = x+4 \int e^{12+e^{-3 x+x^2}+x} \, dx+4 \int e^{12+e^{-3 x+x^2}+x} x^2 \, dx+4 \int e^{12+e^{-3 x+x^2}+x} x^3 \, dx+8 \int e^{12+e^{-3 x+x^2}-2 x+x^2} x^4 \, dx-12 \int e^{12+e^{-3 x+x^2}+x} x \, dx-12 \int e^{12+e^{-3 x+x^2}-2 x+x^2} x \, dx-28 \int e^{12+e^{-3 x+x^2}-2 x+x^2} x^3 \, dx+32 \int e^{12+e^{-3 x+x^2}-2 x+x^2} x^2 \, dx \\ \end{align*}

Mathematica [A] (verified)

Time = 3.35 (sec) , antiderivative size = 22, normalized size of antiderivative = 1.00 \[ \int \left (1+e^{2+e^{-3 x+x^2}+x} \left (e^{10} \left (4-12 x+4 x^2+4 x^3\right )+e^{10-3 x+x^2} \left (-12 x+32 x^2-28 x^3+8 x^4\right )\right )\right ) \, dx=x+4 e^{12+e^{(-3+x) x}+x} (-1+x)^2 x \]

[In]

Integrate[1 + E^(2 + E^(-3*x + x^2) + x)*(E^10*(4 - 12*x + 4*x^2 + 4*x^3) + E^(10 - 3*x + x^2)*(-12*x + 32*x^2
 - 28*x^3 + 8*x^4)),x]

[Out]

x + 4*E^(12 + E^((-3 + x)*x) + x)*(-1 + x)^2*x

Maple [A] (verified)

Time = 0.41 (sec) , antiderivative size = 24, normalized size of antiderivative = 1.09

method result size
risch \(4 x \left (x^{2}-2 x +1\right ) {\mathrm e}^{12+x +{\mathrm e}^{x \left (-3+x \right )}}+x\) \(24\)
default \(x +4 \,{\mathrm e}^{{\mathrm e}^{x^{2}-3 x}+2+x} {\mathrm e}^{10} x -8 \,{\mathrm e}^{{\mathrm e}^{x^{2}-3 x}+2+x} {\mathrm e}^{10} x^{2}+4 \,{\mathrm e}^{{\mathrm e}^{x^{2}-3 x}+2+x} {\mathrm e}^{10} x^{3}\) \(64\)
norman \(x +4 \,{\mathrm e}^{{\mathrm e}^{x^{2}-3 x}+2+x} {\mathrm e}^{10} x -8 \,{\mathrm e}^{{\mathrm e}^{x^{2}-3 x}+2+x} {\mathrm e}^{10} x^{2}+4 \,{\mathrm e}^{{\mathrm e}^{x^{2}-3 x}+2+x} {\mathrm e}^{10} x^{3}\) \(64\)
parallelrisch \(x +4 \,{\mathrm e}^{{\mathrm e}^{x^{2}-3 x}+2+x} {\mathrm e}^{10} x -8 \,{\mathrm e}^{{\mathrm e}^{x^{2}-3 x}+2+x} {\mathrm e}^{10} x^{2}+4 \,{\mathrm e}^{{\mathrm e}^{x^{2}-3 x}+2+x} {\mathrm e}^{10} x^{3}\) \(64\)
parts \(x +4 \,{\mathrm e}^{{\mathrm e}^{x^{2}-3 x}+2+x} {\mathrm e}^{10} x -8 \,{\mathrm e}^{{\mathrm e}^{x^{2}-3 x}+2+x} {\mathrm e}^{10} x^{2}+4 \,{\mathrm e}^{{\mathrm e}^{x^{2}-3 x}+2+x} {\mathrm e}^{10} x^{3}\) \(64\)

[In]

int(((8*x^4-28*x^3+32*x^2-12*x)*exp(5)^2*exp(x^2-3*x)+(4*x^3+4*x^2-12*x+4)*exp(5)^2)*exp(exp(x^2-3*x)+2+x)+1,x
,method=_RETURNVERBOSE)

[Out]

4*x*(x^2-2*x+1)*exp(12+x+exp(x*(-3+x)))+x

Fricas [A] (verification not implemented)

none

Time = 0.24 (sec) , antiderivative size = 36, normalized size of antiderivative = 1.64 \[ \int \left (1+e^{2+e^{-3 x+x^2}+x} \left (e^{10} \left (4-12 x+4 x^2+4 x^3\right )+e^{10-3 x+x^2} \left (-12 x+32 x^2-28 x^3+8 x^4\right )\right )\right ) \, dx=4 \, {\left (x^{3} - 2 \, x^{2} + x\right )} e^{\left ({\left ({\left (x + 2\right )} e^{10} + e^{\left (x^{2} - 3 \, x + 10\right )}\right )} e^{\left (-10\right )} + 10\right )} + x \]

[In]

integrate(((8*x^4-28*x^3+32*x^2-12*x)*exp(5)^2*exp(x^2-3*x)+(4*x^3+4*x^2-12*x+4)*exp(5)^2)*exp(exp(x^2-3*x)+2+
x)+1,x, algorithm="fricas")

[Out]

4*(x^3 - 2*x^2 + x)*e^(((x + 2)*e^10 + e^(x^2 - 3*x + 10))*e^(-10) + 10) + x

Sympy [A] (verification not implemented)

Time = 16.46 (sec) , antiderivative size = 37, normalized size of antiderivative = 1.68 \[ \int \left (1+e^{2+e^{-3 x+x^2}+x} \left (e^{10} \left (4-12 x+4 x^2+4 x^3\right )+e^{10-3 x+x^2} \left (-12 x+32 x^2-28 x^3+8 x^4\right )\right )\right ) \, dx=x + \left (4 x^{3} e^{10} - 8 x^{2} e^{10} + 4 x e^{10}\right ) e^{x + e^{x^{2} - 3 x} + 2} \]

[In]

integrate(((8*x**4-28*x**3+32*x**2-12*x)*exp(5)**2*exp(x**2-3*x)+(4*x**3+4*x**2-12*x+4)*exp(5)**2)*exp(exp(x**
2-3*x)+2+x)+1,x)

[Out]

x + (4*x**3*exp(10) - 8*x**2*exp(10) + 4*x*exp(10))*exp(x + exp(x**2 - 3*x) + 2)

Maxima [A] (verification not implemented)

none

Time = 0.30 (sec) , antiderivative size = 33, normalized size of antiderivative = 1.50 \[ \int \left (1+e^{2+e^{-3 x+x^2}+x} \left (e^{10} \left (4-12 x+4 x^2+4 x^3\right )+e^{10-3 x+x^2} \left (-12 x+32 x^2-28 x^3+8 x^4\right )\right )\right ) \, dx=4 \, {\left (x^{3} e^{12} - 2 \, x^{2} e^{12} + x e^{12}\right )} e^{\left (x + e^{\left (x^{2} - 3 \, x\right )}\right )} + x \]

[In]

integrate(((8*x^4-28*x^3+32*x^2-12*x)*exp(5)^2*exp(x^2-3*x)+(4*x^3+4*x^2-12*x+4)*exp(5)^2)*exp(exp(x^2-3*x)+2+
x)+1,x, algorithm="maxima")

[Out]

4*(x^3*e^12 - 2*x^2*e^12 + x*e^12)*e^(x + e^(x^2 - 3*x)) + x

Giac [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 51 vs. \(2 (20) = 40\).

Time = 0.30 (sec) , antiderivative size = 51, normalized size of antiderivative = 2.32 \[ \int \left (1+e^{2+e^{-3 x+x^2}+x} \left (e^{10} \left (4-12 x+4 x^2+4 x^3\right )+e^{10-3 x+x^2} \left (-12 x+32 x^2-28 x^3+8 x^4\right )\right )\right ) \, dx=4 \, x^{3} e^{\left (x + e^{\left (x^{2} - 3 \, x\right )} + 12\right )} - 8 \, x^{2} e^{\left (x + e^{\left (x^{2} - 3 \, x\right )} + 12\right )} + 4 \, x e^{\left (x + e^{\left (x^{2} - 3 \, x\right )} + 12\right )} + x \]

[In]

integrate(((8*x^4-28*x^3+32*x^2-12*x)*exp(5)^2*exp(x^2-3*x)+(4*x^3+4*x^2-12*x+4)*exp(5)^2)*exp(exp(x^2-3*x)+2+
x)+1,x, algorithm="giac")

[Out]

4*x^3*e^(x + e^(x^2 - 3*x) + 12) - 8*x^2*e^(x + e^(x^2 - 3*x) + 12) + 4*x*e^(x + e^(x^2 - 3*x) + 12) + x

Mupad [B] (verification not implemented)

Time = 10.81 (sec) , antiderivative size = 54, normalized size of antiderivative = 2.45 \[ \int \left (1+e^{2+e^{-3 x+x^2}+x} \left (e^{10} \left (4-12 x+4 x^2+4 x^3\right )+e^{10-3 x+x^2} \left (-12 x+32 x^2-28 x^3+8 x^4\right )\right )\right ) \, dx=x-8\,x^2\,{\mathrm {e}}^{x+{\mathrm {e}}^{-3\,x}\,{\mathrm {e}}^{x^2}+12}+4\,x^3\,{\mathrm {e}}^{x+{\mathrm {e}}^{-3\,x}\,{\mathrm {e}}^{x^2}+12}+4\,x\,{\mathrm {e}}^{x+{\mathrm {e}}^{-3\,x}\,{\mathrm {e}}^{x^2}+12} \]

[In]

int(exp(x + exp(x^2 - 3*x) + 2)*(exp(10)*(4*x^2 - 12*x + 4*x^3 + 4) - exp(10)*exp(x^2 - 3*x)*(12*x - 32*x^2 +
28*x^3 - 8*x^4)) + 1,x)

[Out]

x - 8*x^2*exp(x + exp(-3*x)*exp(x^2) + 12) + 4*x^3*exp(x + exp(-3*x)*exp(x^2) + 12) + 4*x*exp(x + exp(-3*x)*ex
p(x^2) + 12)