Sufficient conditions for limit exchanges in single-variable calculus I was trying to prove that:
$$\lim_{x \to 0} \frac{e^x - 1}{x} = 1$$
Using the following definition of $e$:
$$e = \lim_{h \to 0}(1+h)^\frac{1}{h}$$
We can rewrite the initial limit as:
$$\lim_{x \to 0} \frac{(\lim_{h \to 0}(1+h)^\frac{1}{h})^x - 1}{x}$$
If we "ignore" the internal limit (I don't know how to say this formally), this problem is easy:
$$\lim_{x \to 0} \frac{\big((1+x)^\frac{1}{x} \big)^x - 1}{x} = \lim_{x \to 0} (1 + x - 1) \frac{1}{x} = 1$$
My question is about this exchange:
$$\lim_{x \to 0} \frac{(\lim_{h \to 0}(1+h)^\frac{1}{h})^x - 1}{x} = \lim_{x \to 0} \frac{\big((1+x)^\frac{1}{x} \big)^x - 1}{x}$$
I am not sure if this is correct or not. I now this isn't valid for every case, so is there a way for me to know when this operation is valid or not? I was trying to find a theorem/explanation about this, but I wasn't able to describe this operation in words.
EDIT: Sorry if this isn't clear, my question is just about the limit exchange, I want to know if the operation I used is valid or not, the initial statement is just my motivation to ask this question.
 A: You're not really "exchanging" limits, but specializing a two variable limit to a single variable one: the formula
$$\lim_{x \to 0} \frac{(\lim_{h \to 0}(1+h)^\frac{1}{h})^x - 1}{x} = \lim_{x \to 0}\lim_{h\to 0} \frac{\big((1+h)^\frac{1}{h} \big)^x - 1}{x}$$
has two variables, so we can think of this as an iterated limit. That is, we are doing some multi-variable calculus.
To do this rigorously, we need to be careful about convergence when we interchange limits. BUT if we just want to see why things worked out, I'll just assert that everything converges and manipulate the limits. We can thus view it as a multi-variable limit
$$\lim_{x \to 0}\lim_{h\to 0} \frac{\big((1+h)^\frac{1}{h} \big)^x - 1}{x}=\lim_{(x,h)\to (0,0)} \frac{\big((1+h)^\frac{1}{h} \big)^x - 1}{x}. $$
This second integral is more complicated: its definition requires convergence along all possible paths as $(x,h)$ approach $(0,0)$ in the $(x,h)$-plane. Taking this convergence for granted (for the purpose of seeing what's going on), we can then compute the limit by choosing a convenient path, such as approaching $(0,0)$ along the diagonal line $x=h$. That is, just compute
$$\lim_{(x,h)\to (0,0)} \frac{\big((1+h)^\frac{1}{h} \big)^x - 1}{x}=\lim_{x=h\to 0} \frac{\big((1+x)^\frac{1}{x} \big)^x - 1}{x},$$
which is what you did.
The upshot is: this operation is not a valid trick unless you justify what you are doing with the two-variable limit.
