Here is the exercise
Let $f:[a,b]\rightarrow \mathbb{R}$ be Riemann-integrable. Prove that $f^+$, $f^-$ and $|f|$ are also Riemann-integrable, when
$$f^+=\begin{cases} f(x) & f(x)\geq 0 \\ 0 & otherwise \end{cases}$$
$$f^-=\begin{cases} -f(x) & f(x)\leq 0 \\ 0 & otherwise \end{cases}$$
This problem seems so obvious. Why wouldn't $f^+$ be integrable? Anyway, I need to prove this using this hint:
"$f$ is Riemann-integrable if with every $\epsilon>0$ there exists step functions $h\leq f\leq g $ such that $\int h -\int g <\epsilon$."
I have no idea where to start...
We prove the Riemann integrability of $f^+$. A similar proof can be done for $f^-$.
As $f$ is Riemann-integrable, for all $\epsilon>0$ there exists step functions $h \leq f\leq g $ such that $\int h -\int g <\epsilon$.
Now define $h^+ = \max(h,0)$ and $g^+ = \max(g,0)$. You can verify that:
And concludes the proof.