SeeSchloß

| ← this is not a pipe

Isix

Isix is a cellular automaton, written using the D programming language for Linux, and which can probably run under OS X and *BSD as well.

Source code and binaries of Isix are available (the binaries are there because I guess not everybody has a D compiler on his machine).

I started this project to try D, and because I like cellular automata in general. Three modes are available to display the world : ncurses, stdout and DUI (which is GTK+2 for D)

isix-0.000, and ncurses
Impressive, heh ? Well... it's only a 0.001

isix-0.5, and DUI/GTK+2
Better isn't it ? Isix-0.5 using the GTK+2 GUI, with Conway's Game of Life rule.

isix-0.5-2, standard rule
And with the standard 3 states rule.

If, by chance, you were interested in this project, you can find the source there. To compile it yourself, you'll need DMD (and GCC, but I hope you already have it). You can probably use GDC instead of DMD, if you find out how to make it work.

By default, the world is the size of your term when using ncurses, 25×50 with stdout and 75×100 with DUI. You can switch between the interfaces with —ncurses, —stdout and —dui (default is DUI), and specify the size of the world with —cols=n and —lines=n.

Each cell can have any number of different states. You can change the number of states with —states=n, default is 3.

It is also possible to have a rules file (/etc/isix.rules, $HOME/.isix.rules or isix.rules) which specifies and names 2-states rules. An example file is found here : isix.rules. 2-states rules can be defined with the standard 23/3 format. The first numbers are what is required for a cell to stay alive, and the second set of numbers is the requirement for birth. This means with the 23/3 rule, a cell is born if and only if there are 3 neighbours and lives on if there are either 2 or 3 neighbours. Specifying a rule is done with —std=rule, where rule is either the name of a rule, defined in the isix.rules file, or a rule in the standard format (the number of states is automatically set to 2).

Future

Before saying "hrmm... but this thing is useless", remember I only do it to use the D programming language (which I find quite OK up to now) and forget the Java I'm learning at univ...

Now... I like cellular automata, btw my first C program (here) was a cellular automata quite similar to what Isix is for now. But Isix should go farther, if I'm not bored before. Anyway, the future should see a GUI, using DUI, the only one available for D and Linux, and above all more things to customize regarding the rules :

  • Ability to change the number of possible states (for example, only two states like in Conway's Game of Life) — Done !
  • Ability to modify the way the next state is calculated (ie, not only depending on the sum of the surrounding cells)
  • Ability to modify the states of the cells and the rules during the execution (with the GUI version) — Done !
seeschlossseeschloss.org