# The absolute value of a Riemann integrable function is Riemann integrable.

This is an exercise in Bartle & Sherbert's Introduction to Real Analysis second edition.

They ask to show that if $I=[a,b]$ is a closed bounded interval and that $f:I\to\mathbb{R}$ is (Riemann) integrable on $I$, then $|f|$ is integrable on $I$. Of course we know that the composition of an integrable function with a continuous function is integrable, but here they ask to prove it directly using the inequality $$|f(x)|-|f(y)|\leq|f(x)-f(y)|,\quad\forall x,y\in I.$$ By the Riemann's Criterion, $\epsilon>0$ given, there exists a partition $P$ of $I$ such that the difference between the upper and lower sum is less than $\epsilon$, i.e. $$U_f(P)-L_f(P)<\epsilon.$$ So if we can show that $$U_{|f|}(P)-L_{|f|}(P)\leq U_f(P)-L_f(P)$$ then we would be done. But I can't see how to prove this last inequality.

– Did
Feb 27, 2013 at 19:31

In each subinterval of the partition, $\sup |f|-\inf|f|\le \sup f-\inf f$. This is clear (with equality) if $\inf f\ge 0$ or $\sup f\le 0$, and also if $\inf f<0<\sup f$.
• It is not so clear for me. Why do they ask to use the inequality $|f(x)|-|f(y)|\leq|f(x)-f(y)|$? Feb 27, 2013 at 18:35
• Spenser, you use that inequality to show that $$\sup_{x\in I}|f(x)|-\inf_{x\in I}|f(x)|\le \sup_{x\in I}f(x)-\inf_{x\in I}f(x)$$ Specifically, you choose $x_1$ so that $|f(x_1)|$ is within $\epsilon$ of $\inf |f|$ and $x_2$ so that $|f(x_2)|$ is within $\epsilon$ of $\sup |f|$. Then sup $\sup |f| - \inf |f| -2\epsilon < |f(x_2)|-|f(x_1)| \leq |f(x_2)-f(x_1)| \leq \sup f - \inf f$. So $\sup f - \inf f \geq \sup |f| -\inf |f|$ Feb 27, 2013 at 19:15
• @ThomasAndrews I think I'm missing something simple, but doesn't the inequality in your comment just show that $\sup |f| - \inf |f| - 2\epsilon < \sup f - \inf f$, not $\sup |f| - \inf |f| < \sup f - \inf f$? Or does it work because $\epsilon$ can be as small as possible, so in the limit the inequality holds?
• @Spenser Also, I don't see how that inequality leads to $U_{|f|}(P)-L_{|f|}(P)\leq U_f(P)-L_f(P)$? Can you clarify that a bit? All I can get is that for each interval of $P$, I have $\sup |f| - \inf |f| - 2\epsilon < \sup f - \inf f$, which when I put that into the summation notation, I get an $\epsilon$ inside the summation, which doesn't seem right.