vants
simulate a population of generalized virtual ants
vants -help
or
vants [-width integer] [-height integer] [-num integer]
[-rule string] [-dense double] [-steps integer]
[-seed integer] [-inv] [-mag integer] [-term
string]
Simulates and plots a population of generalized virtual ants (vants). The behavior of the vants is determined by a bit string with length equal to the number of states that each cell in the vants' grid world can take. If a vant walks on a cell in state s, then the vant turns right if the s'th bit of the rule string is 1 and left if it is 0. As it leaves the cell the vant changes the state of the old cell to (s + 1) modulo the number of states.
Simulate and plot a population of virtual ants (vants). The behavior of the vants is determined by a bit string with length equal to the number of states that each cell in the vants' grid world can take. If a vant walks on a cell in state S, then the vant turns right if the S'th bit of the rule string is 1 and left if it's 0. As it leaves the cell the vant changes the state of the old cell to (S + 1) % NUMSTATES.
Miscellany
It is definitely worthwhile to simulate multiple vants as the possible composite behavior of multiple vants is far
different than a single vant. In fact, multiple vants can invert the work of other vants, which yields interesting deconstructive behavior.
Bugs
No sanity checks are performed to make sure that any of the options make sense.
Options
-width | Width of the plot in pixels. | 200 |
-height | Height of the plot in pixels. | 200 |
-num | Number of ants. | 1 |
-rule | Rule string. | 10 |
-dense | Density of random crud. | 0.0 |
-steps | Number of simulated steps. | 100000000 |
-seed | Random seed for initial state. | 0 |
-inv | Invert all colors? | False |
-mag | Magnification factor. | 1 |
-term | How to plot points. | None |