Skip to content
homeaboutworkprojectsthesiswritingresume
Loading
~/blog/riemann-integral0%dark
  1. home/
  2. writing/
  3. The Riemann Integral

16 June 2026 · 6 min read · updated 09 June 2026

The Riemann Integral

The Riemann integral defines area as the common value of over and under estimates when they can be made to agree. We build upper and lower sums, prove the Riemann criterion that a function is integrable exactly when the gap between them can be made arbitrarily small, prove every continuous function on a closed interval is integrable through uniform continuity, and prove the two halves of the fundamental theorem of calculus, that integration and differentiation invert one another. This is the integral the mean-square and Stieltjes constructions refine.

  • 3 equations
  • 9 results
  • 8 connections
  • real-analysis
  • integration
  • calculus
On this page▾
  • Upper and lower sums
  • The Riemann criterion
  • Continuous functions are integrable
  • The fundamental theorem of calculus

6 min left

  • Upper and lower sums1m
  • The Riemann criterion1m
  • Continuous functions are integrable2m
  • The fundamental theorem of calculus2m

The integral assigns an area under a graph, and the Riemann construction does it by trapping the area between sums that overestimate and sums that underestimate, calling the function integrable when the two can be brought together. The construction rests on the completeness of the reals through the supremum and on uniform continuity to control the gap, and it culminates in the fundamental theorem of calculus, which makes the integral the inverse of the derivative. This post builds it for bounded functions on a closed interval [1], [2].

#Upper and lower sums

Definition1

A partition of [a,b][a,b][a,b] is a finite set a=t0<t1<⋯<tm=ba=t_0<t_1<\cdots<t_m=ba=t0​<t1​<⋯<tm​=b. For a bounded fff, the lower and upper sums are

L(f,P)=∑i=1m(inf⁡[ti−1,ti]f)(ti−ti−1),U(f,P)=∑i=1m(sup⁡[ti−1,ti]f)(ti−ti−1).(1)L(f,P)=\sum_{i=1}^m\Big(\inf_{[t_{i-1},t_i]}f\Big)(t_i-t_{i-1}),\qquad U(f,P)=\sum_{i=1}^m\Big(\sup_{[t_{i-1} ,t_i]}f\Big)(t_i-t_{i-1}). \tag{1}L(f,P)=i=1∑m​([ti−1​,ti​]inf​f)(ti​−ti−1​),U(f,P)=i=1∑m​([ti−1​,ti​]sup​f)(ti​−ti−1​).(1)

The lower integral is ∫‾f=sup⁡PL(f,P)\underline{\int}f=\sup_P L(f,P)∫​f=supP​L(f,P) and the upper integral is ∫‾f=inf⁡PU(f,P)\overline{\int}f =\inf_P U(f,P)∫​f=infP​U(f,P). The function is Riemann integrable when these are equal, their common value the integral ∫abf\int_a^b f∫ab​f.

Refining a partition by inserting points raises lower sums and lowers upper sums, because splitting a subinterval replaces one infimum by two larger ones and one supremum by two smaller ones. Consequently any lower sum is at most any upper sum, since both are comparable to their common refinement, and so ∫‾f≤∫‾f\underline{\int}f\le\overline{\int}f∫​f≤∫​f always. Integrability is the statement that no gap remains.

#The Riemann criterion

The definition asks a supremum and infimum to coincide. The criterion restates this as a single approximation that is easier to verify.

Theorem2

A bounded fff is Riemann integrable on [a,b][a,b][a,b] if and only if for every ε>0\varepsilon>0ε>0 there is a partition PPP with U(f,P)−L(f,P)<εU(f,P)-L(f,P)<\varepsilonU(f,P)−L(f,P)<ε.

Proof

