# Measurable Functions, Preimages and Image Measures

Functions whose level sets can be measured: preimages, the half-line test, closure under limits, simple functions, σ(f) and the image measure.

"Lebesgue measure and null sets" built length for every Borel set, and "σ-algebras and Borel sets" explained which sets may be measured at all: the sets of a chosen σ-algebra, the events one can answer questions about. So far the objects being measured have been sets. But most of what one wants to know about a space is described by functions on it: a score, a temperature, a position. A function has no length. What can be measured is how much of the space the function sends into a given range of values, the length of $\{x : f(x) \in B\}$. This lesson asks which functions allow that question to be answered for every Borel set $B$, calls them **measurable**, and shows that nearly every function met in practice is one. It then introduces two tools that the following lessons build on: **simple functions**, which approximate any measurable function from below, and **image measures**, which record where a measure ends up after a function has moved its points.

## Preimages

Take the function $f(x) = x^2$ on $[0, 1]$, with length as the measure. How much of $[0, 1]$ is sent into the range of values from $0.25$ to $0.64$? Since $x^2 \ge 0.25$ exactly when $x \ge 0.5$, and $x^2 \le 0.64$ exactly when $x \le 0.8$, the answer is the interval $[0.5, 0.8]$, which has length $0.3$. The set of points whose value falls in a given set $B$ is called the **preimage** of $B$:

$$
f^{-1}(B) = \{\omega \in \Omega : f(\omega) \in B\}.
$$

Here $\Omega$ is the space where $f$ lives, and $B$ is a set of values. The notation does not mean that $f$ has an inverse function: $x^2$ on $[-1, 1]$ certainly has none, because $-0.5$ and $0.5$ share the value $0.25$.

A preimage can have several pieces. Let $g(x) = 4x(1 - x)$, a hump that rises from 0 at $x = 0$ to 1 at $x = 0.5$ and falls back to 0 at $x = 1$. The points with a value in $[0.75, 1]$ form the single interval $[0.25, 0.75]$, because $g(0.25) = 0.75$, and its length is $0.5$. The points with a value in $[0.25, 0.64]$ form two intervals, one on the rising side and one on the falling side. Solving $4x(1 - x) = y$ gives $x = \tfrac12\big(1 \pm \sqrt{1 - y}\big)$. For $y = 0.25$ this is $0.0670$ and $0.9330$, for $y = 0.64$ it is $0.2$ and $0.8$, so the preimage is $[0.0670, 0.2] \cup [0.8, 0.9330]$, of total length $0.2660$.

Preimages are the right tool because they respect every operation on sets that a σ-algebra is built from:

$$
f^{-1}(B^c) = \big(f^{-1}(B)\big)^c, \qquad f^{-1}\Big(\bigcup_k B_k\Big) = \bigcup_k f^{-1}(B_k), \qquad f^{-1}\Big(\bigcap_k B_k\Big) = \bigcap_k f^{-1}(B_k).
$$

Each identity takes one line. A point $\omega$ lies in $f^{-1}(B^c)$ exactly when $f(\omega)$ is not in $B$, that is, exactly when $\omega$ is not in $f^{-1}(B)$. A point lies in $f^{-1}(\bigcup_k B_k)$ exactly when $f(\omega)$ is in some $B_k$, that is, exactly when $\omega$ is in some $f^{-1}(B_k)$. The reason is that every point has exactly one value, so the question "is $f(\omega)$ in $B$?" has a yes-or-no answer for each $\omega$ separately. For $x^2$ on $[0, 1]$ the set $B = [0, 0.25]$ has the preimage $[0, 0.5]$, and its complement $(0.25, 1]$ has the preimage $(0.5, 1]$, which is the complement of $[0, 0.5]$ in $[0, 1]$.

