How do you solve the equation $e^{-x}(1+x) = m$

algebra-precalculuslogarithms

Applying $\log$ to both sides gives $-x + \log(1+x) = \log (m)$, which doesn't seem much easier to solve. I thought about expanding $\log(1+x)$ in a Taylor series but if $m$ is such that $x$ is large it's not a good approximation.

I also tried integrating both sides but I get $2 – 2e^{-x} – xe^{-x} = mx$ which I'm not sure what to do with.

What am I missing here? This looks like it should be very simple.

Best Answer

Just so the question is answered, we can, as stated above, use the Lambert W function. We first divide both sides by $-e$: $$e^{-x - 1}(-x - 1) = -\frac{m}{e}.$$ Taking the Lambert W function of both sides: $$-x - 1 = W\left(-\frac{m}{e}\right) \implies x = -W\left(-\frac{m}{e}\right) - 1.$$ It's worth pointing out that the Lambert $W$ function is defined only on $[-e^{-1}, \infty)$ and multivalued on $[-e^{-1}, 0)$. So, in order for there to be a solution, we require $m \le 1$, and in order for the solution to be unique, we require $m \le 0$.

EDIT: Actually, $W$ is also single-valued at the point $-e^{-1}$, so indeed the solution is unique at $m = 1$ too.

Related Question