MPE StudioMath of Planet Earth
Statistical Toolkit · 10

Markov Chain Monte Carlo: Reconstructing Distributions

Recovering a complex density through random exploration

When a target can be evaluated only up to a constant, MCMC can still generate samples. Their empirical distribution reconstructs the normalized density.

watchone idea
→
manipulateone example
→
leave withone intuition

The essential idea: a long-run sample pattern can recover a distribution whose normalization has no closed form.

Watch the concept

One Concept · One Example

Markov Chain Monte Carlo: Reconstructing Distributions video thumbnail▶

Markov Chain Monte Carlo: Reconstructing Distributions

Presented by Charlotte Moser

Watch on YouTube ↗

What to notice

The idea in 30 seconds

A density can be known without its constant

Target shape

The unnormalized function is easy to evaluate point by point even though its integral is not available analytically.

f(x)=exp(x+4x2−2x3−4x4)

MCMC reconstruction

After burn-in, a histogram of chain states approximates p(x) = f(x)/Z.

samples→empirical density≈p(x)
Explore

Build the chain, then reconstruct the density

First reproduce the six proposal, random-number, accept-or-reject decisions from the slides. Then use many chain states to construct the empirical PDF.

EXAMPLE 1 · BUILD THE CHAIN

The first six Metropolis decisions

Start at x₀ = 0. Each proposal uses the Gaussian random move from the slides. Compare the uniform draw r with min(1, α): accept the proposal, or repeat the previous state.

01chain state xₖiteration k

The open circle is the current proposal. A rejection creates a horizontal segment because xₖ = xₖ₋₁.

kproposal x′ratio αrandom rnext state xₖdecision
1-0.64902.39390.7203-0.6490accept
2-1.40750.01140.0923-0.6490reject
3-1.49460.00120.3456-0.6490reject
4-1.20770.29150.5388-0.6490reject
5-0.84591.35780.6852-0.8459accept
6-1.69780.00000.8781-0.8459reject
EXAMPLE 2 · FROM CHAIN TO PDF

Use enough states to reconstruct the density

Once the chain has mixed, its empirical histogram becomes an approximation of the unknown normalized PDF.

-1.61.6
reconstructionnormalized target for comparison
KEY TAKEAWAY

Strategic correlated sampling can recover an unknown, multimodal probability density without calculating its normalization constant.