Forward images do not behave like this. Let $f(x) = x^2$ on $[-1, 1]$, $A = [-1, 0]$ and $B = [0, 1]$. The two sets meet only in the point $0$, so $f(A \cap B) = \{0\}$, yet $f(A) \cap f(B) = [0, 1] \cap [0, 1] = [0, 1]$. Different points can share a value, and the forward image forgets which point a value came from. This is why measurability is defined through preimages.

## Measurable functions

Let $(\Omega, \mathcal{F})$ be a measurable space, as in "σ-algebras and Borel sets". A function $f : \Omega \to \mathbb{R}$ is **measurable** if the preimage of every Borel set lies in $\mathcal{F}$:

$$
f^{-1}(B) \in \mathcal{F} \qquad \text{for every } B \in \mathcal{B}(\mathbb{R}).
$$

In words: for every question of the form "does the value of $f$ fall in $B$?", the set of points where the answer is yes is an event. If $\mu$ is a measure on $(\Omega, \mathcal{F})$, then $\mu(f^{-1}(B))$ is defined for every Borel set $B$, and this is the number that says how much of $\Omega$ has its value in $B$.

Each ingredient of the definition has a job. The condition on $\mathcal{F}$ guarantees that the preimages can be measured at all. The Borel sets on the value side are the sets of $\mathbb{R}$ that are meaningful to ask about, and they cannot be replaced by all subsets of $\mathbb{R}$: with $\Omega = [0, 1]$, the Borel sets as $\mathcal{F}$, and the identity function $f(x) = x$, the preimage of Vitali's set $V$ is $V$ itself, which is not in $\mathcal{F}$.

## The half-line test

There are far too many Borel sets to check one by one. Luckily it is enough to check the half-lines. Write $\{f \le c\}$ for the set $\{\omega : f(\omega) \le c\} = f^{-1}((-\infty, c])$. If $\{f \le c\} \in \mathcal{F}$ for every real number $c$, then $f$ is measurable. The argument has three steps, and its idea is used again and again.

1. Collect the **good sets**: let $\mathcal{G}$ be the family of all $B \subseteq \mathbb{R}$ for which $f^{-1}(B) \in \mathcal{F}$. This family is a σ-algebra. It contains $\mathbb{R}$, because $f^{-1}(\mathbb{R}) = \Omega \in \mathcal{F}$. It is closed under complements and countable unions, because preimages turn complements into complements and unions into unions, and $\mathcal{F}$ is closed under both.
2. By assumption, $\mathcal{G}$ contains every half-line $(-\infty, c]$.
3. The Borel sets are the smallest σ-algebra that contains the half-lines ("σ-algebras and Borel sets"). A σ-algebra that contains the half-lines contains the smallest one, so $\mathcal{G}$ contains every Borel set, which says that $f$ is measurable.

Other half-lines work just as well, because each can be built from another by complements and countable operations: $\{f > c\}$ is the complement of $\{f \le c\}$, and $\{f < c\} = \bigcup_n \{f \le c - 1/n\}$. Later lessons use whichever form is most convenient.

As an example, take $f(x) = x^2$ on $[0, 1]$. The set $\{f \le c\}$ is $[0, \sqrt{c}\,]$ for $0 \le c \le 1$, empty for $c < 0$, and all of $[0, 1]$ for $c > 1$: always an interval, so $x^2$ is measurable. For the hump $g$ and $c = 0.64$, $\{g \le 0.64\}$ is $[0, 0.2] \cup [0.8, 1]$, again a Borel set.

## Examples and a non-example

Most functions one meets are measurable, and several familiar kinds are quickly seen to be.

