\(\int \frac {-1-x^2+e^{256+32 x+x^2} (1-32 x-2 x^2)}{x^2} \, dx\) [3453]

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

Optimal result

Integrand size = 32, antiderivative size = 20 \[ \int \frac {-1-x^2+e^{256+32 x+x^2} \left (1-32 x-2 x^2\right )}{x^2} \, dx=\frac {1-e^{(16+x)^2}-x^2}{x} \]

[Out]

1/x*(1-x^2-exp((x+16)^2))

Rubi [A] (verified)

Time = 0.05 (sec) , antiderivative size = 34, normalized size of antiderivative = 1.70, number of steps used = 5, number of rules used = 2, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.062, Rules used = {14, 2326} \[ \int \frac {-1-x^2+e^{256+32 x+x^2} \left (1-32 x-2 x^2\right )}{x^2} \, dx=-\frac {e^{x^2+32 x+256} \left (x^2+16 x\right )}{(x+16) x^2}-x+\frac {1}{x} \]

[In]

Int[(-1 - x^2 + E^(256 + 32*x + x^2)*(1 - 32*x - 2*x^2))/x^2,x]

[Out]

x^(-1) - x - (E^(256 + 32*x + x^2)*(16*x + x^2))/(x^2*(16 + x))

Rule 14

Int[(u_)*((c_.)*(x_))^(m_.), x_Symbol] :> Int[ExpandIntegrand[(c*x)^m*u, x], x] /; FreeQ[{c, m}, x] && SumQ[u]
 &&  !LinearQ[u, x] &&  !MatchQ[u, (a_) + (b_.)*(v_) /; FreeQ[{a, b}, x] && InverseFunctionQ[v]]

Rule 2326

Int[(y_.)*(F_)^(u_)*((v_) + (w_)), x_Symbol] :> With[{z = v*(y/(Log[F]*D[u, x]))}, Simp[F^u*z, x] /; EqQ[D[z,
x], w*y]] /; FreeQ[F, x]

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

Mathematica [A] (verified)

Time = 0.50 (sec) , antiderivative size = 17, normalized size of antiderivative = 0.85 \[ \int \frac {-1-x^2+e^{256+32 x+x^2} \left (1-32 x-2 x^2\right )}{x^2} \, dx=-\frac {-1+e^{(16+x)^2}+x^2}{x} \]

[In]

Integrate[(-1 - x^2 + E^(256 + 32*x + x^2)*(1 - 32*x - 2*x^2))/x^2,x]

[Out]

-((-1 + E^(16 + x)^2 + x^2)/x)

Maple [A] (verified)

Time = 0.72 (sec) , antiderivative size = 19, normalized size of antiderivative = 0.95

method result size
risch \(\frac {1}{x}-x -\frac {{\mathrm e}^{\left (x +16\right )^{2}}}{x}\) \(19\)
parallelrisch \(-\frac {x^{2}-1+{\mathrm e}^{x^{2}+32 x +256}}{x}\) \(20\)
parts \(\frac {1}{x}-x -\frac {{\mathrm e}^{x^{2}+32 x +256}}{x}\) \(22\)
norman \(\frac {1-x^{2}-{\mathrm e}^{x^{2}+32 x +256}}{x}\) \(23\)

[In]

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

[Out]

1/x-x-exp((x+16)^2)/x

Fricas [A] (verification not implemented)

none

Time = 0.24 (sec) , antiderivative size = 19, normalized size of antiderivative = 0.95 \[ \int \frac {-1-x^2+e^{256+32 x+x^2} \left (1-32 x-2 x^2\right )}{x^2} \, dx=-\frac {x^{2} + e^{\left (x^{2} + 32 \, x + 256\right )} - 1}{x} \]

[In]

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

[Out]

-(x^2 + e^(x^2 + 32*x + 256) - 1)/x

Sympy [A] (verification not implemented)

Time = 0.07 (sec) , antiderivative size = 15, normalized size of antiderivative = 0.75 \[ \int \frac {-1-x^2+e^{256+32 x+x^2} \left (1-32 x-2 x^2\right )}{x^2} \, dx=- x - \frac {e^{x^{2} + 32 x + 256}}{x} + \frac {1}{x} \]

[In]

integrate(((-2*x**2-32*x+1)*exp(x**2+32*x+256)-x**2-1)/x**2,x)

[Out]

-x - exp(x**2 + 32*x + 256)/x + 1/x

Maxima [F]

\[ \int \frac {-1-x^2+e^{256+32 x+x^2} \left (1-32 x-2 x^2\right )}{x^2} \, dx=\int { -\frac {x^{2} + {\left (2 \, x^{2} + 32 \, x - 1\right )} e^{\left (x^{2} + 32 \, x + 256\right )} + 1}{x^{2}} \,d x } \]

[In]

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

[Out]

I*sqrt(pi)*erf(I*x + 16*I) - x + 1/x - integrate((32*x*e^256 - e^256)*e^(x^2 + 32*x)/x^2, x)

Giac [A] (verification not implemented)

none

Time = 0.26 (sec) , antiderivative size = 19, normalized size of antiderivative = 0.95 \[ \int \frac {-1-x^2+e^{256+32 x+x^2} \left (1-32 x-2 x^2\right )}{x^2} \, dx=-\frac {x^{2} + e^{\left (x^{2} + 32 \, x + 256\right )} - 1}{x} \]

[In]

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

[Out]

-(x^2 + e^(x^2 + 32*x + 256) - 1)/x

Mupad [B] (verification not implemented)

Time = 0.09 (sec) , antiderivative size = 20, normalized size of antiderivative = 1.00 \[ \int \frac {-1-x^2+e^{256+32 x+x^2} \left (1-32 x-2 x^2\right )}{x^2} \, dx=-x-\frac {{\mathrm {e}}^{x^2+32\,x+256}-1}{x} \]

[In]

int(-(exp(32*x + x^2 + 256)*(32*x + 2*x^2 - 1) + x^2 + 1)/x^2,x)

[Out]

- x - (exp(32*x + x^2 + 256) - 1)/x