\(\int \frac {6-20 x+28 x^2+e^5 (-2+6 x-8 x^2)}{3 x-14 x^2+e^5 (-x+4 x^2)} \, dx\) [6687]

   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 = 49, antiderivative size = 29 \[ \int \frac {6-20 x+28 x^2+e^5 \left (-2+6 x-8 x^2\right )}{3 x-14 x^2+e^5 \left (-x+4 x^2\right )} \, dx=-3-2 x+\log \left (\frac {x^2}{1-4 x-\frac {2 x}{3-e^5}}\right ) \]

[Out]

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

Rubi [A] (verified)

Time = 0.06 (sec) , antiderivative size = 28, normalized size of antiderivative = 0.97, number of steps used = 4, number of rules used = 3, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.061, Rules used = {2009, 1607, 907} \[ \int \frac {6-20 x+28 x^2+e^5 \left (-2+6 x-8 x^2\right )}{3 x-14 x^2+e^5 \left (-x+4 x^2\right )} \, dx=-2 x+2 \log (x)-\log \left (-2 \left (7-2 e^5\right ) x-e^5+3\right ) \]

[In]

Int[(6 - 20*x + 28*x^2 + E^5*(-2 + 6*x - 8*x^2))/(3*x - 14*x^2 + E^5*(-x + 4*x^2)),x]

[Out]

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

Rule 907

Int[((d_.) + (e_.)*(x_))^(m_)*((f_.) + (g_.)*(x_))^(n_)*((a_.) + (b_.)*(x_) + (c_.)*(x_)^2)^(p_.), x_Symbol] :
> Int[ExpandIntegrand[(d + e*x)^m*(f + g*x)^n*(a + b*x + c*x^2)^p, x], x] /; FreeQ[{a, b, c, d, e, f, g}, x] &
& NeQ[e*f - d*g, 0] && NeQ[b^2 - 4*a*c, 0] && NeQ[c*d^2 - b*d*e + a*e^2, 0] && IntegerQ[p] && ((EqQ[p, 1] && I
ntegersQ[m, n]) || (ILtQ[m, 0] && ILtQ[n, 0]))

Rule 1607

Int[(u_.)*((a_.)*(x_)^(p_.) + (b_.)*(x_)^(q_.))^(n_.), x_Symbol] :> Int[u*x^(n*p)*(a + b*x^(q - p))^n, x] /; F
reeQ[{a, b, p, q}, x] && IntegerQ[n] && PosQ[q - p]

Rule 2009

Int[(u_)^(p_.)*(v_)^(q_.), x_Symbol] :> Int[ExpandToSum[u, x]^p*ExpandToSum[v, x]^q, x] /; FreeQ[{p, q}, x] &&
 QuadraticQ[{u, v}, x] &&  !QuadraticMatchQ[{u, v}, x]

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

Mathematica [A] (verified)

Time = 0.02 (sec) , antiderivative size = 27, normalized size of antiderivative = 0.93 \[ \int \frac {6-20 x+28 x^2+e^5 \left (-2+6 x-8 x^2\right )}{3 x-14 x^2+e^5 \left (-x+4 x^2\right )} \, dx=-2 x+2 \log (x)-\log \left (3-e^5-14 x+4 e^5 x\right ) \]

[In]

Integrate[(6 - 20*x + 28*x^2 + E^5*(-2 + 6*x - 8*x^2))/(3*x - 14*x^2 + E^5*(-x + 4*x^2)),x]

[Out]

-2*x + 2*Log[x] - Log[3 - E^5 - 14*x + 4*E^5*x]

Maple [A] (verified)

Time = 0.50 (sec) , antiderivative size = 26, normalized size of antiderivative = 0.90

method result size
norman \(-2 x +2 \ln \left (x \right )-\ln \left (4 x \,{\mathrm e}^{5}-{\mathrm e}^{5}-14 x +3\right )\) \(26\)
risch \(-2 x +2 \ln \left (-x \right )-\ln \left (x \left (4 \,{\mathrm e}^{5}-14\right )+3-{\mathrm e}^{5}\right )\) \(28\)
parallelrisch \(-2 x +2 \ln \left (x \right )-\ln \left (\frac {4 x \,{\mathrm e}^{5}-{\mathrm e}^{5}-14 x +3}{4 \,{\mathrm e}^{5}-14}\right )\) \(36\)
default \(-2 x +\frac {2 \left (-2 \,{\mathrm e}^{5}+7\right ) \ln \left (4 x \,{\mathrm e}^{5}-{\mathrm e}^{5}-14 x +3\right )}{4 \,{\mathrm e}^{5}-14}+2 \ln \left (x \right )\) \(40\)
meijerg \(\frac {\left ({\mathrm e}^{5}-3\right )^{2} \left (-8 \,{\mathrm e}^{5}+28\right ) \left (\frac {2 x \left (2 \,{\mathrm e}^{5}-7\right )}{3-{\mathrm e}^{5}}-\ln \left (1+\frac {2 x \left (2 \,{\mathrm e}^{5}-7\right )}{3-{\mathrm e}^{5}}\right )\right )}{4 \left (2 \,{\mathrm e}^{5}-7\right )^{2} \left (3-{\mathrm e}^{5}\right )}-\frac {\left (6 \,{\mathrm e}^{5}-20\right ) \left ({\mathrm e}^{5}-3\right ) \ln \left (1+\frac {2 x \left (2 \,{\mathrm e}^{5}-7\right )}{3-{\mathrm e}^{5}}\right )}{2 \left (3-{\mathrm e}^{5}\right ) \left (2 \,{\mathrm e}^{5}-7\right )}+\frac {2 \,{\mathrm e}^{5} \left ({\mathrm e}^{5}-3\right ) \left (\ln \left (x \right )+\ln \left (2\right )+\ln \left (2 \,{\mathrm e}^{5}-7\right )+\ln \left (-\frac {1}{3-{\mathrm e}^{5}}\right )+i \pi -\ln \left (1+\frac {2 x \left (2 \,{\mathrm e}^{5}-7\right )}{3-{\mathrm e}^{5}}\right )\right )}{\left (3-{\mathrm e}^{5}\right )^{2}}-\frac {6 \left ({\mathrm e}^{5}-3\right ) \left (\ln \left (x \right )+\ln \left (2\right )+\ln \left (2 \,{\mathrm e}^{5}-7\right )+\ln \left (-\frac {1}{3-{\mathrm e}^{5}}\right )+i \pi -\ln \left (1+\frac {2 x \left (2 \,{\mathrm e}^{5}-7\right )}{3-{\mathrm e}^{5}}\right )\right )}{\left (3-{\mathrm e}^{5}\right )^{2}}\) \(248\)

