3.11.78 \(\int \frac {-9 x+14 x^2-3 x^3+e^x (-6-2 x+x^2)}{-3 x^2+4 x^3-x^4+e^x (-3 x+x^2)} \, dx\)

Optimal. Leaf size=23 \[ \log \left (\frac {x^2 \left (e^x+x-x^2\right )}{500 (-3+x)}\right ) \]

________________________________________________________________________________________

Rubi [F]  time = 0.89, 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 {-9 x+14 x^2-3 x^3+e^x \left (-6-2 x+x^2\right )}{-3 x^2+4 x^3-x^4+e^x \left (-3 x+x^2\right )} \, dx \end {gather*}

Verification is not applicable to the result.

[In]

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

[Out]

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

Rubi steps

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

________________________________________________________________________________________

Mathematica [A]  time = 0.16, size = 24, normalized size = 1.04 \begin {gather*} -\log (3-x)+2 \log (x)+\log \left (e^x+x-x^2\right ) \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[(-9*x + 14*x^2 - 3*x^3 + E^x*(-6 - 2*x + x^2))/(-3*x^2 + 4*x^3 - x^4 + E^x*(-3*x + x^2)),x]

[Out]

-Log[3 - x] + 2*Log[x] + Log[E^x + x - x^2]

________________________________________________________________________________________

fricas [A]  time = 0.71, size = 21, normalized size = 0.91 \begin {gather*} \log \left (-x^{2} + x + e^{x}\right ) - \log \left (x - 3\right ) + 2 \, \log \relax (x) \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(((x^2-2*x-6)*exp(x)-3*x^3+14*x^2-9*x)/((x^2-3*x)*exp(x)-x^4+4*x^3-3*x^2),x, algorithm="fricas")

[Out]

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

________________________________________________________________________________________

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

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(((x^2-2*x-6)*exp(x)-3*x^3+14*x^2-9*x)/((x^2-3*x)*exp(x)-x^4+4*x^3-3*x^2),x, algorithm="giac")

[Out]

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

________________________________________________________________________________________

maple [A]  time = 0.04, size = 22, normalized size = 0.96




method result size



risch \(-\ln \left (x -3\right )+2 \ln \relax (x )+\ln \left (x +{\mathrm e}^{x}-x^{2}\right )\) \(22\)
norman \(2 \ln \relax (x )-\ln \left (x -3\right )+\ln \left (x^{2}-x -{\mathrm e}^{x}\right )\) \(24\)



Verification of antiderivative is not currently implemented for this CAS.

[In]

int(((x^2-2*x-6)*exp(x)-3*x^3+14*x^2-9*x)/((x^2-3*x)*exp(x)-x^4+4*x^3-3*x^2),x,method=_RETURNVERBOSE)

[Out]

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

________________________________________________________________________________________

maxima [A]  time = 0.40, size = 21, normalized size = 0.91 \begin {gather*} \log \left (-x^{2} + x + e^{x}\right ) - \log \left (x - 3\right ) + 2 \, \log \relax (x) \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(((x^2-2*x-6)*exp(x)-3*x^3+14*x^2-9*x)/((x^2-3*x)*exp(x)-x^4+4*x^3-3*x^2),x, algorithm="maxima")

[Out]

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

________________________________________________________________________________________

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

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((9*x + exp(x)*(2*x - x^2 + 6) - 14*x^2 + 3*x^3)/(exp(x)*(3*x - x^2) + 3*x^2 - 4*x^3 + x^4),x)

[Out]

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

________________________________________________________________________________________

sympy [A]  time = 0.17, size = 19, normalized size = 0.83 \begin {gather*} 2 \log {\relax (x )} - \log {\left (x - 3 \right )} + \log {\left (- x^{2} + x + e^{x} \right )} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(((x**2-2*x-6)*exp(x)-3*x**3+14*x**2-9*x)/((x**2-3*x)*exp(x)-x**4+4*x**3-3*x**2),x)

[Out]

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

________________________________________________________________________________________