Translations of Cellular Automata for Efficient Simulation
Cellular automata can be described in many different ways, one of which is to use a special purpose description language. Here, the language CDL is used as the source for translations into Java or C code for computer simulations. Several coding styles are generated automatically: The state transition function can be coded as Java code, as C code with stubs for integration into a Java simulation environment, as a lookup table, or as Java code consisting of boolean functions which allow the parallel simulation of 32 or 64 cells on one processor. The coding styles are compared for several examples and it is found that the boolean function style (also called multispin-coding) realized in Java is often, but not always, significantly more efficient than even native C code.