maths2u
Tier
⌕ Search ⌘K
Theorem

The Fubini–Tonelli theorem

T-088Home MU-302Threads space · chance
Statement

Let \((X,\mathcal{A},\mu)\) and \((Y,\mathcal{B},\nu)\) be \(\sigma\)-finite measure spaces, and let \(\mathcal{A}\otimes\mathcal{B}\) denote the product \(\sigma\)-algebra on \(X\times Y\), with \(\mu\otimes\nu\) the unique product measure on \((X\times Y,\mathcal{A}\otimes\mathcal{B})\) satisfying \((\mu\otimes\nu)(A\times B)=\mu(A)\nu(B)\) for all \(A\in\mathcal{A}\), \(B\in\mathcal{B}\). (Tonelli.) If \(f:X\times Y\to[0,\infty]\) is \(\mathcal{A}\otimes\mathcal{B}\)-measurable, then the maps \(x\mapsto\int_Y f(x,y)\,d\nu(y)\) and \(y\mapsto\int_X f(x,y)\,d\mu(x)\) are measurable (with values in \([0,\infty]\)), and \[\int_{X\times Y} f\,d(\mu\otimes\nu)=\int_X\left(\int_Y f(x,y)\,d\nu(y)\right)d\mu(x)=\int_Y\left(\int_X f(x,y)\,d\mu(x)\right)d\nu(y),\] all three quantities being equal in \([0,\infty]\) with no integrability hypothesis. (Fubini.) If instead \(f:X\times Y\to\mathbb{R}\) (or \(\mathbb{C}\)) is \(\mathcal{A}\otimes\mathcal{B}\)-measurable and \(\int_{X\times Y}|f|\,d(\mu\otimes\nu)\lt\infty\), then \(f(x,\cdot)\) is \(\nu\)-integrable for \(\mu\)-a.e. \(x\), \(f(\cdot,y)\) is \(\mu\)-integrable for \(\nu\)-a.e. \(y\), the a.e.-defined functions \(x\mapsto\int_Y f(x,y)\,d\nu(y)\) and \(y\mapsto\int_X f(x,y)\,d\mu(x)\) are integrable, and the same iterated-integral equality holds, now as an equality of finite real (or complex) numbers.

Why it matters

Iterated integration is the only computationally tractable way to evaluate most multivariable integrals — one reduces a genuinely two-dimensional problem to two successive one-dimensional problems. But an iterated integral is defined regardless of whether the double integral it purports to compute even exists as a well-defined quantity, and the two iterated integrals \(\int_X\int_Y\) and \(\int_Y\int_X\) can disagree with each other and with the double integral when the hypotheses fail. Fubini–Tonelli identifies exactly the circumstances — measurability of \(f\) on the product, plus either non-negativity (Tonelli) or absolute integrability (Fubini) — under which all three quantities coincide, licensing the routine swap of integration order used throughout analysis, probability, and PDE theory.

The theorem also underlies the entire machinery of independent random variables: the joint law of an independent pair is a product measure, and Fubini–Tonelli is precisely the statement that expectations of joint functionals may be computed by conditioning on one coordinate at a time.

