3.37.27 \(\int \frac {4+e^{2 x} (-1-x)-x^2}{2-2 x+e^{2 x} x-x^2} \, dx\)

Optimal. Leaf size=20 \[ 1+x-\log \left (2+\left (-2+e^{2 x}-x\right ) x\right ) \]

________________________________________________________________________________________

Rubi [F]  time = 0.67, antiderivative size = 0, normalized size of antiderivative = 0.00, number of steps used = 0, number of rules used = 0, integrand size = 0, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.000, Rules used = {} \begin {gather*} \int \frac {4+e^{2 x} (-1-x)-x^2}{2-2 x+e^{2 x} x-x^2} \, dx \end {gather*}

Verification is not applicable to the result.

[In]

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

[Out]

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

Rubi steps

\begin {gather*} \begin {aligned} \text {integral} &=\int \left (\frac {-1-x}{x}+\frac {-2-4 x+3 x^2+2 x^3}{x \left (-2+2 x-e^{2 x} x+x^2\right )}\right ) \, dx\\ &=\int \frac {-1-x}{x} \, dx+\int \frac {-2-4 x+3 x^2+2 x^3}{x \left (-2+2 x-e^{2 x} x+x^2\right )} \, dx\\ &=\int \left (-1-\frac {1}{x}\right ) \, dx+\int \left (-\frac {4}{-2+2 x-e^{2 x} x+x^2}-\frac {2}{x \left (-2+2 x-e^{2 x} x+x^2\right )}+\frac {3 x}{-2+2 x-e^{2 x} x+x^2}+\frac {2 x^2}{-2+2 x-e^{2 x} x+x^2}\right ) \, dx\\ &=-x-\log (x)-2 \int \frac {1}{x \left (-2+2 x-e^{2 x} x+x^2\right )} \, dx+2 \int \frac {x^2}{-2+2 x-e^{2 x} x+x^2} \, dx+3 \int \frac {x}{-2+2 x-e^{2 x} x+x^2} \, dx-4 \int \frac {1}{-2+2 x-e^{2 x} x+x^2} \, dx\\ \end {aligned} \end {gather*}

________________________________________________________________________________________

Mathematica [A]  time = 0.20, size = 22, normalized size = 1.10 \begin {gather*} x-\log \left (2-2 x+e^{2 x} x-x^2\right ) \end {gather*}

Antiderivative was successfully verified.

[In]

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

[Out]

x - Log[2 - 2*x + E^(2*x)*x - x^2]

________________________________________________________________________________________

fricas [A]  time = 0.57, size = 29, normalized size = 1.45 \begin {gather*} x - \log \relax (x) - \log \left (-\frac {x^{2} - x e^{\left (2 \, x\right )} + 2 \, x - 2}{x}\right ) \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

x - log(x) - log(-(x^2 - x*e^(2*x) + 2*x - 2)/x)

________________________________________________________________________________________

giac [A]  time = 0.14, size = 21, normalized size = 1.05 \begin {gather*} x - \log \left (-x^{2} + x e^{\left (2 \, x\right )} - 2 \, x + 2\right ) \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

x - log(-x^2 + x*e^(2*x) - 2*x + 2)

________________________________________________________________________________________

maple [A]  time = 0.04, size = 21, normalized size = 1.05




method result size



norman \(x -\ln \left (-x \,{\mathrm e}^{2 x}+x^{2}+2 x -2\right )\) \(21\)
risch \(x -\ln \relax (x )-\ln \left ({\mathrm e}^{2 x}-\frac {x^{2}+2 x -2}{x}\right )\) \(28\)



Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

x-ln(-x*exp(x)^2+x^2+2*x-2)

________________________________________________________________________________________

maxima [A]  time = 0.48, size = 29, normalized size = 1.45 \begin {gather*} x - \log \relax (x) - \log \left (-\frac {x^{2} - x e^{\left (2 \, x\right )} + 2 \, x - 2}{x}\right ) \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

x - log(x) - log(-(x^2 - x*e^(2*x) + 2*x - 2)/x)

________________________________________________________________________________________

mupad [B]  time = 0.08, size = 20, normalized size = 1.00 \begin {gather*} x-\ln \left (2\,x-x\,{\mathrm {e}}^{2\,x}+x^2-2\right ) \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

x - log(2*x - x*exp(2*x) + x^2 - 2)

________________________________________________________________________________________

sympy [A]  time = 0.19, size = 20, normalized size = 1.00 \begin {gather*} x - \log {\relax (x )} - \log {\left (e^{2 x} + \frac {- x^{2} - 2 x + 2}{x} \right )} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

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

________________________________________________________________________________________