\(\int \frac {1}{2} (20+e^{\frac {1}{2} (-x+2 e^2 x-4 x^2)} (1-2 e^2+8 x)) \, dx\) [1617]

   Optimal result
   Rubi [A] (verified)
   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 [B] (verification not implemented)

Optimal result

Integrand size = 38, antiderivative size = 30 \[ \int \frac {1}{2} \left (20+e^{\frac {1}{2} \left (-x+2 e^2 x-4 x^2\right )} \left (1-2 e^2+8 x\right )\right ) \, dx=-e^{-x+x \left (e^2-\left (2-\frac {1}{2 x}\right ) x\right )}+10 x \]

[Out]

10*x-exp(x*(exp(2)-x*(2-1/2/x))-x)

Rubi [A] (verified)

Time = 0.04 (sec) , antiderivative size = 26, normalized size of antiderivative = 0.87, number of steps used = 4, number of rules used = 3, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.079, Rules used = {12, 2276, 2268} \[ \int \frac {1}{2} \left (20+e^{\frac {1}{2} \left (-x+2 e^2 x-4 x^2\right )} \left (1-2 e^2+8 x\right )\right ) \, dx=10 x-e^{-2 x^2-\frac {1}{2} \left (1-2 e^2\right ) x} \]

[In]

Int[(20 + E^((-x + 2*E^2*x - 4*x^2)/2)*(1 - 2*E^2 + 8*x))/2,x]

[Out]

-E^(-1/2*((1 - 2*E^2)*x) - 2*x^2) + 10*x

Rule 12

Int[(a_)*(u_), x_Symbol] :> Dist[a, Int[u, x], x] /; FreeQ[a, x] &&  !MatchQ[u, (b_)*(v_) /; FreeQ[b, x]]

Rule 2268

Int[(F_)^((a_.) + (b_.)*(x_) + (c_.)*(x_)^2)*((d_.) + (e_.)*(x_)), x_Symbol] :> Simp[e*(F^(a + b*x + c*x^2)/(2
*c*Log[F])), x] /; FreeQ[{F, a, b, c, d, e}, x] && EqQ[b*e - 2*c*d, 0]

Rule 2276

Int[(F_)^(v_)*(u_)^(m_.), x_Symbol] :> Int[ExpandToSum[u, x]^m*F^ExpandToSum[v, x], x] /; FreeQ[{F, m}, x] &&
LinearQ[u, x] && QuadraticQ[v, x] &&  !(LinearMatchQ[u, x] && QuadraticMatchQ[v, x])

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

Mathematica [A] (verified)

Time = 0.14 (sec) , antiderivative size = 23, normalized size of antiderivative = 0.77 \[ \int \frac {1}{2} \left (20+e^{\frac {1}{2} \left (-x+2 e^2 x-4 x^2\right )} \left (1-2 e^2+8 x\right )\right ) \, dx=-e^{-\frac {1}{2} x \left (1-2 e^2+4 x\right )}+10 x \]

[In]

Integrate[(20 + E^((-x + 2*E^2*x - 4*x^2)/2)*(1 - 2*E^2 + 8*x))/2,x]

[Out]

-E^(-1/2*(x*(1 - 2*E^2 + 4*x))) + 10*x

Maple [A] (verified)

Time = 0.07 (sec) , antiderivative size = 20, normalized size of antiderivative = 0.67

method result size
risch \(10 x -{\mathrm e}^{\frac {x \left (2 \,{\mathrm e}^{2}-4 x -1\right )}{2}}\) \(20\)
parallelrisch \(10 x -{\mathrm e}^{\frac {x \left (2 \,{\mathrm e}^{2}-4 x -1\right )}{2}}\) \(20\)
norman \(10 x -{\mathrm e}^{{\mathrm e}^{2} x -2 x^{2}-\frac {x}{2}}\) \(21\)
default \(10 x +\frac {\sqrt {\pi }\, {\mathrm e}^{\frac {\left ({\mathrm e}^{2}-\frac {1}{2}\right )^{2}}{8}} \sqrt {2}\, \operatorname {erf}\left (\sqrt {2}\, x -\frac {\left ({\mathrm e}^{2}-\frac {1}{2}\right ) \sqrt {2}}{4}\right )}{8}-{\mathrm e}^{-2 x^{2}+\left ({\mathrm e}^{2}-\frac {1}{2}\right ) x}+\frac {\left ({\mathrm e}^{2}-\frac {1}{2}\right ) \sqrt {\pi }\, {\mathrm e}^{\frac {\left ({\mathrm e}^{2}-\frac {1}{2}\right )^{2}}{8}} \sqrt {2}\, \operatorname {erf}\left (\sqrt {2}\, x -\frac {\left ({\mathrm e}^{2}-\frac {1}{2}\right ) \sqrt {2}}{4}\right )}{4}-\frac {{\mathrm e}^{2} \sqrt {\pi }\, {\mathrm e}^{\frac {\left ({\mathrm e}^{2}-\frac {1}{2}\right )^{2}}{8}} \sqrt {2}\, \operatorname {erf}\left (\sqrt {2}\, x -\frac {\left ({\mathrm e}^{2}-\frac {1}{2}\right ) \sqrt {2}}{4}\right )}{4}\) \(125\)
parts \(10 x +\frac {\sqrt {\pi }\, {\mathrm e}^{\frac {\left ({\mathrm e}^{2}-\frac {1}{2}\right )^{2}}{8}} \sqrt {2}\, \operatorname {erf}\left (\sqrt {2}\, x -\frac {\left ({\mathrm e}^{2}-\frac {1}{2}\right ) \sqrt {2}}{4}\right )}{8}-{\mathrm e}^{-2 x^{2}+\left ({\mathrm e}^{2}-\frac {1}{2}\right ) x}+\frac {\left ({\mathrm e}^{2}-\frac {1}{2}\right ) \sqrt {\pi }\, {\mathrm e}^{\frac {\left ({\mathrm e}^{2}-\frac {1}{2}\right )^{2}}{8}} \sqrt {2}\, \operatorname {erf}\left (\sqrt {2}\, x -\frac {\left ({\mathrm e}^{2}-\frac {1}{2}\right ) \sqrt {2}}{4}\right )}{4}-\frac {{\mathrm e}^{2} \sqrt {\pi }\, {\mathrm e}^{\frac {\left ({\mathrm e}^{2}-\frac {1}{2}\right )^{2}}{8}} \sqrt {2}\, \operatorname {erf}\left (\sqrt {2}\, x -\frac {\left ({\mathrm e}^{2}-\frac {1}{2}\right ) \sqrt {2}}{4}\right )}{4}\) \(125\)

