How to solve the exponential equation $e^{a+bx}+e^{c+dx}=1$?

759 Views Asked by At

$$e^{a+bx}+e^{c+dx}=1$$ The problem comes from formula (14) in this paper, which says the solution is found numerically. My questions are:

  1. Does there exist an analytical solution?
  2. How to derive the numerical solution?

PS. My post tags might be inaccurate and false, but I am sorry that I cannot figure out proper tags, someone may fix it.

EDIT I found C++ program(line 1002, function computeExpSPRT) solving the equation in paper, now rewrite the equation as $$ \exp(\log \epsilon+h\log \frac{\delta_i}{\epsilon_i})+\exp(\log (1-\epsilon)+h\log \frac{1-\delta_i}{1-\epsilon_i})=1$$ $\epsilon,\delta_i,\epsilon_i$ are known and lie in $(0,1)$ and $\epsilon \ge \epsilon_i$, now the target is to search a $h$ satisfying above equation with $h>1$. According to the program, $h$ can be numerically found as follows: $$al=\log(\frac{\delta_i}{\epsilon_i}),be=\log \frac{1-\delta_i}{1-\epsilon_i}$$ $$x_0=-\frac{1}{be}\log(1-\epsilon),v_0=\epsilon\exp (al\cdot x_0)$$ $$x_1=\frac{1}{be}\log{\frac{1-2v_0}{1-\epsilon}},v_1=\epsilon \exp(al \cdot x_1)+(1-\epsilon)\exp(be \cdot x_1)$$ $$h=\frac{1-v_1}{1+v_0-v_1}x_0+\frac{v_0}{1+v_0-v_1}x_1$$ Can anyone help me analyzing the thread?

2

There are 2 best solutions below

5
On BEST ANSWER

Considering the more specific case of $$f(x)=a\,e^{bx}+(1-a)\,e^{cx}-1$$ where $0<a<1$, we have $$f'(x)=a b\, e^{b x}+(1-a) c\, e^{c x}$$ $$f''(x)=a b^2 \,e^{b x}+(1-a) c^2\, e^{c x}\, >0 \qquad \forall x$$ The first derivative cancels at $$x_{min}=\frac{\log \left(\frac{-(1-a) c}{a b}\right)}{b-c}$$ which, in the real domain exists if $bc<0$ and this is a minimum and, since $f(0)=0$, the solution of $f(x)=0$ is away from $x_{min}$.

Since $f(x_{min}) <0$, we need to find a value $x_*$ such that $f(x_*)>0$ in order to start Newton iterations and this would be safe (no overshoot of the solution since at this point $f(x_*)\,f''(x_*)>0$ - by Draboux theorem).

To find this point, we could use a golden search that is to say define a sequence $$x_k=\phi^k \,x_{min}$$ (where $\phi$ is the golden ratio) and run it until $f(x_k)>0$. If you prefer, replace $\phi$ by any number $>1$.

For example, using $a=0.123$, $b=0.234$, $c=-0.345$, we get $x_{min}=4.06312$. So $$x_1=6.57426\implies f(x_1)=-0.336410$$ $$x_2=10.6374\implies f(x_2)=+0.504618$$ Now, Newton iterates $$\left( \begin{array}{cc} n & x_{(n)} \\ 0 & 10.63738381 \\ 1 & 9.149460984 \\ 2 & 8.788301285 \\ 3 & 8.769596643 \\ 4 & 8.769548495 \end{array} \right)$$ which is the solution for ten significant figures.

5
On

Writing th problem as $$e^{a+bx}+e^{c+dx}=1$$ is a generalization of equation $(14)$ in the linked paper in which they have $e^a+e^c=1$.

For sure, we shall assume $b\neq d$ (otherwise, the problem would be very simple).

So, let us consider that we look for the zero of function $$f(x)=e^a \, e^{bx}+e^c \, e^{dx}-1\tag 1$$ If the function does not go through any extremum, it is bounded by $$g(x)=(e^a+e^c)\,e^{bx}-1\implies x_1=-\frac{\log \left(e^a+e^c\right)}{b}\tag 2$$ $$h(x)=(e^a+e^c)\,e^{dx}-1\implies x_2=-\frac{\log \left(e^a+e^c\right)}{d}\tag 3$$ and then, the solution $x_*$ of $(1)$ is such that $$\min (x_1,x_2) < x_* <\max (x_1,x_2)$$ On the other hand $$f'(x)=b\ e^{a+b x}+d\, e^{c+d x}$$ may cancel at $$x_3=\frac{c-\log \left(-\frac{ b}{d}e^a\right)}{b-d}$$ which can only happen if $b\,d<0$.

If $x_3$ does exist, it would correspond to a minimum of the function since $$f''(x)=b^2\ e^{a+b x}+d^2\, e^{c+d x} >0$$ and, if $f(x_3)<0$, we should find $\color{red}{\text{two}}$ solutions (one being $< x_3$ and one being $> x_3$). But, if $f(x_3)>0$, $\color{red}{\text{no}}$ solution to the equation.

If $x_3$ does not exist in the real domain, then no minimum and you can start Newton method using $$x_0=\frac{x_1+x_2}2$$ to find the $\color{red}{\text{single}}$ root of the equation.

For illustration purposes, let us consider the case $a=0.123$, $b=0.234$, $c=0.345$, $d=0.456$. Since $b\,d >0$, $x_3$ does not exist and we have $x_1\approx-3.98844$ and $x_2\approx -2.04670$. So, let us start Newton method using $x_0=-3$. The iterates would then be $$\left( \begin{array}{cc} n & x_n \\ 0 & -3.000000000 \\ 1 & -2.728802219 \\ 2 & -2.741157913 \\ 3 & -2.741185518 \end{array} \right)$$ which is the solution for ten significant figures.

Using the same numbers except $b=-0.234$ we have $x_1\approx 3.98844$, $x_2\approx -2.04670$ and $x_3 \approx -1.28865$ but $f(x_3) \approx 1.31346$; then no root.

Finally, consider the case $a=-0.789$, $b=-0.123$, $c=-0.345$, $d=0.456$. For these values, $x_1\approx 1.22430$, $x_2\approx -0.330240$ and $x_3 \approx -3.02989$ and $f(x_3) \approx-0.16265$; so, two roots. So, Newton iterates would then be $$\left( \begin{array}{cc} n & x_n \\ 0 & 0 \\ 1 & -0.6085273172 \\ 2 & -0.7506361354 \\ 3 & -0.7576454727 \\ 4 & -0.7576619221 \\ 5 & -0.7576619222 \end{array} \right)$$ and, for the second

$$\left( \begin{array}{cc} 0 & -5.000000000 \\ 1 & -6.240875927 \\ 2 & -6.044184300 \\ 3 & -6.039496855 \end{array} \right)$$