MatrixTranslatorFrom VLEThe translator of grid (matrix) of DEVS models (not necessary CellDevs model) : <?xml version="1.0" ?> <celldevs> <grid> <dim axe="0" number="11" /> <dim axe="1" number="7" /> </grid> <cells connectivity="neuman|moore" library="libcellule" > <libraries> <library index="1" name="lib1" /> <library index="2" name="lib2" /> </libraries> <prefix>cell</prefix> <init> 0 0 0 1 1 1 1 1 1 1 0 0 0 0 0 1 1 1 1 1 1 0 0 0 0 0 0 1 1 1 1 0 0 0 0 0 0 0 0 1 1 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 <!-- 1: cell is present, 0: no cell. Matrix line by line from 0,0 (top left) to 11,6 (bottom right). --> </init> </cells> </celldevs> The init part is optional. If it isn't presented then the same library is used for all cell of matrix. There are two possible specifications of the library:
The names of port are the following:
These input ports are utsed by CellDevs for exchange of cell states. Warning, important naming rule : The names of the cells start at 1. The first cell of a cellular automaton is (1, 1) if the automaton is in two dimensions. |