How to calculate $\int_a^b \frac{1}{x^2} dx$ by the definition of Riemann integral. ($0<a<b$) How to calculate $\int_a^b \frac{1}{x^2} dx$ by the definition of Riemann integral. ($0&lt;a&lt;b$)


I have tried to let $x_k=a+\frac{(b-a)}{n}k$. However, I have no idea to deal with the denominator in the following expression:
$$
\sum_{k=1}^n\frac{b-a}{n}\cdot\left(\frac{1}{a+\frac{b-a}{n}k}\right)^2
$$
I expanded the quadratic term, but it seems become more difficult.
Using the end points for the Riemann sum is not a very good idea as you have observed the difficulty. 

Instead, let $x_k^*$ be the geometric mean of $x_{k-1}$ and $x_k$, that is $x_k^*=\sqrt{x_{k-1}x_k}$. Then the Riemann sum becomes
$$
R_n=\sum_{k=1}^n\frac{b-a}{n}\frac{1}{(x_k^*)^2}
=\sum_{k=1}^n\frac{b-a}{n}\frac{1}{x_{k-1}x_k}.
$$
Now observe that 
$$
\begin{align}
\frac{1}{x_{k-1}x_k}&amp;=\frac{1}{(a+h_nk-h_n)\cdot(a+h_nk)}\\
&amp;=\left(\frac{1}{a+h_nk-h_n}-\frac{1}{a+h_nk}\right)\frac{n}{b-a},\quad h_n:=\frac{b-a}{n}.
\end{align}
$$
So
$$
R_n=\sum_{k=1}^n\left(\frac{1}{a+h_n(k-1)}-\frac{1}{a+h_nk}\right)
=\frac{1}{a}-\frac{1}{a+h_nn}.
$$
Now the limit $\lim_{n\to\infty}R_n$ should be easy.
Divide the interval from $a$ to $b$ into $n$ pieces.  Each piece will have length $(b-a)/n$.  Let $x_k^*$ be a point in the $k$th interval.  We approximate the value all across each interval by its value at $x_k^*$, $\frac{1}{x_k^*}$ so approximate the "area under the curve" by the area $\frac{1}{x_k^{*2}}(b-a)/n$.

The area under the curve from $a$ to $b$ is approximated by the sum
$\sum_{k=1}^n \frac{1}{x_k^{*2}}(b- a)/n= \frac{b-a}{n}\sum_{k=1} 
\frac{1}{x_k^{*2}}$.

We can, in particular, take $x_k^*$ to be the right hand endpoint of each interval, $k(b-a)/n$, so the Riemann sum is $\frac{b-a}{n}\sum_{k=1}^n \frac{1}{k^2(b-a)^2/n^2}= \frac{n}{b-a}\sum_{k=1}^n \frac{1}{k^2}$  

Now, can you find a "closed form" for $\sum_{k=1}^n \frac{1}{k^2}$?