Proof that if $f(x)$ is continuous on $[a,b]$ it is uniformly continuous on $[a,b]$

real-analysissolution-verificationuniform-continuity

My textbook gave a proof by contradiction of the following theorem:

Theorem: If $f(x)$ is a real-valued function that is continuous on $[a,b]$ then it is uniformly continuous on $[a,b]$

The proof by contradiction seemed overly complex and indirect. Was wondering if the following direct proof is valid.

Direct proof of Theorem

Since $f(x)$ is continuous on $[a,b]$ then for any $\epsilon > 0$ and $y,x \in [a,b],\; \exists \delta_x(\epsilon)>0 $ such that $|y-x|<\delta_x(\epsilon) \implies |f(y)-f(x)|< \epsilon$.

Letting $\delta(\epsilon) := \min_{x \in [a,b]} \delta_x(\epsilon)$ Then for each $\epsilon > 0$ and $x,y \in [a,b]$, we have $|x-y|<\delta(\epsilon) \leq \delta_x(\epsilon) \implies |f(x)-f(y)|< \epsilon\;\square$

This seems pretty direct to me and was wondering if I am missing something in this proof.

EDIT: As the great answers and comments have shown, my mistake/challenge is due to the ill-defined $\delta_x(\epsilon)$ function. I was assuming there was some (undefined) process that would select a finite positive number for each $\delta_x(\epsilon)$, but I did not specify it. I also rely on the continuity of $\delta_x(\epsilon)$ and that is not assured or proved.

Best Answer

The problem is in the argument that $\delta(\epsilon)$ exists because the minimum exists. Here, you are using a theorem that says that a minimum of a continuous function over a compact set always exists.

However, you don't have any reason to believe that the function $x\mapsto \delta_x(\epsilon)$ is continuous, so the argument is incorrect.

Related Question