Diffusion-limited aggregation

In this example, we see freely diffusing particles (blue) aggregate into a crystal (white). This is implemented as two communicating grids: one CPM (blue) and one CA (white).

The "diffusion" is implemented as a Cellular Potts Model (CPM) with a hard volume range constraint, such that each "cell" can only be 1 or 2 pixels big. Without any other constraint, this ensures that the particles follow Brownian motion. In a way, this is not really a CPM since there is no Hamiltonian H, but it still follows the same copy attempt dynamics as a real CPM.

The white crystal grows on a cellular automaton (CA), which has been seeded with a single point in the middle of the grid. Every step, this grid updates according to the following rules:

  1. A pixel of type 1 (crystal) remains type 1 (once a particle has aggregated, it cannot become free again)
  2. A pixel of type 0 (background) becomes type 1 (crystal) if and only if: