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

More from Thermodynamics

Other simulators in this category — or see all 31.

View category →
NewSchool

Leidenfrost Effect (Toy)

T_plate vs ~200 °C threshold: vapor gap and lifetime curves — pedagogical, not measured boiling data.

Launch Simulator
NewUniversity / research

Peltier & Seebeck (Schematic)

Current pumps heat across junction; ΔT drives toy mV — same couple, two modes.

Launch Simulator
NewSchool

Joule Expansion

Ideal gas into vacuum: Q = W = ΔU = 0; ΔS = nR ln 2 when volume doubles.

Launch Simulator
NewUniversity / research

2D Ising Model

Square lattice Metropolis: kT/J vs |m| and E; T_c ≈ 2.27; optional field h.

Launch Simulator
NewUniversity / research

Lorentz Gas (Billiard)

Point particle specularly reflected from fixed disks in a box: chaotic paths and MSD growth toward diffusion.

Launch Simulator
NewUniversity / research

Site Percolation (2D)

Square lattice occupation p: clusters, left–right spanning, p_c ≈ 0.593; rough box-counting D̂ on the largest cluster.

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/Thermodynamics/Maxwell’s Demon (Toy)

Maxwell’s Demon (Toy)

Maxwell's Demon is a famous thought experiment challenging the second law of thermodynamics. This simulator brings it to life as a 2D billiard system. Particles move within a box, colliding elastically with each other and the walls. A central, intelligent 'demon' controls a gate. Based on a configurable speed threshold, the demon allows only fast-moving particles to cross from left to right and only slow-moving particles to cross from right to left. Over time, this selective sorting can create a temperature gradient, with the average kinetic energy (and thus temperature) higher on the right side than the left, seemingly decreasing entropy within the box. The core physics involves the kinetic theory of gases, where temperature is proportional to the mean square speed: (1/2)m⟨v²⟩ = (3/2)k_B T for a 3D ideal gas (conceptually adapted here for 2D). The simulation demonstrates the paradox: the demon's actions appear to create order from disorder without doing macroscopic work. The key learning point is the resolution to the paradox, often attributed to Landauer's principle. The act of acquiring, storing, and erasing information about particle speeds (e.g., in the demon's 'memory') has a thermodynamic cost. Erasing one bit of information dissipates at least k_B T ln 2 of heat, ultimately increasing the entropy of the universe by at least as much as the demon decreases within the box. This simulator simplifies reality by using frictionless 2D elastic collisions, point particles, and an idealized, instantly responsive gate. By interacting with it, students can visualize the statistical nature of the second law, understand the connection between information and thermodynamics, and explore how a simple sorting rule can seemingly violate—but ultimately uphold—one of physics' most fundamental laws.

Who it's for: Undergraduate physics or engineering students studying thermodynamics, statistical mechanics, or the foundations of information theory. It is also valuable for educators and enthusiasts seeking an intuitive grasp of Maxwell's Demon and Landauer's principle.

Key terms

  • Maxwell's Demon
  • Second Law of Thermodynamics
  • Entropy
  • Kinetic Theory
  • Landauer's Principle
  • Thermodynamics
  • Statistical Mechanics
  • Information Theory

Demon

0.38

Landauer: erasing one bit of which-side information dissipates at least kT ln 2 — the hidden entropy bucket.

Measured values

MeansTop of canvas

How it works

Thought experiment made clickable: sorting by speed looks like breaking the second law until the demon pays an information–energy bill.

Frequently asked questions

Doesn't this simulator prove the second law of thermodynamics is wrong?
No. The simulator shows the apparent paradox but not its full resolution. The demon's operation requires measuring particle speeds and deciding when to open the gate. According to modern understanding (Landauer's principle), the demon must store and eventually erase this information, which dissipates heat and increases total entropy. The net entropy change of the universe always increases, preserving the second law.
What is the real-world significance of Maxwell's Demon?
While a purely theoretical construct, the demon profoundly influenced physics by linking information processing to thermodynamics. It underpins the thermodynamic limits of computing, showing that irreversible computation (like erasing data) has a minimal energy cost. This principle is crucial for understanding the ultimate energy efficiency of computers and emerging nanoscale technologies.
Why are the particle collisions perfectly elastic? Is that realistic?
Perfectly elastic collisions are a simplification that conserves the total kinetic energy of the system, making it an isolated 'ideal gas.' In real gases, collisions are nearly elastic for monatomic gases like argon at moderate conditions. This simplification lets us focus on the entropy changes caused by sorting, not by energy loss to internal degrees of freedom or heat.
Can I actually build a Maxwell's Demon?
Not in the idealized form shown. However, modern experiments using single-molecule feedback systems or quantum dots have created 'information engines' that realize the demon's core function. These devices explicitly account for the information-to-energy conversion, validating Landauer's principle and demonstrating the thermodynamic cost of information processing.