Iterative arrays with finite inter-cell communication

Iterative arrays whose internal inter-cell communication is quantitatively restricted are investigated. The quantity of communication is measured by counting the number of uses of the links between cells. In particular, iterative arrays are studied where the maximum number of communications per cell occurring in accepting computations is drastically bounded by a constant number. Additionally, the iterative arrays have to work in realtime. We study the computational capacity of such devices. For example, a result is that a strict and dense hierarchy with respect to the constant number of communications exists. Due to their very restricted communication, the question arises whether the usually studied decidability problems such as, for example, emptiness, finiteness, inclusion, or equivalence become decidable for such devices. However, it can be shown that all such decidability questions remain undecidable even if only four communications per cell are allowed. Finally, the undecidability results are shown to hold as well for one-way and two-way cellular automata having at most four communications per cell.


Introduction
Devices of homogeneous, interconnected, parallel acting automata have widely been investigated from a computational capacity point of view. Multi-dimensional devices with nearest neighbor connections whose cells are finite automata are commonly called cellular automata (CA). The cells work synchronously at discrete time steps. If the input mode is sequential to a distinguished communication cell, such devices are called iterative arrays (IA).
In connection with formal language recognition onedimensional iterative arrays have been introduced in Cole (1969), where it was shown that the language family accepted by realtime IAs forms a Boolean algebra not closed under concatenation and reversal. In Chang et al. (1987) it is shown that for every context-free grammar a two-dimensional lineartime iterative array parser exists. A realtime IA acceptor for prime numbers has been constructed in Fischer (1965). A characterization of various types of IAs in terms of restricted Turing machines and several results, especially speed-up theorems, are given in Ibarra and Palis (1985), (1988). Several more results concerning formal languages can be found, for example, in the survey (Kutrib 2009).
It is obvious that inter-cell communication is an essential resource for iterative arrays that can be measured qualitatively as well as quantitatively. In the first case, the number of different messages to be communicated by the cells is bounded by some fixed constant. IAs with this restricted inter-cell communication have been investigated in Umeo andKamikawa (2002, 2003) with respect to the algorithmic design of sequence generation. In particular, it is shown that several infinite, non-regular sequences such as exponential or polynomial, Fibonacci, and prime sequences can be generated in realtime. In connection with language recognition and decidability questions multi-dimensional IAs and one-dimensional (one-way) CAs with restricted communication have intensively been studied in Kutrib andMalcher (2009a, 2011), Worsch (2000).
For a quantitative measure of communication in iterative arrays the number of uses of the links between cells is counted. Additionally, it is distinguished between bounds There are quite a few results in the literature with respect to these measures. Results for (one-way) cellular automata may be found in Kutrib andMalcher (2010a, 2010b). In Kutrib andMalcher (2009b, 2010b) also cellular automata are investigated that are restricted with respect to the qualitative and the quantitative measure. The main results are in both cases hierarchy results and the undecidability of almost all commonly studied decidability questions such as emptiness, finiteness, equivalence, inclusion, regularity, and context-freeness. It should be noted that already a finite amount of communication per cell is sufficient to obtain undecidability results for cellular automata. First results on iterative arrays with restricted communication are presented in Malcher (2018) and comprise again hierarchy results as well as undecidability results for the above questions. Concerning the measure on the maximum communication per cell it has been shown that the undecidability results hold as long as at least a logarithmic number of communications per cells is allowed. Moreover, it is stated as an open question whether the undecidable questions become decidable when the allowed communication is even more restricted, namely, bounded by a constant number.
In this paper, we can answer the latter question negatively even if only four communications per cell are allowed. In addition, we establish a strict and dense hierarchy with respect to the constant number of communications. The paper is organized as follows. In the next section, we present some basic notions and definitions, introduce the classes of max communication bounded iterative arrays, and give an illustrative example. Then, in Sect. 3 we show that for every k ! 2, IAs with at most k þ 1 communications per cell are more powerful than devices with at most k communications per cell. For k 2 f0; 1; 2g it turns out that devices with at most k communications per cell can accept regular languages only. Section 4 is devoted to showing the undecidability of the usually studied decidability questions for IAs working in realtime and having at most four communications per cell. This is done by a reduction of the halting problem for counter machines (Minsky 1961). The ideas and constructions of Sect. 4 are applied in Sect. 5 where the known undecidability results for realtime one-way and two-way cellular automata with max bounded communication can essentially be improved to hold for machines with at most four communications per cell as well.
We would like to note that a preliminary version of this paper has been presented in Kutrib and Malcher (2019). Here, we have provided the full proofs of the results in Sect. 3. Moreover, the undecidability results in Kutrib and Malcher (2019) have been obtained by a reduction of Hilbert's tenth problem. Here, a different reduction is chosen which leads to more precise results in Sect. 4. Moreover, the results presented in Sect. 5 are new.

