Jump to content

Abelian sandpile model: Difference between revisions

m
added websites with many examples
m (→‎{{header|Pascal}}: added link to python abelian (64))
m (added websites with many examples)
Line 5:
The task requires the creation of a 2D grid of arbitrary size on which "piles of sand" can be placed. Any "pile" that has 4 or more sand particles on it ''collapses'', resulting in '''four particles being subtracted from the pile''' and '''distributed among it's neighbors.'''
 
It is recommended to display the output in some kind of image format, as terminal emulators are usually too small to display images larger than a few dozen characters tall. As an example of how to accomplish this, see the [https://rosettacode.org/wiki/Bitmap/Write_a_PPM_file Bitmap/Write a PPM file] task.<BR>
[http://www.math.cmu.edu/~wes/sand.html Examples up to 2^30, wow!]<BR>
 
[http://www.natureincode.com/code/various/sandpile.html javascript running on web]<BR>
'''Examples:'''
 
Anonymous user
Cookies help us deliver our services. By using our services, you agree to our use of cookies.