- **Continuous functions.** If $f : [0, 1] \to \mathbb{R}$ is continuous, the preimage of an open set is open, and open sets are Borel. Open sets generate the Borel sets, so the good-sets argument gives $f^{-1}(B) \in \mathcal{B}([0, 1])$ for every Borel $B$.
- **Monotone functions.** If $f$ is increasing, then $\{f \le c\}$ is an interval: if $f(y) \le c$ and $x < y$, then $f(x) \le f(y) \le c$. So monotone functions are measurable even when they jump.
- **Indicators.** The indicator $\mathbf{1}_A$ equals 1 on $A$ and 0 elsewhere. A preimage under $\mathbf{1}_A$ is $\emptyset$, $A$, $A^c$ or $\Omega$, depending on whether $B$ contains neither of the values 0 and 1, only 1, only 0, or both. So $\mathbf{1}_A$ is measurable exactly when $A \in \mathcal{F}$.
- **Step functions.** A function that takes finitely many values on intervals is measurable, because each preimage is a finite union of those intervals. The step function of the figure below is $0.2$ on $[0, 0.3)$, $0.7$ on $[0.3, 0.6)$ and $0.4$ on $[0.6, 1]$; then $\{f \le 0.4\} = [0, 0.3) \cup [0.6, 1]$, of length $0.7$.

Continuity is not required. The function $\mathbf{1}_{\mathbb{Q}}$, equal to 1 at the rationals and 0 at the irrationals, is discontinuous at every point of $[0, 1]$, yet it is measurable, because the rationals form a countable, hence Borel, set. Measurability asks only that the level sets can be measured, not that the function varies smoothly.

A non-example comes from the one place where measurability can fail. With Vitali's set $V \subseteq [0, 1)$ and the Borel sets as $\mathcal{F}$, the indicator $\mathbf{1}_V$ is not measurable, because $\{\mathbf{1}_V > \tfrac12\} = V$ is not an event. A function is non-measurable exactly when it hides a non-measurable set, and every such example needs the same exotic constructions as Vitali's set itself. Every function that can be written down by a formula, a limit or an explicit rule is measurable.

## Measurability on a partition

Measurability is easiest to understand when $\Omega$ is finite. Let $\mathcal{F}$ be the σ-algebra generated by a partition, as in "σ-algebras and Borel sets", whose pieces are the atoms. Every event is a union of atoms, and a function $f$ is measurable exactly when it is **constant on every atom**.

To see why, suppose $f$ takes two different values on one atom, at points $a$ and $b$. The preimage of the single value $f(a)$ contains $a$ but not $b$. It is an event, hence a union of atoms, hence it contains $b$ whenever it contains $a$, because $a$ and $b$ lie in the same atom. This is a contradiction. In the other direction, if $f$ is constant on every atom, every preimage is a union of whole atoms, which is an event.

The running example of the die makes this concrete. Let $\Omega = \{1, \ldots, 6\}$ and let the observer who sees only the parity of the face have the σ-algebra $\{\emptyset, \{1, 3, 5\}, \{2, 4, 6\}, \Omega\}$, with the two atoms $\{1, 3, 5\}$ and $\{2, 4, 6\}$. The function "face mod 2", equal to 1 on odd faces and 0 on even faces, is constant on both atoms, hence measurable, and its preimages are $\{2, 4, 6\}$ for the value 0 and $\{1, 3, 5\}$ for the value 1. The function $f(\omega) = \omega$, the face itself, is not measurable: it takes the values 1 and 3 on the atom $\{1, 3, 5\}$, and the event "the face is 1" is not one the parity observer can answer. The observer who sees only "at most 2" has the atoms $\{1, 2\}$ and $\{3, 4, 5, 6\}$, and a function is measurable for this observer exactly when it is a pair of numbers, one for each atom.

In words, a function is measurable when its value can be computed from the information the σ-algebra stands for: the parity observer can compute "face mod 2" but not the face, and an observer who knows nothing can compute only constants.

## The σ-algebra generated by a function

Every function carries some information, namely the information that is revealed by knowing its value. This is captured by the collection of all preimages of Borel sets:

$$
\sigma(f) = \{ f^{-1}(B) : B \in \mathcal{B}(\mathbb{R}) \}.
$$

