Let x=(xa,xb)∼N(μ,Σ) with partitions μ=(μa,μb) and Σ=(ΣaaΣabΣbaΣbb). How do you derive the conditional distribution of xa given xb by completing the square with the precision matrix Λ=Σ−1?

Probability and statistics, Multivariate Gaussian
Level L4 Advanced. Length Long. Nature Mat Mathematical.

What's being asked

Completing the square in a partitioned quadratic form, then converting back to covariance blocks using the block inverse.

Key idea

xa∣xb∼N ⁣(μa+ΣabΣbb−1(xb−μb), Σaa−ΣabΣbb−1Σba). In precision form, the conditional covariance is Λaa−1.

Steps

  1. The log-density is −12(x−μ)⊤Λ(x−μ) plus a constant. Write u=xa−μa, v=xb−μb and partition Λ into blocks Λaa,Λab,Λba,Λbb.
  2. Expand: −12[u⊤Λaau+2u⊤Λabv+v⊤Λbbv], using Λba=Λab⊤ (symmetry).
  3. Fix xb (so v is a constant) and keep only terms in u: −12u⊤Λaau−u⊤Λabv.
  4. Complete the square: this equals −12(u+Λaa−1Λabv)⊤Λaa(u+Λaa−1Λabv)+const. So xa∣xb is Gaussian with precision Λaa and mean μa−Λaa−1Λab(xb−μb).
  5. Use the block-inverse identities with the Schur complement Σ/Σbb=Σaa−ΣabΣbb−1Σba: Λaa=(Σ/Σbb)−1 and Λab=−(Σ/Σbb)−1ΣabΣbb−1.
  6. Substitute: Λaa−1Λab=−ΣabΣbb−1, so the mean is μa+ΣabΣbb−1(xb−μb) and the covariance is Λaa−1=Σaa−ΣabΣbb−1Σba.
  7. Check against the scalar case: this gives mean μa+σabσb2(xb−μb) and variance σa2−σab2/σb2. The covariance does not depend on xb.

Common mistakes

How long your answer should be

One page; 10 minutes.

Last checked on 4 December 2026.

Read this

Previous in Probability and statistics: For a natural exponential family p(x∣η)=h(x)exp⁡(η T(x)−A(η)), why is A′(η)=E[T(X)] and A′′(η)=Var(T(X)), and hence why does the MLE satisfy A′(η^)=1n∑iT(xi)? What does this give for exponential data 2,5,3,6,4?
Next in Probability and statistics: Let U1,U2 be independent Uniform(0,1). Define R=−2ln⁡U1, Θ=2πU2, X=Rcos⁡Θ and Y=Rsin⁡Θ. Why are X and Y independent N(0,1) variables, and what are (X,Y) for U1=0.5, U2=0.25?