Let f and g be real-valued integrable functions on a measure space (X,B,μ), and define
Ft={x∈X∣f(x)>t}, Gt={x∈X∣g(x)>t}.
Prove
∫∣f−g∣dμ=∫−∞∞μ((Ft∖Gt)∪(Gt∖Ft))dt.
Solution.
First, notice that Ft∖Gt and Gt∖Ft are disjoint, so
χ(Ft∖Gt)∪(Gt∖Ft)=χFt∖Gt+χGt∖Ft.
Because f and g are measurable, the sets
A={∣f−g∣=0}andAn={∣f−g∣≥n1}
are measurable. Moreover, because f and g are integrable,
nμ(An)≤∫An∣f−g∣dμ≤∫X∣f−g∣dμ<∞.
Combining this with the fact that A=⋃n=1∞An, we see that A is a σ-finite set with respect to μ. Hence, we may apply Fubini-Tonelli on R×A.
Notice that on x∈Ac, then f(x)=g(x), and so
Ft∩Ac=Gt∩Ac⟹(Ft∖Gt)∩Ac=(Gt∖Ft)∩Ac=∅.
In other words, Ft∖Gt⊆A and Gt∖Ft⊆A, and so by Fubini-Tonelli,
∫−∞∞μ((Ft∖Gt)∪(Gt∖Ft))dt=∫−∞∞∫XχFt∖Gt+χGt∖Ftdμdt=∫−∞∞∫AχFt∖Gt+χGt∖Ftdμdt=∫A∫−∞∞χFt∖Gt+χGt∖Ftdtdμ=∫A∫−∞∞χ{g(x)≤t<f(x)}+χ{f(x)≤t<g(x)}dtdμ=∫A∫g(x)f(x)χ{g(x)<f(x)}dt+∫f(x)g(x)χ{f(x)<g(x)}dtdμ=∫A(f(x)−g(x))χ{g(x)<f(x)}+(g(x)−f(x))χ{f(x)<g(x)}dμ=∫A∣f−g∣dμ=∫X∣f−g∣dμ,
since ∫Ac∣f−g∣dμ=0.