Go implementation of the original sandpile experiment showing Self-Organized Criticality (SOC).
To run the simulation with a grid of 50x50 and 1M iterations:
go run sand.go --size 50 --iters 1_000_000 --chart
End result of a 500 width pile after 100k iterations:
go run sand.go -s 500 -i 100_000 --pixel
End result of a 200 width pile after 4M iterations with height of 12:
go run sand.go -x 12 -s 200 -i 4_000_000 --pixel
see all options:
go run sand.go --help