\(\int \frac {-e^{4+4 x}+12 x^2-x^4+e^{2+2 x} (12-6 x-16 x^2)}{e^{4+4 x}-2 e^{2+2 x} x^2+x^4} \, dx\) [8112]

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

Optimal result

Integrand size = 64, antiderivative size = 32 \[ \int \frac {-e^{4+4 x}+12 x^2-x^4+e^{2+2 x} \left (12-6 x-16 x^2\right )}{e^{4+4 x}-2 e^{2+2 x} x^2+x^4} \, dx=4-x+\frac {3 x (-x+4 (1+x))}{e^{2+2 x}-x^2} \]

[Out]

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

Rubi [F]

\[ \int \frac {-e^{4+4 x}+12 x^2-x^4+e^{2+2 x} \left (12-6 x-16 x^2\right )}{e^{4+4 x}-2 e^{2+2 x} x^2+x^4} \, dx=\int \frac {-e^{4+4 x}+12 x^2-x^4+e^{2+2 x} \left (12-6 x-16 x^2\right )}{e^{4+4 x}-2 e^{2+2 x} x^2+x^4} \, dx \]

[In]

Int[(-E^(4 + 4*x) + 12*x^2 - x^4 + E^(2 + 2*x)*(12 - 6*x - 16*x^2))/(E^(4 + 4*x) - 2*E^(2 + 2*x)*x^2 + x^4),x]

[Out]

-x + 6*Defer[Int][(E^(1 + x) - x)^(-2), x] - (3*Defer[Int][(E^(1 + x) - x)^(-1), x])/2 - (3*Defer[Int][x/(E^(1
 + x) - x)^2, x])/2 - (9*Defer[Int][x/(E^(1 + x) - x), x])/2 - (9*Defer[Int][x^2/(E^(1 + x) - x)^2, x])/2 + 6*
Defer[Int][(E^(1 + x) + x)^(-2), x] - (3*Defer[Int][x/(E^(1 + x) + x)^2, x])/2 - (9*Defer[Int][x^2/(E^(1 + x)
+ x)^2, x])/2 + (3*Defer[Int][(E^(1 + x) + x)^(-1), x])/2 + (9*Defer[Int][x/(E^(1 + x) + x), x])/2

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

Mathematica [A] (verified)

Time = 5.60 (sec) , antiderivative size = 27, normalized size of antiderivative = 0.84 \[ \int \frac {-e^{4+4 x}+12 x^2-x^4+e^{2+2 x} \left (12-6 x-16 x^2\right )}{e^{4+4 x}-2 e^{2+2 x} x^2+x^4} \, dx=-x-\frac {3 x (4+3 x)}{-e^{2+2 x}+x^2} \]

[In]

Integrate[(-E^(4 + 4*x) + 12*x^2 - x^4 + E^(2 + 2*x)*(12 - 6*x - 16*x^2))/(E^(4 + 4*x) - 2*E^(2 + 2*x)*x^2 + x
^4),x]

[Out]

-x - (3*x*(4 + 3*x))/(-E^(2 + 2*x) + x^2)

Maple [A] (verified)

Time = 0.29 (sec) , antiderivative size = 27, normalized size of antiderivative = 0.84

method result size
risch \(-x -\frac {3 \left (4+3 x \right ) x}{x^{2}-{\mathrm e}^{2+2 x}}\) \(27\)
parallelrisch \(-\frac {x^{3}-x \,{\mathrm e}^{2+2 x}+9 x^{2}+12 x}{x^{2}-{\mathrm e}^{2+2 x}}\) \(38\)
norman \(\frac {x \,{\mathrm e}^{2+2 x}-9 \,{\mathrm e}^{2+2 x}-12 x -x^{3}}{x^{2}-{\mathrm e}^{2+2 x}}\) \(41\)

[In]

int((-exp(1+x)^4+(-16*x^2-6*x+12)*exp(1+x)^2-x^4+12*x^2)/(exp(1+x)^4-2*x^2*exp(1+x)^2+x^4),x,method=_RETURNVER
BOSE)

[Out]

-x-3*(4+3*x)*x/(x^2-exp(2+2*x))

Fricas [A] (verification not implemented)

none

