\(\int \frac {-36963+11655 x+219 x^2+x^3+(36963-23310 x-657 x^2-4 x^3) \log (x)}{\log ^2(x)} \, dx\) [9812]

   Optimal result
   Rubi [B] (verified)
   Mathematica [A] (verified)
   Maple [A] (verified)
   Fricas [A] (verification not implemented)
   Sympy [A] (verification not implemented)
   Maxima [C] (verification not implemented)
   Giac [B] (verification not implemented)
   Mupad [B] (verification not implemented)

Optimal result

Integrand size = 36, antiderivative size = 16 \[ \int \frac {-36963+11655 x+219 x^2+x^3+\left (36963-23310 x-657 x^2-4 x^3\right ) \log (x)}{\log ^2(x)} \, dx=\frac {(3-x) x (111+x)^2}{\log (x)} \]

[Out]

(111+x)^2*x/ln(x)*(-x+3)

Rubi [B] (verified)

Leaf count is larger than twice the leaf count of optimal. \(35\) vs. \(2(16)=32\).

Time = 0.22 (sec) , antiderivative size = 35, normalized size of antiderivative = 2.19, number of steps used = 25, number of rules used = 8, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.222, Rules used = {6873, 6874, 2403, 2334, 2335, 2343, 2346, 2209} \[ \int \frac {-36963+11655 x+219 x^2+x^3+\left (36963-23310 x-657 x^2-4 x^3\right ) \log (x)}{\log ^2(x)} \, dx=-\frac {x^4}{\log (x)}-\frac {219 x^3}{\log (x)}-\frac {11655 x^2}{\log (x)}+\frac {36963 x}{\log (x)} \]

[In]

Int[(-36963 + 11655*x + 219*x^2 + x^3 + (36963 - 23310*x - 657*x^2 - 4*x^3)*Log[x])/Log[x]^2,x]

[Out]

(36963*x)/Log[x] - (11655*x^2)/Log[x] - (219*x^3)/Log[x] - x^4/Log[x]

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 2334

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

Rule 2335

Int[Log[(c_.)*(x_)]^(-1), x_Symbol] :> Simp[LogIntegral[c*x]/c, x] /; FreeQ[c, x]

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 2403

Int[((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))^(p_.)*(Polyx_), x_Symbol] :> Int[ExpandIntegrand[Polyx*(a + b*Log[c*
x^n])^p, x], x] /; FreeQ[{a, b, c, n, p}, x] && PolynomialQ[Polyx, x]

Rule 6873

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

Rule 6874

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

Rubi steps \begin{align*} \text {integral}& = \int \frac {(111+x) \left (-333+108 x+x^2+333 \log (x)-213 x \log (x)-4 x^2 \log (x)\right )}{\log ^2(x)} \, dx \\ & = \int \left (\frac {(-3+x) (111+x)^2}{\log ^2(x)}+\frac {36963-23310 x-657 x^2-4 x^3}{\log (x)}\right ) \, dx \\ & = \int \frac {(-3+x) (111+x)^2}{\log ^2(x)} \, dx+\int \frac {36963-23310 x-657 x^2-4 x^3}{\log (x)} \, dx \\ & = \int \left (-\frac {36963}{\log ^2(x)}+\frac {11655 x}{\log ^2(x)}+\frac {219 x^2}{\log ^2(x)}+\frac {x^3}{\log ^2(x)}\right ) \, dx+\int \left (\frac {36963}{\log (x)}-\frac {23310 x}{\log (x)}-\frac {657 x^2}{\log (x)}-\frac {4 x^3}{\log (x)}\right ) \, dx \\ & = -\left (4 \int \frac {x^3}{\log (x)} \, dx\right )+219 \int \frac {x^2}{\log ^2(x)} \, dx-657 \int \frac {x^2}{\log (x)} \, dx+11655 \int \frac {x}{\log ^2(x)} \, dx-23310 \int \frac {x}{\log (x)} \, dx-36963 \int \frac {1}{\log ^2(x)} \, dx+36963 \int \frac {1}{\log (x)} \, dx+\int \frac {x^3}{\log ^2(x)} \, dx \\ & = \frac {36963 x}{\log (x)}-\frac {11655 x^2}{\log (x)}-\frac {219 x^3}{\log (x)}-\frac {x^4}{\log (x)}+36963 \operatorname {LogIntegral}(x)+4 \int \frac {x^3}{\log (x)} \, dx-4 \text {Subst}\left (\int \frac {e^{4 x}}{x} \, dx,x,\log (x)\right )+657 \int \frac {x^2}{\log (x)} \, dx-657 \text {Subst}\left (\int \frac {e^{3 x}}{x} \, dx,x,\log (x)\right )+23310 \int \frac {x}{\log (x)} \, dx-23310 \text {Subst}\left (\int \frac {e^{2 x}}{x} \, dx,x,\log (x)\right )-36963 \int \frac {1}{\log (x)} \, dx \\ & = -23310 \operatorname {ExpIntegralEi}(2 \log (x))-657 \operatorname {ExpIntegralEi}(3 \log (x))-4 \operatorname {ExpIntegralEi}(4 \log (x))+\frac {36963 x}{\log (x)}-\frac {11655 x^2}{\log (x)}-\frac {219 x^3}{\log (x)}-\frac {x^4}{\log (x)}+4 \text {Subst}\left (\int \frac {e^{4 x}}{x} \, dx,x,\log (x)\right )+657 \text {Subst}\left (\int \frac {e^{3 x}}{x} \, dx,x,\log (x)\right )+23310 \text {Subst}\left (\int \frac {e^{2 x}}{x} \, dx,x,\log (x)\right ) \\ & = \frac {36963 x}{\log (x)}-\frac {11655 x^2}{\log (x)}-\frac {219 x^3}{\log (x)}-\frac {x^4}{\log (x)} \\ \end{align*}

