---
title: "Conditional Expectation Given a Sigma-Algebra"
description: "For integrable X, define E[X|G] by G-measurability and matching integrals on G-events. For square-integrable X, interpret it as a least-squares prediction."
canonical: https://lightmysky.com/learn/mathematics/conditional-expectation-given-a-sigma-algebra-mt_i2sxZc-ER8
source: https://lightmysky.com/learn/mathematics/conditional-expectation-given-a-sigma-algebra-mt_i2sxZc-ER8.md
retrieved: 2026-11-12
---

> **Agent view.** This is the Markdown twin of the page, for tools and assistants.
> When to use this site, and the call that answers each job: https://lightmysky.com/agent-instructions.md
> API description (OpenAPI 3.1): https://lightmysky.com/openapi.json · Authentication: https://lightmysky.com/auth.md
> Pricing: https://lightmysky.com/pricing.md · Catalog: https://lightmysky.com/llms.txt · Full catalog: https://lightmysky.com/llms-full.txt
> Every machine-readable file on this domain: https://lightmysky.com/.well-known/ai-catalog.json
> Ask for Markdown with `Accept: text/markdown`, a `.md` address, or `?mode=agent`.

# Conditional Expectation Given a Sigma-Algebra

For integrable X, define E[X|G] by G-measurability and matching integrals on G-events. For square-integrable X, interpret it as a least-squares prediction.

Subject: Mathematics · Area: Probability · Ages 22 to 23
Page: https://lightmysky.com/learn/mathematics/conditional-expectation-given-a-sigma-algebra-mt_i2sxZc-ER8

## Ready when they can

- State the defining property and prove uniqueness up to a null set
- Recover conditional expectation from a finite partition and explain why a constant conditional mean need not imply independence
- Use the tower property for nested sigma-algebras and the L2 projection interpretation on worked examples

## Lesson: Forecasting with what you know

Work on a probability space (Omega,F,P). Let X be real with E[|X|]<infinity, and G be a sub-sigma-algebra of F. Conditional expectation Y=E[X|G] exists and is integrable and G-measurable. It satisfies E[1_A Y]=E[1_A X] for every A in G. Here 1_A is 1 on A and 0 elsewhere. The identity equates integrals over A, not normalized averages. A null set has probability 0; almost surely means outside a null set.

If G is generated by a finite measurable partition A_1,...,A_n, a G-measurable forecast is constant on each block. On a block A with P(A)>0, the defining identity gives its value c=E[1_A X]/P(A). For finite outcomes, add value times outcome probability within A, then divide by P(A). An unweighted average works when the outcomes within A are equally likely. On a probability-zero block, any finite constant works.

**Example.** Suppose outcomes a,b,c have probabilities 0.1,0.4,0.5 and X-values 1,6,9. G distinguishes {a,b} from {c}. The first block has probability 0.5 and weighted total 0.1(1)+0.4(6)=2.5. Its forecast is 2.5/0.5=5. The singleton block's forecast is 9.

Suppose Y,Z satisfy the definition. D=Y-Z is integrable and G-measurable. For A={D>0} in G, subtract their identities: E[1_A D]=0. A nonnegative variable with mean 0 is 0 almost surely: otherwise some set where it is at least 1/n would have positive probability and force a positive mean. Thus P(D>0)=0. Swap Y and Z to get P(D<0)=0, so Y=Z almost surely.

Taking A=Omega gives E[E[X|G]]=E[X]. For partition-block forecasts c_i, this says E[X]=sum_i P(A_i)c_i. The nested tower property says that if H is a sub-sigma-algebra of G, then E[E[X|G]|H]=E[X|H] almost surely. The outer conditioning uses the coarser information. No independence is required.

**Example.** Let X count heads in three independent fair coin flips. G records the first flip. After heads, the forecast is 1+0.5+0.5=2. After tails, it is 0+0.5+0.5=1. Each branch has probability 1/2, so the forecast's mean is (2+1)/2=1.5. This equals E[X]=0.5+0.5+0.5.

If integrable X is independent of G, E[X|G]=E[X] almost surely. The constant E[X] is integrable and G-measurable. For every A in G, independence gives E[1_A X]=P(A)E[X], which also equals E[1_A E[X]]. Thus the constant satisfies the definition, and uniqueness identifies it as the forecast.

For E[X^2]<infinity, use L2(F), the space of square-integrable real variables, identifying variables equal almost surely. Its inner product is E[UV]. The G-measurable elements form a closed subspace L2(G). Y=E[X|G] is the orthogonal projection of X onto L2(G). Its residual satisfies E[(X-Y)Z]=0 for every Z in L2(G). This projection description requires square integrability.

**Example.** For W in L2(G), orthogonality gives E[(X-W)^2]=E[(X-Y)^2]+E[(Y-W)^2]. Thus Y uniquely minimizes mean squared error up to null sets. With trivial G, predictors are constants. If X is 0 or 8 with equal probability, Y=4. A constant c has error (c^2+(8-c)^2)/2=(c-4)^2+16, minimized at c=4 with value 16.

If integrable X is already G-measurable, X itself satisfies both definition requirements. Hence E[X|G]=X almost surely. With full information G=F, the forecast keeps the observed value. On a finite space with positive outcome probabilities, the full sigma-algebra distinguishes singleton blocks, each with its own X-value.

**Example.** Matching overall means does not verify conditional expectation. Let a,b be equally likely, with X(a)=0 and X(b)=4, and let G contain all subsets. The constant Y=2 has E[Y]=E[X]=2. But for A={a}, E[1_A Y]=1 and E[1_A X]=0. It fails the defining identity on a known event. Check integrability, G-measurability and the identity on every G-event.

**Example.** Nesting cannot be dropped from the tower identity. Let X be 0 or 2 with equal probability. Let G be trivial and let H reveal X. Then E[X|G]=1, so E[E[X|G]|H]=1. But E[X|H]=X, which is 0 or 2. Here H is not contained in G, and the identity fails.

**Example.** A constant conditional mean does not prove independence. Let X take -2,0,2 with probabilities 1/4,1/2,1/4. Let G reveal whether X=0. Both information blocks have mean 0, so E[X|G]=0=E[X]. Yet on A={X=0}, the probability of X=0 becomes 1 instead of 1/2. The conditional distributions differ even though their means agree.

**Recap.** For integrable X, match integrals on every G-event. Nested conditioning obeys the tower property. For square-integrable X, the forecast is the projection onto L2(G).

*The lesson, questions, worked solutions and flashcards were written for this dataset.*

## Practice

18 questions on this page, each with its working shown.

## Needs first

- [Sigma-Algebras and Measurable Sets](https://lightmysky.com/learn/mathematics/sigma-algebras-and-measurable-sets-mt_cpvegazufk)
- [The Lebesgue Integral and What It Repairs](https://lightmysky.com/learn/mathematics/the-lebesgue-integral-and-what-it-repairs-mt_KO92nLc5YU)

## Optional connections

- [Hilbert Spaces and Orthogonal Projection in Infinite Dimensions](https://lightmysky.com/learn/mathematics/hilbert-spaces-and-orthogonal-projection-in-infinite-dimensions-mt_xmKq8SAgvy)

## Opens up

- [Martingales and Optional Stopping](https://lightmysky.com/learn/mathematics/martingales-and-optional-stopping-mt_198uXX3jRJ)
- [Markov Chains and the Memoryless Assumption](https://lightmysky.com/learn/mathematics/markov-chains-and-the-memoryless-assumption-mt_2wDa_JxJ_o)
