A cellular automata model of fractal drainage systems

Sample image

Cellular automata

Cellular automata and particle systems are the most obvious approaches to modelling fractal drainage systems.

Two layer model

I use a two-layer cellular automata for this model:
  • One layer represents the density of the liquid at each point;
  • The other represents the height of the landscape above the ground;

Simulated fluid flow

The liquid flows across the surface (described by the array of height values) under the influence of gravity.

In the interests of getting the simulation to run at a reasonable rate, I employed my own model of fluid flow on a surface. This uses the [Moore neighbourhood] - with weighted corner cells in an attempt to get reasonable degree of isotropy.

A partitioning system is used to ensure that the volume of fluid is conserved. In each time step the water in each cell is divided into eight approximately-equal portions - and one is allocated to each neighbour.

Fluid flow between that cell and its neighbour is proportional to their height difference - and to the volume of fluid in the higher cell. However fluid flow is limited to the maximum value in the higher cell allocated to that neighbour. This ensures that the overall fluid volume is conserved.

Simulated eroding landscape

The landscape also has a cellular automaton governing its behaviour - this time using the [von-Neumann neighbourhood].

The landscape rises up (to replace the material lost to erosion), undergoes simple diffusion processes, and is corroded by fluid flow across the surface.

The corrosive effect is proportional to the volume of fluid moving over a given spot.

Sample code

A Java code fragment that implements the automaton is available for reference purposes here.

Further work

There are several undesirable effects in the model - which future work will hopefully redress.

The most obvious problem is that the program rarely produces a fractal pattern over a wide range. A branching pattern is visible - but it does not extend very far.

In order to refress this I plan a three-layer model. Two of the layers will represent height, with one indicating the general slope, and the other showing local deviations from this due to corrosion. It is hoped that this will allow more control over the behaviour of the model. It would be like modelling topsoil - or like modelling deviations from an overall field in plasma caused by local ionisation.

Another thing that needs doing at the same time is reducing the effect of diffusion on the landscape - this currently blurs things too much.

Fianlly, more realistic fluid models would no-doubt help. Real fluids have volume and momentum - both of which would probably lead to more realistic effects.

Real rivers bend and twist spontaneously - since they erode their banks on the outside of curved and deposit material on the insides of them. Modelling this effect would stop rivers from all running in straight lines.

To visit the applet described above, click here.

tim@tt1.org | http://fractaldrainage.com/