\(\int \frac {14+25 e^{-5+e^5-x} (-2-x)}{x^3} \, dx\) [4974]

   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 [B] (verification not implemented)
   Mupad [B] (verification not implemented)

Optimal result

Integrand size = 23, antiderivative size = 27 \[ \int \frac {14+25 e^{-5+e^5-x} (-2-x)}{x^3} \, dx=5-\frac {7-25 e^{-5+e^5-x}}{x^2}-\log ^2(3) \]

[Out]

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

Rubi [A] (verified)

Time = 0.03 (sec) , antiderivative size = 21, normalized size of antiderivative = 0.78, number of steps used = 3, number of rules used = 2, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.087, Rules used = {14, 2228} \[ \int \frac {14+25 e^{-5+e^5-x} (-2-x)}{x^3} \, dx=\frac {25 e^{-x+e^5-5}}{x^2}-\frac {7}{x^2} \]

[In]

Int[(14 + 25*E^(-5 + E^5 - x)*(-2 - x))/x^3,x]

[Out]

-7/x^2 + (25*E^(-5 + E^5 - x))/x^2

Rule 14

Int[(u_)*((c_.)*(x_))^(m_.), x_Symbol] :> Int[ExpandIntegrand[(c*x)^m*u, x], x] /; FreeQ[{c, m}, x] && SumQ[u]
 &&  !LinearQ[u, x] &&  !MatchQ[u, (a_) + (b_.)*(v_) /; FreeQ[{a, b}, x] && InverseFunctionQ[v]]

Rule 2228

Int[(F_)^((c_.)*(v_))*(u_)^(m_.)*(w_), x_Symbol] :> With[{b = Coefficient[v, x, 1], d = Coefficient[u, x, 0],
e = Coefficient[u, x, 1], f = Coefficient[w, x, 0], g = Coefficient[w, x, 1]}, Simp[g*u^(m + 1)*(F^(c*v)/(b*c*
e*Log[F])), x] /; EqQ[e*g*(m + 1) - b*c*(e*f - d*g)*Log[F], 0]] /; FreeQ[{F, c, m}, x] && LinearQ[{u, v, w}, x
]

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

Mathematica [A] (verified)

Time = 0.28 (sec) , antiderivative size = 18, normalized size of antiderivative = 0.67 \[ \int \frac {14+25 e^{-5+e^5-x} (-2-x)}{x^3} \, dx=\frac {-7+25 e^{-5+e^5-x}}{x^2} \]

[In]

Integrate[(14 + 25*E^(-5 + E^5 - x)*(-2 - x))/x^3,x]

[Out]

(-7 + 25*E^(-5 + E^5 - x))/x^2

Maple [A] (verified)

Time = 0.14 (sec) , antiderivative size = 19, normalized size of antiderivative = 0.70

method result size
norman \(\frac {-7+{\mathrm e}^{2 \ln \left (5\right )+{\mathrm e}^{5}-x -5}}{x^{2}}\) \(19\)
parallelrisch \(\frac {-7+{\mathrm e}^{2 \ln \left (5\right )+{\mathrm e}^{5}-x -5}}{x^{2}}\) \(19\)
risch \(-\frac {7}{x^{2}}+\frac {25 \,{\mathrm e}^{{\mathrm e}^{5}-x -5}}{x^{2}}\) \(20\)
parts \(-\frac {7}{x^{2}}+\frac {{\mathrm e}^{2 \ln \left (5\right )+{\mathrm e}^{5}-x -5}}{x^{2}}\) \(23\)
derivativedivides \(\frac {5 \,{\mathrm e}^{2 \ln \left (5\right )+{\mathrm e}^{5}-x -5}}{2 x}-\frac {5 \,{\mathrm e}^{2 \ln \left (5\right )+{\mathrm e}^{5}-5} \operatorname {Ei}_{1}\left (x \right )}{2}-\left (5-2 \ln \left (5\right )-{\mathrm e}^{5}\right ) \left (-\frac {{\mathrm e}^{2 \ln \left (5\right )+{\mathrm e}^{5}-x -5}}{2 x^{2}}+\frac {{\mathrm e}^{2 \ln \left (5\right )+{\mathrm e}^{5}-x -5}}{2 x}-\frac {{\mathrm e}^{2 \ln \left (5\right )+{\mathrm e}^{5}-5} \operatorname {Ei}_{1}\left (x \right )}{2}\right )-\frac {7}{x^{2}}-\frac {3 \,{\mathrm e}^{2 \ln \left (5\right )+{\mathrm e}^{5}-x -5}}{2 x^{2}}+{\mathrm e}^{5} \left (\frac {{\mathrm e}^{2 \ln \left (5\right )+{\mathrm e}^{5}-x -5}}{2 x^{2}}-\frac {{\mathrm e}^{2 \ln \left (5\right )+{\mathrm e}^{5}-x -5}}{2 x}+\frac {{\mathrm e}^{2 \ln \left (5\right )+{\mathrm e}^{5}-5} \operatorname {Ei}_{1}\left (x \right )}{2}\right )+2 \ln \left (5\right ) \left (\frac {{\mathrm e}^{2 \ln \left (5\right )+{\mathrm e}^{5}-x -5}}{2 x^{2}}-\frac {{\mathrm e}^{2 \ln \left (5\right )+{\mathrm e}^{5}-x -5}}{2 x}+\frac {{\mathrm e}^{2 \ln \left (5\right )+{\mathrm e}^{5}-5} \operatorname {Ei}_{1}\left (x \right )}{2}\right )\) \(221\)
default \(\frac {5 \,{\mathrm e}^{2 \ln \left (5\right )+{\mathrm e}^{5}-x -5}}{2 x}-\frac {5 \,{\mathrm e}^{2 \ln \left (5\right )+{\mathrm e}^{5}-5} \operatorname {Ei}_{1}\left (x \right )}{2}-\left (5-2 \ln \left (5\right )-{\mathrm e}^{5}\right ) \left (-\frac {{\mathrm e}^{2 \ln \left (5\right )+{\mathrm e}^{5}-x -5}}{2 x^{2}}+\frac {{\mathrm e}^{2 \ln \left (5\right )+{\mathrm e}^{5}-x -5}}{2 x}-\frac {{\mathrm e}^{2 \ln \left (5\right )+{\mathrm e}^{5}-5} \operatorname {Ei}_{1}\left (x \right )}{2}\right )-\frac {7}{x^{2}}-\frac {3 \,{\mathrm e}^{2 \ln \left (5\right )+{\mathrm e}^{5}-x -5}}{2 x^{2}}+{\mathrm e}^{5} \left (\frac {{\mathrm e}^{2 \ln \left (5\right )+{\mathrm e}^{5}-x -5}}{2 x^{2}}-\frac {{\mathrm e}^{2 \ln \left (5\right )+{\mathrm e}^{5}-x -5}}{2 x}+\frac {{\mathrm e}^{2 \ln \left (5\right )+{\mathrm e}^{5}-5} \operatorname {Ei}_{1}\left (x \right )}{2}\right )+2 \ln \left (5\right ) \left (\frac {{\mathrm e}^{2 \ln \left (5\right )+{\mathrm e}^{5}-x -5}}{2 x^{2}}-\frac {{\mathrm e}^{2 \ln \left (5\right )+{\mathrm e}^{5}-x -5}}{2 x}+\frac {{\mathrm e}^{2 \ln \left (5\right )+{\mathrm e}^{5}-5} \operatorname {Ei}_{1}\left (x \right )}{2}\right )\) \(221\)

