# Prove that the given function $f(x)$ is Riemann integrable on $[0, 2]$.

The function $f$ is (Riemann) integrable on $I$ if there is some $L\in\mathbb{R}$ such that for every $\epsilon>0$ there is a $\delta> 0$ such that if $P$ is any tagged partition of $I$ with $\|P\|<\delta$, then $|S(f,P) − L|<\epsilon$.

By using this definition show that

$$f(x) =\begin{cases}1,& 0\leq x \leq 1\\2,&1 < x \leq 2\end{cases}$$

Any hint?

Take $L=1\cdot1+2\cdot1=3$ and for a given $\epsilon>0$ choose $\delta=2$ and $P=\{\{[0,1],\text{ with tag }x=0\}, \{[1,2],\text{ with tag }x=2\}\}$
Then $\|P\|=1<2=\delta$ and since $S(f,P)=f(0)\cdot(1-0)+f(2)\cdot(2-1)=3$ we get $$|S(f,P)-L|=|3-3|=0<\epsilon.$$