How to solve $a^x+b^x=1$ (solve for $x$)
Solution 1:
In general, there is no analytical solution.
If $$b=a^{m/n}$$ where $m,n$ are naturals, the equation can be written as
$$z^n+z^m=1$$ where $z:=a^{x/m}$. There are explicit formulas for the cases $m,n\le4$, and specific numerical methods for polynomials of higher degree. But in the latter case and when the exponent is irrational, direct resolution with an equation solver (Newton) is simpler.
Another way to look at the problem is by setting $t:=a^x$ so that
$$t^{\log b/\log a}+t=1$$ or $$t^\alpha+t=1.$$
From this
$$\alpha=\frac{\log(1-t)}{\log(t)}=:f(t)$$ gives you an explicit relation between $t$ and $\alpha$.
What you are after is the inverse, $t=f^{-1}(\alpha)$ and you can some how precompute/tabulate this inverse, by interpolation or other means.
We have the pretty good approximation
$$f^{-1}(\alpha)=\frac{(\alpha-1)(\sqrt{0.25\alpha})^\alpha+1}{\alpha(\sqrt{0.25\alpha})^{\alpha-1}+1}$$ for $\alpha<1$.
Solution 2:
Unfortunately, there is no closed form so far, at least without using special functions, but here it is using this graph. You can also think of plugging in some value of x into the final answer at the top of the power tower like answer or just imagine it goes away and just the value of x is left in terms of a power tower like answer of a and b. The inequality at the end is from @ThomasAndrews:
$$a^x+b^x=1\implies a^x=1-b^x\implies c_0=x=\log_a(1-b^x)=\log_b(1-a^x)=c_1\implies c_{n+1}= \log_a(1-b^{c_n})=\log_b(1-a^{c_n}) \implies x=\lim_{n \to \infty} c_n= \log_a\left(1-b^{\log_a(1-b^{…})}\right)= \quad\log_b\left(1-a^{\log_b(1-a^{…})}\right) \implies x=c_\infty,0\not<a\not\le 1\not\le b\ \mathrm{or} \ 0 \not <b \not\le 1 \not\le a$$
Here are two other special case solutions I have. Just set the c-value to 1 in one of my answers
here
I will try to find a closed form or alternate non-closed form if possible. In the graph, the solution curve turns into y=k or x=k as the solution as x crosses the curve at (k,k). Please correct me and give me feedback!
Solution 3:
In the most general case, there is no analytical solution for the zero of function $$f(x)=a^x+b^x-1$$ and numerical iterative methods would be required.
If wa assume $a>1$ and $b>1$, $f(x)$ is not very pleasant to look at if graphing but this is not the case of its logarithmic tansform $$g(x)=\log(a^x+b^x)$$ which looks quite close to a straight line.
Being lazy, expand $g(x)$ as a Taylor series around $x=0$ and obtain $$g(x)=\log(2)+\log(\sqrt{ab})x+O(x^2)\implies x_0=-\frac {2\log(2) } {\log({ab}) }$$ and start Newton method for generating the sequence $$x_{n+1}=x_n-\frac{\left(a^{x_n}+b^{x_n}\right) \log \left(a^{x_n}+b^{x_n}\right)}{a^{x_n} \log (a)+b^{x_n} \log (b)}$$
For illustration, using $a=3$ and $b=7$, the iterates will be $$\left( \begin{array}{cc} n & x_n \\ 0 & -0.455340 \\ 1 & -0.468168 \\ 2 & -0.468178 \end{array} \right)$$ which is quite fast.
But we could have a still better approximation performing one single iteration of Halley method starting at $x=0$. This would give, as an approximation, $$x_0=\frac {4\log(2)\log(ab) } {(\log (2)-2) \left(\log ^2(a)+\log ^2(b)\right)-2 (2+\log (2)) \log (a) \log (b) }$$
For the worked example, this would give $x_0=-0.46790$.
This estimate could still be improved using one single iteration of higher order methods (we still get analytical expressions. The formulae start to be too long for typing them, but for the worked example, as a function of the order of the method, the results would be $$\left( \begin{array}{ccc} n & x_0^{(n)} & \text{method} \\ 2 & -0.4553404974 & \text{Nexton} \\ 3 & -0.4679002951 & \text{Halley} \\ 4 & -0.4682565630 & \text{Householder} \\ 5 & -0.4681819736 & \text{no name} \\ 6 & -0.4681774686 & \text{no name} \\ 7 & -0.4681781776 & \text{no name} \\ 8 & -0.4681782373 & \text{no name} \end{array} \right)$$