Continuity over a Compact Implies Uniform Continuity There is a well-known theorem in mathematical analysis that says

Suppose $f:M\to N$ is a function from a metric space $(M,d_M)$ to another metric space $(N,d_N)$. Assume that $M$ is compact. Then $f$ is uniformly continuous over $(M,d_M)$.

For now, let us take $M=[a,b]$, $N=\mathbb{R}$, $d_M=d_N=|\cdot|$. I have seen two different proofs for this case.

*

*T. A. Apostol, Calculus, Volume 1, 2nd Edition, Page 152, 1967.


*C. C. Pugh, Real Mathematical Analysis, 2nd Edition, Page 85, 2015.
Apostol argues by contradiction using the method of bisections and the least upper bound property. Pugh also explains by contradiction but prefers to use a technique that one of my teachers called it continuous induction to prove that $[a\,\,\,b]$ is sequentially compact and then uses this property to prove the theorem. Both proofs can be found on the pages mentioned above.
Recently, I noticed that Pugh has suggested another approach in exercise 43 of chapter 1 on page 52. However, I couldn't riddle it out. Here is the question



*Prove that a continuous function defined on an interval $[a\,\,\,b]$ is uniformaly continuous.

Hint. Let $\epsilon>0$ be given. Think of $\epsilon$ as fixed and consider the sets
\begin{align*}A(\delta)&=\{u\in[a,b]\,|\,\text{if}\,x,t\in[a,u]\,\text{and}\,|x-t|<\delta\,\text{then}\,|f(x)-f(t)|<\epsilon\}, \\
A&=\bigcup_{\delta>0}A(\delta).
\end{align*}
Using the least upper bound property, prove that $b\in A$. Infer that $f$ is uniformly continuous.

Can you shed some light on what Pugh is trying to suggest in the hint?

Uniform Continuity
In the definition of continuity we have that
$$\forall x\in[a,b],\,\,\forall\epsilon>0,\,\,\exists\delta>0,\,\,\forall t\in[a,b]\,\wedge\,|t-x|<\delta\,\implies|f(t)-f(x)|<\epsilon$$
Here the delta depends on $x$ and $\epsilon$. Now, fix $\epsilon$ and let $\Delta_{\epsilon}$ be the set that contains all values of $\delta$ corresponding to different $x$'s. Then uniform continuity is just telling us that $\Delta_\epsilon$ has a minimum. Consequently, this means that there is a $\delta$ that works for all $x\in[a,b]$. This leads to the following definition
$$\forall\epsilon>0,\,\,\exists\delta>0,\,\,\forall x\in[a,b],\,\,\forall t\in[a,b]\,\wedge\,|t-x|<\delta\,\implies|f(t)-f(x)|<\epsilon$$
where $\delta$ only depends on $\epsilon$.
 A: Note that $a\in A$, since $x,t\in[a,a]$ implies $|f(x)-f(t)|=0<\epsilon$.
Assume $c\in A$. Then, from continuity at $c$ there is $\delta$ such that if $|x-c|<\delta$ then $|f(x)-f(c)|<\epsilon/2$. Then, if $x,t$ are $\delta$-close to $c$, then $|f(x)-f(t)|\leq|f(x)-f(c)|+|f(t)-f(c)|<\epsilon$. Therefore, $[c,\delta/2]\subset A$.
Let $b'$ be the supremum of the $c$ such that $[a,c]\subset A$. The argument above shows that if $b'<b$, then there is $\delta>0$ such that $[b',b+\delta]\subset A$ contradicting that $b'$ is the supremum. 
Therefore, $b'=b$.

The argument has an inductive structure in that you check it for the initial point $a$. Then, assuming the conclusion for a set $[a,b']$ you prove that it is satisfied for $[a,b'+\delta]$ for some $\delta>0$. The combination of them gives that it holds on $[a,b]$ all $b$.
A: $A$ is indeed the largest domain over which $f$ is uniformly continuous. We proceed as follows.
For every $\delta>0$, we know that $a\in A(\delta)$ and that $A(\delta)$ is bounded above by $b$. Consequently, $a\in A$ and $A$ is also bounded above by $b$. This means that $A$ has a supremum $c:=\sup A$ with $a\leq c\leq b$. If $c=a$ then by the continuity at $a$ we observe that there is a $\delta>0$ such that for every $u\in[a,a+\delta)$ we have $|f(u)-f(a)|<\frac{\epsilon}{2}$. Now, for every $x, t\in[a,a+\delta)$ we have that $|f(x)-f(t)|\leq|f(x)-f(a)|+|f(a)-f(t)|<\frac{\epsilon}{2}+\frac{\epsilon}{2}=\epsilon.$ This means that $f$ is uniformly continuous over $[a,c_*]$ for any $c_*\in(a,a+\delta)$. Consequently, $c_*\in A$ which contradicts the fact the $a$ was an upper bound for $A$. If $a<c<b$ then for every $\delta>0$ there is a $v\in A$ such that $v\in(c-\delta,c)$ otherwise $c-\delta$ would be an upper bound for $A$ contradicting that $c$ is the least upper bound for $A$. Again, by continuity at $c$ we can conclude that for every $x,t\in(c-\delta,c+\delta)$ we have $|f(t)-f(x)|<\epsilon$. We see that $f$ is uniformly continuous over $[a,v]$ and $[v,c_*]$ so it is indeed uniformly continuous over $[a,c_*]$ and $c_*\in A$. But $c_*>c$ which contrdicts $c$ being an upper bound for $A$. This leaves us with the only option that $c=b$. Using the continuity at $b$ we know that for every $x,t\in(b-\delta,b]$ we have $|f(x)-f(t)|<\epsilon$. Also, there is a $c_*\in A$ such that $c_*\in(b-\delta, b]$. Since $f$ is uniformly continuous over $[a,c_*]$ and $[c_*,b]$ then it is uniformly continuous over $[a,b]$ or equivalently there is a $\delta>0$ such that $b\in A(\delta)$ that implies $b\in A$.
