\(\int \frac {-4 x^3+4 x^4-x^5+(8 x^3-8 x^4+2 x^5) \log (x)+(40-40 x) \log ^2(x)}{(4 x^2-4 x^3+x^4) \log ^2(x)} \, dx\) [5925]

   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 = 66, antiderivative size = 26 \[ \int \frac {-4 x^3+4 x^4-x^5+\left (8 x^3-8 x^4+2 x^5\right ) \log (x)+(40-40 x) \log ^2(x)}{\left (4 x^2-4 x^3+x^4\right ) \log ^2(x)} \, dx=9+e^3-\frac {20}{2 x-x^2}+\frac {x^2}{\log (x)} \]

[Out]

x^2/ln(x)+9-20/(-x^2+2*x)+exp(3)

Rubi [A] (verified)

Time = 0.22 (sec) , antiderivative size = 21, normalized size of antiderivative = 0.81, number of steps used = 10, number of rules used = 7, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.106, Rules used = {1608, 27, 6820, 75, 2343, 2346, 2209} \[ \int \frac {-4 x^3+4 x^4-x^5+\left (8 x^3-8 x^4+2 x^5\right ) \log (x)+(40-40 x) \log ^2(x)}{\left (4 x^2-4 x^3+x^4\right ) \log ^2(x)} \, dx=\frac {x^2}{\log (x)}-\frac {20}{(2-x) x} \]

[In]

Int[(-4*x^3 + 4*x^4 - x^5 + (8*x^3 - 8*x^4 + 2*x^5)*Log[x] + (40 - 40*x)*Log[x]^2)/((4*x^2 - 4*x^3 + x^4)*Log[
x]^2),x]

[Out]

-20/((2 - x)*x) + x^2/Log[x]

Rule 27

Int[(u_.)*((a_) + (b_.)*(x_) + (c_.)*(x_)^2)^(p_.), x_Symbol] :> Int[u*Cancel[(b/2 + c*x)^(2*p)/c^p], x] /; Fr
eeQ[{a, b, c}, x] && EqQ[b^2 - 4*a*c, 0] && IntegerQ[p]

Rule 75

Int[((a_.) + (b_.)*(x_))*((c_.) + (d_.)*(x_))^(n_.)*((e_.) + (f_.)*(x_))^(p_.), x_Symbol] :> Simp[b*(c + d*x)^
(n + 1)*((e + f*x)^(p + 1)/(d*f*(n + p + 2))), x] /; FreeQ[{a, b, c, d, e, f, n, p}, x] && NeQ[n + p + 2, 0] &
& EqQ[a*d*f*(n + p + 2) - b*(d*e*(n + 1) + c*f*(p + 1)), 0]

Rule 1608

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

Rule 2209

Int[(F_)^((g_.)*((e_.) + (f_.)*(x_)))/((c_.) + (d_.)*(x_)), x_Symbol] :> Simp[(F^(g*(e - c*(f/d)))/d)*ExpInteg
ralEi[f*g*(c + d*x)*(Log[F]/d)], x] /; FreeQ[{F, c, d, e, f, g}, x] &&  !TrueQ[$UseGamma]

Rule 2343

Int[((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))^(p_)*((d_.)*(x_))^(m_.), x_Symbol] :> Simp[(d*x)^(m + 1)*((a + b*Log
[c*x^n])^(p + 1)/(b*d*n*(p + 1))), x] - Dist[(m + 1)/(b*n*(p + 1)), Int[(d*x)^m*(a + b*Log[c*x^n])^(p + 1), x]
, x] /; FreeQ[{a, b, c, d, m, n}, x] && NeQ[m, -1] && LtQ[p, -1]

Rule 2346

Int[((a_.) + Log[(c_.)*(x_)]*(b_.))^(p_)*(x_)^(m_.), x_Symbol] :> Dist[1/c^(m + 1), Subst[Int[E^((m + 1)*x)*(a
 + b*x)^p, x], x, Log[c*x]], x] /; FreeQ[{a, b, c, p}, x] && IntegerQ[m]

Rule 6820