[In]

int(((-8*x^2+6*x-2)*exp(5)+28*x^2-20*x+6)/((4*x^2-x)*exp(5)-14*x^2+3*x),x,method=_RETURNVERBOSE)

[Out]

-2*x+2*ln(x)-ln(4*x*exp(5)-exp(5)-14*x+3)

Fricas [A] (verification not implemented)

none

Time = 0.43 (sec) , antiderivative size = 24, normalized size of antiderivative = 0.83 \[ \int \frac {6-20 x+28 x^2+e^5 \left (-2+6 x-8 x^2\right )}{3 x-14 x^2+e^5 \left (-x+4 x^2\right )} \, dx=-2 \, x - \log \left ({\left (4 \, x - 1\right )} e^{5} - 14 \, x + 3\right ) + 2 \, \log \left (x\right ) \]

[In]

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

[Out]

-2*x - log((4*x - 1)*e^5 - 14*x + 3) + 2*log(x)

Sympy [A] (verification not implemented)

Time = 0.66 (sec) , antiderivative size = 24, normalized size of antiderivative = 0.83 \[ \int \frac {6-20 x+28 x^2+e^5 \left (-2+6 x-8 x^2\right )}{3 x-14 x^2+e^5 \left (-x+4 x^2\right )} \, dx=- 2 x + 2 \log {\left (x \right )} - \log {\left (x + \frac {9 - 3 e^{5}}{-42 + 12 e^{5}} \right )} \]

[In]

integrate(((-8*x**2+6*x-2)*exp(5)+28*x**2-20*x+6)/((4*x**2-x)*exp(5)-14*x**2+3*x),x)

[Out]

-2*x + 2*log(x) - log(x + (9 - 3*exp(5))/(-42 + 12*exp(5)))

Maxima [A] (verification not implemented)

none

Time = 0.20 (sec) , antiderivative size = 26, normalized size of antiderivative = 0.90 \[ \int \frac {6-20 x+28 x^2+e^5 \left (-2+6 x-8 x^2\right )}{3 x-14 x^2+e^5 \left (-x+4 x^2\right )} \, dx=-2 \, x - \log \left (2 \, x {\left (2 \, e^{5} - 7\right )} - e^{5} + 3\right ) + 2 \, \log \left (x\right ) \]

[In]

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

[Out]

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

Giac [A] (verification not implemented)

none

Time = 0.28 (sec) , antiderivative size = 43, normalized size of antiderivative = 1.48 \[ \int \frac {6-20 x+28 x^2+e^5 \left (-2+6 x-8 x^2\right )}{3 x-14 x^2+e^5 \left (-x+4 x^2\right )} \, dx=-\frac {2 \, {\left (2 \, x e^{5} - 7 \, x\right )}}{2 \, e^{5} - 7} - \log \left ({\left | 4 \, x e^{5} - 14 \, x - e^{5} + 3 \right |}\right ) + 2 \, \log \left ({\left | x \right |}\right ) \]

[In]

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

[Out]

-2*(2*x*e^5 - 7*x)/(2*e^5 - 7) - log(abs(4*x*e^5 - 14*x - e^5 + 3)) + 2*log(abs(x))

Mupad [B] (verification not implemented)

Time = 12.68 (sec) , antiderivative size = 46, normalized size of antiderivative = 1.59 \[ \int \frac {6-20 x+28 x^2+e^5 \left (-2+6 x-8 x^2\right )}{3 x-14 x^2+e^5 \left (-x+4 x^2\right )} \, dx=2\,\ln \left (x\right )-\ln \left (12\,x\,{\mathrm {e}}^5-3\,{\mathrm {e}}^5-42\,x+9\right )+\frac {28\,x}{4\,{\mathrm {e}}^5-14}-\frac {8\,x\,{\mathrm {e}}^5}{4\,{\mathrm {e}}^5-14} \]

[In]

int((20*x + exp(5)*(8*x^2 - 6*x + 2) - 28*x^2 - 6)/(exp(5)*(x - 4*x^2) - 3*x + 14*x^2),x)

[Out]

2*log(x) - log(12*x*exp(5) - 3*exp(5) - 42*x + 9) + (28*x)/(4*exp(5) - 14) - (8*x*exp(5))/(4*exp(5) - 14)