TITLE: Proving $fg$ and $f+g$ is Riemann integrable through the easy and hard way.
QUESTION [8 upvotes]: Problem: Suppose $f,g$ are Riemann integrable functions, show that $f+g$ and $fg$ are also Riemann integrable.

I know there is really easy to do this with measure theory, but I want to see if this method works as well. I will write an answer for $f+g$ using measures.

Write up 1: Denote $D_f, D_g$ to be the set of all discontinuities of $f$ and $g$. $f+g$ can only be integrable if and only if $D_f \cap D_g$ has measure zero, but without any loss of generality, we also have $D_f \cap D_g \subset D_f$, the set on the left has measure zero. So $f+g$ is Riemann integrable.

Okay this one is the longer one. 

Write up 2: As $f$ and $g$ are integrable, there are partitions $P_f$ and $P_g$ such that $$U(f,P_f) - L(f,P_f) < \epsilon/2,$$
  $$U(g,P_g) - L(g,P_g) < \epsilon/2.$$
  Now we begin the estimation starting with $$L(f,P)L(g,P) \leq L(fg,P),$$ and $$U(f,P)U(g,P) \geq U(fg, P).$$
  Therefore if we let $P \supset P_f \cup P_g$ then we get,
\begin{align}
U(fg,P) - L(fg,P) &\leq U(f,P)U(g,P) - L(f,P)U(g,P) + L(f,P)U(g,P) - L(f,P)L(g,P) \\
&=U(g,P)[U(f,P) - L(f,P)] + L(f,P)[U(g,P) - L(g,P)]\\
&\leq \epsilon/2[U(g,P) + L(f,P)]\\
&\leq \epsilon/2[ U(g,P)  +  \sup \{L(f,P) \}]
\end{align}

I am stuck with the last step, I am not sure how to bound $U(g,P)$. May I get some pointers?
My futile idea is that I can do the following bound $U(g,P) < \epsilon/2 + L(g,P) < \epsilon/2 + \sup \{L(g,P) \}$
note: I know for $fg$, there is another short proof with $4fg = (f+g)^2 - (f - g)^2.$ I am not seeking that one either.

REPLY [2 votes]: Given a function $f:\ [a,b]\to{\mathbb R}$ and a subinterval $Q\subset[a,b]$ write $\mu(Q)$ for the length of $Q$, and put
$$\|\Delta f\|_Q:=\sup_{x,y\in Q}|f(y)-f(x)|\qquad\bigl(=\sup_{x\in Q} f(x)-\inf_{x\in Q} f(x)\bigr)\ .$$
This $f$ is Riemann integrable over $[a,b]$ if for any $\epsilon>0$ we can find a partition $P$ of $[a,b]$ into finitely many  subintervals $Q_k$ such that
$$\bigl(U(f,P)-L(f,P)=\bigr)\qquad D_P(f):=\sum_k \|\Delta f\|_{Q_k}\>\mu(Q_k)<\epsilon\ .$$
When $f$ passes this test it is automatically bounded. Furthermore we note that a refinement of $P$ makes $D_P(f)$ smaller.
Now assume that two integrable functions $f$ and $g$ are given. In the following I shall deal with $fg$ only, since $f+g$ is simpler. Then there is an $M>0$ such that both $f$ and $g$ are globally bounded by $M$. From
$$f(y)g(y)-f(x)g(x)=f(y)\bigl(g(y)-g(x)\bigr)+g(x)\bigl(f(y)-f(x)\bigr)$$
it follows that
$$|f(y)g(y)-f(x)g(x)|\leq M\bigl(|f(y)-f(x)|+|g(y)-g(x)|\bigr)\qquad\forall \ x,\>y\in[a,b]\ ,$$
and this implies that for any subinterval $Q\subset[a,b]$ we have
$$\|\Delta (fg)\|_Q\leq M\bigl(\|\Delta f\|_Q+\|\Delta g\|_Q\bigr)\ .\tag{1}$$
Now let an $\epsilon>0$ be given. By assumption there are partitions $P'$ and $P''$ of $[a,b]$ such that
$$D_{P'}(f)<{\epsilon\over 2M},\quad D_{P''}(g)<{\epsilon\over 2M}\ .$$
Let $P$ be a common refinement of $P'$ and $P''$. Then from $(1)$ it follows that
$$D_P(fg)\leq M\bigl(D_P(f)+D_P(g)\bigr)\leq M\bigl(D_{P'}(f)+D_{P''}(g)\bigr)<\epsilon\ .$$