Hypotheses
\(\sigma\)-finiteness of \(\mu\) and \(\nu\).Take \(X=Y=\mathbb{R}\), \(\mu=\) Lebesgue measure, \(\nu=\) counting measure (not \(\sigma\)-finite). Let \(f=\mathbf{1}_{\{(x,x):x\in[0,1]\}}\), the indicator of the diagonal restricted to \([0,1]\). For each fixed \(x\), \(\int_Y f(x,y)\,d\nu(y)=1\) (counting the single point \(y=x\)), so \(\int_X\int_Y f\,d\nu\,d\mu=1\). For each fixed \(y\), \(\int_X f(x,y)\,d\mu(x)=0\) (a single point has Lebesgue measure zero), so \(\int_Y\int_X f\,d\mu\,d\nu=0\). The two iterated integrals disagree: \(1\neq 0\). Product measurability of \(f\).Under the Continuum Hypothesis one can well-order \([0,1]\) so that each initial segment is countable, and use this to build a set \(E\subseteq[0,1]^2\) whose vertical sections \(E_x=\{y:(x,y)\in E\}\) are co-countable and horizontal sections \(E^y\) are countable, for Lebesgue measure on both axes. Then \(f=\mathbf{1}_E\) has \(\int_X\int_Y f\,d\nu\,d\mu=1\) (each \(E_x\) has full measure) while \(\int_Y\int_X f\,d\mu\,d\nu=0\) (each \(E^y\) is null), yet \(f\) is not jointly measurable, so neither Tonelli nor Fubini applies and no contradiction with the theorem arises — but the naive belief that "iterated integrals always agree" fails. (Fubini only) Integrability of \(|f|\) on the product, i.e. \(\int_{X\times Y}|f|\,d(\mu\otimes\nu)\lt\infty\).Take \(X=Y=\mathbb{N}\) with counting measure, \(f(m,n)=1\) if \(m=n\), \(f(m,n)=-1\) if \(m=n+1\), \(f(m,n)=0\) otherwise. Row sums (summing over \(n\) for fixed \(m\)) telescope to give \(\sum_m\sum_n f(m,n)=1\) (the classic "\(1-1+1-1+\cdots\)" rearrangement done row by row), while column sums give \(\sum_n\sum_m f(m,n)=0\). Here \(\int|f|\,d(\mu\otimes\nu)=\infty\), Fubini's hypothesis fails, and the iterated sums genuinely disagree, \(1\neq0\).
Proof
1
\(\mathcal{A}\otimes\mathcal{B}\), the product \(\sigma\)-algebra, is generated by the measurable rectangles \(A\times B\), \(A\in\mathcal{A}\), \(B\in\mathcal{B}\).
Definition of the product \(\sigma\)-algebra: \(\mathcal{A}\otimes\mathcal{B}:=\sigma(\{A\times B:A\in\mathcal{A},B\in\mathcal{B}\})\). A
2
The product measure \(\mu\otimes\nu\) exists and is the unique measure on \(\mathcal{A}\otimes\mathcal{B}\) with \((\mu\otimes\nu)(A\times B)=\mu(A)\nu(B)\), provided \(\mu,\nu\) are \(\sigma\)-finite.
Carathéodory extension theorem applied to the premeasure on the algebra of finite disjoint unions of rectangles; \(\sigma\)-finiteness of \(\mu\otimes\nu\) on that algebra gives uniqueness of the extension. B
3
Fix \(E\in\mathcal{A}\otimes\mathcal{B}\). For each \(x\in X\) the section \(E_x=\{y\in Y:(x,y)\in E\}\) lies in \(\mathcal{B}\), and for each \(y\in Y\) the section \(E^y=\{x\in X:(x,y)\in E\}\) lies in \(\mathcal{A}\).
The collection \(\mathcal{D}=\{E\in\mathcal{A}\otimes\mathcal{B}: E_x\in\mathcal{B}\ \forall x,\ E^y\in\mathcal{A}\ \forall y\}\) contains all rectangles (their sections are either \(B\), \(\varnothing\), \(A\), or \(\varnothing\)) and is closed under complementation and countable disjoint unions — a routine check using \((E^c)_x=(E_x)^c\) and \((\bigcup_n E_n)_x=\bigcup_n (E_n)_x\) — so \(\mathcal{D}\) is a \(\sigma\)-algebra (indeed a \(\lambda\)-system) containing the generating \(\pi\)-system of rectangles; by Dynkin's \(\pi\)-\(\lambda\) theorem \(\mathcal{D}\supseteq\sigma(\text{rectangles})=\mathcal{A}\otimes\mathcal{B}\). C
4
Assume first \(\mu(X)\lt\infty\), \(\nu(Y)\lt\infty\). For \(E\in\mathcal{A}\otimes\mathcal{B}\), the functions \(x\mapsto\nu(E_x)\) and \(y\mapsto\mu(E^y)\) are measurable and \[(\mu\otimes\nu)(E)=\int_X \nu(E_x)\,d\mu(x)=\int_Y \mu(E^y)\,d\nu(y).\]
Let \(\mathcal{C}\) be the collection of \(E\in\mathcal{A}\otimes\mathcal{B}\) for which this display holds with both sides measurable and finite. \(\mathcal{C}\) contains every rectangle (both integrals reduce to \(\mu(A)\nu(B)\)) and, being a \(\pi\)-system's extension, is closed under complements (using finiteness of the total measures, so subtraction is legitimate: \(\nu((E^c)_x)=\nu(Y)-\nu(E_x)\)) and countable increasing unions (Monotone Convergence Theorem for the sequence of section-integrals). By Dynkin's theorem again, \(\mathcal{C}=\mathcal{A}\otimes\mathcal{B}\). B
5
For \(\sigma\)-finite \(\mu,\nu\), write \(X=\bigcup_n X_n\), \(Y=\bigcup_n Y_n\) as increasing unions of sets of finite measure. Step 4 applied to \(E\cap(X_n\times Y_n)\), followed by Monotone Convergence as \(n\to\infty\), extends the section formula of Step 4 to all \(E\in\mathcal{A}\otimes\mathcal{B}\), without any finiteness restriction on \(\mu,\nu\) beyond \(\sigma\)-finiteness.
Monotone Convergence Theorem applied twice (once to \(\nu(E_x\cap Y_n)\uparrow\nu(E_x)\), then to the outer integral over \(X_n\uparrow X\)); this is exactly where \(\sigma\)-finiteness is used, and it is the step that fails in the counting-measure counterexample. B
6
Tonelli holds for \(f=\mathbf{1}_E\), \(E\in\mathcal{A}\otimes\mathcal{B}\): this is exactly the content of Step 5, since \(\int_Y \mathbf{1}_E(x,y)\,d\nu(y)=\nu(E_x)\) and \(\int_{X\times Y}\mathbf{1}_E\,d(\mu\otimes\nu)=(\mu\otimes\nu)(E)\).
Definition of the integral of an indicator function. A
7
Tonelli holds for non-negative simple functions \(s=\sum_{i=1}^n c_i\mathbf{1}_{E_i}\) (\(c_i\geq0\), \(E_i\in\mathcal{A}\otimes\mathcal{B}\)), by linearity of the integral applied to the finite sum in Step 6.
Linearity of the integral (finite sums of non-negative terms; no cancellation, so no integrability issue). A
8
For general measurable \(f:X\times Y\to[0,\infty]\), choose simple \(s_n\uparrow f\) pointwise (possible since \(f\geq0\) is measurable). Then \(\int_Y s_n(x,y)\,d\nu(y)\uparrow\int_Y f(x,y)\,d\nu(y)\) for each \(x\), the left side is measurable in \(x\) by Step 7, hence the limit is measurable in \(x\); applying Monotone Convergence once more in \(x\) (and symmetrically in \(y\), and to the double integral) passes the equality of Step 7 to the limit, proving Tonelli in full.
Existence of an increasing simple approximating sequence for non-negative measurable functions; Monotone Convergence Theorem, applied three times (inner integral in \(y\), inner integral in \(x\), and the double integral), each legitimate because all integrands are non-negative and increasing. B
9
Now let \(f:X\times Y\to\mathbb{R}\) be \(\mathcal{A}\otimes\mathcal{B}\)-measurable with \(\int_{X\times Y}|f|\,d(\mu\otimes\nu)\lt\infty\). Apply Tonelli (Step 8) to \(|f|\geq0\): \[\int_X\left(\int_Y|f(x,y)|\,d\nu(y)\right)d\mu(x)=\int_{X\times Y}|f|\,d(\mu\otimes\nu)\lt\infty.\]
Tonelli's theorem, just established, applied to the non-negative measurable function \(|f|\); \(|f|\) is measurable as the composition of the measurable \(f\) with the continuous map \(t\mapsto|t|\). A
10
Since \(\int_X g(x)\,d\mu(x)\lt\infty\) for \(g(x):=\int_Y|f(x,y)|\,d\nu(y)\), the set \(N:=\{x\in X: g(x)=\infty\}\) has \(\mu(N)=0\); hence \(f(x,\cdot)\) is \(\nu\)-integrable for \(\mu\)-a.e.\ \(x\).
If \(\mu(N)\gt0\) then \(\int_X g\,d\mu\geq\int_N g\,d\mu=\infty\cdot\mu(N)=\infty\), contradicting finiteness — a standard consequence of Markov's inequality / the definition of the integral of a \([0,\infty]\)-valued function. A
11
Write \(f=f^+-f^-\) with \(f^\pm\geq0\) measurable and \(f^+,f^-\leq|f|\). By Step 10 (applied to \(f^+\) and to \(f^-\)), for \(\mu\)-a.e.\ \(x\), both \(\int_Y f^+(x,y)\,d\nu(y)\) and \(\int_Y f^-(x,y)\,d\nu(y)\) are finite, so \(F(x):=\int_Y f(x,y)\,d\nu(y)=\int_Y f^+(x,y)\,d\nu(y)-\int_Y f^-(x,y)\,d\nu(y)\) is well-defined and finite for \(\mu\)-a.e.\ \(x\) (set \(F(x):=0\) on the exceptional null set).
Definition of the integral of a real-valued (signed) function as the difference of the integrals of its positive and negative parts, valid whenever both parts are finite; measurability of \(F\) off the null set follows from Step 8 applied separately to \(f^+\) and \(f^-\), each of which gives a measurable section-integral function. B
12
\(F\) is \(\mu\)-integrable: \(\int_X F\,d\mu=\int_X\int_Y f^+\,d\nu\,d\mu-\int_X\int_Y f^-\,d\nu\,d\mu=\int_{X\times Y}f^+\,d(\mu\otimes\nu)-\int_{X\times Y}f^-\,d(\mu\otimes\nu)=\int_{X\times Y}f\,d(\mu\otimes\nu),\) with each equality justified: the first by Step 11, the middle two by Tonelli (Step 8) applied to \(f^\pm\), and the last by definition of \(\int f\,d(\mu\otimes\nu):=\int f^+\,d(\mu\otimes\nu)-\int f^-\,d(\mu\otimes\nu)\), legitimate since both terms are finite by Step 9.
Linearity of the (Lebesgue) integral for integrable functions, plus Tonelli applied twice to the non-negative parts \(f^+,f^-\); finiteness of both terms (from Step 9, since \(f^\pm\leq|f|\)) avoids the forbidden \(\infty-\infty\). B
13
By symmetry (interchanging the roles of \(X\) and \(Y\) throughout Steps 9–12), \(G(y):=\int_X f(x,y)\,d\mu(x)\) is defined for \(\nu\)-a.e.\ \(y\), is \(\nu\)-integrable, and \(\int_Y G\,d\nu=\int_{X\times Y}f\,d(\mu\otimes\nu)\). Combining with Step 12 gives the Fubini equality \[\int_X\int_Y f\,d\nu\,d\mu=\int_{X\times Y}f\,d(\mu\otimes\nu)=\int_Y\int_X f\,d\mu\,d\nu.\]
Symmetry of the roles of the two factor spaces in the product-measure construction (Step 2) and in Tonelli's theorem (Step 8), which treats both marginals identically. A
14
For \(f:X\times Y\to\mathbb{C}\), apply Steps 9–13 to \(\operatorname{Re}f\) and \(\operatorname{Im}f\) separately (each has \(|\operatorname{Re}f|,|\operatorname{Im}f|\leq|f|\), hence integrable) and recombine via \(f=\operatorname{Re}f+i\operatorname{Im}f\), completing the proof of Fubini's theorem.
Linearity of the integral over \(\mathbb{C}\), decomposing into real and imaginary parts, each a real-valued integrable function to which the real case applies. A
Result
\[\int_{X\times Y}\!f\,d(\mu\otimes\nu)=\int_X\!\!\int_Y f\,d\nu\,d\mu=\int_Y\!\!\int_X f\,d\mu\,d\nu\]

