How to isolate $x$ in $a^x + b^x = c$? (For use in medical statistics) I've broken a somewhat complex calculation down to the following mathematical equation to be solved:
$a^x + b^x = c$
How do I find $x$ when $a, b$ and $c$ are given as parameters?
I.e., if $a=3$, $b=4$ and $c=25$, then the solution is $x=2$.
(The question has nothing to do with geometry - this is just the simplest example I can come up with.)
Background
For specifying a person's overweight/underweight, the term Z-score is used and the Z-score is calculated based on the person's BMI, sex and age. For each sex and age interval, the constants $\lambda$, $\mu$ and $\sigma$ are given.
I have the formula $Z = \frac{(\frac{B}{ \mu})^\lambda -1}{\lambda\sigma}$, where $B$ is the person's BMI, for calculating the Z-score. Also, I have a set of $B$-values for a specific age and sex, for $Z \in \{-2, -1, 0, 1, 2\}$. For $Z=n$, let's call the $B$ data set $B_n$.
My task is, based on the above knowledge, to calculate $\mu$, $\sigma$ and $\lambda$ for a specific sex and age, so I can calculate the Z-score for a specific BMI, based on sex and age.
It is obvious that $\mu = B_0$. Moreover, using the Z-formula on $B_1$, I get $\sigma = \frac{(\frac{B_1}{B_0})^\lambda -1}{\lambda}$.
Using the Z-formula on $B_1$ and $B_{-1}$, I get $(\frac{B_{-1}}{B_0})^\lambda + (\frac{B_{1}}{B_0})^\lambda = 2$.
So, pretty simple, I just need to find how to isolate $x$ in the equation $a^x + b^x = c$...
There is almost surely no closed form expression, but a qualitative approach is possible.
If $b=a$, there is clearly a solution. Let us assume $\dfrac{b}{a}&gt;1$, WLOG.
Taking the natural logarithm of both sides of the given equation:
$$\operatorname{ln}(a^x (1+\left(\tfrac{b}{a}\right)^x)=\operatorname{ln}(c)$$
$$\operatorname{ln}(a^x)+\operatorname{ln}(1+\left(\tfrac{b}{a}\right)^x)=\operatorname{ln}(c)$$
$$-x\operatorname{ln}(a)+\operatorname{ln}(c)=\operatorname{ln}(1+\left(\tfrac{b}{a}\right)^x)$$
which represents the equation verified by the abscissas of the possible intersection point(s) of the straight line (L) (magenta on the figure) and curve (C) (red on the figure) with resp. equations:
$$\begin{cases}y&amp;=&amp;-x\operatorname{ln}(a)+\operatorname{ln}(c)\\
y&amp;=&amp;\operatorname{ln}(1+\left(\tfrac{b}{a}\right)^x)\end{cases}$$
Please note that the second curve has a slant asymptote with equation $y=x \ln(b/a)$.

Therefore, 3 cases can occur with 0, 1 or 2 roots,

according to the resp. values of $a,b,c$. One cannot have more than two roots because curve (C) can be shown to be convex, and a straight line cannot intersect a convex curve in more than two points.

Fig. 1: The given case $a=3;b=4;c=25$ with a unique root at $x=2$.

Fig. 1: The case $a=0.5;b=2;c=2.5$ with two roots $x=-1$ and $x=1$.
We can do this assuming b is a function of a such that $b=a^{-1}$:
$$a^x+b^x=c=$$
$$a^x+a^{-x}=c$$
$$\frac{a^x+a^{-x}}{2}=\frac c2=$$
$$\frac{e^{x*ln(a)}+e^{-x*ln(a)}}{2}=\frac c2=$$
$$cosh(x*ln(a))=\frac{c}{2}$$
Now we can use the inverse hyperbolic cosine to solve for x:
$$x*ln(a)=x*ln(a)=2πin\pm cosh^{-1}\frac c2=$$
$$x=\frac{2πin\pm cosh^{-1}\frac c2}{ln(a)}=$$
$$x=\frac{2πin\pm ln(c+\sqrt{c-2}\sqrt{c+2})-ln(2)}{ln(a)}=$$
$$x=\frac{2πin}{ln(a)}\pm log_a(c+\sqrt{c-2}\sqrt{c+2})-log_a(2)$$
To finish off, this idea is from one of the comments and assuming that $n\in \Bbb Z$.
Another idea in the comments was to do $b=a^n$ so that a general solution can be found. Let us reset the variables so that no other ones are defined but our starting equation:
$$a^x+b^x=c=a^x+(a^x)^n=c$$
With $t=a^x$, this happens:
$$t+t^n=c=$$
$$t^n+t-c=0$$
It can be solved that:
$$t=\sqrt[n]{c-t}=$$
$$t= \sqrt[n]{c-\sqrt[n]{c-\sqrt[n]{...}}}$$
However, this path causes alternating pattern for $n\in\Bbb Z$. This problem makes us need to modify our solution:
$$-t= \sqrt[n]{c-\sqrt[n]{1+\sqrt[n]{c+...}}}$$ for odd n to avoid imaginary numbers, even though they may or may not bring about other roots of the polynomial, or  $$-t=\sqrt[n]{c+\sqrt[n]{c+\sqrt[n]{c+...}}}$$ for even n.
Because we defined  $t=a^x$, this advances to:
$$x=log_a\sqrt[n]{c\pm\sqrt[n]{c+\sqrt[n]{c+...}}}+\frac{2iπm}{ln(a)}; a,b,ln(a)\ne 0,b=\sqrt[n]a,n\in \Bbb Z$$
Use the positive branch for n=2k and the negative branch for n=2k+1, $k\in \Bbb Z$.
Here is proof of my answer for c=1: https://www.desmos.com/calculator/l8gr3pnb0u.
I apologize for whatever I did wrong that got a “down vote”. It would be significantly harder to figure out for $n\in \Bbb U$ or the universal set.
Please correct me and give me feedback!