Int[u_, x_Symbol] :> With[{v = SimplifyIntegrand[u, x]}, Int[v, x] /; SimplerIntegrandQ[v, u, x]]

Rubi steps \begin{align*} \text {integral}& = \int \frac {-4 x^3+4 x^4-x^5+\left (8 x^3-8 x^4+2 x^5\right ) \log (x)+(40-40 x) \log ^2(x)}{x^2 \left (4-4 x+x^2\right ) \log ^2(x)} \, dx \\ & = \int \frac {-4 x^3+4 x^4-x^5+\left (8 x^3-8 x^4+2 x^5\right ) \log (x)+(40-40 x) \log ^2(x)}{(-2+x)^2 x^2 \log ^2(x)} \, dx \\ & = \int \left (-\frac {40 (-1+x)}{(-2+x)^2 x^2}-\frac {x}{\log ^2(x)}+\frac {2 x}{\log (x)}\right ) \, dx \\ & = 2 \int \frac {x}{\log (x)} \, dx-40 \int \frac {-1+x}{(-2+x)^2 x^2} \, dx-\int \frac {x}{\log ^2(x)} \, dx \\ & = -\frac {20}{(2-x) x}+\frac {x^2}{\log (x)}-2 \int \frac {x}{\log (x)} \, dx+2 \text {Subst}\left (\int \frac {e^{2 x}}{x} \, dx,x,\log (x)\right ) \\ & = -\frac {20}{(2-x) x}+2 \text {Ei}(2 \log (x))+\frac {x^2}{\log (x)}-2 \text {Subst}\left (\int \frac {e^{2 x}}{x} \, dx,x,\log (x)\right ) \\ & = -\frac {20}{(2-x) x}+\frac {x^2}{\log (x)} \\ \end{align*}

Mathematica [A] (verified)

Time = 0.07 (sec) , antiderivative size = 21, normalized size of antiderivative = 0.81 \[ \int \frac {-4 x^3+4 x^4-x^5+\left (8 x^3-8 x^4+2 x^5\right ) \log (x)+(40-40 x) \log ^2(x)}{\left (4 x^2-4 x^3+x^4\right ) \log ^2(x)} \, dx=\frac {10}{-2+x}-\frac {10}{x}+\frac {x^2}{\log (x)} \]

[In]

Integrate[(-4*x^3 + 4*x^4 - x^5 + (8*x^3 - 8*x^4 + 2*x^5)*Log[x] + (40 - 40*x)*Log[x]^2)/((4*x^2 - 4*x^3 + x^4
)*Log[x]^2),x]

[Out]

10/(-2 + x) - 10/x + x^2/Log[x]

Maple [A] (verified)

Time = 0.06 (sec) , antiderivative size = 20, normalized size of antiderivative = 0.77

method result size
risch \(\frac {20}{\left (-2+x \right ) x}+\frac {x^{2}}{\ln \left (x \right )}\) \(20\)
default \(\frac {x^{2}}{\ln \left (x \right )}+\frac {10}{-2+x}-\frac {10}{x}\) \(22\)
parts \(\frac {x^{2}}{\ln \left (x \right )}+\frac {10}{-2+x}-\frac {10}{x}\) \(22\)
norman \(\frac {x^{4}-2 x^{3}+20 \ln \left (x \right )}{x \left (-2+x \right ) \ln \left (x \right )}\) \(27\)
parallelrisch \(\frac {x^{4}-2 x^{3}+20 \ln \left (x \right )}{x \left (-2+x \right ) \ln \left (x \right )}\) \(27\)

[In]

int(((-40*x+40)*ln(x)^2+(2*x^5-8*x^4+8*x^3)*ln(x)-x^5+4*x^4-4*x^3)/(x^4-4*x^3+4*x^2)/ln(x)^2,x,method=_RETURNV
ERBOSE)

[Out]

20/(-2+x)/x+x^2/ln(x)

Fricas [A] (verification not implemented)

none