Since preimages keep complements and countable unions, $\sigma(f)$ is a σ-algebra, and it is the smallest one for which $f$ is measurable: any σ-algebra that makes $f$ measurable contains all these preimages. It consists of the events whose truth can be decided by looking at $f$ alone.

On the die, let $f(\omega) = 1$ if $\omega \le 2$ and $f(\omega) = 0$ otherwise. The preimages are $f^{-1}(\{1\}) = \{1, 2\}$ and $f^{-1}(\{0\}) = \{3, 4, 5, 6\}$, and so $\sigma(f) = \{\emptyset, \{1, 2\}, \{3, 4, 5, 6\}, \Omega\}$, exactly the "at most 2" observer. A function with more values knows more. Let $f(\omega) = (\omega - 3.5)^2$, the squared distance of the face from the middle. Its values are $6.25$ for the faces $1$ and $6$, $2.25$ for $2$ and $5$, and $0.25$ for $3$ and $4$. The atoms of $\sigma(f)$ are $\{1, 6\}$, $\{2, 5\}$ and $\{3, 4\}$, and $\sigma(f)$ has $2^3 = 8$ events. Squaring has lost the side of the middle on which the face lies; no event separating $1$ from $6$ is in $\sigma(f)$. The same happens for $x^2$ on $[-1, 1]$, where $\sigma(f)$ contains only the Borel sets that are symmetric about 0.

## Combining measurable functions

New measurable functions come from old ones, and the rules explain why measurability is so rarely a problem. Let $f$ and $g$ be measurable. The sum $f + g$ is measurable, and the proof shows how countability enters. A point satisfies $f(\omega) + g(\omega) > c$ exactly when some rational number $q$ separates the two parts, with $f(\omega) > q$ and $g(\omega) > c - q$:

$$
\{f + g > c\} = \bigcup_{q \in \mathbb{Q}} \big( \{f > q\} \cap \{g > c - q\} \big).
$$

If $f(\omega) + g(\omega) > c$, then $c - g(\omega) < f(\omega)$, and a rational number $q$ fits strictly between them. The right side is a countable union of events, so it is an event.

The other rules use the same half-line test. The maximum and minimum satisfy $\{\max(f, g) > c\} = \{f > c\} \cup \{g > c\}$ and $\{\min(f, g) > c\} = \{f > c\} \cap \{g > c\}$. The square $f^2$ is measurable, since $\{f^2 > c\}$ is $\Omega$ for $c < 0$ and $\{f > \sqrt{c}\,\} \cup \{f < -\sqrt{c}\,\}$ otherwise, and the product follows from $fg = \tfrac14\big((f + g)^2 - (f - g)^2\big)$. If $h : \mathbb{R} \to \mathbb{R}$ is a Borel function, such as $|x|$ or a continuous function, then $h \circ f$ is measurable, because $(h \circ f)^{-1}(B) = f^{-1}\big(h^{-1}(B)\big)$ and $h^{-1}(B)$ is Borel.

The strongest rules concern sequences. If $f_1, f_2, \ldots$ are measurable, then so are $\sup_n f_n$ and $\inf_n f_n$, since

$$
\Big\{ \sup_n f_n > c \Big\} = \bigcup_n \{ f_n > c \}, \qquad \Big\{ \inf_n f_n < c \Big\} = \bigcup_n \{ f_n < c \}.
$$

The supremum exceeds $c$ exactly when some term does. These functions may take the value $+\infty$ or $-\infty$, and the half-line test works unchanged for functions with values in $[-\infty, \infty]$. From suprema and infima come $\limsup_n f_n = \inf_n \sup_{k \ge n} f_k$ and $\liminf_n f_n$, and so the pointwise limit $\lim_n f_n$, wherever it exists, which is where $\limsup$ and $\liminf$ agree.