Reading. On a product of \(\sigma\)-finite measure spaces, a jointly measurable function's double integral can be computed by integrating one variable at a time, in either order, and getting the same answer — provided either the function is non-negative (Tonelli, no other conditions needed) or its absolute value has finite double integral (Fubini). Tonelli is typically used first, on \(|f|\), to check the finiteness hypothesis that then licenses Fubini for \(f\) itself.

Scope. Applies to any pair of \(\sigma\)-finite measure spaces — Lebesgue measure on \(\mathbb{R}^n\), counting measure on a countable set (recovering rearrangement theorems for double series), or probability spaces (recovering independence and joint-expectation formulas). Does not by itself extend to non-\(\sigma\)-finite spaces or to integrands that are merely separately measurable in each variable rather than jointly \(\mathcal{A}\otimes\mathcal{B}\)-measurable.

Corollaries & converses
  • Order of summation for double series. If \(a_{mn}\geq0\), or if \(\sum_{m,n}|a_{mn}|\lt\infty\), then \(\sum_m\sum_n a_{mn}=\sum_n\sum_m a_{mn}\) — the special case \(X=Y=\mathbb{N}\) with counting measure.
  • Differentiation under the integral sign and interchange of integral and infinite sum are routinely justified by recasting the sum as an integral against counting measure and invoking Fubini–Tonelli jointly with dominated convergence.
  • Independence and product expectation. If \(X,Y\) are independent random variables with finite \(\mathbb{E}|g(X)h(Y)|\), then \(\mathbb{E}[g(X)h(Y)]=\mathbb{E}[g(X)]\,\mathbb{E}[h(Y)]\), by applying Fubini to the product measure \(\mu_X\otimes\mu_Y\), which is the joint law precisely because of independence.
  • Convolution. For \(f,g\in L^1(\mathbb{R}^n)\), \((f*g)(x)=\int f(x-y)g(y)\,dy\) is defined for a.e.\ \(x\), lies in \(L^1\), and \(\|f*g\|_1\leq\|f\|_1\|g\|_1\); this is Fubini–Tonelli applied to \(F(x,y)=f(x-y)g(y)\).
  • Converse: does equality of the two iterated integrals imply the Fubini/Tonelli hypotheses hold? No. The two iterated integrals can coincide "by accident" even when \(f\) is not integrable, or (under CH, as in the Hypotheses section) even when \(f\) is not jointly measurable at all. Equality of iterated integrals is necessary but nowhere near sufficient for the theorem's conclusion, so it can never be used to retroactively certify the hypotheses.
