PhysSandbox
Classical MechanicsWaves & SoundElectricity & MagnetismOptics & LightGravity & OrbitsLabs
🌙Astronomy & The Sky🌡️Thermodynamics🌍Biophysics, Fluids & Geoscience📐Math Visualization🔧Engineering🧪Chemistry

More from Math Visualization

Other simulators in this category — or see all 84.

View category →
NewUniversity / research

LMS / NLMS Adaptive Noise Cancellation

Primary p = s + v with v a fixed unknown FIR of Gaussian reference x[n]. Watch an L-tap FIR adapt by LMS or NLMS so error e = p − wᵀx → s; running MSE and ‖w − h‖.

Launch Simulator
NewUniversity / research

DCT & JPEG Quantization (8×8)

64×64 luma: 8×8 DCT with −128 shift, ISO luminance quant table scaled by JPEG quality, or zigzag AC truncation (keep K). Click a block for coefficient heatmaps and zigzag trace.

Launch Simulator
NewUniversity / research

PLL (Phase-Locked Loop)

Discrete-time analog-style PLL: multiplier PD e = K_d sin(φ_ref − φ_VCO), PI loop filter, VCO ω = ω_fr + K_v u; step ω_ref to explore lock, capture, and steady-state phase error.

Launch Simulator
NewUniversity / research

ΔΣ (1-bit) Modulator

First- and second-order discrete-time ΔΣ with ±1 quantizer: shaped quantization noise, sine test tone, boxcar reconstruction, and Hann-windowed error spectrum (last 1024 samples).

Launch Simulator
NewUniversity / research

Polyphase L/M Resampling

Zero-stuff by L, Hamming-windowed sinc FIR at the high rate with min(π/L,π/M) cutoff, then decimate by M; spectra in/out and Noble-identity polyphase intuition.

Launch Simulator
NewUniversity / research

Mandelbrot Deep Zoom

Drag/wheel deep zoom into the Mandelbrot set with smooth continuous coloring and named landmarks.

Launch Simulator
PhysSandbox

Interactive physics, chemistry, and engineering simulators for students, teachers, and curious minds.

Physics

  • Classical Mechanics
  • Waves & Sound
  • Electricity & Magnetism

Science

  • Optics & Light
  • Gravity & Orbits
  • Astronomy & The Sky

More

  • Thermodynamics
  • Biophysics, Fluids & Geoscience
  • Math Visualization
  • Engineering
  • Chemistry

© 2026 PhysSandbox. Free interactive science simulators.

PrivacyTermsContact
Home/Math Visualization/Markov Chain Mixing

Markov Chain Mixing

A Markov chain evolves a probability vector by repeated multiplication with a transition matrix. The simulator shows a three-state chain, current probabilities, convergence toward the stationary distribution, total variation distance, a detailed-balance cue, and a spectral-gap proxy for mixing speed.

Who it's for: Probability, stochastic processes, Markov chain Monte Carlo, statistical physics, data science, and algorithms courses.

Key terms

  • Markov chain
  • Transition matrix
  • Stationary distribution
  • Mixing time
  • Detailed balance
  • Spectral gap

Self-loops slow mixing; directional bias can break detailed balance while preserving a stationary distribution.

Live graphs

Transition matrix

0.72
0.08
0
20

Measured values

Stationary π0.31, 0.39, 0.31
TV distance0.0000
Spectral gap proxy0.280

How it works

Markov chain mixing visualizer with transition matrix, stationary distribution, total variation distance, detailed balance, and spectral gap.

Key equations

p_{t+1}=p_t P, πP=π
Mixing speed is controlled by eigenvalues; larger spectral gap means faster convergence

Frequently asked questions

What is a stationary distribution?
It is a distribution pi such that pi P = pi. If the chain is ergodic, repeated transitions converge to this distribution from any starting state.
Why does the spectral gap matter?
The second-largest eigenvalue controls how fast transients decay. A larger gap generally means faster mixing.