Suppose the gap can be made small. For any ε\varepsilonε pick PPP with U(f,P)−L(f,P)<εU(f,P)-L(f,P)<\varepsilonU(f,P)−L(f,P)<ε. Then ∫‾f−∫‾f≤U(f,P)−L(f,P)<ε\overline{\int}f-\underline{\int}f\le U(f,P)-L(f,P)<\varepsilon∫​f−∫​f≤U(f,P)−L(f,P)<ε, using ∫‾f≥L(f,P)\underline{\int}f\ge L(f,P)∫​f≥L(f,P) and ∫‾f≤U(f,P)\overline{\int}f\le U(f,P)∫​f≤U(f,P). Since this holds for every ε\varepsilonε, the nonnegative difference ∫‾f−∫‾f\overline{\int}f-\underline{\int}f∫​f−∫​f is zero, so fff is integrable. Conversely, suppose fff is integrable with ∫‾f=∫‾f=I\underline{\int}f=\overline{\int}f=I∫​f=∫​f=I. Given ε\varepsilonε, the supremum defining ∫‾f\underline{\int}f∫​f gives a partition P1P_1P1​ with L(f,P1)>I−ε/2L(f,P_1)>I-\varepsilon/2L(f,P1​)>I−ε/2, and the infimum gives P2P_2P2​ with U(f,P2)<I+ε/2U(f,P_2)<I+ \varepsilon/2U(f,P2​)<I+ε/2. Their common refinement PPP satisfies L(f,P)≥L(f,P1)L(f,P)\ge L(f,P_1)L(f,P)≥L(f,P1​) and U(f,P)≤U(f,P2)U(f,P)\le U(f,P_2)U(f,P)≤U(f,P2​) by the refinement monotonicity, so U(f,P)−L(f,P)<(I+ε/2)−(I−ε/2)=εU(f,P)-L(f,P)<(I+\varepsilon/2)-(I-\varepsilon/2)=\varepsilonU(f,P)−L(f,P)<(I+ε/2)−(I−ε/2)=ε.

The criterion reduces integrability to making the total oscillation of fff, summed against the subinterval lengths, as small as desired. Continuity makes this automatic.

#Continuous functions are integrable

Theorem3

Every continuous function on [a,b][a,b][a,b] is Riemann integrable.

Proof

Let ε>0\varepsilon>0ε>0. By the Heine-Cantor theorem fff is uniformly continuous on [a,b][a,b][a,b], so there is a δ>0\delta>0δ>0 with ∣f(s)−f(t)∣<ε/(b−a)\abs{f(s)-f(t)}<\varepsilon/(b-a)∣f(s)−f(t)∣<ε/(b−a) whenever ∣s−t∣<δ\abs{s-t}<\delta∣s−t∣<δ. Take any partition PPP with every subinterval shorter than δ\deltaδ. On each subinterval the extreme value theorem makes the supremum and infimum of fff attained values f(si)f(s_i)f(si​) and f(ui)f(u_i)f(ui​) at points of the subinterval, so ∣si−ui∣\abs{s_i-u_i}∣si​−ui​∣ is below the subinterval length and hence below δ\deltaδ, and the oscillation sup⁡−inf⁡=f(si)−f(ui)<ε/(b−a)\sup-\inf=f(s_i)-f(u_i)< \varepsilon/(b-a)sup−inf=f(si​)−f(ui​)<ε/(b−a). Summing,

U(f,P)−L(f,P)=∑i=1m(sup⁡[ti−1,ti]f−inf⁡[ti−1,ti]f)(ti−ti−1)<εb−a∑i=1m(ti−ti−1)=ε.(2)U(f,P)-L(f,P)=\sum_{i=1}^m\big(\textstyle\sup_{[t_{i-1},t_i]}f-\inf_{[t_{i-1},t_i]}f\big)(t_i-t_{i-1}) <\frac{\varepsilon}{b-a}\sum_{i=1}^m(t_i-t_{i-1})=\varepsilon. \tag{2}U(f,P)−L(f,P)=i=1∑m​(sup[ti−1​,ti​]​f−inf[ti−1​,ti​]​f)(ti​−ti−1​)<b−aε​∑i=1m​(ti​−ti−1​)=ε.(2)

By Theorem 2, fff is integrable.

