Riemann Integration
Recall prompts
Section titled “Recall prompts”Attempt these from memory before reading.
- Define the upper and lower sums of a bounded function with respect to a partition.
- What does it mean for to be Riemann integrable?
- Is every continuous function on Riemann integrable?
- Is Dirichlet’s function Riemann integrable on ? Why not?
- State the two parts of the fundamental theorem of calculus.
Check your answers against the text. The Dirichlet question is the one that motivates everything in measure theory.
Motivation: what does “area” mean, precisely?
Section titled “Motivation: what does “area” mean, precisely?”Everyone knows the area of a rectangle. The Riemann integral is the attempt to extend that to curved regions by slicing into rectangles and taking a limit.
The definition has to be careful about which rectangles, and it is here that the subject makes its first real demand. There are two obvious approaches: approximate from above with rectangles that contain the region, or from below with rectangles contained in it. If the two agree, that common value is the integral. If they do not, the region has no area in this sense — and finding out which functions are integrable turns out to be the interesting question.
That question is answered by the Lebesgue criterion: a bounded function on is Riemann integrable exactly when its discontinuities form a set of measure zero. The criterion is the bridge to measure theory, and it explains the counterexamples on this page in one line.
6.1 Definition
Section titled “6.1 Definition”Let be bounded. A partition of is a finite set with .
The upper sum and lower sum of with respect to are:
Where , And .
The mesh of is .
Definition. is Riemann integrable on if the upper and lower integrals are equal:
Where and .
The common value is denoted .
6.2 Integrability Criteria
Section titled “6.2 Integrability Criteria”Theorem 6.1 (Riemann Integrability Criterion). A bounded function is Riemann integrable if and only if for every There exists a partition such that
Theorem 6.2. Every continuous function on is Riemann integrable.
Proof. Let be continuous on . By the Heine-Cantor theorem, is uniformly continuous. Given Choose such that implies .
Let be any partition with . On each subinterval By the Extreme Value Theorem, attains its maximum and minimum . By uniform continuity: . Therefore:
By the Riemann integrability criterion, is integrable.
Theorem 6.3. Every monotone function on is Riemann integrable.
Proof. Assume is increasing (the decreasing case is analogous). Given Let be the uniform partition with subintervals of length . On : and . Then:
Choose large enough that .
Theorem 6.4. A bounded function with finitely many discontinuities on is Riemann integrable.
Proof (sketch). Let have discontinuities at . Given Enclose each in a small interval of total length Where . On the remaining set (a finite union of closed intervals), is continuous, Hence uniformly continuous. Choose a partition fine enough that the oscillation of on each Subinterval outside the is less than . Then:
Proposition 6.4a. The set of Riemann integrable functions on forms a vector space, and If and are integrable, then so are , And .
Theorem 6.4b (Lebesgue’s Criterion for Riemann Integrability). A bounded function Is Riemann integrable if and only if the set of its discontinuities has (Lebesgue) measure zero.
Remark. A set has measure zero if it can be covered by countably many intervals of arbitrarily Small total length. In particular, every countable set has measure zero. This means:
- Every continuous function is integrable (empty set of discontinuities).
- Every function with countably many discontinuities is integrable (Theorem 6.4 is a special case).
- The Dirichlet function for and for is discontinuous everywhere (set of discontinuities = Measure ), hence not integrable.
- Thomae’s function if in lowest terms, and if is irrational, is continuous at every irrational and discontinuous at every rational. Since is countable (measure zero), Thomae’s function is Riemann integrable, with .
6.3 Properties of the Integral
Section titled “6.3 Properties of the Integral”Theorem 6.5 (Linearity). If and are integrable on and :
Theorem 6.6 (Monotonicity). If for all Then .
Theorem 6.7 (Triangle Inequality). .
6.4 The Fundamental Theorem of Calculus
Section titled “6.4 The Fundamental Theorem of Calculus”Theorem 6.8 (FTC Part 1). If is continuous on Then the function
Is differentiable on and .
Proof. Let (the case is similar). By the Mean Value Theorem for Integrals (which follows from the EVT), there exists such that
As We have (since ). By continuity of . Hence . A similar argument gives .
Theorem 6.9 (FTC Part 2). If is differentiable on with (and is integrable), Then
Proof. Let be any partition of . By the Mean Value Theorem, For each there exists with . Summing:
The right-hand side is a Riemann sum for . As This converges to the Integral. Hence .
6.5 Worked Examples
Section titled “6.5 Worked Examples”Problem. Compute from the definition.
Solution. Let . On , Has and .
As : .
Similarly, . So .
Worked Example: Compute $\int_0^1 \sqrt{x}\, dx$ from the definition
Solution. Let . On , has and .
Using (obtained from comparing with ):
Similarly Confirming .
6.6 Improper Integrals
Section titled “6.6 Improper Integrals”Definition. An improper integral is a Riemann integral where either the interval of integration Is unbounded or the integrand is unbounded.
Type I (Infinite Intervals). If is Riemann integrable on for every Define:
The integral converges if this limit exists as a finite number; otherwise it diverges.
Type II (Unbounded Integrands). If is unbounded near but integrable on for every :
Theorem 6.10 (Comparison Test for Improper Integrals). If for :
- If converges, then converges.
- If diverges, then diverges.
Theorem 6.11 (Absolute Convergence). If converges, then converges.
Theorem 6.12 (-Test for Improper Integrals).
- Type I: converges if and only if .
- Type II: converges if and only if .
Proof. For Type I with :
This converges when I.e., . For : .
For Type II: . This converges when I.e., .
Remark. The -test for Type I integrals mirrors the -series test: converges Iff . This is not a coincidence --- the integral test establishes the connection.
Worked Example: Evaluate $\int_0^{\infty} e^{-x}\, dx$
Solution. This is a Type I improper integral:
So the integral converges to .
Worked Example: Does $\int_1^{\infty} \frac{\sin x}{x}\, dx$ converge?
Solution. The integral diverges (compare with , which diverges by comparison with the harmonic series).
However, converges by Dirichlet’s test for integrals. Let Which is bounded by . Since decreases to By integration by parts:
As The boundary term and , so the improper integral converges (conditionally).
Worked Example: Evaluate $\int_0^1 \frac{1}{\sqrt{x}}\, dx$ (Type II improper integral)
Solution. The integrand is unbounded as . Compute:
The improper integral converges to . Note that converges for and Diverges for .
Worked Example: Determine convergence of $\int_1^{\infty} \frac{1}{x^p}\, dx$ for various $p$
Solution. By the -test (Theorem 6.12): converges iff .
Specifically:
- : . Converges.
- : . Diverges.
- : . Diverges.
This mirrors the -series test: converges iff .
Worked Example: Evaluate $\int_0^{\infty} x e^{-x}\, dx$
Solution. This integral requires both a Type I and Type II limit:
Integrate by parts with , So , :
Evaluating: .
So . This equals .
Counterexamples worth knowing by name
Section titled “Counterexamples worth knowing by name”| Function | Bounded? | Riemann integrable on ? | Why |
|---|---|---|---|
| yes | yes | continuous | |
| (Dirichlet) | yes | no | discontinuous everywhere |
| (Thomae) | yes | yes, integral | discontinuous only on , which has measure zero |
| no | improper only | unbounded at | |
| yes | yes | one discontinuity |
Why Dirichlet fails and Thomae succeeds. Every upper sum for Dirichlet’s function is (every interval contains a rational) and every lower sum is (every interval contains an irrational), so the upper and lower integrals differ by . For Thomae, the discontinuities are the rationals — countable, hence of measure zero — so the upper and lower sums converge to the same value.
That is the Lebesgue criterion in action, and it is the reason the Riemann integral had to be replaced. A function that is on a dense set and on another dense set ought to have integral if the first set is small, and Riemann’s integral cannot say so.
The improper integral is a different object. even though is unbounded. The “integral” there is defined as a limit of proper integrals, not as an upper/lower sum, and the two notions agree only when the proper integral exists.
Interleaving problems
Section titled “Interleaving problems”Mix these with material from Sequences and Limits, Continuity and Measure Theory.
- (Sequences.) Show that is integrable by computing the upper and lower sums for the uniform partition and taking the limit.
- (Continuity.) Show that a continuous function on is uniformly continuous, and use that to prove it is Riemann integrable.
- (Measure theory.) Show that a countable set has measure zero, and deduce that a bounded function with finitely many discontinuities is integrable.
- (Measure theory.) Show Thomae’s function and Dirichlet’s function have the same set of discontinuities as each other’s complement, and explain why one is integrable and the other is not.
- (Probability.) Let be uniform on . Show that , and explain why Dirichlet’s function is Riemann integrable in the Lebesgue sense with integral .
6.7 Common Mistakes
Section titled “6.7 Common Mistakes”Mistake 1: Confusing Riemann integrability with Lebesgue integrability Every Riemann integrable function is Lebesgue integrable, but not vice versa. The Dirichlet function is not Riemann integrable but is Lebesgue integrable (with integral zero). The Riemann integral requires the set of discontinuities to have measure zero, while the Lebesgue integral handles a much broader class of functions.
Mistake 2: Interchanging limits and integrals without justification Swapping and requires a convergence theorem such as the dominated convergence theorem or the monotone convergence theorem. Pointwise convergence alone is insufficient: the sequence converges pointwise to on , yet for all . Always verify the hypotheses of a convergence theorem before interchanging limits and integrals.
Mistake 3: Applying the Fundamental Theorem of Calculus to discontinuous integrands The FTC Part 1 requires to be continuous. If has a jump discontinuity, the integral function is continuous but not differentiable at the discontinuity. The FTC Part 2 requires everywhere on , which fails if is discontinuous. Check continuity before applying the FTC.
Intuition
Section titled “Intuition”The Riemann integral answers the question: how do we add up infinitely many infinitely thin slices? Consider the area under a curve f(x) from a to b. The Riemann sum approximates this by dividing the interval into subintervals and summing f(x) times the width of each subinterval — a collection of rectangles whose total area approaches the true area as the partition becomes finer. This is the same logic as computing distance by summing velocity over time, or charge by summing current over time: the integral accumulates a quantity that varies continuously.
The Fundamental Theorem of Calculus reveals the deep connection between accumulation (integration) and rate of change (differentiation). If F(x) represents the accumulated area from a to x, then F’(x) = f(x): the rate at which area accumulates is exactly the height of the curve. Conversely, integrating a rate function recovers the total change. This duality is why the FTC is the most important theorem in calculus: it converts the hard problem of computing areas into the easy problem of finding antiderivatives. The improper integral extends this to infinite intervals or unbounded functions by taking limits, but the core intuition — accumulation of slices — remains the same.