HomeArticlesChemistry & Materials

FHP Lattice Gas: Navier-Stokes From True/False Bits on a Hexagon

Boolean particles, streaming and collision rules on a hexagonal lattice, and how coarse-graining recovers fluid dynamics from pure discrete geometry.

mysimulator teamUpdated June 2026≈ 8 min read▶ Open the simulation

Fluid dynamics from a grid of true/false bits

The FHP model — named for Uriel Frisch, Brosl Hasslacher and Yves Pomeau, who introduced it in 1986 — is one of the strangest-looking routes to fluid dynamics on record: it recovers the incompressible Navier-Stokes equations from a grid of boolean particles following absurdly simple local rules, with no floating-point pressure or velocity field anywhere in the model. Each site on a two-dimensional hexagonal lattice can hold at most one particle moving in each of six possible directions (the six edges of a hexagon), so the entire state of the system is just a handful of bits per site.

live demo · boolean particles streaming and colliding on a hexagonal lattice● LIVE

Two steps, repeated forever: stream and collide

Every time step alternates two local operations. In the propagation (streaming) step, every particle moves one lattice spacing in the direction it is already travelling, landing on the corresponding neighbouring site. In the collision step, particles that have just arrived at the same site are redirected according to a fixed rule table that conserves both the number of particles and total momentum at that site — for example, two particles arriving head-on (moving in opposite directions) are the classic FHP collision case, and the rule scatters them onto the two directions perpendicular to their original line of travel, chosen with a coin flip to avoid an unphysical bias.

// one FHP time step, conceptually
propagate();   // every particle moves 1 site in its direction of travel
collide();     // at each site: apply the local rule table
               //   - conserves particle count at that site
               //   - conserves total momentum at that site
               //   - the specific outgoing directions are looked up from
               //     a small table indexed by which incoming directions
               //     were occupied

Why a hexagonal lattice, not a square one

An earlier lattice gas on a square grid (the HPP model, 1976) has a fatal flaw: its equilibrium distribution is not isotropic enough, and the fourth-rank tensor that appears in the derivation of the macroscopic momentum equation does not reduce to the rotationally invariant form Navier-Stokes needs — the square lattice's four-fold symmetry leaks into the fluid behaviour as a directionally dependent viscosity. FHP's hexagonal lattice has six-fold symmetry, which turns out to be exactly enough discrete rotational symmetry for the relevant tensor to become isotropic in the continuum limit. This was the specific insight that made FHP work where HPP had failed — the choice of lattice geometry is not cosmetic, it is what makes the emergent physics correct.

Coarse-graining into Navier-Stokes

No single particle obeys anything like a fluid equation — the physics only appears after coarse-graining: average particle occupation over many lattice sites and many time steps to get a smoothly varying density and velocity field, and that averaged field obeys the incompressible Navier-Stokes equations up to a correction. The correction is a subtlety worth knowing: FHP's derived momentum equation is not perfectly Galilean invariant, because the lattice gas's equilibrium distribution is not quite Maxwell-Boltzmann. This shows up as a density-dependent multiplicative factor g(rho) in front of the nonlinear advection term, which has to be corrected for (either analytically or numerically) to recover the exact Navier-Stokes form rather than a lattice-gas-flavoured approximation of it.

From lattice gas to Lattice Boltzmann

FHP's boolean occupation numbers mean the model is inherently noisy — any macroscopic quantity you extract is really a statistical average over particle counts, and getting a smooth velocity field requires spatial or temporal averaging over many sites or many runs, which is expensive. The Lattice Boltzmann Method (LBM), developed in the years after FHP, replaces the boolean per-direction occupation numbers with real-valued single-particle distribution functions — essentially pre-averaging the boolean population directly instead of averaging over an ensemble of boolean simulations after the fact. LBM keeps FHP's core idea (a fixed lattice, local streaming and collision rules, recovery of Navier-Stokes in the continuum limit) but eliminates the statistical noise, and it is LBM rather than the original boolean FHP model that ended up in serious computational fluid dynamics use for complex geometries, porous media and multiphase flow.

Frequently asked questions

How can a grid of true/false bits behave like a fluid?

No single bit behaves like a fluid — the fluid behaviour only emerges after averaging particle occupation over many lattice sites and time steps. That coarse-grained average obeys a form close to the incompressible Navier-Stokes equations, because the streaming-and-collision rules conserve mass and momentum locally, the same conservation laws real fluids obey.

Why does FHP use a hexagonal lattice instead of a simpler square grid?

An earlier square-lattice model (HPP) has only four-fold symmetry, which is not enough to make the derived viscosity isotropic — the fluid behaves differently depending on direction, which real fluids don't. The hexagonal lattice's six-fold symmetry is sufficient for the relevant tensor to become rotationally invariant in the continuum limit, which is what makes FHP recover proper Navier-Stokes behaviour.

Is FHP still used for real fluid dynamics simulations today?

Rarely in its original boolean form, because it is statistically noisy and needs heavy averaging to extract a smooth field. Its direct successor, the Lattice Boltzmann Method, replaces the boolean occupation numbers with real-valued distribution functions and keeps the same streaming-and-collision structure, and LBM is what actually gets used in modern computational fluid dynamics for complex geometries and multiphase flow.

Try it live

Everything above runs in your browser — open FHP Lattice Gas and change the parameters while it is running. Nothing is installed, nothing is uploaded, the whole model lives in one tab.

▶ Open FHP Lattice Gas simulation

What did you find?

Add reproduction steps (optional)