[In]

int(1/2*(-2*exp(2)+8*x+1)*exp(exp(2)*x-2*x^2-1/2*x)+10,x,method=_RETURNVERBOSE)

[Out]

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

Fricas [A] (verification not implemented)

none

Time = 0.26 (sec) , antiderivative size = 20, normalized size of antiderivative = 0.67 \[ \int \frac {1}{2} \left (20+e^{\frac {1}{2} \left (-x+2 e^2 x-4 x^2\right )} \left (1-2 e^2+8 x\right )\right ) \, dx=10 \, x - e^{\left (-2 \, x^{2} + x e^{2} - \frac {1}{2} \, x\right )} \]

[In]

integrate(1/2*(-2*exp(2)+8*x+1)*exp(exp(2)*x-2*x^2-1/2*x)+10,x, algorithm="fricas")

[Out]

10*x - e^(-2*x^2 + x*e^2 - 1/2*x)

Sympy [A] (verification not implemented)

Time = 0.06 (sec) , antiderivative size = 17, normalized size of antiderivative = 0.57 \[ \int \frac {1}{2} \left (20+e^{\frac {1}{2} \left (-x+2 e^2 x-4 x^2\right )} \left (1-2 e^2+8 x\right )\right ) \, dx=10 x - e^{- 2 x^{2} - \frac {x}{2} + x e^{2}} \]

[In]

integrate(1/2*(-2*exp(2)+8*x+1)*exp(exp(2)*x-2*x**2-1/2*x)+10,x)

[Out]

10*x - exp(-2*x**2 - x/2 + x*exp(2))

Maxima [A] (verification not implemented)

none

Time = 0.18 (sec) , antiderivative size = 20, normalized size of antiderivative = 0.67 \[ \int \frac {1}{2} \left (20+e^{\frac {1}{2} \left (-x+2 e^2 x-4 x^2\right )} \left (1-2 e^2+8 x\right )\right ) \, dx=10 \, x - e^{\left (-2 \, x^{2} + x e^{2} - \frac {1}{2} \, x\right )} \]

[In]

integrate(1/2*(-2*exp(2)+8*x+1)*exp(exp(2)*x-2*x^2-1/2*x)+10,x, algorithm="maxima")

[Out]

10*x - e^(-2*x^2 + x*e^2 - 1/2*x)

Giac [A] (verification not implemented)

none

Time = 0.26 (sec) , antiderivative size = 20, normalized size of antiderivative = 0.67 \[ \int \frac {1}{2} \left (20+e^{\frac {1}{2} \left (-x+2 e^2 x-4 x^2\right )} \left (1-2 e^2+8 x\right )\right ) \, dx=10 \, x - e^{\left (-2 \, x^{2} + x e^{2} - \frac {1}{2} \, x\right )} \]

[In]

integrate(1/2*(-2*exp(2)+8*x+1)*exp(exp(2)*x-2*x^2-1/2*x)+10,x, algorithm="giac")

[Out]

10*x - e^(-2*x^2 + x*e^2 - 1/2*x)

Mupad [B] (verification not implemented)

Time = 0.19 (sec) , antiderivative size = 20, normalized size of antiderivative = 0.67 \[ \int \frac {1}{2} \left (20+e^{\frac {1}{2} \left (-x+2 e^2 x-4 x^2\right )} \left (1-2 e^2+8 x\right )\right ) \, dx=10\,x-{\mathrm {e}}^{x\,{\mathrm {e}}^2-\frac {x}{2}-2\,x^2} \]

[In]

int((exp(x*exp(2) - x/2 - 2*x^2)*(8*x - 2*exp(2) + 1))/2 + 10,x)

[Out]

10*x - exp(x*exp(2) - x/2 - 2*x^2)