Definitions and preliminaries
We denote the non-negative integers by N. Let R denote a finite set of letters. Then we write R Ã for the set of all finite words (strings) consisting of letters from R. The empty word is denoted by k, and we set R þ ¼ R Ã n fkg. A subset of R Ã is called a language over R. A language L over some alphabet fa 1 ; a 2 ; . . .; a k g is said to be letter-bounded, if L a Ã 1 a Ã 2 Á Á Á a Ã k . For the reversal of a word w we write w R and for its length we write |w|. In general, we use for inclusions and & for strict inclusions.
A one-dimensional iterative array is a linear, semi-infinite array of identical deterministic finite state machines, sometimes called cells. Except for the leftmost cell each one is connected to its both nearest neighbors (see Fig. 1). For convenience we identify the cells by their coordinates, that is, by non-negative integers. The distinguished leftmost cell at the origin is connected to its right neighbor and, additionally, equipped with a one-way read-only input tape. At the outset of a computation the input is written on the input tape with an infinite number of end-of-input symbols to the right, and all cells are in the so-called quiescent state. The finite state machines work synchronously at discrete time steps. The state transition of all cells but the communication cell depends on the current state of the cell itself and on the information which is currently sent by its neighbors. The information sent by a cell depends on its current state and is determined by socalled communication functions. The state transition of the communication cell additionally depends on the input symbol to be read next. The head of the one-way input tape is moved to the right in each step. With an eye towards recognition problems the machines have no extra output tape but the states are partitioned into accepting and rejecting states.
Formally, an iterative array ðIAÞ denotes a system hS; F; A; B; O; s 0 ; b l ; b r ; d; d 0 i, where S is the finite, nonempty set of cell states, F S is the set of accepting states, A is the finite set of input symbols, B is the finite set of communication symbols, O 6 2 A is the end-of-input symbol, s 0 2 S is the quiescent state, b l ; b r : S ! B [ f?g s 0 s 0 s 0 s 0 s 0 a 1 a 2 a 3 · · · a n  Let M be an IA. A configuration of M at some time t ! 0 is a description of its global state which is a pair ðw t ; c t Þ, where w t 2 A Ã is the remaining input sequence and c t : N ! S is a mapping that maps the single cells to their current states. The configuration ðw 0 ; c 0 Þ at time 0 is defined by the input word w 0 and the mapping c 0 that assigns the quiescent state to all cells, while subsequent configurations are chosen according to the global transition function D that is induced by d and d 0 as follows: Let ðw t ; c t Þ, t ! 0, be a configuration. Then its successor configuration ðw tþ1 ; c tþ1 Þ ¼ Dðw t ; c t Þ is as follows.
We remark that we obtain the classical definition of IA, if we set B ¼ S and b l ðsÞ ¼ b r ðsÞ ¼ s for all s 2 S.
An input w is accepted by an IA M if at some time i during the course of its computation the communication cell enters an accepting state. The language accepted by M is denoted by L(M). Let t : N ! N, tðnÞ ! n þ 1 be a mapping. If all w 2 LðMÞ are accepted with at most t(|w|) time steps, then M and L(M) are said to be of time complexity t.
The family of all languages which are accepted by some type of device X with time complexity t is denoted by L t ðXÞ. If t is the function n þ 1, acceptance is said to be in realtime and we write L rt ðXÞ. Since for nontrivial computations an IA has to read at least one end-of-input symbol, realtime has to be defined as ðn þ 1Þ-time.
In the following we study the impact of communication in iterative arrays. The communication is measured by the number of uses of the links between cells. It is understood that whenever a communication symbol not equal to ? is sent, a communication takes place. Here we do not distinguish whether either or both neighboring cells use the link. More precisely, the number of communications between cell i and cell i þ 1 up to time step t is defined by comði; tÞ ¼ f j j 0 j\t and ðb r ðc j ðiÞÞ 6 ¼ ?
or b l ðc j ði þ 1ÞÞ 6 ¼ ?Þ gj: For computations we now consider the maximal number of communications between two cells. Let c 0 ; c 1 ; . . .; c tðjwjÞ be the sequence of configurations computed on input w by some iterative array with time complexity t(n), that is, the computation on w. Then we define mcomðwÞ ¼ maxf comði; tðjwjÞÞ j 0 i tðjwjÞ À 1 g: Let f : N ! N be a mapping. If all w 2 LðMÞ are accepted with computations where mcomðwÞ f ðjwjÞ, then M is said to be max communication bounded by f. We denote the class of IA that are max communication bounded by some function f by MCðf Þ-IA. In addition, we use the notation const for functions from O(1).
To illustrate the definitions we start with an example. In the next section it turns out that the non-regular language f a n b n j n ! 1 g is accepted by some realtime iterative array using at most three communications per inter-cell link. The following example reveals that only five communications per inter-cell link are sufficient to accept the non-semilinear and, hence, non-context-free language L ¼ f a 3nþ2b ffiffi n p c b 2n j n ! 1 g in realtime. Moreover, L is a subset of a Ã b Ã and, hence, a letter-bounded language.
Example 1 The language L belongs to L rt ðMCð5Þ-IAÞ.
The basic idea is to use the construction given in Mazoyer and Terrier (1999) where a cellular automaton is described such that the nth cell enters a designated state s exactly at time step 2n þ b ffiffi ffi n p c. We basically implement this construction, but realize it with speed 1/2 in contrast to the construction in Mazoyer and Terrier (1999). Hence, the nth cell enters a designated state exactly at time step 4n þ 2b ffiffi ffi n p c. When the communication cell reads the first b, it sends a signal with maximum speed to the right which arrives in the nth cell exactly at the moment when state s should be entered. In this case, another signal is sent with maximum speed to the left and the input is accepted if the latter signal reaches the communication cell when the end-of-input symbol is read. Thus, L is accepted by a realtime IA. Moreover, the construction given in Mazoyer and Terrier (1999) needs three right-moving signals. Thus, four right-moving signals and one left-moving signal are sufficient to accept L. This shows that the IA constructed is a realtime MCð5Þ-IA. h 3 k + 1 communications are better than k This section is devoted to studying the impact of the precise finite number k of communications between cells. It turns out that this number in fact matters unless it is very small. That is, we will obtain an infinite strict hierarchy for k ! 2, whereas the families of languages accepted with 0, 1, and 2 communications per inter-cell link coincide with the regular languages. We start at the bottom of the hierarchy.
Iterative arrays with finite inter-cell communication 5 The witnesses for the hierarchy are languages whose words are repetitions of unary blocks of the same size but with alternating symbols. For i ! 2 define Proof Any word from L hi is the concatenation of i unary blocks of the same size but with alternating symbols. The correct format of an input, namely to be of the form ða þ b þ Þ þ a Ã , can be checked by the communication cell.
The basic idea to verify the correct lengths of the blocks is as follows (see Fig. 2). Initially, the communication cell sends a signal S 0 with speed 1/3 to the right. That is, the signal resides in the first three configurations in the communication cell, is then sent to the next cell where it resides in the following three configurations, and so on. When the first symbol of the second block has been read, the communication cell sets up another signal S 1 that runs with speed 1 to the right. When the latter signal catches up with the former one, both are canceled and i À 1 signals R j with speeds 1=ð2j À 1Þ, for 1 j i À 1, are sent to the left. If these signals arrive in the communication cell at the time steps in which new blocks (or the end-of-input symbol) appear in the input, the lengths of all blocks are correct. More precisely, for x ! 0, signal S 0 resides at times 3x, 3x þ 1, and 3x þ 2 in cell x. Signal S 1 resides at time n þ 1 in cell 0 and at time n þ 1 þ x in cell x. If n is even, signal S 1 arrives at time n þ 1 þ n 2 ¼ 3 n 2 þ 1 in cell n 2 where S 0 resides at times 3 n 2 , 3 n 2 þ 1, and 3 n 2 þ 2. Therefore, signals S 0 and S 1 meet in cell b n 2 c. If n is odd, signal S 1 arrives at time n þ 1 þ b n 2 c ¼ 3b n 2 c þ 2 in cell b n 2 c where S 0 resides at times 3b n 2 c, 3b n 2 c þ 1, and 3b n 2 c þ 2. Therefore, signals S 0 and S 1 meet in cell b n 2 c also in this case. Now, for the sending of the signals R j the parity of n is distinguished. (The parity of n is straightforwardly checked by the communication cell and can be sent together with signal S 1 ). If n is even, the signals R j are set up by cell n 2 immediately at time 3 n 2 þ 1. So, signal R j arrives at the communication cell at time Since 1 j i À 1, these are the times 2n þ 1; 3n þ 1; . . .; i Á n þ 1 at which new blocks (or the end-of-input symbol) appear in the input.
If n is odd, the signals R j are set up by cell b n 2 c with a delay of j time steps at time 3b n 2 c þ 2 þ j, respectively. So, each signal R j arrives at the communication cell at time As in the first case, since 1 j i À 1, these are the times 2n þ 1; 3n þ 1; . . .; i Á n þ 1 at which new blocks (or the end-of-input symbol) appear in the input. So, the IA constructed accepts language L hi in realtime. Moreover, each of the altogether i þ 1 signals takes at most one communication step per inter-cell link and, thus, the IA is an MCði þ 1Þ-IA. h Theorem 1 For i ! 2, the family L rt ðMCðiÞ-IAÞ is strictly included in the family L rt ðMCði þ 1Þ-IAÞ Proof For i ! 2, the witness language L hi is used to show the strict inclusion L rt ðMCðiÞ-IAÞ & L rt ðMCði þ 1Þ-IAÞ. By Lemma 1, language L hi is accepted by some MCði þ 1Þ-IA in realtime. So, it remains to be shown that L hi is not accepted by any MCðiÞ-IA in realtime. Let M ¼ hS; F; A; B; O; s 0 ; b l ; b r ; d; d 0 i be an iterative array accepting L hi in realtime. We consider the communications on the inter-cell link between the communication cell and its neighbor. For clearer writing, we represent a configuration by a pair ðw; sĉÞ, where w 2 A Ã is the remaining input sequence as usual, s 2 S is the state of the communication cell, andĉ is a mapping that maps cells j ! 1 to their current states.
A key observation is that on unary inputs long enough the communication cell will run into state cycles unless a communication takes place. So, let w 2 L hi be an accepted word whose block length n is long enough.
Assume that no communication takes place while processing the first |S| symbols a from the first block. Recall that by definition we have b l ðs 0 Þ ¼ b r ðs 0 Þ ¼ ?. Let w ¼ a n v with the first letter in v being b. Then on processing the input prefix a jSj the communication cell necessarily enters some state at least twice. That is, there are 0 p 1 , 1 p 2 with p 1 þ p 2 jSj such that That is, there is a state cycle of length p 2 leading from state s 1 to state s 1 . So, the input a nþp 2 v 6 2 L hi is accepted as well. From the contradiction it follows that there is at least one communication during the first |S| time steps.
Next, we consider the sub-computations that process the last |S| symbols of a block and the first jSj 2 þ jSj symbols of the following block. Without loss of generality, let this factor be a jSj b jSj 2 þjSj , and so w ¼ ua jSj b jSj 2 þjSj v. Assume that no communication takes place (on the inter-cell link between the communication cell and its neighbor) while processing this factor. Let Then there are 0 p 1 , 1 p 2 with p 1 þ p 2 jSj such that That is, there is a state cycle of length p 2 leading from state s 1 to state s 1 . Continuing the computation without communication yields the existence of 0 p 3 , 1 p 4 jSj with jSj p 1 þ p 2 þ p 3 and p 1 þ p 2 þ p 3 þ p 4 2jSj such that That is, there is a state cycle of length p 4 leading from state s 2 to state s 2 . Since there are no communications on the factor a jSj b jSj 2 þjSj , we can replace this factor by the factor a jSjþp 2 p 4 b jSj 2 þjSjÀp 2 p 4 of the same length, and the configurations to the right of the communication cell develop exactly as before. We obtain the sub-computations Since the communication cell runs through the state cycle of length p 2 leading from state s 1 to state s 1 and there is no communication, the sub-computation continues as D p 4 ðb jSj 2 þ2jSjÀp 2 p 4 Àp 1 Àp 2 Àp 3 v; s 2ĉ7 Þ ¼ ðb jSj 2 þ2jSjÀp 2 p 4 Àp 1 Àp 2 Àp 3 Àp 4 v; s 2ĉ5 Þ: Iterative arrays with finite inter-cell communication 7 For the last equation, note that the length of the replaced factor is the same as of the original factor. That, is the number of steps is the same on both factors. Moreover, since there is no communication of the communication cell, during these steps the right part of the configuration develops as before. So, the configuration of the right part is finallyĉ 5 .
Since the configurations after processing the original factor and its replacement are identical, the input word with replaced factor not belonging to L hi is accepted as well. From the contradiction it follows that there is at least one communication while processing the factor a jSj b jSj 2 þjSj . Now we turn to the end of the computation. Assume that no communication takes place while processing the last 2|S| symbols from the last block, say these are symbols b. Let w ¼ ub n with the last letter in u being an a. Then on processing the input suffix b 2jSj the communication cell necessarily enters some state at least twice. Let D jujþnÀ2jSj ðub n ; s 0ĉ0 Þ ¼ ðb 2jSj ; sĉÞ: Then there are 0 p 1 , Since the input is accepted, the communication cell enters an accepting state in this state cycle of length p 2 (which cannot be left until the end of the computation) or before. This implies that input ub nÀp 2 is accepted as well. From the contradiction it follows that there is at least one communication during the last 2|S| time steps.
Altogether we have seen that the communication cell of M necessarily communicates with its neighbor, or vice versa, during the first |S| steps, during the last 2|S| steps, and on the factors a jSj b jSj 2 þjSj and b jSj a jSj 2 þjSj that include the block borders. Since there are i À 1 such block borders, in total, there are at least i þ 1 communications for n long enough. h

Undecidability results for realtime MC(constÞ -IAs
It is shown in Kutrib and Malcher (2019) by a reduction of Hilbert's tenth problem that emptiness is undecidable for realtime MCðconstÞ-IAs. However, this proof does not provide a precise constant, since the number of communications per cell in the construction depends on the polynomial given in Hilbert's tenth problem. In this section, we will improve this undecidability result in two directions. Namely, we show that emptiness is already undecidable for realtime IAs with at most four communications per cell which, in addition, work on a unary input. The basic idea is to construct a realtime MCð4Þ-IA that simulates a two-counter machine C on empty input and accepts some input if and only if C halts on empty input.
Since it is a well-known fact that it is undecidable whether or not a deterministic counter machine having two counters that are initially zero and starting with empty input will eventually halt (Minsky 1961), the simulation implies the undecidability of the emptiness problem for realtime MCð4Þ-IAs. In a first step, we will construct a realtime IA in the following lemma which simulates a given twocounter machine and accepts some input if and only if the given counter machine halts on empty input. In a second step, we will refine the construction so that the realtime IA will be a realtime MCð4Þ-IA which gives the desired undecidability result.
Lemma 2 Let C be a two-counter machine. Then, a unary realtime IA M can be constructed such that L(M) is not empty if and only if C halts on empty input.
Proof For the simulation of the two-counter machine by an IA we basically follow the construction given in Carton et al. (2018), where a general construction of a lineartime quasi-acyclic one-way cellular automaton is given that simulates a given k-counter machine on a given input. However, here we have the additional restriction that a two-counter machine on empty input has to be simulated and that we have to ensure that the simulating machine is indeed an MCð4Þ-IA working in realtime. Let C ¼ hS; s 0 ; di be a two-counter machine, where S denotes the state set, s 0 is the initial state, and d : S Â f0; 1g 2 ! S Â fþ1; 0; À1g 2 is the transition function. Here, 0 denotes an empty counter and 1 denotes a positive counter. Without loss of generality we may assume that C accepts by halting and makes at least one move. Now, we construct in a first step a conventional IA on unary input that simulates C and accepts if and only if C halts (see the following Example 2 and its computation depicted in Fig. 3). In a second step, we will later discuss how to refine the construction so that the IA constructed is indeed a realtime MCð4Þ-IA. The basic idea following (Carton et al. 2018) is to encode the current value of each counter in the first two tracks of the IA in a ''vertical way''. This means that in cell i the sequence of entries over time in one of those tracks encodes the value of the corresponding counter of C at time i þ 1. In detail, the sequence of states will be a substring of the form >1 Ã 0?# þ , where the number of 1's denotes the current value of the counter. Furthermore, we will store the current state of the counter machine as well as the update information for both counters in additional tracks. if dðs 0 ; 0; 0Þ ¼ ðs 1 ; m 1 ; m 2 Þ with s 1 2 S and m 1 ; m 2 2 fþ1; 0; À1g. To update the counters in the communication cell, we add the following transitions where s 2 S, q 2 S 0 , c 1 ; c 2 2 f0; 1g, and m 1 ; m 2 2 fþ1; 0; À1g. For i 2 f1; 2g we define c 0 i as follows. The transitions for the other cells are as follows. To start the computation, we first implement a delay using the transitions and initialize the computation when the left neighbor initializes its counter values by changing from > to 1 or 0. Let us first assume that the computation is initialized with a non-halting configuration. For s; s 0 2 S, c 1 ; c 2 2 f0; 1g, and m 1 ; m 2 ; m 0 1 ; m 0 2 2 fþ1; 0; À1g we set with c 1 ; c 2 ; c 0 1 ; c 0 2 2 f>; 0; 1; ?; #g, m 1 ; m 2 ; m 0 1 ; m 0 2 2 fþ1; 0; À1g, s; s 0 2 S, and q 2 S 0 n ff 0 g. For i 2 f1; 2g we define c 00 i as follows. If c 0 i 2 f>; 1g, then we set If c 0 i 2 f0; ?; #g, we set  Fig. 3 Example computation on an iterative array simulating the counter machine from Example 2 according to the construction given in Lemma 2 Iterative arrays with finite inter-cell communication 9 As soon as the computation would be initialized with a halting configuration of the counter machine, the accepting state f 0 is entered and is sent with maximum speed to the left. Hence, we set for s 2 S, c 1 ; c 2 2 f0; 1g, and m 1 ; m 2 2 fþ1; 0; À1g d 0 ððc 1 ; c 2 ; s; m 1 ; m 2 Þ; s 0 0 ; s 0 0 Þ ¼ f 0 ; if dðs; c 1 ; c 2 Þ is undefined.
Furthermore, d 0 ðq; q 0 ; f 0 Þ ¼ f 0 for all q; q 0 2 S 0 with q 0 6 ¼ f 0 , and d 0 ðO; q; f 0 Þ ¼ f 0 , for all q 2 S 0 n fs 0 2 g. Finally, d 0 ðq; f 0 ; q 0 Þ ¼ s 0 2 , for all q; q 0 2 S 0 , and d 0 ðO; q; q 0 Þ ¼ s 0 2 , for all q 2 S 0 and q 0 2 S 0 n ff 0 g. By this construction, M is a unary realtime IA and accepts a non-empty language if and only if C is halting on empty input. h Example 2 As an example for the construction we consider the following two-counter machine C ¼ hfs 0 ; s 1 ; s 2 ; s 3 g; s 0 ; di with the transitions dðs 0 ; 0; 0Þ ¼ðs 1 ; þ1; þ1Þ; dðs 1 ; 1; 1Þ ¼ðs 2 ; þ1; 0Þ; dðs 2 ; 1; 1Þ ¼ðs 3 ; þ1; À1Þ; and dðs 3 ; 1; 0Þ ¼ðs 3 ; À1; 0Þ: The remaining transitions are undefined which means that C halts and accepts if a configuration is entered where no transition is defined. The accepting computation of C on empty input is then as follows: ðs 0 ; 0; 0Þ ' ðs 1 ; 1; 1Þ ' ðs 2 ; 2; 1Þ ' ðs 3 ; 3; 0Þ ' ðs 3 ; 2; 0Þ ' ðs 3 ; 1; 0Þ ' ðs 3 ; 0; 0Þ: The simulation of this computation by a realtime IA M is depicted in Fig. 3. Since the computation of C on empty input is halting, M accepts some input, in this case a 19 . Apart from the quiescent state s 0 0 , the accepting state f 0 , and the auxiliary states s 0 1 and s 0 2 , the states of M are quintuples, where in the first (second) track the first (second) counter of C is simulated. The third track contains the current state of C and in track four (five) the next action on counter one (two) is stored. It can be observed that the configuration at time i þ 1 is stored in cell i. For example, the configuration ðs 2 ; 2; 1Þ at time two is stored in cell 1: track 3 contains state s 2 , track 1 contains (vertically read) the substring >110?# which is an encoding of two, and track 2 contains the substring >10?# which is an encoding of one. h Our next task is to refine the construction of Lemma 2 to obtain a realtime MCð4Þ-IA. To this end, we consider again the example computation in Fig. 3 and first analyze the flow of information from left to right. It can be observed that the simulation in cell i is started at time step 2ði þ 1Þ for i ! 1. This starting point is defined by the first time when tracks 1 and 2 of the left neighboring cell of cell i change from > to 1 or 0. This leads to one communication per cell. The corresponding cells sending this information are depicted with solid gray background in Fig. 3. Next, in tracks 1 and 2 the following holds: whenever state 0 is entered at time t, the state at time t þ 1 is ?, and the state at time t 0 [ t þ 1 is #. This means that no communication from left to right is necessary to compute the next states in some track as soon as the information that track 1 or track 2 enters 0 is communicated. In addition, it can be assumed without further communication that, starting with the initialization, track 1 and track 2 of the left neighbor are in state 1 up to the moment when state 0 is communicated. Hence, the transition function can suitably be modified such that the only communication needed from the left neighbor for the state changes in track 1 or track 2 is the information when track 1 or track 2 enter state 0. This gives at most two more communications per cell and the corresponding cells are depicted with a crosshatched background. Finally, we have one additional communication per cell from right to left for communicating the accepting state f 0 to the communication cell in case of a halting computation of the counter machine. Such cells are depicted with a lined background. Altogether, we have at most four communications per cell. These considerations and the fact that the halting problem is undecidable for two-counter machines on empty input (Minsky 1961), immediately yield the following undecidability result.
The undecidability of the emptiness problem and its proof can be used to show the undecidability of the following problems.
Proof In the proof of Lemma 2 a unary realtime IA M is constructed that accepts a non-empty language if and only if the simulated counter machine is halting. In addition, if M is non-empty, it accepts exactly one input a n . The construction can be modified in a straightforward way to a unary realtime IA M 0 so that M 0 accepts all unary inputs a m with m ! n, where a n is accepted by M. Hence, M 0 accepts an infinite language if and only if the simulated counter machine is halting. Similar to the considerations of Theorem 2 we may assume that M 0 is a realtime MCð4Þ-IA. Since the halting problem on empty input is undecidable for counter machines, we therefore obtain that finiteness and infiniteness are undecidable for unary realtime MCðiÞ-IAs, if i ! 4.
The fact that the empty set is accepted by some realtime MCð4Þ-IA and the result that emptiness is undecidable for realtime MCð4Þ-IAs by Theorem 2 immediately imply the undecidability of inclusion and equivalence for unary realtime MCðiÞ-IAs, if i ! 4.
To show the undecidability of the regularity problem we will construct a realtime MCð4Þ-IA M 0 that accepts the language L M ¼ b n c n wa 2 j w 2 LðMÞ and n ! 2 is even È É ; where M is the realtime MCð4Þ-IA from Theorem 2 that accepts a non-empty language if and only if the simulated counter machine is halting. It is clear that L M ¼ LðM 0 Þ is a regular language if and only if L(M) is empty. The latter holds if and only if the simulated counter machine is not halting. Hence, if we could decide the regularity problem for M 0 , we could decide the halting problem for counter machines which is a contradiction to (Minsky 1961). Thus, it remains for us to construct the realtime MCð4Þ-IA M 0 . First, we implement the construction given in Lemma 1 for the language f b n c n j n ! 1 g for which we know that at most three communications per cell are needed due to two signals from left to right and one signal from right to left (see Fig. 4). The signal from right to left is started when both signals from left to right meet. This happens for even n at time 3n=2 þ 1 in cell n/2. In the next time step, we start in the right neighboring cell n=2 þ 1 the simulation of M where cell n=2 þ 1 is considered as the communication cell of M. Whenever cell n=2 þ 1 enters an accepting state of M a new signal g is sent with maximum speed to the left which brings the communication cell of M 0 (cell 0) to accept an input x after reading the end-ofinput symbol O exactly when signal g arrives, if x has the correct format b þ c þ a þ and a maximal prefix from b þ c þ that belongs to f b n c n j n ! 2 is even g. The property that n is even can be checked in the communication cell. From this construction we know that the simulation of M is started at time 3n=2 þ 2 in cell n=2 þ 1. Hence, this cell enters state f 0 at time 3n=2 þ 2 þ jwj, if w 2 LðMÞ. Thus, the signal g reaches the communication cell at time 3n=2 þ 2 þ jwj þ n=2 þ 1 ¼ 2n þ jwj þ 3. We can conclude that M 0 accepts L M . To show that M 0 performs at most four communications per cell we observe that the active cells in M 0 either simulate M or check whether the input prefix from b þ c þ in fact belongs to f b n c n j n ! 2 is even g. In the latter case, we know from the construction given in Lemma 1 (see Fig. 4) that at most three communications are performed per cell. In addition, the rightmost active cell in Fig. 4 performs one communication only, namely, the signal to the left is started. Here, this cell n/2 performs two more communications, namely, it initiates that cell n=2 þ 1 starts the simulation of M and it transports the signal g to the left. Hence, cell n/2 performs three communications, whereas cells 0; 1; . . .; n=2 À 1 perform at most four communications taking into account signal g. For cell n=2 þ 1 we obtain from Fig. 3 that two communications are sent to the right. Here, we have three communications in cell n=2 þ 1 considering the additional signal g. The remaining cells j [ n=2 þ 1 perform at most four communications by construction. Altogether, we obtain that M 0 is a realtime MCð4Þ-IA. h Finally, we can show that it is neither possible to decide whether an arbitrary realtime IA performs a constant number of communications per cell at all nor whether an arbitrary realtime IA performs a fixed number of communications per cell for a given number i ! 4.
Theorem 4 It is undecidable for an arbitrary realtime IA M whether or not M is a realtime MCðconstÞ-IA. It is undecidable for an arbitrary realtime IA M and some i ! 4 whether or not M is a realtime MCðiÞ-IA.
Proof Let M 0 be a realtime MCð4Þ-IA. We define the language where c is some new alphabet symbol. A realtime IA M can accept L M 0 by using two tracks as follows. The correct number of c-and non-c-symbols can be checked in one track in the same way as in Lemma 1 for the language f a n b n j n ! 1 g. This check needs three communications per cell. Additionally, the IA M 0 is simulated on the other track. As soon as M reads the first c and the simulated IA M 0 would enter an accepting state, the communication cell sends in every of the remaining |w| time steps two alternating signals with maximum speed into the array. obtain that the question of whether M is a realtime MCðconstÞ-IA is undecidable. Now, we consider language L M 0 ;i ¼ f c iþ1 w j w 2 LðM 0 Þ g for a fixed i ! 4. A realtime IA M can accept L M 0 ;i as follows. First, we use the communication cell to check that exactly i þ 1 c's are read. For every c the communication cell performs some communication. When the first non-c is read, the simulation of the given realtime MCð4Þ-IA M 0 is started. Finally, the IA M accepts if the simulated IA M 0 would accept and the number of c's has been i þ 1. Thus, we can conclude that M is a realtime MCðiÞ-IA if and only if LðM 0 Þ is empty. Since emptiness is undecidable for realtime MCð4Þ-IAs due to Theorem 2, we obtain that the question of whether M is a realtime MCðiÞ-IA is undecidable. h We would like to note that the results obtained in this section are almost optimal. All decidability questions discussed are decidable for realtime MCðiÞ-IAs with i 2, since the languages accepted by such automata are regular owing to Proposition 1. The only remaining question is the decidability status of the problems for realtime MCð3Þ-IAs.

Undecidability results for realtime MC(constÞ -OCAs and realtime MC(constÞ -CAs
In this section, we will use the ideas and constructions presented in the preceding section to obtain similar undecidability results for max communication bounded realtime one-way cellular automata (realtime MCðf Þ-OCA) and realtime two-way cellular automata (realtime MCðf Þ-CA) which process their input in contrast to IAs a parallel way. For a precise definition of such automata we refer to (Kutrib and Malcher 2010a). The best results known so far are as follows. It is shown in Kutrib and Malcher (2010a) that all usually studied decidability questions are undecidable for realtime MCðconstÞ-OCAs and hence are undecidable for realtime MCðconstÞ-CAs as well. The proof is by a reduction of Hilbert's tenth problem. Thus, the precise number of communications per cell is not known. The special case of letter-bounded languages has been investigated in Kutrib and Malcher (2010b), where it was possible to show undecidability results for realtime MCðlogðnÞÞ-OCAs accepting letter-bounded languages, again by a reduction of Hilbert's tenth problem. However, the number of different symbols in the letter-bounded language depends on the given polynomial of the instance of Hilbert's tenth problem and is therefore not a fixed number.
Here, we can improve these known results. First, we show that the emptiness problem is undecidable for realtime MCð4Þ-CAs working on a unary alphabet. Second, we obtain the undecidability of emptiness for realtime MCð4Þ-OCAs that accept letter-bounded languages that are subsets of a Ã b Ã . Then the undecidability of finiteness, infiniteness, inclusion, equivalence, and regularity can be shown as well. These results are in a certain sense the best possible results, since it is known that unary languages accepted by realtime OCAs are regular (Seidel 1979). Hence, all questions discussed become decidable. Let us start with some undecidability results for unary realtime MCðiÞ-CAs with i ! 4. If we slightly adapt the above construction by never forwarding signal f 0 and only forwarding an accepting signal g when it has met some cell carrying f 0 or s 0 2 , then we obtain a realtime MCð4Þ-CA that accepts an infinite language if and only if the underlying counter machine is halting. Hence, the problems of finiteness and infiniteness are undecidable as well. Finally, the undecidability of inclusion as well as equivalence can be shown the same way as it is done in the proof of Theorem 3. h Now, we turn to one-way cellular automata and show the undecidability of the emptiness problem if at most four communications per cell are performed and the given OCA accepts a letter-bounded language that is a subset of a Ã b Ã .
Proof We consider an input from a þ b þ and we will implement on the a-part of the input the construction given in the proof of Lemma 2 in a reversed way. This means that the communication cell is simulated in the rightmost acell and the flow of information is from right to left. In addition, the accepting signal f 0 , which is initiated whenever a halting configuration of the simulated counter machine is entered, is here not started, but the information is kept in some cell. The b-part of the input is provided to have enough time for the simulation of the counter machine in the a-part. Hence, the rightmost cell of the b-part starts a signal g with maximum speed to the left which checks whether the input has the format a þ b þ and which changes to an accepting signal g 0 if a state f 0 is met in the a-part which means that the counter machine has entered a halting configuration. If a wrong format is detected or the state f 0 is never met, the input is rejected. As an example an accepting computation may be found in Fig. 5.
So, the OCA constructed accepts a non-empty and infinite language if and only if the counter machine halts. Thus, the emptiness problem is undecidable due to the undecidability of the halting problem for counter machines (Minsky 1961). According to the considerations of Theorem 2 we know that the IA constructed there is an MCð4Þ-IA. Hence, we can conclude that the OCA constructed here is an MCð4Þ-OCA, since we have on the one hand at most three communications per cell on the apart for the simulation of the counter machine. We note that the signal f 0 is not started in our modified construction. On the other hand, we have one additional communication per cell for the signals g and g 0 . h The undecidability of the emptiness problem can now be used to show further undecidability results.
Proof In the proof of Theorem 6 a realtime MCð4Þ-OCA is constructed that accepts an infinite language if and only if the counter machine halts. Thus, the finiteness problem as well as the infiniteness problem are undecidable for realtime MCðiÞ-OCAs, if i ! 4.
The fact that the empty set is accepted by some realtime MCð4Þ-OCA and the result that emptiness is undecidable for realtime MCð4Þ-OCAs by Theorem 6 immediately imply the undecidability of inclusion and equivalence for realtime MCðiÞ-OCAs, if i ! 4.
To show the undecidability of the regularity problem we use a similar approach as in the proof of Theorem 3 and construct a realtime MCð4Þ-OCA M 0 that accepts the language L M ¼ c n d n w j w 2 LðMÞ and n ! 1 f g , where M is the realtime MCð4Þ-OCA from Theorem 6. Again, L M ¼ LðM 0 Þ is a regular language if and only if L(M) is empty which leads to the undecidability of regularity.
For the construction of the realtime MCð4Þ-OCA M 0 we implement the construction of a realtime MCð2Þ-OCA that, on the input part from c þ d þ , accepts f c n d n j n ! 1 g as given in Example 2 of Kutrib and Malcher (2010a). On the input part from a þ b þ we implement the construction given in the proof of Theorem 6 which implies that every cell performs at most four communications. The signal g 0 is forwarded from the leftmost a-cell through the c þ d þ part to the leftmost cell of M 0 . The signal g 0 checks additionally that the remaining input has the format c þ d þ , and stops and changes to the sole accepting state g 00 if an accepting state of the construction given in Example 2 of Kutrib and Malcher (2010a) is found. By this construction, every cell in the c þ d þ part performs at most three communications.
Example computation of a one-way cellular automaton simulating the counter machine from Example 2 according to the construction given in Theorem 6. In contrast to Fig. 3 only the first two tracks of the cells are depicted. Cells that perform some communication are depicted with a non-empty background Iterative arrays with finite inter-cell communication 13 Altogether, we obtain that M 0 is a realtime MCð4Þ-OCA accepting L M . h Since OCAs are in particular CAs, we immediately obtain the undecidability of regularity in the two-way case.
Finally, we show that it is again undecidable to check whether or not a given realtime OCA performs a finite number of communications per cell.
Theorem 8 It is undecidable for an arbitrary realtime OCA M whether or not M is a realtime MCðconstÞ-OCA. It is undecidable for an arbitrary realtime OCA M and some i ! 4 whether or not M is a realtime MCðiÞ-OCA.
Proof Let M 0 be an arbitrary realtime MCð4Þ-OCA. From M 0 we construct an equivalent realtime OCA M that has basically the same transitions as M 0 , but is additionally modified such that every cell performs a communication in every time step. Hence, M is a realtime MCðconstÞ-OCA if and only if LðM 0 Þ is finite. Since finiteness is undecidable for realtime MCð4Þ-OCAs by Theorem 7, we obtain the first statement.
Next, let M 0 be the realtime MCð4Þ-OCA constructed in the proof of Theorem 6. We define the language L M 0 ;i ¼ c n w j w 2 LðM 0 Þ and n ! i þ 1 f g , where c is some new alphabet symbol and i ! 4 is fixed. A realtime OCA M can accept L M 0 ;i by simulating M 0 on non-c cells. Additionally, it is ensured that all c-cells perform a communication in every time step. As soon as the rightmost c-cell obtains the signal g 0 from its right neighbor, this signal is forwarded to the left whereby it is checked that at least i þ 1 c's are provided. If so, the input is accepted and otherwise rejected. We claim that M is an MCðiÞ-OCA if and only if LðM 0 Þ is empty. If LðM 0 Þ is empty, then M accepts the empty set and hence is in particular an MCðiÞ-OCA. If LðM 0 Þ is not empty, then LðM 0 Þ contains a word w that is at least of length 2. Hence, L M 0 ;i contains a word c iþ1 w. By construction, this already implies more than i communications in the leftmost cell. Hence, M is not an MCðiÞ-OCA. Since the emptiness problem is undecidable for M 0 by Theorem 6, we obtain the claim of the theorem. h Again, these results hold in case of two-way communication as well.
Corollary 2 It is undecidable for an arbitrary realtime CA M whether or not M is a realtime MCðconstÞ-CA. It is undecidable for an arbitrary realtime CA M and some i ! 4 whether or not M is a realtime MCðiÞ-CA.
Acknowledgements The authors would like to thank one anonymous reviewer of the conference version (Kutrib and Malcher 2019) who gave us the valuable hint to consider the simulation of counter machines by cellular automata given in Carton et al. (2018). Additionally, the authors gratefully acknowledge the comments and suggestions given by the anonymous referees of the journal submission which improved the presentation of the paper.
Open Access This article is licensed under a Creative Commons Attribution 4.0 International License, which permits use, sharing, adaptation, distribution and reproduction in any medium or format, as long as you give appropriate credit to the original author(s) and the source, provide a link to the Creative Commons licence, and indicate if changes were made. The images or other third party material in this article are included in the article's Creative Commons licence, unless indicated otherwise in a credit line to the material. If material is not included in the article's Creative Commons licence and your intended use is not permitted by statutory regulation or exceeds the permitted use, you will need to obtain permission directly from the copyright holder. To view a copy of this licence, visit http://creativecommons. org/licenses/by/4.0/.
Funding Open Access funding enabled and organized by Projekt DEAL.