Consider a function f(x) and some interval a ≤ x ≤ b. To approximate the area underneath the graph of f(x) over this interval, start by forming a partition of [a,b] into n segments. That is choose points \{x1, x2, ..., xn-1\} such that a = x0 < x1 < ... < xn-1 < xn = b. Then, construct a rectangle for each segment [xj, xj+1] such that the side of the rectangle opposite this segment intersects the graph of f(x). The sum of the areas of this sequence of n rectangles is called a Riemann sum.