A pointwise limit of continuous functions need not be continuous, but it is measurable. The functions $f_n(x) = x^n$ on $[0, 1]$ are all continuous. At $x = 0.9$ they take the values $0.9, 0.81, 0.729, \ldots$, which tend to 0, while at $x = 1$ they stay at 1. The limit is therefore $0$ on $[0, 1)$ and $1$ at the single point $x = 1$, which is $\mathbf{1}_{\{1\}}$: not continuous, but measurable, and equal to the zero function almost everywhere.

One last rule concerns null sets. Suppose $g$ equals the measurable function $f$ except on a null set $N$. Then $\{g > c\}$ and $\{f > c\}$ differ at most inside $N$, so $g$ is measurable for the completed σ-algebra of "Lebesgue measure and null sets". It need not be Borel measurable: if $S$ is a subset of the Cantor set that is not Borel, then $\mathbf{1}_S$ equals the zero function almost everywhere, yet $\{\mathbf{1}_S > \tfrac12\} = S$ is not Borel.

## Simple functions

The simplest nonconstant measurable functions take only finitely many values. A **simple function** is a finite combination

$$
\varphi = \sum_{k=1}^{m} a_k \mathbf{1}_{A_k}, \qquad a_k \in \mathbb{R}, \; A_k \in \mathcal{F}.
$$

It is measurable because each indicator is measurable and sums and constant multiples are. The sets $A_k$ may overlap. For example, $\varphi = 2\cdot\mathbf{1}_{[0, 0.5]} + 3\cdot\mathbf{1}_{[0.25, 1]}$ on $[0, 1]$ equals $2$ on $[0, 0.25)$, where only the first indicator is on, $2 + 3 = 5$ on $[0.25, 0.5]$, where both are on, and $3$ on $(0.5, 1]$. Its **standard form** uses the distinct values and the disjoint sets on which they are taken, $\varphi = 2\cdot\mathbf{1}_{[0, 0.25)} + 5\cdot\mathbf{1}_{[0.25, 0.5]} + 3\cdot\mathbf{1}_{(0.5, 1]}$. The sets $\{\varphi = a_k\}$ then partition $\Omega$, with lengths $0.25$, $0.25$ and $0.5$. A simple function is a finite list of values, each with the event where it is taken.

The reason for introducing simple functions is that every nonnegative measurable function is a limit of them. Given $f \ge 0$ and a level of detail $n$, round every value down to a multiple of $2^{-n}$ (a **dyadic** grid), and cap the result at $n$:

$$
\varphi_n(\omega) = \min\Big( n, \; \frac{\lfloor 2^n f(\omega) \rfloor}{2^n} \Big).
$$

The cap keeps the number of values finite, even if $f$ is unbounded: for $f(x) = 1/x$ at $x = 0.1$, where $f = 10$, the value of $\varphi_3$ is $3$. This $\varphi_n$ is simple. It takes values $k/2^n$ for $k = 0, 1, \ldots, n 2^n$, and the set where it takes the value $k/2^n$ is $\{k/2^n \le f < (k+1)/2^n\}$, or $\{f \ge n\}$ for the largest value. These are events because $f$ is measurable. Moreover $\varphi_n \le f$, and $\varphi_n \le \varphi_{n+1}$, since a finer grid can only move the rounded-down value up, and the cap $n$ only grows. Finally $\varphi_n \to f$ pointwise: once $n > f(\omega)$ the cap is inactive and $f(\omega) - \varphi_n(\omega) < 2^{-n}$.

For $f(x) = x^2$ at $x = 0.7$, where $f = 0.49$, the approximations are $\varphi_1 = 0$, $\varphi_2 = 0.25$, $\varphi_3 = 0.375$, $\varphi_4 = 0.4375$ and $\varphi_5 = 0.46875$. They rise towards $0.49$ and stay below it, and at $n = 5$ the error $0.02125$ is below $2^{-5} = 0.03125$.

