Elementary Cellular Automata
There are 256 elementary cellular automata, where "elementary" means that there is a single row of cells, with binary values, and update rules that depend only on nearest-neighbour interactions. They are described at http://mathworld.wolfram.com/ElementaryCellularAutomaton.html
Our artist in residence asked if anyone had a program that would generate the patterns produced by these simple automata. I said it would only take a few minutes to write one in Matlab. Here's the result. It demonstrates the use of sub2ind to write very compact code.
In this function, the width of the pattern (the length of the array of cells) may be restricted, in which case the 1D array is taken to be circular to determine the states of the end elements. Random noise may also be added to the processing if required.
Cita come
David Young (2025). Elementary Cellular Automata (https://it.mathworks.com/matlabcentral/fileexchange/26929-elementary-cellular-automata), MATLAB Central File Exchange. Recuperato .
Compatibilità della release di MATLAB
Compatibilità della piattaforma
Windows macOS LinuxCategorie
- Sciences > Biological and Health Sciences >
- Sciences > Physics > Polymers & Soft Matter >
- Sciences > Physics > Thermodynamics & Statistical Physics >
- Sciences > Material Sciences > Polymers >
Tag
Riconoscimenti
Ispirato: EternalTime/CellularAutomata
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!Scopri Live Editor
Crea script con codice, output e testo formattato in un unico documento eseguibile.