Fails without
  • Drop \(\sigma\)-finiteness: with \(\mu=\) Lebesgue on \([0,1]\) and \(\nu=\) counting measure on \([0,1]\) (not \(\sigma\)-finite), the indicator of the diagonal gives iterated integrals \(1\) and \(0\) respectively — see the Hypotheses section for the full computation.
  • Drop joint measurability: a CH-constructed subset of \([0,1]^2\) with co-countable vertical sections and countable horizontal sections yields an \(f\) whose iterated integrals are \(1\) and \(0\), yet \(f\) is not \(\mathcal{A}\otimes\mathcal{B}\)-measurable, so it lies outside the theorem's scope entirely.
  • Drop absolute integrability in the signed case: \(f(x,y)=\dfrac{x^2-y^2}{(x^2+y^2)^2}\) on \((0,1)\times(0,1)\) has \(\int_0^1\!\int_0^1 f\,dy\,dx=\tfrac{\pi}{4}\) but \(\int_0^1\!\int_0^1 f\,dx\,dy=-\tfrac{\pi}{4}\); indeed \(\int\!\int|f|=\infty\), so Fubini's hypothesis fails and the two orders genuinely disagree.
  • Drop non-negativity without absolute integrability (Tonelli misapplied to a signed function): the row/column-alternating array \(a_{mn}\) of the Hypotheses section shows a signed, non-integrable \(f\) for which the two iterated sums are unequal, confirming Tonelli's conclusion cannot be invoked once \(f\) takes both signs and \(|f|\) is not integrable.
