Let $f:[a,b] \rightarrow \mathbb{R}$ be a bounded function and continuous on $(a,b)$. Prove $f$ is Riemann integrable on $[a,b]$

I'm trying to prove that if $f:[a,b] \rightarrow \mathbb{R}$ is a bounded function, and assuming that $f$ is continuous on $(a,b)$ then $f$ is Riemann integrable on $[a,b]$. Here's my attempt at the proof:

Since $f$ is continuous, by definition $\exists \delta$ such that $\forall \epsilon > 0$:

$|x - y| < \delta \rightarrow |f(x) - f(y)| < \epsilon$

Now I'm going to guess that I'm supposed to use either the theorem:

$f$ is Riemann integrable iff $\forall \epsilon > 0, \exists \text{ partition, } P \text{ s.t } U(f,p) - L(f,p) < \epsilon$

or the theorem:

$f$ is Riemann integrable with Riemann integral I iff $\forall \epsilon > 0, \exists \text{ a partition P s.t. } U(f,p)-\epsilon < I < L(f,p) + \epsilon$

to create some sort of epsilon argument. I'm going to try using the first one because if I'm being honest, I wouldn't know how to go about with the second.

Let $P$ be a partition of $[a,b]$ such that $P=\{a = x_0, x_1, \ldots, x_n = b\}$ where the distance between each $x_i$ and $x_{i+1}$ is less than $\delta$ (because of continuity?). And then our sup and inf will exist somewhere within our partition:

$M_i = \sup(f(x))$ where $x\in (x_i, x_{i+1})$

$m_i = \inf(f(x))$ where $x \in (x_i, x_{i+1})$

And here's where I'm stuck. Help or advice would be much appreciated!

• Hints: use a partition such that the first rectangle (the one containing $a$) is narrow enough so that $(M_0 - m_0) \times \text{width}$ is less than $\epsilon/3$, and similarly for the last rectangle (the one containing $b$). You will need the boundedness in order to do this. Then, use uniform continuity on $[x_1, x_{n-1}]$. – Bungo Dec 8 '16 at 2:08
• @Bungo Sorry, but I don't quite understand how to set up the partition. Do we let the partition be something like $P_N = \{a + \frac{0 \cdot (b-a)}{N}, a + \frac{1 (b-a)}{N}.... a+\frac{N(b-a)}{N} = b$? – Nikitau Dec 8 '16 at 2:29
• You can define it that way (uniformly spaced) but only if you make $N$ sufficiently large. How large does it need to be? Well, if we let $\Delta = (b-a)/N$ for brevity, we would like to simultaneously satisfy $(M_0 - m_0) \Delta < \epsilon / 3$, and $(M_N - m_N) \Delta < \epsilon / 3$, and $\sum_{j=1}^{N-1}(M_j - m_j)\Delta < \epsilon/3$. For the first two conditions, use the boundedness of $f$, and for the last one, use the uniform continuity of $f$ on any closed bounded interval contained in $(a,b)$. Work out how large $N$ has to be to satisfy each condition, then choose the max. – Bungo Dec 8 '16 at 2:34
• Do you already know that a bounded continuous function is integrable? The two additonal points cannot do anything to the integral. – Jacob Wakem Dec 8 '16 at 2:46
• @Alephnull I do know the proof where if f is continuous on closed [a,b], then f is RI on [a,b]. Would the proof then be completely analogous to that? – Nikitau Dec 8 '16 at 2:52