Definite integral as the limit of a Riemann sum