Common errors
  • Swapping the order of integration first and only checking (or never checking) integrability afterwards — the standard fallacy is to compute both iterated integrals, find they agree, and conclude Fubini "applies"; agreement of iterated integrals does not certify the hypotheses (see Corollaries).
  • Invoking "Fubini's theorem" for a manifestly non-negative integrand and then separately worrying about absolute convergence — for \(f\geq0\) one should cite Tonelli, which needs no integrability hypothesis at all; conflating the two names obscures which hypothesis is actually doing the work.
  • Checking integrability of \(f\) itself (i.e., that \(\int f\) is finite) rather than of \(|f|\) — a function can have well-defined, finite, and even equal iterated integrals of \(f\) while \(\int\int|f|=\infty\), and Fubini's conclusion can still fail in such cases (the classical \(f(x,y)=(x^2-y^2)/(x^2+y^2)^2\)-type examples).
  • Forgetting the a.e. qualifiers: assuming \(x\mapsto\int_Y f(x,y)\,d\nu(y)\) is defined for every \(x\), when Fubini only guarantees this for \(\mu\)-a.e. \(x\); on the exceptional null set the inner integral may not exist (both \(f^+\) and \(f^-\) sections may be non-integrable there).
  • Applying the theorem to a function known only to be separately measurable in each variable (measurable in \(x\) for each fixed \(y\), and vice versa) rather than jointly \(\mathcal{A}\otimes\mathcal{B}\)-measurable; separate measurability does not imply joint measurability in general (it does under extra continuity assumptions, e.g. Carathéodory functions, but not unconditionally).
Discussion

The theorem is really two theorems bundled under one name for good pedagogical reason: Tonelli handles the "easy" non-negative case with no integrability hypothesis whatsoever — only measurability and \(\sigma\)-finiteness — because Monotone Convergence tolerates \(\infty\) gracefully, whereas Fubini's signed/complex case must additionally guard against the \(\infty-\infty\) indeterminacy that plagues subtraction of infinite quantities. The standard proof strategy, visible in the steps above, is the "climb the ladder of function classes" technique common throughout measure theory: establish a result for indicators, extend to simple functions by linearity, extend to non-negative measurable functions by monotone approximation, then extend to signed/complex functions by decomposition — precisely the same ladder used to define the Lebesgue integral itself.

Guido Fubini proved the integrable case in 1907 for Lebesgue measure on \(\mathbb{R}^n\); Leonida Tonelli gave the non-negative version in 1909, freeing the theorem from any a priori integrability assumption. The abstract measure-space formulation used today, built via Carathéodory extension of the product premeasure, is due to the general development of measure theory in the following decades and is the version needed for probability theory, where \(X\) and \(Y\) are typically infinite or continuous sample spaces.

In probability, the theorem is the analytic engine behind the definition of independence itself: two random variables are independent exactly when their joint law is the product of their marginal laws, and Fubini's theorem is what allows "integrate out one variable, then the other" computations of joint expectations, convolutions of independent sums, and conditional expectation formulas via disintegration. The \(\sigma\)-finiteness hypothesis is automatic for any probability space (total mass \(1\)), which is one reason probabilists rarely dwell on it, but it is essential and is exactly what fails for, e.g., certain non-\(\sigma\)-finite Palm measures in point-process theory.

