maths2u
Tier
⌕ Search ⌘K
Theorem

The Riemann integrability criterion

T-043Home MU-201Threads space · change
Statement

Let \( a, b \in \mathbb{R} \) with \( a \lt b \), and let \( f : [a,b] \to \mathbb{R} \) be bounded. For a partition \( P : a = x_0 \lt x_1 \lt \cdots \lt x_n = b \) write \( \Delta x_i = x_i - x_{i-1} \), \( m_i = \inf\{ f(x) : x \in [x_{i-1}, x_i] \} \), \( M_i = \sup\{ f(x) : x \in [x_{i-1}, x_i] \} \), and form the lower and upper Darboux sums \( L(f,P) = \sum_{i=1}^{n} m_i \, \Delta x_i \) and \( U(f,P) = \sum_{i=1}^{n} M_i \, \Delta x_i \). Then \( f \) is Riemann (Darboux) integrable on \( [a,b] \) — that is, \( \sup_P L(f,P) = \inf_P U(f,P) \), the suprema and infima taken over all partitions of \( [a,b] \) — if and only if \[ \forall \varepsilon \gt 0 \;\; \exists \text{ a partition } P_\varepsilon \text{ of } [a,b] \text{ such that } U(f,P_\varepsilon) - L(f,P_\varepsilon) \lt \varepsilon . \]

Why it matters

The definition of the Darboux integral asks that two infinite optimisation problems — a supremum over all lower sums and an infimum over all upper sums — happen to agree. That is almost never checkable directly. The criterion replaces it with a single finitary test: exhibit, for each tolerance \( \varepsilon \), one partition on which the upper and lower staircases squeeze to within \( \varepsilon \). Nearly every integrability proof in a first analysis course — continuous functions, monotone functions, Thomae's function, products and absolute values of integrable functions — is really an application of this criterion.

Conceptually, it recasts integrability as a statement about oscillation: since \( U(f,P) - L(f,P) = \sum_i (M_i - m_i)\,\Delta x_i \), the function is integrable exactly when its total oscillation, weighted by interval length, can be made small. This is the germ of Lebesgue's later characterisation of Riemann integrability via sets of measure zero, and the reason the criterion sits at the crossroads of the space (area, measure) and change (accumulation) threads.

