A hierarchical structure in the motion representation of 2-state number-conserving cellular automata
AA HIERARCHICAL STRUCTURE IN THE MOTIONREPRESENTATION OF STATE NUMBER - CONSERVINGCELLULAR AUTOMATA
A P
REPRINT
KONG Gil-Tak
Department of Information EngineeringHiroshima UniversityHiroshima, 739-0046 [email protected]
IMAI Katsunobu
Department of Information EngineeringHiroshima UniversityHiroshima, 739-0046 [email protected]
NAKANISHI Toru
Department of Information EngineeringHiroshima UniversityHiroshima, 739-0046 [email protected]
October 21, 2019 A BSTRACT
A one-dimensional two-state number-conserving cellular automaton (NCCA) is a cellular automatonwhose states are or and where cells take states 0 and 1 and updated their states by the rule whichkeeps overall sum of states constant. It can be regarded as a kind of particle based modeling of physicalsystems and has another intuitive representation, motion representation, based on the movementof each particle. We introduced a kind of hierarchical interpretation of motion representations tounderstand the necessary pattern size to each motion. We show any NCCA of its neighborhood size n can be hierarchically represented by NCCAs of their neighborhood size from n − to . K eywords Cellular automata · number conservation · motion representation Cellular automata(CA), introduced by von Neumann for modelling biological self-reproduction, is a discrete dynamicalsystem which evolves in discrete space and time [9]. Among many kind of CA, a number-conserving CA (NCCA)has a feature that total number of states in a configuration is identical with that in the configuration of the previoustime step [1, 4]. By the feature, NCCA can be a model to analyze a physical phenomenon with the property of massconservation such as a traffic flow [8].An NCCA can also be considered as a system of particle movements, i.e., each number in a cell represents the number ofparticles in the cell and the particles move to another cell simultaneously and each particle is not divided or disappeared.To describe the motions of particles, Boccara et al. proposed motion representation [1, 2]. Although an NCCA hasmany variations of motion representations, Moreira et al. [7] introduced a canonical motion representation which isuniquely determined for an NCCA.An NCCA and a motion representation are inherently different computing models. For an NCCA, its neighborhoodsize is essential in contrast to a motion representation. Even the case of a two-state simple shift NCCA for a largeneighborhood size n , the values for its rule table should be assigned for all -patterns of length n to determine the nextstate. But in the case of motion representation, just an information of a cell of state 1 is enough to identify the value 1 to a r X i v : . [ n li n . C G ] O c t PREPRINT - O
CTOBER
21, 2019be moved. Thus the only motion representation is enough to describe the simple shift CA for any neighborhood size.The simplest car traffic rule 184 [8], can be regarded as the combination of a basic shift and a motion depending on asize-two pattern, even the evolution can be embedded into an NCCA of any neighborhood size which is larger thanthree.Thus any motion representation of a two-state NCCA seems to be constructed by the set of motions which are orderedby their pattern size. From this idea, we introduced a kind of hierarchical interpretation to motion representations tounderstand the necessary pattern size to each motion.In this paper, we show any NCCA of its neighborhood size n can be hierarchically represented by NCCAs of theirneighborhood size from n − to . A CA is a machine which cell’s states are evolved through the interaction of each cells in a fixed area. The fixed areaand the interaction are called neighborhood and rule. There are many kinds of CA according to neighborhood size, stateof cells, etc. In this paper, we will deal with only 1-dimensional 2-state CA and we simply call it CA.
Definition 1 (1-dimensional 2-state Cellular Automata) . A 1-dimensional 2-state cellular automaton A is defined by A = ( n, f ) , where its neighborhood size n is a non-negative finite integer and f : { , } n → { , } is a mappingcalled the local function. A configuration over { , } is a mapping c : Z → { , } where Z is the set of all integers.Then Conf( { , } ) = { c | c : Z → { , }} is the set of all configurations over { , } . The global function F of A isdefined as F : Conf( { , } ) → Conf( { , } ) , i.e., ∀ c ∈ Conf( { , } ) , ∀ i ∈ Z : F ( c )( i ) = f ( c ( i ) · · · c ( i + n − . As above formula, the focus cell of CA is the left most cell in the neighborhood in this paper. Note that we use theWolfram coding [10] W ( f ) to represent a local function f : W ( f ) = (cid:80) f ( a · · · a n )2 n − a +2 n − a + ··· +2 a n wherethe sum is applied on ∀ a i ∈ n (1 ≤ i ≤ n ) . To represent a CA, we also use a pair of its neighborhood size and itsWolfram number instead of its local function. The local function f is also referred to as the rule of A . Fig. 1 shows therule table of CA (3, 226) as an example.Figure 1: The rule table of a 3-cell CA Definition 2 (Number Conserving CA) . A CA A is said to be finite-number-conserving (FNC) iff ∀ c ∈ Conf( { , } ) , (cid:88) i ∈ Z { F ( c )( i ) − c ( i ) } = 0 In this paper, we only think about the case of finite configuration, i.e., the number of nonzero cells are finite. BecauseDurand et al. [3] showed that FNC is equivalent to the general infinite case, FNC is enough to show the number-conservation of a CA even for the case of infinite number of nonzero cells.
Definition 3 (Pattern) . A pattern p = a a · · · a k is a sequence of a i ∈ { , } of a finite length k . In addition, for apattern p , _ · · · _ p or p _ · · · _ or _ · · · _ p _ · · · _ is an extended pattern of p where “_ · · · _” represents a finite sequenceof the wildcard character “_” which represents both and . For example, _ p p represents p p and p p for any patterns p and p . Also we use the notation of concatenationof two or more patterns to represent another pattern. For example, if p = 010 , then p = 0010 and p .In the following section, we denote a configuration c = · · · , c ( i ) , c ( i + 1) , · · · , c ( i + n − , · · · by · · · c i c i +1 · · · c i + n − · · · as an abbreviation. We regard a sub configuration of finite size as a patternand use it as the argument list of a local function f , i.e., we also denote f ( c ( i ) , · · · , c ( i + n − by f ( c i · · · c i + n − ) .We also use the notation, | | , to represent the number of elements. For a pattern set P , | P | means the number ofpatterns of P . For a pattern p , | p | means the length of p as a pattern string. But it is used in a slightly different way forconfigurations, i.e., for a configuration c , | c | means the number of 1s.2 PREPRINT - O
CTOBER
21, 2019
Definition 4 (Bundle) . For a length n − pattern r , if length n patterns p and q satisfy the condition: p = 0 r, q = 1 r (resp .p = r , q = r then we call p ( q ) l-bundle (resp. r-bundle) of r . When p, q, r satisfy the both cases, we call r the bundle pattern of p and q . Next we define motion representation. Because an evolution of NCCA can be regarded as the movement of particles,there is another representation of an NCCA rule, motion representation [1, 7].
Definition 5 (Motion Representation) . Let ˜ p be an extended pattern for invoking a motion µ . A motion µ is defined as µ = (˜ p, s, e, v ) where s and e is a start location and an end location, respectively. v is a finite nonzero integer whichrepresents a moving value from s to e . Let M be a set of motions { µ , . . . , µ n } . For any configuration c of an NCCA A = ( n, f ) with the global function F , for each position in c to which a translated p i (of µ i ) matches, subtract v i fromthe cell s i and add v i to the cell e i simultaneously. If the resulting configuration is equal to F ( c ) for any c , M is amotion representation of A . We also graphically represent a motion µ by an arrow over ˜ p from s to e whose suffix is v . The suffix is omitted when v =1. It is shown that the motion representation of any 2-state CA can be composed by motions with v = 1 [5]. Webriefly show the idea of the proof: suppose there is a motion µ = ( p , s , e , in a motion representation. Thestart cell should be the destination of another motion, say µ = ( p , s , e , v ) . Then if v = 1 these motions can bereplaced by µ (cid:48) = ( p , s , e , and µ = ( p , s , e , where p is a union of µ and µ and s ( e ) is the relatedposition to s ( e ), respectively. If v = 2 then µ (cid:48) = ( p , s , e , is also remained. In turn it is possible to replace allmotions of (or more particles). Fig. 2 is an example of 3-cell motion representations.Figure 2: Graphical representation of motion representationFigure 3: 3-cell NCCA rules In this section, we show a property of NCCA and the main principle of bundle tree for any NCCA.
Definition 6 (Value-1 pattern set) . For a CA A = ( n, f ) , we call the pattern set P A = { p | f ( p ) = 1 } the value-1pattern set of A . Definition 7 (Bundle pattern set) . Let P is a pattern set of length n patterns. For any p = a · · · a n ∈ P , if q = ¯ a a · · · a n (or a · · · a n − ¯ a n ) is in P then ˆ P = { r | r = a · · · a n ( or a · · · a n − ) } is a bundle pattern set of P and r is a bundle pattern of p and q . If there is not such a pattern q for a pattern in P thenthere is no bundle pattern set of P . Also if r ( ∈ ˆ P ) is a bundle pattern of p and q then p and q can not be l- or r-bundleof another pattern in ˆ P . PREPRINT - O
CTOBER
21, 2019For example, { , } can be a bundle pattern set of { , , , } . Because can be a bundle pattern of , and can be a bundle pattern of , . Moreover the following sets have no bundle pattern sets. { , , , } , { , , } , { , , , } Lemma 1.
For a pattern p in a value-1 pattern set of an NCCA, there exists a pattern q in the set and a pattern r s.t. p and q are either l-bundle or r-bundle of r .Proof. Let F be the global function of an NCCA A = ( n, f ) . Then | F ( · · · c c · · · c n · · · ) | = f (0 · · · c ) + f (0 · · · c c ) + · · · + f ( c c · · · c n ) + · · · + f ( c n − c n · · ·
0) + f ( c n · · · .Considering the configuration c = · · · c c · · · c n · · · (cid:124) (cid:123)(cid:122) (cid:125) k ¯ c c c · · · c n · · · (cid:124) (cid:123)(cid:122) (cid:125) k c c · · · c n − ¯ c n · · · ( k > n ), the follow-ing equation holds: | c | = 2 n (cid:88) k =1 c k + ( ¯ c + c + · · · + c n − + ¯ c n ) , where ¯ c is the negation of c i.e., c + ¯ c = 1 . Since f (0 · · ·
0) = 0 then | F ( c ) | = | F ( · · · c · · · c n · · · ) | + | F ( · · · c c · · · c n · · · ) | + | F ( · · · c · · · c n − ¯ c n · · · ) | = 2 | F (0 · · · c · · · c n · · · | − f ( c c · · · c n ) + f (0 · · · c ) + · · · + f ( ¯ c c · · · c n ) + f ( c · · · c n − ¯ c n ) + f ( c · · · c n − ¯ c n
0) + · · · + f ( ¯ c n · · · .Moreover the next formula holds because F is the global function of an NCCA. n (cid:88) k =1 c k + ( ¯ c + c + · · · + c n − + ¯ c n ) = | F ( c ) | (1)Because (cid:80) nk =1 c k = | F (0 · · · c · · · c n · · · | and ¯ c + c + · · · + c n − + ¯ c n = | F (0 · · · c c · · · c n − ¯ c n · · · | ,we can get the following formula from (1): f ( ¯ c c · · · c n − ¯ c n ) + f ( c c · · · c n ) = f ( ¯ c c · · · c n ) + f ( c · · · c n − ¯ c n ) (2)From (2), we can get the following result.If f ( c c · · · c n ) = 1 f ( ¯ c c · · · c n ) = 1 or f ( c c · · · c n − ¯ c n ) = 1 . By Lemma 1, we can know that there are always bundle pattern for all patterns in value-1 pattern set of an NCCA.When a pattern can be paired with two different elements in the value-1 pattern set P of an NCCA, for example, { , , } ⊂ P , we show that is also in P by the next Lemma 2. Lemma 2.
Let P A is a value-1 pattern set of an NCCA A ( n, f ) . If three patterns a · · · a n , a · · · a n − ¯ a n , ¯ a a · · · a n are in P A then pattern ¯ a a · · · a n − ¯ a n is also in P A .Proof. Suppose ¯ a a · · · a n − ¯ a n is not in P A with a · · · a n , a · · · a n − ¯ a n , ¯ a a · · · a n ∈ P A . In other words, f ( a · · · a n ) = f ( a · · · a n − ¯ a n ) = f (¯ a a · · · a n ) = 1 and f (¯ a a · · · a n − ¯ a n ) = 0 .According to NCCA principles, we can get following formulas; a = f ( a · · · a n ) + f (0 a · · · a n − ) + · · · + f (0 · · · a ) − { f (0 a · · · a n ) + · · · + f (0 · · · a ) } = f ( a · · · a n − ¯ a n ) + f (0 a · · · a n − ) + · · · + f (0 · · · a ) − { f (0 a · · · a n − ¯ a n ) + · · · + f (0 · · · a ) } Then f ( a · · · a n ) − f (0 a · · · a n ) − { f ( a · · · a n − ¯ a n ) − f (0 a · · · a n − ¯ a n } .Since f ( a · · · a n ) = f ( a · · · a n − ¯ a n ) = 1 , f (0 a · · · a n ) = f (0 a · · · a n − ¯ a n ) (3)On the same way, ¯ a = f (¯ a a · · · a n ) + f (0¯ a a · · · a n − ) + · · · + f (0 · · · a ) − { f (0 a · · · a n ) + · · · + f (0 · · · a ) } = f (¯ a a · · · a n − ¯ a n ) + f (0¯ a a · · · a n − ) + · · · + f (0 · · · a ) − { f (0 a · · · a n − ¯ a n ) + · · · + f (0 · · · a ) } .Then f (¯ a a · · · a n ) − f (0 a · · · a n ) − { f (¯ a a · · · a n − ¯ a n ) − f (0 a · · · a n − ¯ a n } .Since f (¯ a a · · · a n ) = 1 , f (¯ a a · · · a n − ¯ a n ) = 0 , f (0 a · · · a n ) = 1 + f (0 a · · · a n − ¯ a n ) (4)Formula (3) and (4) be a contradiction. 4 PREPRINT - O
CTOBER
21, 2019In the process of making a bundle pattern set of the value-1 pattern set of an NCCA, a pattern might be paired withtwo different patterns. For example, the value-1 pattern set of an NCCA rule 204 is { , , , } . In thiscase, can not only make a pair with to but also to . But by Lemma 2, there exist another pattern which can be paired with and . Therefore we can make two distinct pairs like { , } , { , } or { , } , { , } . Thus, every patterns in value-1 pattern set can be paired without any overlapping patterns byLemma 2.For the value-1 pattern set of an NCCA P and for a pattern r , suppose that { r, r, r , r } ⊂ P . Then the bundlepattern of r, r and r , r is both r . But in such case, there exists another element which can be paired with one of r, r, r , r by the next Lemma. Thus all bundle patterns from a value-1 pattern set can be different. Lemma 3.
Let P A be a value-1 pattern set of an NCCA A = ( n, f ) . If a · · · a n − , a · · · a n − , a · · · a n − , a · · · a n − ∈ P A then at least one pattern among a · · · a n − ¯ a n − , a · · · a n − ¯ a n − , ¯ a a · · · a n − , ¯ a a · · · a n − be an element of P A where a i ∈ { , } .Proof. Omitted.Therefore for all NCCA A , there exist a bundle pattern set ˆ P A of half the size of its value-1 pattern set P A . Theorem 1.
For an n -cell NCCA A ( n ≥ ) with | ˆ P A | = | P A | / , an ( n − -cell CA B satisfying P B = ˆ P A is an ( n − -cell NCCA.Proof. Let F be the global function of an NCCA A = ( n, f ) . Because A is an NCCA, | c | = | F ( c ) | for anyconfiguration c (= · · · c − c c · · · ) . Let G be the global function of a CA B = ( n − , g ) . If | G ( c ) | = | F ( c ) | then | c | = | F ( c ) | = | G ( c ) | . i.e., B can be an NCCA. Then we will show | G ( c ) | = | F ( c ) | from now.For each state-1 cell F ( c )( k ) = 1 , k ∈ Z on F ( c ) , ∃ p = c k · · · c k + n − ∈ P A s . t . f ( p ) = 1 . Also for a pattern q ∈ ˆ P , which is a bundle pattern of p , it can be satisfied g ( q ) = 1 (i.e., q ∈ P B ). Thus if F ( c )( k ) = 1 then either G ( c )( k ) = 1 or G ( c )( k + 1) = 1 holds. When p is a l-bundle of q , G ( c )( k ) = 1 and when p is a r-bundleof q , G ( c )( k + 1) = 1 like Fig. 4. 𝒌 𝒌(cid:2878)𝟏 𝒌(cid:2878)𝒏(cid:2879)𝟏 𝒌(cid:2878)𝒏 C 𝑞 is a l-bundle of F(C)G(C) 𝒌 𝒌(cid:2878)𝟏 𝒌(cid:2878)𝒏(cid:2879)𝟏 𝒌(cid:2878)𝒏 C 𝑞 is a r-bundle of F(C)G(C)
Figure 4: Two evolutions according to the relation between p and q If F ( c )( k ) = F ( c )( k + 1) = 1 then(1) by F ( c )( k ) = 1 , either G ( c )( k ) = 1 or G ( c )( k + 1) = 1 holds,(2) by F ( c )( k + 1) = 1 , either G ( c )( k + 1) = 1 or G ( c )( k + 2) = 1 holds.So if G ( c )( k + 1) = 1 occur simultaneously in (1) and (2), an overlap occurs. Thus | F ( c ) | = | G ( c ) | is satisfied if thereis no overlap.Suppose that the above case has occurred. Then there are four patterns p = c k · · · c k + n − , q = c k +1 · · · c k + n − whichis a l-bundle of p and p (cid:48) = c k +1 · · · c k + n , q (cid:48) = c k +1 · · · c k + n − which is a r-bundle of p . Then q is the same with q (cid:48) .Because of two patterns q, q (cid:48) are the same in P B , | P B | = | P A | / − . This contradics the assumption, | P B | = | P A | / .In the result, G ( c ) is a 2-state configuration with | G ( c ) | = | F ( c ) | = | c | . Then B be an NCCA.The value-1 pattern set of 1-cell NCCA is { } , so the number of elements in P A of n -cell NCCA ( n ≥ ) is always n − . 5 PREPRINT - O
CTOBER
21, 2019Theorem 1 shows that the value-1 pattern sets of an n -cell and an ( n − -cell NCCA have a kind of hierarchicalrelation and we can extract the relation as a tree structure as follows:Let P n be the value-1 pattern set of an NCCA A n = ( n, f n ) . By Theorem 1, we can get a sequence of value-1 patternsets P i ( n ≥ i ≥ of A i = ( i, f i ) where P i − = ˆ P i and | P i | = 2 i − . For each element r in P i (1 < i < n − , thereare two elements p, q ∈ P i +1 where p ( q ) is an l-(r-)bundle of r , respectively. We can construct a tree T A n = ( V, E ) where V is the set of all elements in all sets P i and E is the set of all edges ( r, p ) and ( r, q ) described above. Clearly, T A n is a complete binary tree and its root vertex is and its height is n − . The height- i vertices of T A n are theelements of the value-1 pattern set of A i . We call T A n a bundle tree of A n . Fig. 5 is a bundle tree of the CA (4 , .Figure 5: A bundle tree of (4,62600)By Lemma 1, it is clear that a bundle tree exists for any NCCA rules. Moreover we can get Corollary 1 and Theorem 2by Theorem 1. Corollary 1.
For a bundle tree of A n , ∀ i ∈ Z , A i is an i -cell NCCA. Theorem 2.
Bundle tree of any NCCA is always a binary tree with root { } .Proof. The number of elements of value-1 pattern set of an NCCA ( n, f ) is always n − . Then it is clear that thenumber of elements of pattern sets at i th level is i − by corollary2. Moreover the smallest cell NCCA is 1-cell NCCA . Then bundle tree of any NCCA be a binary tree with root(the st level) . In this paper, we show any NCCA of its neighborhood size n can be hierarchically represented by NCCAs of theirneighborhood size from n − to . The result supports that any NCCA can be understood by a hierarchical motionrepresentations according to the necessary pattern size to each motion. References [1] Boccara, N. and Fuk´s, H.: Cellular automaton rules conserving the number of active sites.
Journal of Physics A:Math. Gen. , (28), 6007–6018 (1998).[2] Boccara, N. and Fuk´s, H.: Number-conserving cellular automaton rules. Fundamenta Informaticae , (1-3), 1–13(2002).[3] Durand, B. Formenti, E. and Róka, Z.: Number-conserving cellular automata I: decidability. Theoretical ComputerScience , (1-3), 523–535 (2003).[4] Hattori, T. and Takesue, S.: Additive conserved quantities in discrete-time lattice dynamical systems. PhysicaD , (3), 295–322 (1991).[5] Ishizaka, H. Takemura, Y. and Imai, K.: On enumeration of motion representable two-dimensional two-statenumber-conserving cellular automata. Proc. 3rd International Workshop on Applications and Fundamentals ofCellular Automata, (CANDAR-AFCA2015) , 412–417 (2015).[6] Kong, G.T. Imai, K. and Nakanishi, T.: Hierarchical Motion Representation of 2-state Number ConservingCellular Automata.
Proc. 5th International Workshop on Applications and Fundamentals of Cellular Automata,(CANDAR-AFCA2017) , 194–199 (2017). 6
PREPRINT - O
CTOBER
21, 2019[7] Moreira, A. Boccara, N. and Goles, E.: On conservative and monotone one-dimensional cellular automata and theirparticle representation.