A subtler point often elided in first courses: the product \(\sigma\)-algebra \(\mathcal{A}\otimes\mathcal{B}\) is in general strictly smaller than the Borel \(\sigma\)-algebra of the product topology, and also strictly smaller than the completed product \(\sigma\)-algebra used to build Lebesgue measure on \(\mathbb{R}^{m+n}\) from Lebesgue measure on \(\mathbb{R}^m\) and \(\mathbb{R}^n\) separately. The completed version of Fubini's theorem — needed to identify Lebesgue measure on \(\mathbb{R}^{m+n}\) with the completion of \(\mathcal{L}(\mathbb{R}^m)\otimes\mathcal{L}(\mathbb{R}^n)\) — requires an extra null-set bookkeeping step (sections of a \(\mu\otimes\nu\)-null set are null for a.e. fixed coordinate, but not literally every section is null), which is routine but is a genuine addition to the argument given here, not a free consequence of it.

Worked examples
1
Compute \(I=\displaystyle\int_0^\infty\int_0^\infty e^{-xy}\sin x\,\mathbf{1}_{(0,1)}(x)\,dx\,dy\) via order reversal.
Set up the integrand \(f(x,y)=e^{-xy}\sin x\,\mathbf{1}_{(0,1)}(x)\) on \((0,\infty)\times(0,\infty)\), Lebesgue \(\times\) Lebesgue, both \(\sigma\)-finite. A
2
\(\displaystyle\int_0^\infty\int_0^\infty |f(x,y)|\,dy\,dx=\int_0^1|\sin x|\left(\int_0^\infty e^{-xy}\,dy\right)dx=\int_0^1\frac{|\sin x|}{x}\,dx\leq\int_0^1 1\,dx=1\lt\infty.\)
Tonelli applied to \(|f|\geq0\) computes the double integral of \(|f|\) as an iterated integral in the \(y\)-then-\(x\) order (legitimate with no further hypothesis); \(\int_0^\infty e^{-xy}dy=1/x\) for \(x\gt0\) by the standard exponential antiderivative, and \(|\sin x|/x\leq1\) on \((0,1)\) is bounded, hence integrable there. B
3
Since \(\int\int|f|\lt\infty\), Fubini applies to \(f\) itself, so \(I=\displaystyle\int_0^1\sin x\left(\int_0^\infty e^{-xy}\,dy\right)dx=\int_0^1\frac{\sin x}{x}\,dx=\operatorname{Si}(1).\)
Fubini's theorem, licensed by Step 2, permits evaluating the double integral in the order (inner \(y\), outer \(x\)) as originally posed; \(\operatorname{Si}\) is the sine-integral special function, and the value \(\operatorname{Si}(1)\approx0.9461\) is the closed form obtainable once the order is fixed to integrate \(y\) first. A
\[I=\int_0^1\frac{\sin x}{x}\,dx=\operatorname{Si}(1)\approx0.9461\]

Reading. Introducing the extra variable \(y\) via \(1/x=\int_0^\infty e^{-xy}dy\) converts a transcendental integral into a Gaussian-type double integral that becomes tractable after reversing the order — a standard "Feynman trick" whose legitimacy rests entirely on Fubini–Tonelli.

1
Let \(X,Y\) be independent random variables, both \(\mathrm{Exp}(1)\)-distributed on \((0,\infty)\), joint density \(f(x,y)=e^{-x-y}\). Compute \(\mathbb{E}[\mathbf{1}_{\{X\lt Y\}}]=P(X\lt Y)\).
Independence gives joint law \(=\) product of marginal Lebesgue-density measures, \(\mu\otimes\nu\) with \(d\mu=e^{-x}\mathbf{1}_{x\gt0}dx\), \(d\nu=e^{-y}\mathbf{1}_{y\gt0}dy\), both \(\sigma\)-finite (indeed finite, total mass \(1\) each). A
2
The integrand \(g(x,y)=\mathbf{1}_{\{x\lt y\}}e^{-x-y}\geq0\) is jointly measurable (indicator of a Borel set times a continuous function), so Tonelli applies with no integrability check needed: \[P(X\lt Y)=\int_0^\infty\!\!\int_0^\infty \mathbf{1}_{\{x\lt y\}}e^{-x-y}\,dy\,dx=\int_0^\infty e^{-x}\left(\int_x^\infty e^{-y}\,dy\right)dx.\]
Tonelli's theorem for the non-negative measurable function \(g\); the inner integral's lower limit changes from \(0\) to \(x\) because the indicator restricts to \(y\gt x\). A
3
\(\displaystyle\int_x^\infty e^{-y}\,dy=e^{-x}\), so \(P(X\lt Y)=\int_0^\infty e^{-x}\cdot e^{-x}\,dx=\int_0^\infty e^{-2x}\,dx=\frac12.\)
Elementary antiderivative of \(e^{-y}\); the final integral is a standard exponential integral, \(\int_0^\infty e^{-2x}dx=1/2\). A
\[P(X\lt Y)=\tfrac12\]

