Approximation of a Riemann integrable function w continuous function in the L2 metric
Let f be a function that is Riemann integrable. Prove there exists a piece-wise linear continuous function g such that
. The given hint was construct g with a suitable partition of [b,a]. Given
define
when 
Here is what I have so far.
So on an interval [
] either
or  f(x_{i+1})\le g(t) \le f(x_i))
So for a given partition P
, Let
be the sup and
be the inf of the interval
.
Let h = |f-g| , for an arbitrary partition resulting from integrating f, let
be the sup for the function h over the interval
. Now
.
is the sup and
is the inf of f over the interval
.
is the sup and
the inf of g over the interval
. Now
combined with
and
Because f is Riemann integrable
: \cdot\Delta x_i < \epsilon)
Let )
Once again because f is Riemann integrable
:
where )
Let
. Construct the function g out of the partition P in piece-wise linear manner as decribed above. Let N be the number of points in P, it has at most has n + (n' -2) points and
in the partition
.
Let B
, let
be such a number that
and 
\cdot\Delta x_i < \epsilon '\cdot\Delta\tilde{x} )
Therefore 

partitions P of [a,b].
is the upper sum of the partition.

 \le (\frac{\epsilon}{\sqrt (b-a)})^2 \cdot (b-a) = \frac{{\epsilon}^2}{b-a}\cdot (b-a) = {\epsilon}^2)
 < \epsilon)
Please let me know where I went wrong or if this whole approach is wrong.
can someone let me know of any good readings about Lp spaces and motivation for the Lp metric's construction.