3.686 \(\int \frac {e^x}{2+3 e^x+e^{2 x}} \, dx\)

Optimal. Leaf size=15 \[ \log \left (e^x+1\right )-\log \left (e^x+2\right ) \]

[Out]

ln(1+exp(x))-ln(2+exp(x))

________________________________________________________________________________________

Rubi [A]  time = 0.03, antiderivative size = 15, normalized size of antiderivative = 1.00, number of steps used = 4, number of rules used = 3, integrand size = 18, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.167, Rules used = {2282, 616, 31} \[ \log \left (e^x+1\right )-\log \left (e^x+2\right ) \]

Antiderivative was successfully verified.

[In]

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

[Out]

Log[1 + E^x] - Log[2 + E^x]

Rule 31

Int[((a_) + (b_.)*(x_))^(-1), x_Symbol] :> Simp[Log[RemoveContent[a + b*x, x]]/b, x] /; FreeQ[{a, b}, x]

Rule 616

Int[((a_.) + (b_.)*(x_) + (c_.)*(x_)^2)^(-1), x_Symbol] :> With[{q = Rt[b^2 - 4*a*c, 2]}, Dist[c/q, Int[1/Simp
[b/2 - q/2 + c*x, x], x], x] - Dist[c/q, Int[1/Simp[b/2 + q/2 + c*x, x], x], x]] /; FreeQ[{a, b, c}, x] && NeQ
[b^2 - 4*a*c, 0] && PosQ[b^2 - 4*a*c] && PerfectSquareQ[b^2 - 4*a*c]

Rule 2282

Int[u_, x_Symbol] :> With[{v = FunctionOfExponential[u, x]}, Dist[v/D[v, x], Subst[Int[FunctionOfExponentialFu
nction[u, x]/x, x], x, v], x]] /; FunctionOfExponentialQ[u, x] &&  !MatchQ[u, (w_)*((a_.)*(v_)^(n_))^(m_) /; F
reeQ[{a, m, n}, x] && IntegerQ[m*n]] &&  !MatchQ[u, E^((c_.)*((a_.) + (b_.)*x))*(F_)[v_] /; FreeQ[{a, b, c}, x
] && InverseFunctionQ[F[x]]]

Rubi steps

\begin {align*} \int \frac {e^x}{2+3 e^x+e^{2 x}} \, dx &=\operatorname {Subst}\left (\int \frac {1}{2+3 x+x^2} \, dx,x,e^x\right )\\ &=\operatorname {Subst}\left (\int \frac {1}{1+x} \, dx,x,e^x\right )-\operatorname {Subst}\left (\int \frac {1}{2+x} \, dx,x,e^x\right )\\ &=\log \left (1+e^x\right )-\log \left (2+e^x\right )\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]  time = 0.01, size = 10, normalized size = 0.67 \[ -2 \tanh ^{-1}\left (2 e^x+3\right ) \]

Antiderivative was successfully verified.

[In]

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

[Out]

-2*ArcTanh[3 + 2*E^x]

________________________________________________________________________________________

fricas [A]  time = 0.41, size = 13, normalized size = 0.87 \[ -\log \left (e^{x} + 2\right ) + \log \left (e^{x} + 1\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

-log(e^x + 2) + log(e^x + 1)

________________________________________________________________________________________

giac [A]  time = 0.21, size = 13, normalized size = 0.87 \[ -\log \left (e^{x} + 2\right ) + \log \left (e^{x} + 1\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

-log(e^x + 2) + log(e^x + 1)

________________________________________________________________________________________

maple [A]  time = 0.04, size = 14, normalized size = 0.93 \[ \ln \left ({\mathrm e}^{x}+1\right )-\ln \left ({\mathrm e}^{x}+2\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(exp(x)/(2+3*exp(x)+exp(2*x)),x)

[Out]

ln(exp(x)+1)-ln(exp(x)+2)

________________________________________________________________________________________

maxima [A]  time = 1.03, size = 13, normalized size = 0.87 \[ -\log \left (e^{x} + 2\right ) + \log \left (e^{x} + 1\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

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

[Out]

-log(e^x + 2) + log(e^x + 1)

________________________________________________________________________________________

mupad [B]  time = 3.49, size = 13, normalized size = 0.87 \[ \ln \left ({\mathrm {e}}^x+1\right )-\ln \left ({\mathrm {e}}^x+2\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(exp(x)/(exp(2*x) + 3*exp(x) + 2),x)

[Out]

log(exp(x) + 1) - log(exp(x) + 2)

________________________________________________________________________________________

sympy [A]  time = 0.12, size = 12, normalized size = 0.80 \[ \log {\left (e^{x} + 1 \right )} - \log {\left (e^{x} + 2 \right )} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(exp(x)/(2+3*exp(x)+exp(2*x)),x)

[Out]

log(exp(x) + 1) - log(exp(x) + 2)

________________________________________________________________________________________