[In]

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

[Out]

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

Fricas [A] (verification not implemented)

none

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

[In]

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

[Out]

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

Sympy [A] (verification not implemented)

Time = 0.06 (sec) , antiderivative size = 17, normalized size of antiderivative = 0.63 \[ \int \frac {14+25 e^{-5+e^5-x} (-2-x)}{x^3} \, dx=\frac {25 e^{- x - 5 + e^{5}}}{x^{2}} - \frac {7}{x^{2}} \]

[In]

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

[Out]

25*exp(-x - 5 + exp(5))/x**2 - 7/x**2

Maxima [C] (verification not implemented)

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

Time = 0.31 (sec) , antiderivative size = 26, normalized size of antiderivative = 0.96 \[ \int \frac {14+25 e^{-5+e^5-x} (-2-x)}{x^3} \, dx=25 \, e^{\left (e^{5} - 5\right )} \Gamma \left (-1, x\right ) + 50 \, e^{\left (e^{5} - 5\right )} \Gamma \left (-2, x\right ) - \frac {7}{x^{2}} \]

[In]

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

[Out]

25*e^(e^5 - 5)*gamma(-1, x) + 50*e^(e^5 - 5)*gamma(-2, x) - 7/x^2

Giac [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 79 vs. \(2 (26) = 52\).

Time = 0.29 (sec) , antiderivative size = 79, normalized size of antiderivative = 2.93 \[ \int \frac {14+25 e^{-5+e^5-x} (-2-x)}{x^3} \, dx=\frac {e^{\left (-x + e^{5} + 2 \, \log \left (5\right ) - 5\right )} - 7}{{\left (x - e^{5} - 2 \, \log \left (5\right ) + 5\right )}^{2} + 2 \, {\left (x - e^{5} - 2 \, \log \left (5\right ) + 5\right )} e^{5} + 4 \, {\left (x - e^{5} - 2 \, \log \left (5\right ) + 5\right )} \log \left (5\right ) + 4 \, e^{5} \log \left (5\right ) + 4 \, \log \left (5\right )^{2} - 10 \, x + e^{10} - 25} \]

[In]

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

[Out]

(e^(-x + e^5 + 2*log(5) - 5) - 7)/((x - e^5 - 2*log(5) + 5)^2 + 2*(x - e^5 - 2*log(5) + 5)*e^5 + 4*(x - e^5 -
2*log(5) + 5)*log(5) + 4*e^5*log(5) + 4*log(5)^2 - 10*x + e^10 - 25)

Mupad [B] (verification not implemented)

Time = 0.10 (sec) , antiderivative size = 20, normalized size of antiderivative = 0.74 \[ \int \frac {14+25 e^{-5+e^5-x} (-2-x)}{x^3} \, dx=\frac {25\,{\mathrm {e}}^{-x}\,{\mathrm {e}}^{-5}\,{\mathrm {e}}^{{\mathrm {e}}^5}}{x^2}-\frac {7}{x^2} \]

[In]

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

[Out]

(25*exp(-x)*exp(-5)*exp(exp(5)))/x^2 - 7/x^2