6 Cellular Automata – A Computational Point of View 197
While the first solution of the problem takes 3n time steps to synchronize
the n cells in between the cells in state #, Goto [18] was the first who presented
a minimal time solution.
Lemma 1. The minimal solution time for the FSSP is 2n −2,wheren is the
number of cells to be synchronized.
Proof. In contrast to the assertion assume there is a faster solution taking
some time t
f
< 2n − 2. Observe that the cells which are initially in the
quiescent state may leave the quiescent state not before their left neighbor
is in a non-quiescent state. Therefore, the rightmost cell n cannot leave the
quiescent state before time n − 1. It takes another n −1 time steps to send a
feedback of this activation back to the general. Since t
f
< 2n −2, the general
fires independently of such a feedback.
Now consider the problem with 2n − 1 cells. Since the cells are determin-
istic, the general fires again at time t
f
< 2n − 2. But at this time step the
rightmost cell 2n−1 is still in the quiescent state, since it takes at least 2n−2
time steps to activate it. &'
Next we present an algorithm that is not time optimal. It takes 3n time,
but reveals basic procedural methods.
Algorithm 1. The FSSP can be solved by dividing the array in two, four,
eight etc. parts of (almost) the same length until all cells are cut-points.
Exactly at this time the cells change to the firing state synchronously. The
divisions are performed recursively. First the array is divided into two parts.
Then the process is applied to both parts in parallel, etc.
In order to divide the array into two parts, the general sends two signals S1
and S2 to the right (cf. Figure 6.14). Signal S1 moves with speed 1, that is,
one cell per time step, and signal S2 with speed 1/3,thatis,onecellevery
three time steps. When signal S1 reaches the right end, a signal S3 is sent
back to the left with speed 1. Signals S2 and S3 meet in the center of the
array. Dependent on whether the length of the array is even or odd the center
is represented by two or one cell. Next, the center cell(s) becomes a general. It
sends signals S1 and S2 to the left and to the right. This process repeats until
all cells are generals. At this time they change to the firing state synchronously.
Since the times needed to divide the sub-arrays are bounded by 3n/2,
3n/4, 3n/8, and so on, altogether the algorithm takes at most 3n time steps.
&'
The next step towards a time optimal solution is to set up additional
signals in order to determine the cut-points earlier.
Algorithm 2. The previous algorithm is modified as follows (cf. Figure 6.15).
When signal S1 arrives at the right end, the end cell becomes a general and
sends two signals S3 and S4
to the left. Signal S4 behavesassignalS2 except
for the moving direction, that is, it moves with speed 1/3 to the left. The center