Hypotheses
Boundedness of \( f \) on \( [a,b] \).Take \( f(x) = 1/\sqrt{x} \) for \( x \in (0,1] \) and \( f(0) = 0 \). On the first subinterval \( [0, x_1] \) of any partition, \( \sup f = +\infty \), so \( U(f,P) \) is not a real number and the Darboux machinery collapses. Boundedness is what makes every \( m_i \) and \( M_i \) a finite real (via the completeness axiom).
The domain is a closed bounded interval \( [a,b] \).On \( [0,\infty) \) no finite partition into bounded subintervals covers the domain, so upper and lower sums are not even defined; integrals over unbounded domains must be built afterwards as improper limits, and the criterion does not apply to them directly (e.g. \( \int_0^\infty \frac{\sin x}{x}\,dx \) converges improperly but \( \frac{\sin x}{x} \) is not "integrable on \( [0,\infty) \)" in the Darboux sense).
\( f \) is real-valued (an ordered codomain).For \( f : [a,b] \to \mathbb{C} \) the quantities \( \sup f \) and \( \inf f \) are meaningless: \( \mathbb{C} \) carries no order compatible with its field structure. One must apply the criterion separately to \( \operatorname{Re} f \) and \( \operatorname{Im} f \); the theorem as stated is a theorem about \( \mathbb{R} \), resting on the least-upper-bound axiom.
Proof
1
Setup. Since \( f \) is bounded, there exist \( m, M \in \mathbb{R} \) with \( m \le f(x) \le M \) for all \( x \in [a,b] \); hence for every partition \( P \) and every \( i \), the numbers \( m_i, M_i \) exist in \( \mathbb{R} \) and satisfy \( m \le m_i \le M_i \le M \). Consequently \( L(f,P) \) and \( U(f,P) \) are well-defined reals with \( m(b-a) \le L(f,P) \le U(f,P) \le M(b-a) \).
Completeness of \( \mathbb{R} \): every nonempty set bounded above has a supremum, every nonempty set bounded below has an infimum; \( m_i \le M_i \) because \( \inf S \le \sup S \) for nonempty \( S \). A
2
Refinement Lemma. If \( P \subseteq P' \) (every point of \( P \) is a point of \( P' \)), then \[ L(f,P) \le L(f,P') \le U(f,P') \le U(f,P). \] Proof: by induction on \( \#(P' \setminus P) \) it suffices to treat \( P' = P \cup \{z\} \) with \( z \in (x_{i-1}, x_i) \) for some \( i \). Write \( m' = \inf_{[x_{i-1},z]} f \) and \( m'' = \inf_{[z,x_i]} f \). Since \( [x_{i-1},z] \subseteq [x_{i-1},x_i] \) and \( [z,x_i] \subseteq [x_{i-1},x_i] \), the infimum over the smaller set is at least the infimum over the larger: \( m_i \le m' \) and \( m_i \le m'' \). Hence \[ m_i \,\Delta x_i = m_i (z - x_{i-1}) + m_i (x_i - z) \le m'(z - x_{i-1}) + m''(x_i - z), \] and all other terms of \( L(f,P) \) and \( L(f,P') \) coincide, so \( L(f,P) \le L(f,P') \). The inequality \( U(f,P') \le U(f,P) \) is dual (suprema over subsets are at most suprema over supersets), and \( L(f,P') \le U(f,P') \) is Step 1.
Monotonicity of \( \inf \) and \( \sup \) under set inclusion: if \( \emptyset \ne A \subseteq B \) then \( \inf B \le \inf A \le \sup A \le \sup B \); finite induction on the number of inserted points. C
3
Comparison Lemma. For arbitrary partitions \( P_1, P_2 \) of \( [a,b] \), \( L(f,P_1) \le U(f,P_2) \). Consequently the lower integral \( \underline{\int_a^b} f := \sup_P L(f,P) \) and the upper integral \( \overline{\int_a^b} f := \inf_P U(f,P) \) exist as finite reals and satisfy \[ \underline{\int_a^b} f \;\le\; \overline{\int_a^b} f . \]
Apply the Refinement Lemma to the common refinement \( P^* = P_1 \cup P_2 \), which refines both: \( L(f,P_1) \le L(f,P^*) \le U(f,P^*) \le U(f,P_2) \). Then every lower sum is a lower bound for the set of upper sums, so \( \sup_P L(f,P) \le U(f,P_2) \) for each \( P_2 \), whence \( \sup_P L \le \inf_P U \); both are finite by the bounds in Step 1. B
4
(\( \Leftarrow \)) Assume: for every \( \varepsilon \gt 0 \) there is a partition \( P_\varepsilon \) with \( U(f,P_\varepsilon) - L(f,P_\varepsilon) \lt \varepsilon \). For any partition \( P \), \[ L(f,P) \;\le\; \underline{\int_a^b} f \;\le\; \overline{\int_a^b} f \;\le\; U(f,P). \]
First inequality: \( L(f,P) \) is a member of the set whose supremum is \( \underline{\int} f \). Middle inequality: Comparison Lemma (Step 3). Last inequality: \( U(f,P) \) is a member of the set whose infimum is \( \overline{\int} f \). A
5
Applying Step 4 with \( P = P_\varepsilon \): \[ 0 \;\le\; \overline{\int_a^b} f - \underline{\int_a^b} f \;\le\; U(f,P_\varepsilon) - L(f,P_\varepsilon) \;\lt\; \varepsilon . \]
Subtract the outer inequalities of Step 4: both \( \underline{\int} f \) and \( \overline{\int} f \) are trapped in the interval \( [\,L(f,P_\varepsilon),\, U(f,P_\varepsilon)\,] \), so their difference is at most the length of that interval. B
6
Since \( \varepsilon \gt 0 \) was arbitrary, \( \overline{\int_a^b} f - \underline{\int_a^b} f = 0 \), i.e. \( f \) is integrable.
A real number \( c \) with \( 0 \le c \lt \varepsilon \) for every \( \varepsilon \gt 0 \) equals \( 0 \): if \( c \gt 0 \), take \( \varepsilon = c \) for a contradiction. A
7
(\( \Rightarrow \)) Assume \( f \) integrable; write \( I = \underline{\int_a^b} f = \overline{\int_a^b} f \). Let \( \varepsilon \gt 0 \). Since \( I = \inf_P U(f,P) \), the number \( I + \tfrac{\varepsilon}{2} \) is not a lower bound for the upper sums, so \[ \exists P_1 : \quad U(f,P_1) \lt I + \tfrac{\varepsilon}{2}. \]
Approximation property of the infimum: for any \( \delta \gt 0 \) there is a member of the set within \( \delta \) above \( \inf \). A
8
Since \( I = \sup_P L(f,P) \), \[ \exists P_2 : \quad L(f,P_2) \gt I - \tfrac{\varepsilon}{2}. \]
Approximation property of the supremum, dual to Step 7. A
9
Let \( P = P_1 \cup P_2 \), the common refinement. Then \[ U(f,P) - L(f,P) \;\le\; U(f,P_1) - L(f,P_2) \;\lt\; \left( I + \tfrac{\varepsilon}{2} \right) - \left( I - \tfrac{\varepsilon}{2} \right) \;=\; \varepsilon . \] Thus \( P \) witnesses the criterion for this \( \varepsilon \), completing both directions. \( \blacksquare \)
Refinement Lemma (Step 2) applied twice: \( P \) refines \( P_1 \) so \( U(f,P) \le U(f,P_1) \), and \( P \) refines \( P_2 \) so \( L(f,P) \ge L(f,P_2) \). The common-refinement trick is the key idea: the two partitions produced by Steps 7 and 8 need not be comparable, and only their union sees both estimates at once. B
Result
\[ f \in \mathcal{R}[a,b] \iff \forall \varepsilon \gt 0 \;\, \exists P : \; U(f,P) - L(f,P) \lt \varepsilon \qquad (f \text{ bounded on } [a,b]) \]

Reading. A bounded function has a well-defined area under its graph exactly when you can sandwich that graph between two staircases — one below, one above — whose areas differ by as little as you please. You never need to check all partitions: one sufficiently clever partition per tolerance suffices.

Scope. Applies to bounded real-valued functions on a closed bounded interval \( [a,b] \subseteq \mathbb{R} \), with the Darboux formulation of the integral (equivalent to Riemann's tagged-sum formulation). It does not apply to unbounded functions or unbounded domains (improper integrals), and it characterises Riemann integrability only — Lebesgue integrability is strictly more permissive.

Corollaries & converses
  • Continuous \( \Rightarrow \) integrable. A continuous \( f \) on \( [a,b] \) is uniformly continuous (Heine–Cantor), so a partition of mesh \( \delta \) gives \( M_i - m_i \lt \varepsilon/(b-a) \) on each cell; the criterion applies.
  • Monotone \( \Rightarrow \) integrable. Worked Example 2 below — no continuity needed, and monotone functions may have countably many jumps.
  • Sequential form. \( f \in \mathcal{R}[a,b] \) iff there is a sequence of partitions \( (P_n) \) with \( U(f,P_n) - L(f,P_n) \to 0 \); then \( \int_a^b f = \lim_n U(f,P_n) = \lim_n L(f,P_n) \) (Problem 3).
  • Stability of \( \mathcal{R}[a,b] \). Via the oscillation estimate \( \sup_S |f| - \inf_S |f| \le \sup_S f - \inf_S f \) and its analogues, integrability of \( f \) (and \( g \)) yields integrability of \( |f| \), \( f^2 \), \( fg \), \( \max(f,g) \) — each proof is a one-line application of the criterion (Problem 4).
  • Converse. The theorem is a biconditional, so the converse is part of the statement. What genuinely fails is the quantifier-strengthened variant "\( U - L \lt \varepsilon \) for every partition of small mesh implies nothing new" — in fact that stronger-looking condition (Darboux's theorem on mesh) is equivalent to the criterion, but proving it requires a separate argument, not a formal consequence.
  • What the criterion does not give. It does not compute \( \int_a^b f \); it only certifies existence. Computation needs limits of specific sums or the Fundamental Theorem of Calculus.
Fails without
  • Drop boundedness. \( f(x) = 1/x \) on \( (0,1] \), \( f(0) = 0 \). For every partition, \( M_1 = \sup_{[0,x_1]} f = +\infty \), so no upper sum exists: the criterion cannot even be stated. (The improper integral \( \int_0^1 \frac{dx}{x} \) moreover diverges, so no rescue by taking limits.)
  • Bounded but oscillation everywhere: the criterion detects non-integrability. Dirichlet's function \( \chi_{\mathbb{Q}}(x) = 1 \) if \( x \in \mathbb{Q} \), \( 0 \) otherwise, on \( [0,1] \). Every subinterval of positive length contains both a rational and an irrational (density of \( \mathbb{Q} \) and of \( \mathbb{R} \setminus \mathbb{Q} \)), so \( M_i = 1 \), \( m_i = 0 \) for every cell of every partition, giving \( U - L = 1 \) always. The criterion fails at \( \varepsilon = 1 \); indeed \( \overline{\int_0^1} \chi_{\mathbb{Q}} = 1 \ne 0 = \underline{\int_0^1} \chi_{\mathbb{Q}} \).
  • Drop the closed bounded interval. On \( [0,\infty) \) there are no finite partitions into bounded cells; on an open interval \( (0,1) \) with \( f \) bounded the theory can be patched, but for \( f \) unbounded near an endpoint (e.g. \( 1/\sqrt{x} \)) only the improper theory survives, and there the "criterion" is replaced by convergence of a limit of integrals — a genuinely different condition.
Common errors
  • Quantifier flip. Writing "for all partitions \( P \), \( U(f,P) - L(f,P) \lt \varepsilon \)". The criterion demands one witness partition per \( \varepsilon \). The for-all version is false as stated (coarse partitions of an integrable function can have huge \( U - L \)).
  • Assuming \( M_i, m_i \) are attained. \( M_i \) is a supremum, not necessarily a maximum — \( f \) need not be continuous. Arguments that "pick \( t_i \) with \( f(t_i) = M_i \)" are invalid in general; use the approximation property of \( \sup \) instead.
  • Endpoint substitution. Writing \( M_i - m_i = f(x_i) - f(x_{i-1}) \). This is only legitimate for monotone increasing \( f \); in general the oscillation on a cell has nothing to do with the endpoint values.
  • Comparing incomparable partitions. In the forward direction, concluding \( U(f,P_1) - L(f,P_2) \lt \varepsilon \) and stopping. The sums belong to different partitions; one must pass to the common refinement \( P_1 \cup P_2 \) before subtracting sums of the same partition.
  • "Small \( U - L \) means \( f \) is nearly continuous." False: Thomae's function is discontinuous at every rational yet satisfies the criterion (Problem 5 territory); the criterion measures aggregate oscillation, not pointwise regularity.
  • Uniform partitions as a hidden assumption. The witness \( P_\varepsilon \) may need unequal cells (e.g. tiny cells around finitely many bad points and coarse cells elsewhere); restricting to uniform partitions can make proofs needlessly hard or impossible to finish.
Discussion

Riemann stated the essence of this criterion in his 1854 Göttingen Habilitationsschrift on trigonometric series — the integral was for him a tool to ask which functions are representable by Fourier series, and he needed a definition wide enough to admit badly discontinuous functions. Cauchy had integrated only continuous functions; Riemann's condition (total contribution of cells with oscillation above any threshold can be made small) widened the class dramatically. Darboux's 1875 reformulation via upper and lower sums, the version proved here, made the logic transparent: integrability is the statement that a single number is squeezed between two monotone families of approximations.

The right invariant hiding in the proof is the oscillation \( \omega_f(S) = \sup_S f - \inf_S f \), since \( U(f,P) - L(f,P) = \sum_i \omega_f([x_{i-1},x_i]) \, \Delta x_i \). The criterion says: \( f \) is integrable iff its oscillation, integrated against length, is negligible. Every classical integrability proof is a strategy for controlling this sum — uniform continuity makes every \( \omega_i \) small (continuous case), telescoping makes \( \sum \omega_i \) small even when individual terms are not (monotone case), and isolation of bad points makes the total length carrying large oscillation small (Thomae, piecewise continuity).

The endpoint of this line of thought is Lebesgue's 1904 criterion: a bounded \( f : [a,b] \to \mathbb{R} \) is Riemann integrable iff its set of discontinuities has Lebesgue measure zero. The bridge is the pointwise oscillation \( \omega_f(x) = \lim_{\delta \to 0^+} \omega_f\!\left( (x-\delta, x+\delta) \cap [a,b] \right) \): the sets \( D_\eta = \{ x : \omega_f(x) \ge \eta \} \) are compact, \( f \) is continuous at \( x \) iff \( \omega_f(x) = 0 \), and the Darboux criterion holds iff each \( D_\eta \) can be covered by finitely many intervals of arbitrarily small total length. Thus the criterion proved on this page is precisely the finitary, partition-level shadow of a measure-theoretic fact — and its limitation (Dirichlet's function, discontinuous everywhere, fails it) is what the Lebesgue integral was built to transcend: \( \chi_{\mathbb{Q}} \) is Lebesgue integrable with integral \( 0 \).

Common misconceptions. The criterion is an existence theorem, not an evaluation device — students often expect it to produce the value of the integral, which it never does. Second, "integrable" here means Riemann integrable; the same word in a measure-theory course means something strictly weaker to fail and strictly wider to hold. Third, the criterion's witness partition depends on \( \varepsilon \): there is no single partition that works for all tolerances unless \( f \) is a step function.

Worked examples

Example 1. Show \( f(x) = x^2 \) is integrable on \( [0,1] \), directly from the criterion.

1
Let \( \varepsilon \gt 0 \). Take the uniform partition \( P_n : x_i = \tfrac{i}{n} \), \( i = 0, 1, \dots, n \), so \( \Delta x_i = \tfrac{1}{n} \).
Any partition may be proposed; the criterion only asks us to exhibit one that works. \( f \) is bounded on \( [0,1] \) by \( 0 \le f \le 1 \), so the sums exist. A
2
\( f(x) = x^2 \) is increasing on \( [0,1] \), so on \( [x_{i-1}, x_i] \): \( m_i = x_{i-1}^2 = \tfrac{(i-1)^2}{n^2} \) and \( M_i = x_i^2 = \tfrac{i^2}{n^2} \).
For increasing \( f \), the infimum on a cell is the left endpoint value and the supremum is the right endpoint value (both attained here since \( f \) is continuous, but monotonicity alone suffices). A
3
\[ U(f,P_n) - L(f,P_n) = \sum_{i=1}^{n} \left( \frac{i^2}{n^2} - \frac{(i-1)^2}{n^2} \right) \frac{1}{n} = \frac{1}{n^3} \sum_{i=1}^{n} \left( i^2 - (i-1)^2 \right) = \frac{n^2}{n^3} = \frac{1}{n}. \]
The sum telescopes: \( \sum_{i=1}^{n} (i^2 - (i-1)^2) = n^2 - 0 \). This is the key computation — no term-by-term estimate is needed. B
4
Choose \( n \gt \tfrac{1}{\varepsilon} \) (possible by the Archimedean property). Then \( U(f,P_n) - L(f,P_n) = \tfrac{1}{n} \lt \varepsilon \), so the criterion is satisfied and \( x^2 \in \mathcal{R}[0,1] \).
Archimedean property of \( \mathbb{R} \), then the Riemann integrability criterion (this page), direction \( \Leftarrow \). A
\[ x^2 \in \mathcal{R}[0,1] \]

Reading. One telescoping identity certifies integrability. (The value then follows separately: \( \int_0^1 x^2\,dx = \lim_n U(f,P_n) = \lim_n \frac{(n+1)(2n+1)}{6n^2} = \frac{1}{3} \).)

Scope. The same telescoping argument works verbatim for \( x^2 \) on any \( [a,b] \subseteq [0,\infty) \), and with minor changes for any \( x^k \).

Example 2. Show every monotone increasing \( f : [a,b] \to \mathbb{R} \) is integrable — continuity is not assumed.

1
\( f \) is bounded: \( f(a) \le f(x) \le f(b) \) for all \( x \in [a,b] \), directly from monotonicity. If \( f(a) = f(b) \) then \( f \) is constant and trivially integrable, so assume \( f(b) \gt f(a) \).
Monotonicity supplies the boundedness hypothesis of the criterion for free; the constant case is checked directly (\( U = L \) for every partition). A
2
Let \( \varepsilon \gt 0 \) and take the uniform partition \( P_n : x_i = a + \tfrac{i}{n}(b-a) \). On each cell, \( m_i = f(x_{i-1}) \) and \( M_i = f(x_i) \).
For increasing \( f \) and \( x \in [x_{i-1}, x_i] \): \( f(x_{i-1}) \le f(x) \le f(x_i) \), and both bounds are values of \( f \) on the cell, hence are the exact inf and sup. A
3
\[ U(f,P_n) - L(f,P_n) = \sum_{i=1}^{n} \left( f(x_i) - f(x_{i-1}) \right) \frac{b-a}{n} = \frac{b-a}{n} \left( f(b) - f(a) \right). \]
Telescoping again: all cells share the same width \( \tfrac{b-a}{n} \), which factors out, and the oscillations sum exactly to the total rise \( f(b) - f(a) \). This is why monotone functions are integrable no matter how many jump discontinuities they have: the jumps compete for a fixed total budget of rise. B
4
Choose \( n \gt \tfrac{(b-a)(f(b)-f(a))}{\varepsilon} \). Then \( U(f,P_n) - L(f,P_n) \lt \varepsilon \), and the criterion gives \( f \in \mathcal{R}[a,b] \). The decreasing case follows by applying this to \( -f \).
Archimedean property, then the criterion (\( \Leftarrow \)); for \( -f \) note \( U(-f,P) = -L(f,P) \), so \( U - L \) is unchanged. A
\[ f \text{ monotone on } [a,b] \implies f \in \mathcal{R}[a,b] \]

Reading. Monotone functions are integrable even with infinitely many (necessarily countably many) jump discontinuities — total oscillation telescopes to the total rise.

Scope. Any monotone (increasing or decreasing) real function on a closed bounded interval; no continuity, no differentiability.

Problems
  1. Let \( f(x) = x \) on \( [0,1] \). Using the uniform partition \( P_n \), compute \( U(f,P_n) - L(f,P_n) \) exactly and deduce integrability from the criterion.
    Solution With \( x_i = \tfrac{i}{n} \), \( f \) is increasing, so \( m_i = \tfrac{i-1}{n} \), \( M_i = \tfrac{i}{n} \). Then \[ U(f,P_n) - L(f,P_n) = \sum_{i=1}^{n} \left( \frac{i}{n} - \frac{i-1}{n} \right)\frac{1}{n} = \sum_{i=1}^{n} \frac{1}{n^2} = \frac{1}{n}. \] Given \( \varepsilon \gt 0 \), pick \( n \gt 1/\varepsilon \) (Archimedean property); then \( U - L \lt \varepsilon \), so by the criterion \( f \in \mathcal{R}[0,1] \). (For the value: \( U(f,P_n) = \sum_{i=1}^n \frac{i}{n^2} = \frac{n+1}{2n} \to \frac{1}{2} \), so \( \int_0^1 x \, dx = \frac{1}{2} \).)
  2. Prove from the criterion that Dirichlet's function \( \chi_{\mathbb{Q}} \) on \( [0,1] \) is not Riemann integrable.
    Solution Let \( P : 0 = x_0 \lt \cdots \lt x_n = 1 \) be any partition. Each cell \( [x_{i-1}, x_i] \) has positive length, so by density of \( \mathbb{Q} \) in \( \mathbb{R} \) it contains a rational, giving \( M_i = 1 \); by density of the irrationals it contains an irrational, giving \( m_i = 0 \). Hence \[ U(\chi_{\mathbb{Q}},P) - L(\chi_{\mathbb{Q}},P) = \sum_{i=1}^{n} (1 - 0)\,\Delta x_i = 1 \] for every partition \( P \). Taking \( \varepsilon = \tfrac{1}{2} \), no partition satisfies \( U - L \lt \varepsilon \), so the criterion fails; by the theorem (contrapositive of \( \Rightarrow \) read through the biconditional), \( \chi_{\mathbb{Q}} \notin \mathcal{R}[0,1] \).
  3. (Sequential criterion.) Let \( f : [a,b] \to \mathbb{R} \) be bounded. Prove: \( f \in \mathcal{R}[a,b] \) iff there exists a sequence of partitions \( (P_n) \) with \( U(f,P_n) - L(f,P_n) \to 0 \); and in that case \( \int_a^b f = \lim_n U(f,P_n) = \lim_n L(f,P_n) \).
    Solution (\( \Rightarrow \)) If \( f \in \mathcal{R}[a,b] \), apply the criterion with \( \varepsilon = \tfrac{1}{n} \) to obtain \( P_n \) with \( 0 \le U(f,P_n) - L(f,P_n) \lt \tfrac{1}{n} \); by the squeeze theorem the difference tends to \( 0 \). (\( \Leftarrow \)) If such \( (P_n) \) exists, then given \( \varepsilon \gt 0 \) choose \( N \) with \( U(f,P_N) - L(f,P_N) \lt \varepsilon \); this \( P_N \) witnesses the criterion, so \( f \in \mathcal{R}[a,b] \). For the value: write \( I = \int_a^b f \). By Step 4 of the main proof, for every \( n \): \[ L(f,P_n) \le I \le U(f,P_n), \qquad L(f,P_n) \le U(f,P_n). \] Hence \( 0 \le U(f,P_n) - I \le U(f,P_n) - L(f,P_n) \to 0 \) and \( 0 \le I - L(f,P_n) \le U(f,P_n) - L(f,P_n) \to 0 \), so both sequences converge to \( I \) by the squeeze theorem.
  4. Prove: if \( f \in \mathcal{R}[a,b] \) then \( |f| \in \mathcal{R}[a,b] \). Show also that the converse fails.
    Solution First an oscillation identity: for nonempty \( S \subseteq [a,b] \), \[ \sup_S f - \inf_S f = \sup\{ f(x) - f(y) : x, y \in S \} \ge \sup\{ \left| |f(x)| - |f(y)| \right| : x,y \in S \} = \sup_S |f| - \inf_S |f|, \] where the middle inequality uses the reverse triangle inequality \( \left| |u| - |v| \right| \le |u - v| \) and \( |f(x)-f(y)| \le \sup_S f - \inf_S f \). (For the first equality: \( f(x) - f(y) \le \sup f - \inf f \) always, and choosing \( x \) near the sup and \( y \) near the inf via the approximation properties shows the bound is sharp.) Now let \( \varepsilon \gt 0 \). Since \( f \in \mathcal{R}[a,b] \), the criterion gives \( P \) with \( U(f,P) - L(f,P) \lt \varepsilon \). Applying the oscillation inequality on each cell, \[ U(|f|,P) - L(|f|,P) = \sum_i \left( \sup_i |f| - \inf_i |f| \right) \Delta x_i \le \sum_i \left( M_i - m_i \right) \Delta x_i \lt \varepsilon , \] so \( |f| \in \mathcal{R}[a,b] \) by the criterion. \( |f| \) is bounded since \( f \) is. Converse fails: let \( f(x) = 1 \) for \( x \in \mathbb{Q} \), \( f(x) = -1 \) otherwise, on \( [0,1] \). Then \( |f| \equiv 1 \) is integrable, but \( f = 2\chi_{\mathbb{Q}} - 1 \) is not (by Problem 2, since integrability is preserved under the affine map \( g \mapsto \tfrac{g+1}{2} \), or directly: every cell has \( M_i = 1 \), \( m_i = -1 \), so \( U - L = 2 \) for all \( P \)).
  5. Let \( f : [a,b] \to \mathbb{R} \) be bounded, with \( |f| \le K \), and continuous except at finitely many points \( c_1, \dots, c_k \). Prove \( f \in \mathcal{R}[a,b] \). You may use the Heine–Cantor theorem (a continuous function on a compact set is uniformly continuous).
    Solution Let \( \varepsilon \gt 0 \). Set \( \eta = \dfrac{\varepsilon}{8Kk} \) (if \( K = 0 \) then \( f \equiv 0 \) and we are done; assume \( K \gt 0 \)). Around each \( c_j \) place the open interval \( I_j = (c_j - \eta, c_j + \eta) \cap [a,b] \); the total length of \( \bigcup_j I_j \) is at most \( 2\eta k = \dfrac{\varepsilon}{4K} \). The set \( C = [a,b] \setminus \bigcup_j I_j \) is a finite union of closed bounded intervals \( J_1, \dots, J_r \) (removing finitely many open intervals from a closed interval leaves such a union), and \( f \) is continuous on each \( J_s \), hence uniformly continuous there by Heine–Cantor. So there is \( \delta \gt 0 \) such that for all \( s \) and all \( x, y \in J_s \) with \( |x - y| \lt \delta \), \( |f(x) - f(y)| \lt \dfrac{\varepsilon}{4(b-a)} \). Build the partition \( P \): take all endpoints of all the \( J_s \) and of the closures of the \( I_j \), then subdivide each \( J_s \) into cells of length less than \( \delta \). Every cell of \( P \) is now of one of two types. Good cells (inside some \( J_s \), length \( \lt \delta \)): here \( M_i - m_i \le \dfrac{\varepsilon}{4(b-a)} \), since for any \( x, y \) in the cell \( |f(x)-f(y)| \lt \frac{\varepsilon}{4(b-a)} \), and \( M_i - m_i = \sup_{x,y} (f(x)-f(y)) \) (approximation property of sup/inf, as in Problem 4) — note the sup of quantities bounded by \( \frac{\varepsilon}{4(b-a)} \) is at most \( \frac{\varepsilon}{4(b-a)} \). Their total contribution is \[ \sum_{\text{good}} (M_i - m_i)\,\Delta x_i \le \frac{\varepsilon}{4(b-a)} \sum_{\text{good}} \Delta x_i \le \frac{\varepsilon}{4(b-a)} (b-a) = \frac{\varepsilon}{4}. \] Bad cells (contained in the closure of some \( I_j \)): here we only know \( M_i - m_i \le 2K \), but their total length is at most \( \dfrac{\varepsilon}{4K} \), so \[ \sum_{\text{bad}} (M_i - m_i)\,\Delta x_i \le 2K \cdot \frac{\varepsilon}{4K} = \frac{\varepsilon}{2}. \] Altogether \( U(f,P) - L(f,P) \le \dfrac{\varepsilon}{4} + \dfrac{\varepsilon}{2} \lt \varepsilon \), so the criterion is satisfied and \( f \in \mathcal{R}[a,b] \). (Remark: the same two-bucket strategy — spend a length budget on bad points, an oscillation budget on the rest — proves Thomae's function integrable, with the finitely many points replaced by the finitely many rationals of small denominator.)