Mathwords logoMathwords

Riemann Integral — Definition, Formula & Examples

The Riemann integral is a way to define the definite integral of a function by partitioning an interval into subintervals, forming rectangles whose heights are sampled function values, and taking the limit of their total area as the subintervals become infinitely thin.

Let ff be a bounded function on [a,b][a,b]. The Riemann integral abf(x)dx=L\int_a^b f(x)\,dx = L exists if for every ε>0\varepsilon > 0 there exists a δ>0\delta > 0 such that for every partition PP of [a,b][a,b] with mesh P<δ\|P\| < \delta and every choice of sample points xi[xi1,xi]x_i^* \in [x_{i-1}, x_i], the Riemann sum satisfies i=1nf(xi)ΔxiL<ε\left|\sum_{i=1}^{n} f(x_i^*)\,\Delta x_i - L\right| < \varepsilon.

Key Formula

abf(x)dx=limP0i=1nf(xi)Δxi\int_a^b f(x)\,dx = \lim_{\|P\| \to 0} \sum_{i=1}^{n} f(x_i^*)\,\Delta x_i
Where:
  • a,ba, b = Lower and upper bounds of integration
  • f(x)f(x) = The function being integrated
  • Δxi\Delta x_i = Width of the i-th subinterval, equal to x_i - x_{i-1}
  • xix_i^* = A sample point chosen in the i-th subinterval
  • P\|P\| = Mesh (norm) of the partition — the width of the largest subinterval

How It Works

You divide the interval [a,b][a,b] into nn subintervals of width Δxi=xixi1\Delta x_i = x_i - x_{i-1}. In each subinterval you pick a sample point xix_i^* and compute the rectangle's area f(xi)Δxif(x_i^*)\,\Delta x_i. Summing all rectangles gives a Riemann sum Sn=i=1nf(xi)ΔxiS_n = \sum_{i=1}^{n} f(x_i^*)\,\Delta x_i, which approximates the area under the curve. If this sum converges to the same value LL regardless of how you choose the partitions and sample points (as the widest subinterval shrinks to zero), then LL is the Riemann integral of ff over [a,b][a,b].

Worked Example

Problem: Use a Riemann sum with n = 4 equal subintervals and right endpoints to approximate the Riemann integral of f(x) = x^2 on [0, 2].
Set up the partition: Divide [0, 2] into 4 equal subintervals. Each has width Δx = (2 − 0)/4 = 0.5. The right endpoints are x₁* = 0.5, x₂* = 1, x₃* = 1.5, x₄* = 2.
Δx=0.5,xi{0.5,1,1.5,2}\Delta x = 0.5, \quad x_i^* \in \{0.5,\, 1,\, 1.5,\, 2\}
Compute the Riemann sum: Evaluate f at each right endpoint and multiply by Δx.
S4=[f(0.5)+f(1)+f(1.5)+f(2)]0.5=[0.25+1+2.25+4]0.5=3.75S_4 = [f(0.5) + f(1) + f(1.5) + f(2)] \cdot 0.5 = [0.25 + 1 + 2.25 + 4] \cdot 0.5 = 3.75
Compare with exact integral: The exact Riemann integral equals the definite integral found via antidifferentiation.
02x2dx=x3302=832.6667\int_0^2 x^2\,dx = \frac{x^3}{3}\bigg|_0^2 = \frac{8}{3} \approx 2.6667
Answer: The right-endpoint Riemann sum with 4 subintervals gives 3.75, which overestimates the exact value of 8/3 ≈ 2.667. As n → ∞, the Riemann sum converges to 8/3.

Why It Matters

The Riemann integral provides the rigorous foundation for every definite integral you compute in calculus. Understanding it clarifies why certain pathological functions (like the Dirichlet function) are not integrable in the Riemann sense, motivating the study of Lebesgue integration in real analysis courses.

Common Mistakes

Mistake: Assuming every bounded function is Riemann integrable.
Correction: A bounded function on [a, b] is Riemann integrable if and only if its set of discontinuities has measure zero (Lebesgue's criterion). Functions with "too many" discontinuities, like the Dirichlet function, fail this condition.