Canadian economist Mike Moffat asks on Twitter:
Math nerd Q: Is there a way to solve $e^x + x = 5$ for $x$, without using a numerical method?
Canadian economist Mike Moffat asks on Twitter:
Math nerd Q: Is there a way to solve $e^x + x = 5$ for $x$, without using a numerical method?
On
Yes, write it as $e^x =(5-x)$, then $e^5 e^{x-5} = (5-x)$ then $e^5 =(5-x)e^{5-x}$. Denote $y=5-x$. Equation becomes $e^5 = y*e^y$ which is an implicit equation defining Lambert W function. The $ y = W(e^5)$ and $x = 5- W(e^5)$.
$W(e^5)$ is approximately $3.69$ hence $x = 1.31$, see Wolfram-Alpha
On
Write $y = 5-x$, giving
$$e^{5-y} = y$$
and hence
$$y e^y = e^5$$
This can be inverted using the Lambert W function to give
$$y = W(e^5)$$
and hence
$$x = 5 - W(e^5)$$
On
If you do not want to use Lambert function or any numerical method, you can have explicit approximations using Newton-like methods of high order $n$ starting at $x=1$.
For example $$x_{(2)}=\frac{5}{1+e}$$ $$x_{(3)}=\frac{10+14 e-e^2}{2+8 e+e^2}$$ $$x_{(4)}=\frac{60+296 e+32 e^2-4 e^3}{12+116 e+56 e^2+2 e^3}$$ $$x_{(5)}=\frac{720+8016 e+4344 e^2-120 e^3-18 e^4}{144+2592 e+3048 e^2+456 e^3+6 e^4}$$ $$x_{(6)}=\frac{14400+286464 e+381696 e^2+45504 e^3-4224 e^4-96 e^5}{2880+81984 e+189696 e^2+69984 e^3+4416 e^4+24 e^5}$$ I stop here because the formulae start to be too large for the page.
Converted to decimals, the above approximations are $$\{1.3447071,1.3061341,1.3064721,1.3065586,1.3065589\}$$
Write $y=5-x$. Then $ye^y=e^5$. Using the Lambert W function, this gives $x=5-W(e^5)$.