Exponential Function – Solving Equations of the Form ae^x + bx + c = 0

exponential function

In a recent piece of homework I needed to solve an equation of the form $ae^x + bx +c = 0$ where $a,b$ and $c$ are constants. I could not do it; no matter how I tried I either went in circles or hit a brick wall. Can someone demonstrate a general method for solving equations of this form? Please show every step in your answers.

Best Answer

\begin{align} a \exp(x)+b x+c&=0 \end{align} Substitute $bx+c=y$: \begin{align} a \exp((-c+y)/b)+y &= 0 \\ -y &= a\exp(-c/b)\exp(y/b) \\ -y/b\exp(-y/b) &= a/b\exp(-c/b) \end{align} The last equation is in the form $u\exp(u)=w$, which has a solution in terms of Lambert $W$ function: \begin{align} u&=W(w). \end{align} Hence \begin{align} -y/b&=W(a/b\exp(-c/b)) \\ y&=-b W(a/b\exp(-c/b)) \\ x&=-W(a/b\exp(-c/b))-c/b. \end{align} In particular, equation $88\exp(x)+12x-5=0$ with $a=88,b=12,c=-5$ has one real root, since the argument of $W$ is positive: \begin{align} x&=-W_0(22/3\exp(5/12))+5/12 \approx-1.3970513. \end{align}

Edit:

Lambert's W function is included in the Gnu Scientific Library (GSL) and is freely available by means of many computer systems and packages (wolframalpha, R, Asymptote, python scipy.special to name a few).

Related Question