What matters most is how $\varphi_n$ cuts up the problem. It slices the range of $f$ into bands of height $2^{-n}$ and records, for each band, the set of points whose value falls in it. It does not slice the domain into pieces of equal width. For $f(x) = x^2$ and $n = 2$ the bands are $[0, \tfrac14)$, $[\tfrac14, \tfrac12)$, $[\tfrac12, \tfrac34)$ and $[\tfrac34, 1)$, and their preimages are $[0, 0.5)$, $[0.5, 0.7071)$, $[0.7071, 0.8660)$ and $[0.8660, 1)$, with lengths $0.5$, $0.2071$, $0.1589$ and $0.1340$, which add up to 1. Each preimage is a Borel set, which is exactly where measurability is needed. The next lesson, "The Lebesgue integral", multiplies every value of $\varphi_n$ by the length of its set and adds up.

### Worked example: Preimages and approximations for f(x) = x²

1. The lower end of $f^{-1}([0.25, 0.64])$ solves $x^2 = 0.25$:
   $$\sqrt{0.25}$$ → **0.5**
2. The upper end solves $x^2 = 0.64$:
   $$\sqrt{0.64}$$ → **0.8**
3. The length of the preimage $[0.5, 0.8]$:
   $$0.8 - 0.5$$ → **0.3**
4. The length of the preimage of $[0, 0.25]$, which is $[0, 0.5]$:
   $$\lambda\big(f^{-1}([0, 0.25])\big) = \sqrt{0.25}$$ → **0.5**
5. At $x = 0.7$ the value is $0.49$, and $\varphi_2$ rounds it down to a multiple of $1/4$:
   $$\lfloor 4 \cdot 0.49 \rfloor / 4$$ → **0.25**
6. $\varphi_3$ rounds down to a multiple of $1/8$:
   $$\lfloor 8 \cdot 0.49 \rfloor / 8$$ → **0.375**
7. $\varphi_4$ rounds down to a multiple of $1/16$:
   $$\lfloor 16 \cdot 0.49 \rfloor / 16$$ → **0.4375**

## Image measures

A measurable function moves a measure from the space where it lives to the number line. Let $(\Omega, \mathcal{F}, \mu)$ be a measure space and $f$ measurable. The **image measure** of $\mu$ under $f$, also called the pushforward, is

$$
(\mu \circ f^{-1})(B) = \mu\big(f^{-1}(B)\big) \qquad \text{for Borel } B \subseteq \mathbb{R}.
$$

The picture is sand. Think of $\mu$ as an amount of sand spread over $\Omega$, and let $f$ carry each grain from $\omega$ to the position $f(\omega)$ on the number line. Then $(\mu \circ f^{-1})(B)$ is the amount of sand that ends up in $B$. It is defined for every Borel set exactly because $f$ is measurable, since the preimages must be sets that $\mu$ can measure.

It is a measure on $\mathcal{B}(\mathbb{R})$. The empty set has an empty preimage, so it receives 0. If $B_1, B_2, \ldots$ are disjoint, their preimages are disjoint, since a point has only one value, and the preimage of the union is the union of the preimages, so countable additivity of $\mu$ carries over:

$$
\mu\Big(f^{-1}\Big(\bigcup_k B_k\Big)\Big) = \mu\Big(\bigcup_k f^{-1}(B_k)\Big) = \sum_k \mu\big(f^{-1}(B_k)\big).
$$

Grains are moved, never created or destroyed, so the total mass is unchanged: $(\mu \circ f^{-1})(\mathbb{R}) = \mu(\Omega)$. A probability measure becomes a probability measure.

Take $\lambda$ on $[0, 1]$ and the step function of the figure. It sends the interval $[0, 0.3)$ to the position $0.2$, $[0.3, 0.6)$ to $0.7$ and $[0.6, 1]$ to $0.4$, so all the sand ends up at three positions: $\lambda \circ f^{-1} = 0.3\,\delta_{0.2} + 0.4\,\delta_{0.4} + 0.3\,\delta_{0.7}$, a combination of point masses as in "Measuring the size of sets". The band $B = [0.3, 0.75]$ contains the positions $0.4$ and $0.7$, so it receives $0.4 + 0.3 = 0.7$, which is also the length of its preimage.

