\(\int \frac {-5-x^2+(5+3 x^2) \log (x)+e^7 (1-2 x) \log ^2(x)}{e^7 \log ^2(x)} \, dx\) [9643]

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

Optimal result

Integrand size = 38, antiderivative size = 22 \[ \int \frac {-5-x^2+\left (5+3 x^2\right ) \log (x)+e^7 (1-2 x) \log ^2(x)}{e^7 \log ^2(x)} \, dx=5+x-x^2+\frac {x \left (5+x^2\right )}{e^7 \log (x)} \]

[Out]

5+x-x^2+(x^2+5)/ln(x)*x/exp(7)

Rubi [A] (verified)

Time = 0.11 (sec) , antiderivative size = 33, normalized size of antiderivative = 1.50, number of steps used = 15, number of rules used = 8, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.211, Rules used = {12, 6874, 2367, 2334, 2335, 2343, 2346, 2209} \[ \int \frac {-5-x^2+\left (5+3 x^2\right ) \log (x)+e^7 (1-2 x) \log ^2(x)}{e^7 \log ^2(x)} \, dx=\frac {x^3}{e^7 \log (x)}-\frac {1}{4} (1-2 x)^2+\frac {5 x}{e^7 \log (x)} \]

[In]

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

[Out]

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

Rule 12

