[motivation]
## Motivation
### The Area Problem
The oldest motivation for integration is the computation of area. The area of a rectangle with sides $a$ and $b$ is $ab$ — but what is the area of the region bounded by a curve $y = f(x)$, the $x$-axis, and the vertical lines $x = a$ and $x = b$? Archimedes answered this for parabolas using the method of exhaustion: approximate the region by inscribed and circumscribed polygons, show the two approximations converge to the same value, and declare that value to be the area. This is, in essence, the Riemann integral — the area is the [limit](/page/Limit) of sums of rectangular areas as the rectangles become infinitely thin.
### Beyond Area: Accumulation
Integration is far more than an area computation. Whenever a quantity accumulates at a varying rate, the total accumulation is an integral. If $v(t)$ is velocity, then $\int_a^b v(t) \, d\mathcal{L}^1(t)$ is displacement. If $\rho(x)$ is mass density, then $\int_U \rho(x) \, d\mathcal{L}^n(x)$ is total mass. If $f(x)$ is a probability density, then $\int_A f(x) \, d\mathcal{L}^1(x)$ is the probability of the event $A$. In each case, the integral "adds up" infinitesimal contributions to produce a finite total.
### Why Multiple Theories?
The Riemann integral — defined by partitioning the $x$-axis and summing $f(x_i^*) \Delta x_i$ — works well for continuous functions but fails for many functions that arise naturally in analysis. The characteristic function $\mathbb{1}_\mathbb{Q}$ of the rationals (equal to $1$ on $\mathbb{Q}$ and $0$ on $\mathbb{R} \setminus \mathbb{Q}$) is not Riemann integrable, because every subinterval contains both rationals and irrationals, so the upper and lower Riemann sums never agree. The pointwise limit of a [sequence](/page/Sequence) of Riemann-integrable functions need not be Riemann integrable. And the Riemann integral does not interact well with [limits](/page/Limit): there exist sequences $f_n \to f$ pointwise with $\int f_n \not\to \int f$.
The Lebesgue integral resolves all these difficulties by replacing the domain partition with a range partition: instead of asking "what is $f$ on the interval $[x_i, x_{i+1}]$?", ask "how much of the domain does $f$ map to values near $y$?" This requires measuring the "size" of sets (measure theory) but produces an integral that handles all measurable functions, supports the [Dominated Convergence Theorem](/theorems/4), and provides the foundation for probability theory, functional analysis, and PDE theory.
[/motivation]