For $f(x) = x^2$ the result is smoother. The set $f^{-1}([0, c]) = [0, \sqrt{c}\,]$ has length $\sqrt{c}$, so $(\lambda \circ f^{-1})([0, c]) = \sqrt{c}$. The quarter of the number line $[0, 0.25]$ receives $\sqrt{0.25} = 0.5$, half of all the sand, while $(0.75, 1]$ receives only $1 - \sqrt{0.75} = 0.1340$. The squaring crowds the values towards 0. For an interval $(a, b]$ the amount is $\sqrt{b} - \sqrt{a}$, which is the area under the curve $y \mapsto 1/(2\sqrt{y})$ between $a$ and $b$, because $\sqrt{y}$ has the derivative $1/(2\sqrt{y})$. So the image measure has the density $1/(2\sqrt{y})$ on $(0, 1]$, which is large near 0, where the sand piles up.

The hump is different. Every height below the top is reached twice, so $\{g \ge y\}$ is the interval from $\tfrac12(1 - \sqrt{1 - y})$ to $\tfrac12(1 + \sqrt{1 - y})$, of length $\sqrt{1 - y}$: $0.5$ for $y = 0.75$ and $0.8$ for $y = 0.36$.

The figure shows all of this. Choose a function and move the ends $c$ and $d$ of the band $B = [c, d]$ on the vertical axis. The thick pieces on the horizontal axis form the preimage $f^{-1}(B)$, listed with its length, and the last readout shows the same number as the amount of sand the image measure places in $B$. With the default $x^2$ and $B = [0.25, 0.64]$ the preimage is $[0.500, 0.800]$, of length $0.3$. For the hump with $B = [0.75, 1]$ it is $[0.250, 0.750]$, of length $0.5$, and with $B = [0.25, 0.64]$ it has two pieces of total length $0.2660$. For the step function and $B = [0.3, 0.75]$ the pieces touch and are listed as $[0.300, 1.000]$, of length $0.7$.

*[Interactive figure: preimage](https://quantsandbox.dev/guide/probability/measurable-functions)*

The probability part of this track gives these objects new names: a measurable function on a probability space is called a random variable, and its image measure is called its distribution. Nothing in the construction changes. Everything in that part is built on the pushforward described here.

## Summary

- The preimage $f^{-1}(B)$ collects the points whose value lies in $B$; unlike forward images, preimages keep complements, unions and intersections.
- A function is measurable if every preimage of a Borel set is an event; it is enough to check the sets $\{f \le c\}$, because the good sets form a σ-algebra that contains the half-lines.
- Continuous, monotone, step functions and indicators of events are measurable, as are sums, products, maxima, minima, suprema, infima and pointwise limits of sequences; the only failures come from non-measurable sets such as Vitali's set.
- On a finite σ-algebra a function is measurable exactly when it is constant on every atom, and $\sigma(f)$ is the information revealed by knowing $f$.
- Simple functions take finitely many values on events, and the dyadic functions $\varphi_n$ rise to any nonnegative measurable $f$ by slicing its range.
- The image measure $\mu \circ f^{-1}$ is the measure on the value side that records how much of $\mu$ lands in each Borel set; it has the same total mass as $\mu$.

[Open the random variables lab](https://quantsandbox.dev/random-variables)

## Interactive labs

- [Random Variables as Functions: Spinner Lab](https://quantsandbox.dev/random-variables)

---

Source: https://quantsandbox.dev/guide/probability/measurable-functions

Previous lesson: [Lebesgue Measure, Borel Sets and Null Sets Explained](https://quantsandbox.dev/guide/probability/lebesgue-measure-null-sets)

Next lesson: [The Lebesgue Integral vs the Riemann Integral](https://quantsandbox.dev/guide/probability/lebesgue-integration)
