# Prove $f$ is riemann integrable if $f$ is continuous on closed interval $[a,b]$. (Explanation)

I was given the following proof of a theorem, quick note about notation, the fact that $$f$$ is riemann integrable on $$[a,b]$$ we denote by $$f\in\mathcal{R}([a,b])$$

Theorem: Let $$a,b\in\mathbb{R},a, let $$f$$ be continuous on closed interval $$[a,b]$$, then $$f\in\mathcal{R}([a,b])$$

We use the following lemma:

Lemma: Let $$a,b\in\mathbb{R},a and $$f$$ bounded on $$[a,b]$$. Then the following is equivallent: $$f\in\mathcal{R}([a,b])\tag{1}$$ $$\forall \epsilon >0 \exists \sigma_{[a,b]}:\overline{S}(f,\sigma)-\underline{S}(f,\sigma)<\epsilon$$

where $$\sigma$$ is a partition of $$[a,b]$$. Now, i understand the proof of the lemma and I'm not giving it here.

Proof. (of the theorem) $$f$$ is continuous on $$[a,b]$$, so $$f$$ is bounded on $$[a,b]$$, also because $$f$$ is bounded on bounded interval, f is uniformly continuous. Let $$\epsilon > 0$$ be given, by assumption, we find $$\delta>0$$ s.t. for any pair $$x,y\in[a,b]:|x-y|<\delta \Rightarrow |f(x)-f(y)|<\epsilon$$. Choose partitioning $$\sigma_{[a,b]}$$ s.t. $$\nu(\sigma)<\delta$$. Then by uniform continuity for each $$i\in\{1\ldots,n\}$$ we have that $$\sup_{[x_{i-1},x_i]}f\leq \inf_{[x_{i-1},x_i]}f+\epsilon$$ thus $$\overline{S}(f,\sigma)-\underline{S}(f,\sigma)=\sum_{i=1}^n \bigg(\sup_{[x_{i-1},x_i]}f-\inf_{[x_{i-1},x_i]}f\bigg)(x_i-x_{i-1})\leq \sum_{i=1}^n \epsilon(x_i-x_{i-1})=\epsilon(b-a)$$ which by lemma shows that $$f\in\mathcal{R}([a,b])$$.

where $$\nu(\sigma)$$ is the norm of the partition, that is $$\nu(\sigma)=\max\{x_{i}-x_{i-1}\mid i\in\{1,\ldots,n\}\}$$

Now, the part I don't understand is why uniform continuity implies something like $$\sup_{[x_{i-1},x_i]}f\leq \inf_{[x_{i-1},x_i]}f+\epsilon$$ (bolded part). Would someone explain more thoroughly, what is going on? Do they mean that by continuity $$f$$ attains extreme values (suprema, and infima) on each of $$\mathcal{I}:=[x_{i-1},x_i]$$ and by $$|f(x)-f(y)|<\epsilon$$, this results in $$\sup_\mathcal{I} f - \inf_\mathcal{I} f \leq \epsilon$$ (now, why is there a $$\leq$$ instead of $$<$$ ?).

Suppose that $$|s-r| <\delta$$, and $$|f(x)-f(y)| < \epsilon$$ whenever $$|x-y| <\delta$$. Then, on the interval $$[r,s]$$ (in the domain of $$f$$), $$\epsilon \ge \sup_{x,y\in [r,s]} (f(x)-f(y)) =\sup_{x\in [r,s]}f(x) - \inf_{x\in [r,s]}f(y)$$ That equality is always true, even without continuity; the supremum minus the infimum is an upper bound for the variation, and we can approach arbitrarily close to each of them. What (uniform) continuity gets us is the inequality out front relating to $$\epsilon$$, as we can choose the mesh fine enough that the variation in any one subinterval is small.

• Oh, I see now, also, we can interchange, by symmetry of $x,y$ on $[a,b]$ right? So maybe this could also be $\sup_{x,y\in I}(f(x)-f(y))=\sup_{x,y\in I}(f(y)-f(x))=\sup_{x\in I} f(x) - \inf_{y\in I}f(y)=$... my argument would go as follows: by boundeness suprema $\sup f =: f(M_i)$ and infima $\inf f =: f(m_i)$exist on each of $[x_{i-1},x_i]$ and by the continuity $|f(M_i)-f(m_i)| = f(M_i)-f(m_i) < \epsilon$, would this also be a good reasoning? – Michal Dvořák Dec 24 '18 at 2:02
• I just changed the variable names - my interval is not the same as your $[a,b]$, and now it uses different letters. This argument is all running on one of the small intervals belonging to the partition. Now, your argument, calling the supremum $f(M_i)$? That invokes continuity; you're saying that the function has a maximum, not just a supremum. Be careful with that sort of thing. – jmerry Dec 24 '18 at 2:11
• Well, then we use the continuity again to show that infima are in fact minima and suprema are maxima on the interval, or? – Michal Dvořák Dec 24 '18 at 2:15
• yes, you can, but its not really relevant to the argument. Saying $\sup f = f(M_i)$ is technically correct by continuity on the closed interval, but you may not always have $M_i$ which allows for $f(M_i) = \sup_{x\in I}f(x)$ – rubikscube09 Dec 24 '18 at 3:20