Find $a$ if $\lim_{x\to a} \frac{a^x-x^a}{x^x-a^a}=-1$ The limit is of the form $\frac 00$
Using L’Hospital gives
$$\lim_{x\to a} \frac{a^x \ln a - a(x^{a-1})}{x^x (\ln x +1) -0}$$
Which proves to be pointless because $x^x$ can be differentiated endlessly.
What is the alternative to this?
 A: You're almost there. Now, just substitute $x\to a$ and solve

$$\frac{a^a\ln a-a^a}{a^a(\ln a+1)}=-1\\ \implies a=1$$

A: Using l'hospital give :
\begin{align*}
\lim_{x\to a}\frac{a^x-x^a}{x^x-a^a}&=\lim_{x\to a}\frac{\ln(a)a^x-ax^{a-1}}{(\ln(x)+1)x^x}\\
&=\frac{\ln(a)a^a-a^a}{(\ln(a)+1)a^a}\\
&=\frac{\ln(a)-1}{\ln(a)+1}\\
\end{align*}
So:
\begin{align*}
\lim_{x\to a }\frac{a^x-x^a}{x^x-a^a}=-1\\
\implies &\frac{\ln(a)-1}{\ln(a)+1}=-1 \\
\implies 2\ln(a)=0\\
 \implies a=1\\
\end{align*}
A: Alternative way: using Taylor series instead of Hopital's rule.
Let $x=a+t$, with $t\to 0$, then
\begin{align}
\frac{a^x-x^a}{x^x-a^a}&=\frac{a^{a+t}-(a+t)^a}{(a+t)^{a+t}-a^a}=
\frac{a^{t}-(1+t/a)^a}{a^t(1+t/a)^{a+t}-1}\\&=\frac{e^{t\ln(a)}-e^{a\ln(1+t/a)}}{e^{t\ln(a)}e^{(a+t)\ln(1+t/a)}-1}=\frac{t\ln(a)-t+o(t)}{(1+t\ln(a)+o(t))(1+t+o(t))-1}\\
&\to
\frac{\ln(a)-1}{\ln(a)+1}.\end{align}
Therefore,
$$\frac{\ln(a)-1}{\ln(a)+1}=-1\Leftrightarrow \ln(a)-1=-\ln(a)-1 \Leftrightarrow
\ln(a)=0\Leftrightarrow a=1.$$
A: First of all its a well known rule that
$$\lim_{x \to p}  f(x)^{g(x)} = \lim_{x \to p} f(x) ^{\lim_{x \to p} {g(x)}}$$
$$\lim_{x\to a} \frac{a^x-x^a}{x^x-a^a}=  \lim_{x\to a} \frac{a^a -  x^a }{x^a- a^a  } =-1$$