Mathematica [A] (verified)

Time = 0.13 (sec) , antiderivative size = 15, normalized size of antiderivative = 0.94 \[ \int \frac {-36963+11655 x+219 x^2+x^3+\left (36963-23310 x-657 x^2-4 x^3\right ) \log (x)}{\log ^2(x)} \, dx=-\frac {(-3+x) x (111+x)^2}{\log (x)} \]

[In]

Integrate[(-36963 + 11655*x + 219*x^2 + x^3 + (36963 - 23310*x - 657*x^2 - 4*x^3)*Log[x])/Log[x]^2,x]

[Out]

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

Maple [A] (verified)

Time = 0.11 (sec) , antiderivative size = 21, normalized size of antiderivative = 1.31

method result size
risch \(-\frac {x \left (x^{3}+219 x^{2}+11655 x -36963\right )}{\ln \left (x \right )}\) \(21\)
norman \(\frac {-x^{4}-219 x^{3}-11655 x^{2}+36963 x}{\ln \left (x \right )}\) \(25\)
parallelrisch \(\frac {-x^{4}-219 x^{3}-11655 x^{2}+36963 x}{\ln \left (x \right )}\) \(25\)
default \(-\frac {x^{4}}{\ln \left (x \right )}-\frac {219 x^{3}}{\ln \left (x \right )}-\frac {11655 x^{2}}{\ln \left (x \right )}+\frac {36963 x}{\ln \left (x \right )}\) \(36\)
parts \(-\frac {x^{4}}{\ln \left (x \right )}-\frac {219 x^{3}}{\ln \left (x \right )}-\frac {11655 x^{2}}{\ln \left (x \right )}+\frac {36963 x}{\ln \left (x \right )}\) \(36\)

[In]

int(((-4*x^3-657*x^2-23310*x+36963)*ln(x)+x^3+219*x^2+11655*x-36963)/ln(x)^2,x,method=_RETURNVERBOSE)

[Out]

-x*(x^3+219*x^2+11655*x-36963)/ln(x)

Fricas [A] (verification not implemented)

none

Time = 0.25 (sec) , antiderivative size = 23, normalized size of antiderivative = 1.44 \[ \int \frac {-36963+11655 x+219 x^2+x^3+\left (36963-23310 x-657 x^2-4 x^3\right ) \log (x)}{\log ^2(x)} \, dx=-\frac {x^{4} + 219 \, x^{3} + 11655 \, x^{2} - 36963 \, x}{\log \left (x\right )} \]

[In]

