3.84.26 \(\int \frac {2+e^4 (-2 e^2+2 x)}{e^4 (e^2-x)} \, dx\) [8326]

Optimal. Leaf size=29 \[ 2 (5-x)-\log (4)-\frac {\log \left (2 \left (e^2-x\right )^2\right )}{e^4} \]

[Out]

-2*x+10-2*ln(2)-ln(2*(exp(2)-x)^2)/exp(4)

________________________________________________________________________________________

Rubi [A]
time = 0.01, antiderivative size = 17, normalized size of antiderivative = 0.59, number of steps used = 4, number of rules used = 3, integrand size = 28, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.107, Rules used = {12, 192, 45} \begin {gather*} -2 x-\frac {2 \log \left (e^2-x\right )}{e^4} \end {gather*}

Antiderivative was successfully verified.

[In]

Int[(2 + E^4*(-2*E^2 + 2*x))/(E^4*(E^2 - x)),x]

[Out]

-2*x - (2*Log[E^2 - x])/E^4

Rule 12

Int[(a_)*(u_), x_Symbol] :> Dist[a, Int[u, x], x] /; FreeQ[a, x] &&  !MatchQ[u, (b_)*(v_) /; FreeQ[b, x]]

Rule 45

Int[((a_.) + (b_.)*(x_))^(m_.)*((c_.) + (d_.)*(x_))^(n_.), x_Symbol] :> Int[ExpandIntegrand[(a + b*x)^m*(c + d
*x)^n, x], x] /; FreeQ[{a, b, c, d, n}, x] && NeQ[b*c - a*d, 0] && IGtQ[m, 0] && ( !IntegerQ[n] || (EqQ[c, 0]
&& LeQ[7*m + 4*n + 4, 0]) || LtQ[9*m + 5*(n + 1), 0] || GtQ[m + n + 2, 0])

Rule 192

Int[(u_)^(m_.)*(v_)^(n_.), x_Symbol] :> Int[ExpandToSum[u, x]^m*ExpandToSum[v, x]^n, x] /; FreeQ[{m, n}, x] &&
 LinearQ[{u, v}, x] &&  !LinearMatchQ[{u, v}, x]

Rubi steps

\begin {gather*} \begin {aligned} \text {integral} &=\frac {\int \frac {2+e^4 \left (-2 e^2+2 x\right )}{e^2-x} \, dx}{e^4}\\ &=\frac {\int \frac {2 \left (1-e^6\right )+2 e^4 x}{e^2-x} \, dx}{e^4}\\ &=\frac {\int \left (-2 e^4+\frac {2}{e^2-x}\right ) \, dx}{e^4}\\ &=-2 x-\frac {2 \log \left (e^2-x\right )}{e^4}\\ \end {aligned} \end {gather*}

________________________________________________________________________________________

Mathematica [A]
time = 0.01, size = 26, normalized size = 0.90 \begin {gather*} \frac {2 \left (-4+e^6-e^4 x-\log \left (e^2-x\right )\right )}{e^4} \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[(2 + E^4*(-2*E^2 + 2*x))/(E^4*(E^2 - x)),x]

[Out]

(2*(-4 + E^6 - E^4*x - Log[E^2 - x]))/E^4

________________________________________________________________________________________

Maple [A]
time = 0.89, size = 21, normalized size = 0.72

method result size
risch \(-2 x -2 \,{\mathrm e}^{-4} \ln \left (x -{\mathrm e}^{2}\right )\) \(16\)
norman \(-2 x -2 \,{\mathrm e}^{-4} \ln \left ({\mathrm e}^{2}-x \right )\) \(18\)
default \({\mathrm e}^{-4} \left (-2 x \,{\mathrm e}^{4}-2 \ln \left (x -{\mathrm e}^{2}\right )\right )\) \(21\)
meijerg \(-2 \,{\mathrm e}^{-4} \ln \left (1-x \,{\mathrm e}^{-2}\right )+2 \,{\mathrm e}^{2} \ln \left (1-x \,{\mathrm e}^{-2}\right )+2 \,{\mathrm e}^{2} \left (-x \,{\mathrm e}^{-2}-\ln \left (1-x \,{\mathrm e}^{-2}\right )\right )\) \(46\)

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(((-2*exp(2)+2*x)*exp(4)+2)/(exp(2)-x)/exp(4),x,method=_RETURNVERBOSE)

[Out]

1/exp(4)*(-2*x*exp(4)-2*ln(x-exp(2)))

________________________________________________________________________________________

Maxima [A]
time = 0.26, size = 16, normalized size = 0.55 \begin {gather*} -2 \, {\left (x e^{4} + \log \left (x - e^{2}\right )\right )} e^{\left (-4\right )} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(((-2*exp(2)+2*x)*exp(4)+2)/(exp(2)-x)/exp(4),x, algorithm="maxima")

[Out]

-2*(x*e^4 + log(x - e^2))*e^(-4)

________________________________________________________________________________________

Fricas [A]
time = 0.38, size = 16, normalized size = 0.55 \begin {gather*} -2 \, {\left (x e^{4} + \log \left (x - e^{2}\right )\right )} e^{\left (-4\right )} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(((-2*exp(2)+2*x)*exp(4)+2)/(exp(2)-x)/exp(4),x, algorithm="fricas")

[Out]

-2*(x*e^4 + log(x - e^2))*e^(-4)

________________________________________________________________________________________

Sympy [A]
time = 0.05, size = 15, normalized size = 0.52 \begin {gather*} - 2 x - \frac {2 \log {\left (x - e^{2} \right )}}{e^{4}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(((-2*exp(2)+2*x)*exp(4)+2)/(exp(2)-x)/exp(4),x)

[Out]

-2*x - 2*exp(-4)*log(x - exp(2))

________________________________________________________________________________________

Giac [A]
time = 0.41, size = 17, normalized size = 0.59 \begin {gather*} -2 \, {\left (x e^{4} + \log \left ({\left | x - e^{2} \right |}\right )\right )} e^{\left (-4\right )} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(((-2*exp(2)+2*x)*exp(4)+2)/(exp(2)-x)/exp(4),x, algorithm="giac")

[Out]

-2*(x*e^4 + log(abs(x - e^2)))*e^(-4)

________________________________________________________________________________________

Mupad [B]
time = 0.08, size = 15, normalized size = 0.52 \begin {gather*} -2\,x-2\,\ln \left (x-{\mathrm {e}}^2\right )\,{\mathrm {e}}^{-4} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(-(exp(-4)*(exp(4)*(2*x - 2*exp(2)) + 2))/(x - exp(2)),x)

[Out]

- 2*x - 2*log(x - exp(2))*exp(-4)

________________________________________________________________________________________