Time = 0.24 (sec) , antiderivative size = 27, normalized size of antiderivative = 1.04 \[ \int \frac {-4 x^3+4 x^4-x^5+\left (8 x^3-8 x^4+2 x^5\right ) \log (x)+(40-40 x) \log ^2(x)}{\left (4 x^2-4 x^3+x^4\right ) \log ^2(x)} \, dx=\frac {x^{4} - 2 \, x^{3} + 20 \, \log \left (x\right )}{{\left (x^{2} - 2 \, x\right )} \log \left (x\right )} \]

[In]

integrate(((-40*x+40)*log(x)^2+(2*x^5-8*x^4+8*x^3)*log(x)-x^5+4*x^4-4*x^3)/(x^4-4*x^3+4*x^2)/log(x)^2,x, algor
ithm="fricas")

[Out]

(x^4 - 2*x^3 + 20*log(x))/((x^2 - 2*x)*log(x))

Sympy [A] (verification not implemented)

Time = 0.08 (sec) , antiderivative size = 14, normalized size of antiderivative = 0.54 \[ \int \frac {-4 x^3+4 x^4-x^5+\left (8 x^3-8 x^4+2 x^5\right ) \log (x)+(40-40 x) \log ^2(x)}{\left (4 x^2-4 x^3+x^4\right ) \log ^2(x)} \, dx=\frac {x^{2}}{\log {\left (x \right )}} + \frac {20}{x^{2} - 2 x} \]

[In]

integrate(((-40*x+40)*ln(x)**2+(2*x**5-8*x**4+8*x**3)*ln(x)-x**5+4*x**4-4*x**3)/(x**4-4*x**3+4*x**2)/ln(x)**2,
x)

[Out]

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

Maxima [A] (verification not implemented)

none

Time = 0.21 (sec) , antiderivative size = 27, normalized size of antiderivative = 1.04 \[ \int \frac {-4 x^3+4 x^4-x^5+\left (8 x^3-8 x^4+2 x^5\right ) \log (x)+(40-40 x) \log ^2(x)}{\left (4 x^2-4 x^3+x^4\right ) \log ^2(x)} \, dx=\frac {x^{4} - 2 \, x^{3} + 20 \, \log \left (x\right )}{{\left (x^{2} - 2 \, x\right )} \log \left (x\right )} \]

[In]

integrate(((-40*x+40)*log(x)^2+(2*x^5-8*x^4+8*x^3)*log(x)-x^5+4*x^4-4*x^3)/(x^4-4*x^3+4*x^2)/log(x)^2,x, algor
ithm="maxima")

[Out]

(x^4 - 2*x^3 + 20*log(x))/((x^2 - 2*x)*log(x))

Giac [A] (verification not implemented)

none

Time = 0.29 (sec) , antiderivative size = 21, normalized size of antiderivative = 0.81 \[ \int \frac {-4 x^3+4 x^4-x^5+\left (8 x^3-8 x^4+2 x^5\right ) \log (x)+(40-40 x) \log ^2(x)}{\left (4 x^2-4 x^3+x^4\right ) \log ^2(x)} \, dx=\frac {x^{2}}{\log \left (x\right )} + \frac {10}{x - 2} - \frac {10}{x} \]

[In]

integrate(((-40*x+40)*log(x)^2+(2*x^5-8*x^4+8*x^3)*log(x)-x^5+4*x^4-4*x^3)/(x^4-4*x^3+4*x^2)/log(x)^2,x, algor
ithm="giac")

[Out]

x^2/log(x) + 10/(x - 2) - 10/x

Mupad [B] (verification not implemented)

Time = 11.86 (sec) , antiderivative size = 19, normalized size of antiderivative = 0.73 \[ \int \frac {-4 x^3+4 x^4-x^5+\left (8 x^3-8 x^4+2 x^5\right ) \log (x)+(40-40 x) \log ^2(x)}{\left (4 x^2-4 x^3+x^4\right ) \log ^2(x)} \, dx=\frac {20}{x\,\left (x-2\right )}+\frac {x^2}{\ln \left (x\right )} \]

[In]

int(-(4*x^3 - log(x)*(8*x^3 - 8*x^4 + 2*x^5) - 4*x^4 + x^5 + log(x)^2*(40*x - 40))/(log(x)^2*(4*x^2 - 4*x^3 +
x^4)),x)

[Out]

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