integrate(((-4*x^3-657*x^2-23310*x+36963)*log(x)+x^3+219*x^2+11655*x-36963)/log(x)^2,x, algorithm="fricas")

[Out]

-(x^4 + 219*x^3 + 11655*x^2 - 36963*x)/log(x)

Sympy [A] (verification not implemented)

Time = 0.04 (sec) , antiderivative size = 19, normalized size of antiderivative = 1.19 \[ \int \frac {-36963+11655 x+219 x^2+x^3+\left (36963-23310 x-657 x^2-4 x^3\right ) \log (x)}{\log ^2(x)} \, dx=\frac {- x^{4} - 219 x^{3} - 11655 x^{2} + 36963 x}{\log {\left (x \right )}} \]

[In]

integrate(((-4*x**3-657*x**2-23310*x+36963)*ln(x)+x**3+219*x**2+11655*x-36963)/ln(x)**2,x)

[Out]

(-x**4 - 219*x**3 - 11655*x**2 + 36963*x)/log(x)

Maxima [C] (verification not implemented)

Result contains higher order function than in optimal. Order 4 vs. order 3.

Time = 0.23 (sec) , antiderivative size = 59, normalized size of antiderivative = 3.69 \[ \int \frac {-36963+11655 x+219 x^2+x^3+\left (36963-23310 x-657 x^2-4 x^3\right ) \log (x)}{\log ^2(x)} \, dx=-4 \, {\rm Ei}\left (4 \, \log \left (x\right )\right ) - 657 \, {\rm Ei}\left (3 \, \log \left (x\right )\right ) - 23310 \, {\rm Ei}\left (2 \, \log \left (x\right )\right ) + 36963 \, {\rm Ei}\left (\log \left (x\right )\right ) - 36963 \, \Gamma \left (-1, -\log \left (x\right )\right ) + 23310 \, \Gamma \left (-1, -2 \, \log \left (x\right )\right ) + 657 \, \Gamma \left (-1, -3 \, \log \left (x\right )\right ) + 4 \, \Gamma \left (-1, -4 \, \log \left (x\right )\right ) \]

[In]

integrate(((-4*x^3-657*x^2-23310*x+36963)*log(x)+x^3+219*x^2+11655*x-36963)/log(x)^2,x, algorithm="maxima")

[Out]

-4*Ei(4*log(x)) - 657*Ei(3*log(x)) - 23310*Ei(2*log(x)) + 36963*Ei(log(x)) - 36963*gamma(-1, -log(x)) + 23310*
gamma(-1, -2*log(x)) + 657*gamma(-1, -3*log(x)) + 4*gamma(-1, -4*log(x))

Giac [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 35 vs. \(2 (15) = 30\).

Time = 0.27 (sec) , antiderivative size = 35, normalized size of antiderivative = 2.19 \[ \int \frac {-36963+11655 x+219 x^2+x^3+\left (36963-23310 x-657 x^2-4 x^3\right ) \log (x)}{\log ^2(x)} \, dx=-\frac {x^{4}}{\log \left (x\right )} - \frac {219 \, x^{3}}{\log \left (x\right )} - \frac {11655 \, x^{2}}{\log \left (x\right )} + \frac {36963 \, x}{\log \left (x\right )} \]

[In]

integrate(((-4*x^3-657*x^2-23310*x+36963)*log(x)+x^3+219*x^2+11655*x-36963)/log(x)^2,x, algorithm="giac")

[Out]

-x^4/log(x) - 219*x^3/log(x) - 11655*x^2/log(x) + 36963*x/log(x)

Mupad [B] (verification not implemented)

Time = 15.21 (sec) , antiderivative size = 15, normalized size of antiderivative = 0.94 \[ \int \frac {-36963+11655 x+219 x^2+x^3+\left (36963-23310 x-657 x^2-4 x^3\right ) \log (x)}{\log ^2(x)} \, dx=-\frac {x\,\left (x-3\right )\,{\left (x+111\right )}^2}{\ln \left (x\right )} \]

[In]

int((11655*x + 219*x^2 + x^3 - log(x)*(23310*x + 657*x^2 + 4*x^3 - 36963) - 36963)/log(x)^2,x)

[Out]

-(x*(x - 3)*(x + 111)^2)/log(x)