Prove the Riemann integral $\int_{a}^{b} x^2 dx = \frac{b^3-a^3}{3}$ by using the mean value theorem 
Prove directly from the definition of Riemann sum and and integral that $$\int_{a}^{b} x^2 dx = \frac{b^3-a^3}{3}$$ Do not assume that the integral exists an use the mean value theorem to show $$\frac{b^3-a^3}{3} = \sum_{j=1}^{n} d^2_j(x_j-x_{j-1})$$

Let $P$ be a partition of $[a,b]$, $P=\{x_0,x_1, ..., x_n\}$ with some points $d_1, d_2, ...d_n$ such that $x_{j-1} \leq d_j \leq x_j$
We have $\sigma$ a Riemann sum of $f$ over a partition $P$ of $[a,b]$ 
$$\sigma = \sum_{j=1}^{n} f(d_j) (x_j - x_{j-1}) = \sum_{j=1}^{n} d^2_j (x_j - x_{j-1})$$
Since $x_{j-1} \leq dj \leq x_j$, $\frac{x_j+x_{j-1}}{2}$ is the mid point of each subinterval. We can then write that $$d_j= \frac{x_j+x_{j-1}}{2} + m_j$$ where $$|m_j| \leq \frac{x_j -x_{j-1}}{2} \leq \frac{||P||}{2}$$
Applying this to $\sigma$ and substituting $d_g$
$$\sigma=\sum_{j=1}^{n} \left[\frac{x_j+x_{j-1}}{2} + m_j\right]^2 (x_j - x_{j-1})$$
After expanding we have
$$\sigma= \sum \frac{1}{4}(x^2_j - x^2_{j-1})(x_j+x_{j-1}) + \sum m_j (x^2_j - x^2_{j-1}) +\sum m^2_j( x_j -x_{j-1})   $$
.
Given that
 $ \sum (x_j -x_{j-1}) = x_n-x_0 = b -a$ and similarly $ \sum (x^2_j -x^2_{j-1}) = b^2 -a^2$ 
We have:
$$\sigma= \frac{b^2-a^2}{4} \sum (x_j+x_{j-1}) + (b^2-a^2) \sum m_j  + (b -a)\sum m^2_j   $$
The goal should then to create an inequality using 
$$|m_j| \leq \frac{x_j -x_{j-1}}{2} \leq \frac{||P||}{2}$$
I am not so sure if I am going in the right direction. I have to admit i am a bit lost. my goal being that the integral cannot be assumed and that the mean value theorem should be applied. I dont see how the mean value theorem can be applied here. Any help is much appreciated.
 A: Consider any partition $a = x_0 < x_1 < \ldots < x_{n-1} < x_n = b$.
By the mean value theorem there is a point $d_j \in [x_{j-1},x_j]$ such that $x_j^3 - x_{j-1}^3 = 3d_j^2(x_j - x_{j-1})$.
Hence,
$$\frac{b^3}{3}- \frac{a^3}{3} = \frac{1}{3} \sum_{j=1}^n(x_j^3 - x_{j-1}^3) = \frac{1}{3} \sum_{j=1}^n3d_j^2(x_j - x_{j-1})\\ = \sum_{j=1}^nd_j^2(x_j - x_{j-1}) $$
Denoting the Riemann sum for this particular set of tags as $S(P,f,\boldsymbol d)$, we immediately have  that
$$\lim_{\|P\| \to 0} S(P,f,\boldsymbol d) = \frac{b^3 - a^3}{3}$$
To show that 
$$\int_a^b x^2 \, dx = \frac{b^3 - a^3}{3},$$
we need only show that for any $\epsilon > 0$ and any choice of tags $\boldsymbol \xi = (\xi_1, \xi_2, \ldots, \xi_n)$, if the partition mesh is sufficiently fine, then 
$$|S(P,f, \boldsymbol \xi) - S(P,f, \boldsymbol d)| = \left|\sum_{j=1}^n (\xi_j^2 - d_j^2)(x_j - x_{j-1}) \right| < \epsilon.$$
This can be shown directly or by using the fact that $x \mapsto x^2$ is uniformly continuous on $[a,b]$.
