Show that if $f$ is continuous on $[a,b]$, then there is a Riemann sum that equals the integral Specifically, I mean a Riemann sum of $f$ over $[a,b]$ that is equal to $\int_a^b f$.
I encountered this question on my analysis exam, but I was unable to answer it. I thought it was an interesting result, so I tried to find a proof when I returned home. To my surprise, I was unable to find one. How would one go about proving this? I am honestly completely stumped.
 A: Note that you can simplify the other answers given.  Apply the mean value theorem to $g(t)=\int_a^t f(x) \, dx$.  Then there exists $c\in (a, b)$ such that $f(c) = \frac{g(b)-g(a)}{b-a} = \frac{\int_a^b f \, dx}{b-a}$.  Multiply both sides by $b-a$ to get $\int_a^b f=f(c)(b-a)$, and you have a Riemann sum with the trivial partition. 
A: Actually this comes up in one of the proofs of the Fundamental Theorem of Calculus.  The way one proves that $F(b) - F(a) = \int_a^b f$ is to show that no matter what partition is chosen, there is always a "tagging" (i.e., a choice of a sample point in each subinterval) such that the corresponding Riemann sum is exactly equal to $F(b) - F(a)$.
My hint for this is to apply the Mean Value Theorem (to $F$) on each subinterval.  Does that help?
(In fact in this result the continuity of $f$ can be weakened to: $f$ is Riemann integrable and has an antiderivative $F$.  That is a subtle advantage of this approach to the FTC.  An equivalent -- and slightly less confusing -- statement of this can be found in $\S$ 8.3.3 of these notes.  Note though that at that point in the notes only upper and lower sums have been introduced, not Riemann sums.  That makes the argument very slightly more complicated and noticeably less elegant: we get that $F(b)-F(a)$ lies in between all the lower and upper sums rather than being on the nose equal to a Riemann sum.)
A: $\int_{a}^{b}f(x)dx=\sum_{k=0}^{n-1}\int_{a+k(\frac{b-a}{n})}^{a+(k+1)(\frac{b-a}{n})}f(x)dx$
By the mean value theorem of integration applied $n$-times (since $f$ is continuous) we have that the above is equal to:
$=\sum_{k=0}^{n-1}f(c_{k})\big(\frac{b-a}{n}\big)$
for $c_{k}\in(a+k(\frac{b-a}{n}),a+(k+1)(\frac{b-a}{n}))$. This last expression is a Riemann sum.
