\(\int \frac {3-e^x-x}{1+e^x-x} \, dx\) [9276]

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

Optimal result

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

[Out]

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

Rubi [F]

\[ \int \frac {3-e^x-x}{1+e^x-x} \, dx=\int \frac {3-e^x-x}{1+e^x-x} \, dx \]

[In]

Int[(3 - E^x - x)/(1 + E^x - x),x]

[Out]

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

Rubi steps \begin{align*} \text {integral}& = \int \left (-1+\frac {2 (-2+x)}{-1-e^x+x}\right ) \, dx \\ & = -x+2 \int \frac {-2+x}{-1-e^x+x} \, dx \\ & = -x+2 \int \left (\frac {2}{1+e^x-x}+\frac {x}{-1-e^x+x}\right ) \, dx \\ & = -x+2 \int \frac {x}{-1-e^x+x} \, dx+4 \int \frac {1}{1+e^x-x} \, dx \\ \end{align*}

Mathematica [A] (verified)

Time = 0.14 (sec) , antiderivative size = 13, normalized size of antiderivative = 0.81 \[ \int \frac {3-e^x-x}{1+e^x-x} \, dx=x-2 \log \left (1+e^x-x\right ) \]

[In]

Integrate[(3 - E^x - x)/(1 + E^x - x),x]

[Out]

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

Maple [A] (verified)

Time = 0.06 (sec) , antiderivative size = 13, normalized size of antiderivative = 0.81

method result size
norman \(x -2 \ln \left (x -{\mathrm e}^{x}-1\right )\) \(13\)
risch \(x -2 \ln \left (1+{\mathrm e}^{x}-x \right )\) \(13\)
parallelrisch \(x -2 \ln \left (x -{\mathrm e}^{x}-1\right )\) \(13\)

[In]

int((3-x-exp(x))/(1+exp(x)-x),x,method=_RETURNVERBOSE)

[Out]

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

Fricas [A] (verification not implemented)

none

Time = 0.27 (sec) , antiderivative size = 12, normalized size of antiderivative = 0.75 \[ \int \frac {3-e^x-x}{1+e^x-x} \, dx=x - 2 \, \log \left (-x + e^{x} + 1\right ) \]

[In]

integrate((3-x-exp(x))/(1+exp(x)-x),x, algorithm="fricas")

[Out]

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

Sympy [A] (verification not implemented)

Time = 0.05 (sec) , antiderivative size = 10, normalized size of antiderivative = 0.62 \[ \int \frac {3-e^x-x}{1+e^x-x} \, dx=x - 2 \log {\left (- x + e^{x} + 1 \right )} \]

[In]

integrate((3-x-exp(x))/(1+exp(x)-x),x)

[Out]

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

Maxima [A] (verification not implemented)

none

Time = 0.22 (sec) , antiderivative size = 12, normalized size of antiderivative = 0.75 \[ \int \frac {3-e^x-x}{1+e^x-x} \, dx=x - 2 \, \log \left (-x + e^{x} + 1\right ) \]

[In]

integrate((3-x-exp(x))/(1+exp(x)-x),x, algorithm="maxima")

[Out]

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

Giac [A] (verification not implemented)

none

Time = 0.27 (sec) , antiderivative size = 12, normalized size of antiderivative = 0.75 \[ \int \frac {3-e^x-x}{1+e^x-x} \, dx=x - 2 \, \log \left (x - e^{x} - 1\right ) \]

[In]

integrate((3-x-exp(x))/(1+exp(x)-x),x, algorithm="giac")

[Out]

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

Mupad [B] (verification not implemented)

Time = 0.09 (sec) , antiderivative size = 12, normalized size of antiderivative = 0.75 \[ \int \frac {3-e^x-x}{1+e^x-x} \, dx=x-2\,\ln \left (x-{\mathrm {e}}^x-1\right ) \]

[In]

int(-(x + exp(x) - 3)/(exp(x) - x + 1),x)

[Out]

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