The integral so constructed is monotone, in the sense that f≤gf\le gf≤g gives ∫f≤∫g\int f\le\int g∫f≤∫g, and additive over adjacent intervals, both read off the corresponding statements for the sums, since inf⁡\infinf and sup⁡\supsup are monotone and a partition containing the split point decomposes LLL and UUU additively. Linearity needs more, because inf⁡\infinf and sup⁡\supsup are only super- and subadditive, giving L(f,P)+L(g,P)≤L(f+g,P)L(f,P)+L(g,P)\le L(f+g,P)L(f,P)+L(g,P)≤L(f+g,P) and U(f+g,P)≤U(f,P)+U(g,P)U(f+g,P)\le U(f,P)+U(g,P)U(f+g,P)≤U(f,P)+U(g,P). Given ε>0\varepsilon>0ε>0, pick partitions with U(f,Pf)−L(f,Pf)<ε/2U(f,P_f)-L(f,P_f)<\varepsilon/2U(f,Pf​)−L(f,Pf​)<ε/2 and U(g,Pg)−L(g,Pg)<ε/2U(g,P_g)-L(g,P_g)<\varepsilon/2U(g,Pg​)−L(g,Pg​)<ε/2 and let P=Pf∪PgP=P_f\cup P_gP=Pf​∪Pg​ be their common refinement, which preserves both gaps. Then U(f+g,P)−L(f+g,P)≤(U(f,P)+U(g,P))−(L(f,P)+L(g,P))<εU(f+g,P)-L(f+g,P)\le(U(f,P)+U(g,P))-(L(f,P)+L(g,P))<\varepsilonU(f+g,P)−L(f+g,P)≤(U(f,P)+U(g,P))−(L(f,P)+L(g,P))<ε, so f+gf+gf+g is integrable by Theorem 2; since both ∫(f+g)\int(f+g)∫(f+g) and ∫f+∫g\int f+\int g∫f+∫g lie in [L(f,P)+L(g,P), U(f,P)+U(g,P)][L(f,P)+L(g,P),\,U(f,P)+U(g,P)][L(f,P)+L(g,P),U(f,P)+U(g,P)], of width <ε<\varepsilon<ε, letting ε→0\varepsilon\to0ε→0 gives ∫(f+g)=∫f+∫g\int(f+g)=\int f+\int g∫(f+g)=∫f+∫g, and ∫(cf)=c∫f\int(cf)=c\int f∫(cf)=c∫f follows from inf⁡(cf)=cinf⁡f\inf(cf)=c\inf finf(cf)=cinff for c≥0c\ge0c≥0 and the sup⁡\supsup/inf⁡\infinf swap for c<0c<0c<0. With existence settled for continuous functions, the integral becomes a function of its upper limit, and that function is differentiable.

#The fundamental theorem of calculus

Theorem4

Let fff be continuous on [a,b][a,b][a,b] and F(x)=∫axf(t) dtF(x)=\int_a^x f(t)\,dtF(x)=∫ax​f(t)dt. Then FFF is differentiable with F′(x)=f(x)F'(x)=f(x)F′(x)=f(x).

Proof

Fix xxx and h≠0h\neq 0h=0 small. By additivity, F(x+h)−F(x)=∫xx+hf(t) dtF(x+h)-F(x)=\int_x^{x+h}f(t)\,dtF(x+h)−F(x)=∫xx+h​f(t)dt under the orientation convention ∫xx+h=−∫x+hx\int_x^{x+h}=-\int_{x+h}^x∫xx+h​=−∫x+hx​ for h<0h<0h<0, so

F(x+h)−F(x)h−f(x)=1h∫xx+h(f(t)−f(x)) dt.(3)\frac{F(x+h)-F(x)}{h}-f(x)=\frac1h\int_x^{x+h}\big(f(t)-f(x)\big)\,dt. \tag{3}hF(x+h)−F(x)​−f(x)=h1​∫xx+h​(f(t)−f(x))dt.(3)

