# Riemann sums

#### Fernando Revilla

##### Well-known member
MHB Math Helper
I quote a question from Yahoo! Answers

Turn the integral to a limit of the right endpoint Reimann sum?
1dt from x to x^2
I have given a link to the topic there so the OP can see my response.

#### Fernando Revilla

##### Well-known member
MHB Math Helper
In general, consider the interval $[a,b]$, and the partition
$$a,a+1\frac{b-a}{n},a+2\frac{b-a}{n},\ldots,a+n\frac{b-a}{n}$$
Then,
$$\int_a^bf(t)dt=\lim_{n\to +\infty}\sum_{k=1}^n\frac{b-a}{n}f\left(a+k\frac{b-a}{n}\right)$$
In our case $f(t)=1$ so,
$$\int_a^bf(t)dt=\lim_{n\to +\infty}\sum_{k=1}^n\frac{b-a}{n}=\lim_{n\to +\infty} (b-a)=b-a$$
That is, $\displaystyle\int_x^{x^2}1dt=x^2-x$ (if $x<x^2$).

For $x^2-x=0$ i.e. $x=1$ or $x=0$ the integral is $0$. If $x^2<x$, use $\displaystyle\int_x^{x^2}1dt=-\displaystyle\int_{x^2}^{x}1dt$

Hence, $\displaystyle\int_x^{x^2}1dt=x^2-x$ for all $x\in\mathbb{R}$.