There are certain pairs of points ${(a,b)}$ for which we can find a nice analytical solution. As an example, take ${a=\frac{1}{2}, b=\frac{1}{4}}$ (so ${b=a^2}$). Then let ${u=\left(\frac{1}{2}\right)^x}$. The equation ${\left(\frac{1}{2}\right)^x + \left(\frac{1}{4}\right)^x = 1}$ simplifies to
$${u + u^2 = 1\Leftrightarrow u^2 + u - 1 = 0}$$
Now you can find the roots of this to find the value of ${\frac{1}{2^x}}$, and hence rearrange to find the exact value of ${x}$.
In general, if ${b = a^{\frac{p}{q}}}$, then let ${u=a^x}$:
$${\Rightarrow u + u^{\frac{p}{q}} = 1}$$
Then let ${u = t^q}$
$${\Rightarrow t^q + t^p = 1}$$
So in this case where one of the numbers ${a,b}$ can be written as a rational power of one another - you can reduce the equation to a sort of "polynomial" - this again, provides no promises of a closed form solution, but depending on the choice of ${p,q}$ it might.
To summarize: in general, I don't think you are going to find a nice closed form. However, if a "nice" relationship between ${a}$ and ${b}$ exists - it's possible a closed form can be found by substitutions and reductions.