Reading. By symmetry \(P(X\lt Y)=P(Y\lt X)\) and \(P(X=Y)=0\) (a null set under a jointly continuous density, itself an instance of Tonelli applied to the diagonal), so the answer \(1/2\) is exactly what symmetry demands — Fubini–Tonelli is what makes the double integral over the "wedge" region \(\{x\lt y\}\) computable as a clean iterated integral in the first place.

Problems
  1. State precisely which of Tonelli's or Fubini's theorem applies to \(f(x,y)=xye^{-(x^2+y^2)}\) on \(\mathbb{R}^2\), and evaluate \(\int_{\mathbb{R}^2}f\,d(\mu\otimes\mu)\) (Lebesgue \(\times\) Lebesgue).
    Solution\(f\) changes sign (positive in quadrants 1 and 3, negative in 2 and 4), so Tonelli does not directly apply to \(f\); check \(\int\int|f|\): \(|f(x,y)|=|x||y|e^{-(x^2+y^2)}\geq0\), and by Tonelli, \(\int_{\mathbb{R}^2}|f|=\left(\int_{\mathbb{R}}|x|e^{-x^2}dx\right)^2=\left(2\int_0^\infty xe^{-x^2}dx\right)^2=(2\cdot\tfrac12)^2=1\lt\infty\). Since \(\int\int|f|\lt\infty\), Fubini applies to \(f\) itself: \(\int_{\mathbb{R}^2}f\,d(\mu\otimes\mu)=\left(\int_{\mathbb{R}}xe^{-x^2}dx\right)^2\). But \(\int_{\mathbb{R}}xe^{-x^2}dx=0\) (odd integrand over symmetric interval), so the answer is \(0\).
  2. Let \(\mu=\nu=\) Lebesgue measure on \((0,1)\). Show that \(f(x,y)=\dfrac{1}{(x+y)^{3}}\) has \(\int_0^1\int_0^1 f\,dx\,dy=\infty\) directly, and explain why this is consistent with (not a counterexample to) Tonelli.
    SolutionCompute \(\int_0^1\frac{dx}{(x+y)^3}=\left[-\tfrac12(x+y)^{-2}\right]_0^1=\tfrac12\left(\tfrac1{y^2}-\tfrac1{(1+y)^2}\right)\). Then \(\int_0^1\tfrac1{2y^2}dy=\infty\) since \(1/y^2\) is non-integrable near \(0\), while \(\int_0^1\tfrac{1}{2(1+y)^2}dy\) is finite; hence the outer integral diverges to \(+\infty\). Since \(f\geq0\) is jointly measurable and \(\mu,\nu\) are \(\sigma\)-finite, Tonelli guarantees the double integral and both iterated integrals are all equal in \([0,\infty]\) — here they are all equal to \(+\infty\). This is fully consistent with Tonelli: the theorem never claims finiteness, only equality (in the extended sense), and \(\infty=\infty=\infty\) is a valid instance of it.
  3. Construct, using Fubini's theorem, a proof that if \(X\geq0\) is a random variable, then \(\mathbb{E}[X]=\int_0^\infty P(X\gt t)\,dt\) (the "layer-cake" / tail-integral formula).
    SolutionWrite \(X(\omega)=\int_0^\infty \mathbf{1}_{\{t\lt X(\omega)\}}\,dt\) (true for every \(\omega\), since the inner integral is just the length of \([0,X(\omega))\)). Then \(\mathbb{E}[X]=\int_\Omega\left(\int_0^\infty \mathbf{1}_{\{t\lt X(\omega)\}}\,dt\right)dP(\omega)\). The integrand \(g(\omega,t)=\mathbf{1}_{\{t\lt X(\omega)\}}\) is non-negative and jointly measurable (as \(\{(\omega,t):t\lt X(\omega)\}\) is measurable in the product \(\sigma\)-algebra \(\mathcal{F}\otimes\mathcal{B}((0,\infty))\), being the preimage of an open set under the jointly measurable map \((\omega,t)\mapsto X(\omega)-t\)), and \((\Omega,\mathcal{F},P)\) and \(((0,\infty),\mathcal{B},\text{Leb})\) are both \(\sigma\)-finite (indeed \(P\) is finite). By Tonelli, the order of integration may be swapped: \(\mathbb{E}[X]=\int_0^\infty\left(\int_\Omega \mathbf{1}_{\{t\lt X(\omega)\}}\,dP(\omega)\right)dt=\int_0^\infty P(X\gt t)\,dt\).
  4. Give an example, distinct from the ones in this article, of a non-\(\sigma\)-finite measure space pairing for which the two iterated integrals of a non-negative jointly measurable function disagree, and identify exactly which step of the proof breaks down.
    SolutionTake \(X=Y=[0,1]\), \(\mu=\) Lebesgue measure (\(\sigma\)-finite, indeed finite), \(\nu=\) counting measure on \([0,1]\) (not \(\sigma\)-finite, since \([0,1]\) is uncountable and every set of finite \(\nu\)-measure is finite/countable, so no countable union of finite-\(\nu\)-measure sets covers \([0,1]\)). Let \(f=\mathbf{1}_D\) where \(D=\{(x,x):x\in[0,1]\}\) is the diagonal, which is closed hence Borel, hence jointly measurable. For fixed \(x\), \(\int_Y f(x,y)\,d\nu(y)=\nu(\{x\})=1\), so \(\int_X\int_Y f\,d\nu\,d\mu=\int_0^1 1\,dx=1\). For fixed \(y\), \(\int_X f(x,y)\,d\mu(x)=\mu(\{y\})=0\), so \(\int_Y\int_X f\,d\mu\,d\nu=\sum_{y\in[0,1]}0\cdot(\text{as a }\nu\text{-integral of the zero function})=0\). The failure is precisely in Step 5 of the proof: the passage from Step 4 (valid only for finite \(\mu,\nu\)) to general \(\sigma\)-finite \(\mu,\nu\) requires writing \(Y\) as a countable increasing union \(Y_n\uparrow Y\) of finite-\(\nu\)-measure sets and invoking Monotone Convergence; with \(\nu\) counting measure on an uncountable set, no such exhaustion exists, so Step 5's Monotone Convergence argument cannot be run, and the section formula \((\mu\otimes\nu)(E)=\int_X\nu(E_x)\,d\mu(x)\) itself fails to hold (indeed \(\mu\otimes\nu\) is not even uniquely determined by its values on rectangles here).
  5. Let \(f(x,y)=\dfrac{x^2-y^2}{(x^2+y^2)^2}\) on \((0,1)\times(0,1)\). Verify \(\int_0^1\int_0^1 f\,dy\,dx=\tfrac{\pi}{4}\) and \(\int_0^1\int_0^1 f\,dx\,dy=-\tfrac{\pi}{4}\), and confirm \(\int\int|f|=\infty\) so this is not a violation of Fubini's theorem.
    SolutionNote \(\dfrac{\partial}{\partial y}\left(\dfrac{-y}{x^2+y^2}\right)=\dfrac{-(x^2+y^2)+y\cdot2y}{(x^2+y^2)^2}=\dfrac{y^2-x^2}{(x^2+y^2)^2}=-f(x,y)\), so \(\int_0^1 f(x,y)\,dy=\left[\dfrac{-y}{x^2+y^2}\right]_{y=0}^{1}\cdot(-1)=\dfrac{1}{x^2+1}\) (careful sign bookkeeping: \(\int_0^1 f\,dy=\left[\frac{y}{x^2+y^2}\right]_0^1=\frac{1}{x^2+1}\)). Then \(\int_0^1\frac{dx}{x^2+1}=\arctan(1)-\arctan(0)=\pi/4\). By the antisymmetry \(f(x,y)=-f(y,x)\), swapping the names of the variables shows \(\int_0^1\int_0^1 f\,dx\,dy=-\pi/4\) immediately, without repeating the computation. For the divergence of \(\int\int|f|\): along the ray \(y=x\), \(f(x,x)=0\), but near the origin \(|f(x,y)|\) is comparable to \(1/r^2\) in polar coordinates \(r^2=x^2+y^2\) (since \(f\) is homogeneous of degree \(-2\) and not identically zero on the unit circle), and \(\int_0^\epsilon \frac{1}{r^2}\cdot r\,dr\,d\theta=\int_0^\epsilon\frac{dr}{r}=\infty\); a full estimate confirms \(\iint_{(0,1)^2}|f|\,dx\,dy=\infty\). Since Fubini's absolute-integrability hypothesis fails, the unequal iterated integrals \(\pi/4\neq-\pi/4\) are fully consistent with (not a counterexample to) the theorem as stated.