When I was teaching calculus recently, a freshman asked me the conditions of the Riemann integrability of composite functions. 


For the composite function $f \circ g$, He presented three cases:
1) both $f$ and $g$ are Riemann integrable;
2) $f$ is continuous and $g$ is Riemann integrable;
3) $f$ is Riemann integrable and $g$ is continuous.


For case 1 there is a counterexample using Riemann function. For case 2 the proof of the integrability is straight forward. However, for case 3, I can neither give a proof nor construct any counterexample. Even under the condition that $g$ is differentiable, I cannot work out anything. How to reply my student?



About the Riemann integrability of composite functions
Let $f$ be bounded and discontinuous on exactly the Cantor set $C$ (for example, the characteristic function of $C$). Let $g$ be continuous increasing on $[0,1]$ and map a set of positive measure (for example a fat Cantor set) onto $C$. Then $f \circ g$ is discontinuous on a set of positive measure. So $f$ is Riemann integrable, $g$ is continuous, and $f \circ g$ is not Riemann integrable. Of course, a Freshman calculus student wont know about "measure zero" so this example is not good for an elementary course.


