# Proving that $f$ is Riemann integrable on [0, 2]

Let $$f(x) = \begin{cases} 1 &\text{if 0 \le x \le 1} \\ 0 &\text{if 1 < x \le 2} \end{cases}$$ Show that $f$ is Riemann integrable on $[0, 2]$ and find $\int_0^2f(x)\space dx$

This is my attempt to prove it, but I am not sure if its valid:

Let $\epsilon > 0$. Let $P$ be a partition of the interval $[0,2]$ where $P = \{0, 1 - \epsilon, 1 + \epsilon, 2\}$. We have that $L(f, P) = (1 - \epsilon) \cdot 1 + (1 + \epsilon) \cdot 0 + 2\cdot0 = 1 - \epsilon = U(f, P)$. Since $U(f,P) - L(f,P) = 0 < \epsilon$, $f$ is Riemann integrable on $[0, 2]$. Since $\epsilon$ is a small quantity, it follows that $\int_0^2 f(x) \space dx = 1$.

I think you made a slight mistake here. Your partition is fine but you should have:

$$L(f,P) = (2 - (1 + \epsilon)) \cdot 1 + (2\epsilon) \cdot 0 + (1 - \epsilon) \cdot 0$$

$$U(f,P) = (2 - (1 + \epsilon)) \cdot 1 + (2\epsilon) \cdot 1 + (1 - \epsilon) \cdot 0$$

$$U(f,P) - L(f,P) = 2\epsilon$$

This is sufficient to prove that $f$ is Riemann integrable on $[0,2]$. And correct, since

$$L(f,P) = 1 - \epsilon,$$

letting $\epsilon \to 0$ you get the integral is 1.

• Naturally, slight blunder. Feb 7, 2014 at 18:56
• On $[1+\epsilon,2]$, in the $L(f, P)$ part, why is the $\inf$ $1$? Sep 15, 2022 at 5:43