Given ε>0\varepsilon>0ε>0, continuity at xxx provides δ\deltaδ with ∣f(t)−f(x)∣<ε\abs{f(t)-f(x)}<\varepsilon∣f(t)−f(x)∣<ε for ∣t−x∣<δ\abs{t-x}<\delta∣t−x∣<δ. For ∣h∣<δ\abs h<\delta∣h∣<δ monotonicity applied to −ε≤f(t)−f(x)≤ε-\varepsilon\le f(t)-f(x)\le\varepsilon−ε≤f(t)−f(x)≤ε over the interval of integration bounds the integral by ε∣h∣\varepsilon\abs hε∣h∣ in absolute value. When h>0h>0h>0 this is ∣∫xx+h(f(t)−f(x)) dt∣≤εh\abs{\int_x^{x+h}(f(t)-f(x))\,dt}\le\varepsilon h​∫xx+h​(f(t)−f(x))dt​≤εh on [x,x+h][x,x+h][x,x+h]; when h<0h<0h<0 the same estimate on [x+h,x][x+h,x][x+h,x] gives ∣∫x+hx(f(t)−f(x)) dt∣≤ε∣h∣\abs{\int_{x+h}^x(f(t)-f(x))\,dt}\le\varepsilon\abs h​∫x+hx​(f(t)−f(x))dt​≤ε∣h∣, and 1h∫xx+h=1∣h∣∫x+hx\frac1h\int_x^{x+h}=\frac1{\abs h}\int_{x+h}^xh1​∫xx+h​=∣h∣1​∫x+hx​ matches it. Either way the right side of Equation (3) has absolute value at most 1∣h∣ ε ∣h∣=ε\frac1{\abs h}\,\varepsilon\,\abs h=\varepsilon∣h∣1​ε∣h∣=ε. Hence the difference quotient tends to f(x)f(x)f(x), which is F′(x)=f(x)F'(x)=f(x)F′(x)=f(x).

Theorem5

If fff is continuous on [a,b][a,b][a,b] and GGG is any antiderivative of fff, meaning G′=fG'=fG′=f, then ∫abf=G(b)−G(a)\int_a^b f=G(b) -G(a)∫ab​f=G(b)−G(a).

Proof

Let F(x)=∫axfF(x)=\int_a^x fF(x)=∫ax​f. By Theorem 4, F′=f=G′F'=f=G'F′=f=G′, so (F−G)′=0(F-G)'=0(F−G)′=0 on [a,b][a,b][a,b], and a function with zero derivative on an interval is constant by the mean value theorem. Thus F−G=cF-G=cF−G=c for a constant ccc. Evaluating at aaa, where F(a)=0F(a)=0F(a)=0, gives c=−G(a)c=-G(a)c=−G(a), and at bbb, ∫abf=F(b)=G(b)+c=G(b)−G(a)\int_a^b f=F(b)=G(b)+c=G(b)-G(a)∫ab​f=F(b)=G(b)+c=G(b)−G(a).

The two halves together say differentiation and integration undo each other, the antiderivative computing the integral and the integral recovering the function. This is the computational engine of calculus, and it is also the structural statement that the integral of a continuous function is a continuously differentiable function of its limits. The Riemann integral is enough for continuous integrands and for the Stieltjes and mean-square integrals built on the same partition idea, while integrands with worse discontinuities require the Lebesgue integral, which replaces partitions of the domain by partitions of the range and integrates a far larger class.

[1]
W. Rudin, Principles of Mathematical Analysis, 3rd ed. McGraw-Hill, 1976.
[2]
S. Abbott, Understanding Analysis, 2nd ed. Springer, 2015.

Part 5 of 6 in Real Analysis

← previousDifferentiation and Taylor's Theoremnext →Series and Power Series

Explore connections

see in the atlas →

related

  • Continuity and Limits of Functions
  • Holomorphic Functions and Cauchy's Theorem
  • Sequences and Completeness

referenced by (1)

  • Holomorphic Functions and Cauchy's Theorem
cite
@misc{riemann-integral,
  author = {Zac Kienzle},
  title  = {The Riemann Integral},
  year   = {2026},
  month  = {06},
  url    = {https://zackienzle.com/blog/riemann-integral}
}