Int[(a_)*(u_), x_Symbol] :> Dist[a, Int[u, x], x] /; FreeQ[a, x] &&  !MatchQ[u, (b_)*(v_) /; FreeQ[b, 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 2367

Int[((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))^(p_.)*((d_) + (e_.)*(x_)^(r_.))^(q_.), x_Symbol] :> With[{u = Expand
Integrand[(a + b*Log[c*x^n])^p, (d + e*x^r)^q, x]}, Int[u, x] /; SumQ[u]] /; FreeQ[{a, b, c, d, e, n, p, q, r}
, x] && IntegerQ[q] && (GtQ[q, 0] || (IGtQ[p, 0] && IntegerQ[r]))

Rule 6874

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

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

Mathematica [A] (verified)

Time = 0.11 (sec) , antiderivative size = 24, normalized size of antiderivative = 1.09 \[ \int \frac {-5-x^2+\left (5+3 x^2\right ) \log (x)+e^7 (1-2 x) \log ^2(x)}{e^7 \log ^2(x)} \, dx=\frac {x \left (5+x^2-e^7 (-1+x) \log (x)\right )}{e^7 \log (x)} \]

[In]

Integrate[(-5 - x^2 + (5 + 3*x^2)*Log[x] + E^7*(1 - 2*x)*Log[x]^2)/(E^7*Log[x]^2),x]

[Out]

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

Maple [A] (verified)

Time = 0.22 (sec) , antiderivative size = 21, normalized size of antiderivative = 0.95

method result size
risch \(-x \left (-1+x \right )+\frac {\left (x^{2}+5\right ) x \,{\mathrm e}^{-7}}{\ln \left (x \right )}\) \(21\)
parallelrisch \(\frac {{\mathrm e}^{-7} \left (-{\mathrm e}^{7} x^{2} \ln \left (x \right )+{\mathrm e}^{7} x \ln \left (x \right )+x^{3}+5 x \right )}{\ln \left (x \right )}\) \(32\)
default \({\mathrm e}^{-7} \left (-x^{2} {\mathrm e}^{7}+x \,{\mathrm e}^{7}+\frac {x^{3}}{\ln \left (x \right )}+\frac {5 x}{\ln \left (x \right )}\right )\) \(33\)
norman \(\frac {x \ln \left (x \right )+{\mathrm e}^{-7} x^{3}-x^{2} \ln \left (x \right )+5 \,{\mathrm e}^{-7} x}{\ln \left (x \right )}\) \(33\)
parts \(x +{\mathrm e}^{-7} \left (-3 \,\operatorname {Ei}_{1}\left (-3 \ln \left (x \right )\right )-5 \,\operatorname {Ei}_{1}\left (-\ln \left (x \right )\right )\right )-x^{2}-{\mathrm e}^{-7} \left (-\frac {x^{3}}{\ln \left (x \right )}-3 \,\operatorname {Ei}_{1}\left (-3 \ln \left (x \right )\right )-\frac {5 x}{\ln \left (x \right )}-5 \,\operatorname {Ei}_{1}\left (-\ln \left (x \right )\right )\right )\) \(69\)

[In]

int(((1-2*x)*exp(7)*ln(x)^2+(3*x^2+5)*ln(x)-x^2-5)/exp(7)/ln(x)^2,x,method=_RETURNVERBOSE)

[Out]

-x*(-1+x)+(x^2+5)/ln(x)*x*exp(-7)

Fricas [A] (verification not implemented)

none

Time = 0.25 (sec) , antiderivative size = 27, normalized size of antiderivative = 1.23 \[ \int \frac {-5-x^2+\left (5+3 x^2\right ) \log (x)+e^7 (1-2 x) \log ^2(x)}{e^7 \log ^2(x)} \, dx=\frac {{\left (x^{3} - {\left (x^{2} - x\right )} e^{7} \log \left (x\right ) + 5 \, x\right )} e^{\left (-7\right )}}{\log \left (x\right )} \]

[In]

integrate(((1-2*x)*exp(7)*log(x)^2+(3*x^2+5)*log(x)-x^2-5)/exp(7)/log(x)^2,x, algorithm="fricas")

[Out]

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

Sympy [A] (verification not implemented)

Time = 0.04 (sec) , antiderivative size = 17, normalized size of antiderivative = 0.77 \[ \int \frac {-5-x^2+\left (5+3 x^2\right ) \log (x)+e^7 (1-2 x) \log ^2(x)}{e^7 \log ^2(x)} \, dx=- x^{2} + x + \frac {x^{3} + 5 x}{e^{7} \log {\left (x \right )}} \]

[In]

integrate(((1-2*x)*exp(7)*ln(x)**2+(3*x**2+5)*ln(x)-x**2-5)/exp(7)/ln(x)**2,x)

[Out]

-x**2 + x + (x**3 + 5*x)*exp(-7)/log(x)

Maxima [C] (verification not implemented)

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

Time = 0.25 (sec) , antiderivative size = 44, normalized size of antiderivative = 2.00 \[ \int \frac {-5-x^2+\left (5+3 x^2\right ) \log (x)+e^7 (1-2 x) \log ^2(x)}{e^7 \log ^2(x)} \, dx=-{\left (x^{2} e^{7} - x e^{7} - 3 \, {\rm Ei}\left (3 \, \log \left (x\right )\right ) - 5 \, {\rm Ei}\left (\log \left (x\right )\right ) + 5 \, \Gamma \left (-1, -\log \left (x\right )\right ) + 3 \, \Gamma \left (-1, -3 \, \log \left (x\right )\right )\right )} e^{\left (-7\right )} \]

[In]

integrate(((1-2*x)*exp(7)*log(x)^2+(3*x^2+5)*log(x)-x^2-5)/exp(7)/log(x)^2,x, algorithm="maxima")

[Out]

-(x^2*e^7 - x*e^7 - 3*Ei(3*log(x)) - 5*Ei(log(x)) + 5*gamma(-1, -log(x)) + 3*gamma(-1, -3*log(x)))*e^(-7)

Giac [A] (verification not implemented)

none

Time = 0.28 (sec) , antiderivative size = 32, normalized size of antiderivative = 1.45 \[ \int \frac {-5-x^2+\left (5+3 x^2\right ) \log (x)+e^7 (1-2 x) \log ^2(x)}{e^7 \log ^2(x)} \, dx=-{\left (x^{2} e^{7} - x e^{7} - \frac {x^{3}}{\log \left (x\right )} - \frac {5 \, x}{\log \left (x\right )}\right )} e^{\left (-7\right )} \]

[In]

integrate(((1-2*x)*exp(7)*log(x)^2+(3*x^2+5)*log(x)-x^2-5)/exp(7)/log(x)^2,x, algorithm="giac")

[Out]

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

Mupad [B] (verification not implemented)

Time = 13.39 (sec) , antiderivative size = 26, normalized size of antiderivative = 1.18 \[ \int \frac {-5-x^2+\left (5+3 x^2\right ) \log (x)+e^7 (1-2 x) \log ^2(x)}{e^7 \log ^2(x)} \, dx=x\,{\mathrm {e}}^{-7}\,\left ({\mathrm {e}}^7-x\,{\mathrm {e}}^7\right )+\frac {x\,{\mathrm {e}}^{-7}\,\left (x^2+5\right )}{\ln \left (x\right )} \]

[In]

int(-(exp(-7)*(x^2 - log(x)*(3*x^2 + 5) + exp(7)*log(x)^2*(2*x - 1) + 5))/log(x)^2,x)

[Out]

x*exp(-7)*(exp(7) - x*exp(7)) + (x*exp(-7)*(x^2 + 5))/log(x)