Time = 0.26 (sec) , antiderivative size = 37, normalized size of antiderivative = 1.16 \[ \int \frac {-e^{4+4 x}+12 x^2-x^4+e^{2+2 x} \left (12-6 x-16 x^2\right )}{e^{4+4 x}-2 e^{2+2 x} x^2+x^4} \, dx=-\frac {x^{3} + 9 \, x^{2} - x e^{\left (2 \, x + 2\right )} + 12 \, x}{x^{2} - e^{\left (2 \, x + 2\right )}} \]

[In]

integrate((-exp(1+x)^4+(-16*x^2-6*x+12)*exp(1+x)^2-x^4+12*x^2)/(exp(1+x)^4-2*x^2*exp(1+x)^2+x^4),x, algorithm=
"fricas")

[Out]

-(x^3 + 9*x^2 - x*e^(2*x + 2) + 12*x)/(x^2 - e^(2*x + 2))

Sympy [A] (verification not implemented)

Time = 0.05 (sec) , antiderivative size = 19, normalized size of antiderivative = 0.59 \[ \int \frac {-e^{4+4 x}+12 x^2-x^4+e^{2+2 x} \left (12-6 x-16 x^2\right )}{e^{4+4 x}-2 e^{2+2 x} x^2+x^4} \, dx=- x + \frac {9 x^{2} + 12 x}{- x^{2} + e^{2 x + 2}} \]

[In]

integrate((-exp(1+x)**4+(-16*x**2-6*x+12)*exp(1+x)**2-x**4+12*x**2)/(exp(1+x)**4-2*x**2*exp(1+x)**2+x**4),x)

[Out]

-x + (9*x**2 + 12*x)/(-x**2 + exp(2*x + 2))

Maxima [A] (verification not implemented)

none

Time = 0.23 (sec) , antiderivative size = 37, normalized size of antiderivative = 1.16 \[ \int \frac {-e^{4+4 x}+12 x^2-x^4+e^{2+2 x} \left (12-6 x-16 x^2\right )}{e^{4+4 x}-2 e^{2+2 x} x^2+x^4} \, dx=-\frac {x^{3} + 9 \, x^{2} - x e^{\left (2 \, x + 2\right )} + 12 \, x}{x^{2} - e^{\left (2 \, x + 2\right )}} \]

[In]

integrate((-exp(1+x)^4+(-16*x^2-6*x+12)*exp(1+x)^2-x^4+12*x^2)/(exp(1+x)^4-2*x^2*exp(1+x)^2+x^4),x, algorithm=
"maxima")

[Out]

-(x^3 + 9*x^2 - x*e^(2*x + 2) + 12*x)/(x^2 - e^(2*x + 2))

Giac [A] (verification not implemented)

none

Time = 0.29 (sec) , antiderivative size = 37, normalized size of antiderivative = 1.16 \[ \int \frac {-e^{4+4 x}+12 x^2-x^4+e^{2+2 x} \left (12-6 x-16 x^2\right )}{e^{4+4 x}-2 e^{2+2 x} x^2+x^4} \, dx=-\frac {x^{3} + 9 \, x^{2} - x e^{\left (2 \, x + 2\right )} + 12 \, x}{x^{2} - e^{\left (2 \, x + 2\right )}} \]

[In]

integrate((-exp(1+x)^4+(-16*x^2-6*x+12)*exp(1+x)^2-x^4+12*x^2)/(exp(1+x)^4-2*x^2*exp(1+x)^2+x^4),x, algorithm=
"giac")

[Out]

-(x^3 + 9*x^2 - x*e^(2*x + 2) + 12*x)/(x^2 - e^(2*x + 2))

Mupad [B] (verification not implemented)

Time = 13.02 (sec) , antiderivative size = 28, normalized size of antiderivative = 0.88 \[ \int \frac {-e^{4+4 x}+12 x^2-x^4+e^{2+2 x} \left (12-6 x-16 x^2\right )}{e^{4+4 x}-2 e^{2+2 x} x^2+x^4} \, dx=\frac {9\,x^2+12\,x}{{\mathrm {e}}^{2\,x+2}-x^2}-x \]

[In]

int(-(exp(4*x + 4) + exp(2*x + 2)*(6*x + 16*x^2 - 12) - 12*x^2 + x^4)/(exp(4*x + 4) - 2*x^2*exp(2*x + 2) + x^4
),x)

[Out]

(12*x + 9*x^2)/(exp(2*x + 2) - x^2) - x