Limits and substitutions I have seen the following performed during analysis of the limiting behaviour of real functions. consider
$$
f(x) = \frac{1-x^a}{1-x^b}
$$
with integers $a,b$. At the point $x\rightarrow 1$ the function is undefined. However, the limit can be found from L''Hospital's rule as
$$
\lim_{x\rightarrow 1} f(x) = \frac{ax^{a-1}}{bx^{b-1}}=\frac{a}{b}\bigg|_{x=1}
$$
Now, at this point, a substitution is made such that $x$ is replaced by $\xi =-1/\log x$ to arrive at
$$
\frac{1-e^{-a/\xi}}{1-e^{-b/\xi}}
$$
I am aware that $\log(1) = 0$; however, why can we substitute this expression in, and can any relevant function with the desired behaviour at $x=1$ be used?
 A: One of the reasons we like continuous functions is that they preserve limits of functions, so if $f$ is continuous, then $\lim_{x\to a} f(g(x)) = f(\lim_{x\to a}g(x))$ (assuming the limit of $g$ exists). That means in particular, that if $-1/\log{x}$ applied to our function has some nice properties, then you can use it just as you noticed.
A: One general theorem is following: suppose exists, finite or not, limits $\lim\limits_{x \to a}f(x)=b$ and $\lim\limits_{y \to b}F(x)$. If in some punctured(deleted) neighbourhood of $a$ holds $f(x) \ne b$, then in point $a$ exists limit of composition and holds
$$\lim\limits_{x \to a}F(f(x))=\lim\limits_{y \to b}F(x)$$
In your case, assuming $a,b \gt 1, a\ne b$, after applying L'Hospital you can directly put $x=1$ without any substitution.
If we want to use substitution of variables, without L'Hospital, then, for example, we can write
$$f(x) = \frac{1-x^a}{1-x^b} = \frac{1-(1+t)^a}{1-(1+t)^b}=\frac{\frac{1-(1+t)^a}{t}}{\frac{1-(1+t)^b}{t}}$$
and use limit $\lim\limits_{t\to 0}\frac{(1+t)^a-1}{t}=a$ for substitution $x=1+t$
