# Graph Cellular Automata with Relation-Based Neighbourhoods of Cells for Complex Systems Modelling: A Case of Traffic Simulation

## Abstract

**:**

## 1. Introduction

## 2. Related Work

## 3. Proposed Approach

#### 3.1. Classic Definition of Cellular Automata

- Cell grid in d-dimensional space (d ≥ 1);
- Automaton $\mathrm{S}$ state, dependent on ${\mathrm{s}}_{\mathrm{i}}$ sets of states of individual cells;
- ${\mathrm{F}}_{\mathrm{CA}}$ rule defining $\mathrm{v}$ cell state at time t + 1 dependent on the state of this cell and its neighbourhood $\mathrm{N}\left({\mathrm{v}}_{\mathrm{i}}\right)$ at time t;
- Classic (homogenous) CA is characterized by:
- ○
- identical set of states for each cell;
- ○
- identical set of rules (identical ${\mathrm{F}}_{\mathrm{CA}})$ for the entire grid;
- ○
- automaton grid not changing over time;
- ○
- identical neighbourhood diagram for the entire grid.

#### 3.2. Graph Changing over Time

#### 3.3. Change of Graph Structure

#### 3.3.1. Removing Vertices from Graph $\mathrm{G}$

#### 3.3.2. Removing Edges from Graph $\mathrm{G}$

#### 3.3.3. Adding Vertices to Graph $\mathrm{G}$

#### 3.3.4. Adding Edges

- ${\mathrm{F}}_{{\mathrm{V}}_{\mathrm{del}}}$—removing vertices defined by ${\mathrm{V}}_{\mathrm{del}}$ set;
- ${\mathrm{F}}_{{\mathrm{E}}_{\mathrm{del}}}$—removing edges defined by ${\mathrm{E}}_{\mathrm{del}}$ set;
- ${\mathrm{F}}_{{\mathrm{V}}_{\mathrm{add}}}$—adding vertices defined by ${\mathrm{V}}_{\mathrm{add}}$ set;
- ${\mathrm{F}}_{{\mathrm{E}}_{\mathrm{add}}}$—adding edges defined by ${\mathrm{E}}_{\mathrm{del}}$ set.

- ${\mathrm{f}}_{{\mathrm{outE}}_{\mathrm{del}}}\left(\mathrm{G},\text{}\mathrm{i},\mathrm{j}\right)$—removing out-edge ${\mathrm{e}}_{\mathrm{ij}}={\text{}\mathrm{v}}_{\mathrm{i}}{\mathrm{v}}_{\mathrm{j}}$;
- ${\mathrm{f}}_{{\mathrm{inE}}_{\mathrm{del}}}\left(\mathrm{G},\text{}\mathrm{i},\mathrm{j}\right)$—removing in-edge ${\mathrm{e}}_{\mathrm{ji}}={\text{}\mathrm{v}}_{\mathrm{j}}{\mathrm{v}}_{\mathrm{i}}$;
- ${\mathrm{f}}_{{\mathrm{outE}}_{\mathrm{add}}}\left(\mathrm{G},\text{}\mathrm{i},\mathrm{j}\right)$—adding out-edge ${\mathrm{e}}_{\mathrm{ij}}={\text{}\mathrm{v}}_{\mathrm{i}}{\mathrm{v}}_{\mathrm{j}}$;
- ${\mathrm{f}}_{{\mathrm{inE}}_{\mathrm{add}}}\left(\mathrm{G},\text{}\mathrm{i},\mathrm{j}\right)$—adding in-edge ${\mathrm{e}}_{\mathrm{ji}}={\text{}\mathrm{v}}_{\mathrm{j}}{\mathrm{v}}_{\mathrm{i}}$.

#### 3.3.5. Reconfigurability of Graph over Time

#### 3.4. Relative Neighbourhood Structurally Dynamic Graph Cellular Automaton

- d—dimension in a d-dimensional space (d ≥ 1) representing cell grid;
- $\mathrm{Q}$—activity state of an automaton, dependent on the set of activity states ${\mathrm{q}}_{\mathrm{i}}$ of individual cells;
- $\mathrm{S}$—state of automaton, dependent on the set of states ${\mathrm{s}}_{\mathrm{i}}$ of individual cells;
- $\mathrm{G}$—directed weighted graph $\mathrm{G}=\left(\mathrm{V},\mathrm{E},\mathrm{K}\right)$ defined above;
- ${\mathrm{F}}_{\mathrm{r}\u2013\mathrm{GCA}}$ is a function defining the state of automaton cell $\mathrm{v}$ at time t + 1 dependent on the state of this cell and its neighborhood ${\mathrm{N}}_{\mathrm{in}}\left({\mathrm{v}}_{\mathrm{i}}\right)$ at time t;
- ${\mathrm{R}}_{\mathrm{rc}}$ is a global rule defining the conditions of activation or deactivation of cellular automaton cells and the rules of graph reconfiguration (defines sets of added and removed by ${\mathrm{F}}_{\mathrm{rcG}}$ vertices and edges of graph G), ${\mathrm{R}}_{\mathrm{rc}}$ depends on the automaton state ${\mathrm{S}}^{\mathrm{t}}$ (states of all cells);
- ${\mathrm{F}}_{\mathrm{rcG}}$ is a function of reconfiguration of graph and cells activation/deactivation based on conditions set by ${\mathrm{R}}_{\mathrm{rc}}$.

- any relation between objects represented by graph vertices (e.g., interdependence of vehicles on the road, interdependence of members of a project team in a computer project, relations between people in this group or types of relations between people connected to a social network);
- the distance between objects represented by graph vertices;

- physical—automaton cell neighbourhood in d-dimensional space;
- logical—a set of relative neighbourhoods defined by a reconfigurable graph $\mathrm{G}$ (which allows for modeling a system of dynamic number of objects).

- activation of inactive cells (which equals to addition of related vertices to the graph);
- deactivation of cells (which equals to removal of graph vertices and edges connected to them);
- adding or removing graph edges, which results in creation or removal of neighbourhood relations.

#### 3.5. Representation in the Computer

## 4. The Case Study—Traffic Simulation

#### 4.1. Existing Traffic Models

#### 4.2. Traffic Model on the Basis of a Graph Cellular Automaton

- Acceleration—if the vehicle did not reach maximum velocity and the weight $\mathrm{W}\in W\left(G\right)$ of the vehicle in front of it is greater than its velocity, and also than the maximum velocity—then it can increase its velocity. This stage of the model can be presented as follows:
- ○
- if ${\mathrm{v}}_{\mathrm{ji}}(\mathrm{t})<{\mathrm{v}}_{\mathrm{max}}{\text{}\mathrm{and}\text{}\mathrm{v}}_{\mathrm{ji}}(\mathrm{t}){\mathrm{W}}_{{\mathrm{ji}}_{\mathrm{next}}}(t)$ then ${\mathrm{v}}_{\mathrm{ji}}(\mathrm{t}+1)\leftarrow {\mathrm{v}}_{\mathrm{ji}}(\mathrm{t})+1$, where the symbol $\leftarrow $ is a value assignment operation, ${\mathrm{v}}_{\mathrm{ji}}(\mathrm{t})$ is a car velocity, ${\mathrm{v}}_{\mathrm{max}}$ is a maximum possible velocity, ${\mathrm{W}}_{{\mathrm{ji}}_{\mathrm{next}}}(t)$ is a weight of the vehicle in front of analyzed one, on the same lane of road.

- Overtaking—if the vehicle was not able to accelerate due to the preceding vehicle and its velocity was less than the maximum velocity, and the vehicles approaching from the opposite direction (on the other lane) are at a far distance:
- ○
- if ${\mathrm{W}}_{\mathrm{kl}}\left(t\right)>{\mathrm{v}}_{\mathrm{ji}}\left(t\right)+{\mathrm{v}}_{\mathrm{kl}}\left(t\right)$ then the car can start overtaking (a procedure “overtake”), where W is a relation neibourhood (from matrix of weights) of car being on another lane of the road and going from the opposite; $\mathrm{j},\text{}\mathrm{k}\in \left\{1,2\right\}$—a number of lanes of analysed vehicles and for the opposite one; i,l are number of CA cells of the analysed vehicle and for the opposite one.
- ○
- The procedure “overtake” consists of few stages: analysis of weights from the matrix of weights for analyzed vehicles, lane changing ($\mathrm{j}\leftarrow \mathrm{k}$), acceleration (above step) and overtaking of vehicle or vehicles and return to the original lane ($\mathrm{j}\leftarrow \mathrm{j}$).
- ○
- The computations necessary for overtaking include establishing the weights of the vehicles located in front of the given vehicle and searching for the smallest weight in the opposite lane. In the first place, an analysis of the opposite lane is performed. The weights on the lane in front of the vehicle are sorted from the smallest to the greatest. Figure 9 presents the aim of sorting the weights in the context of a possibility to overtake any individual vehicles. Vehicle ${\mathrm{V}}_{4}$ could overtake the vehicles driving in front of it. The analysis of weights enables checking the possibility of overtaking as many vehicles as possible. In case there is no such possibility, possible spaces between the vehicles are searched for.

- Braking—if the vehicle cannot accelerate, it cannot overtake, and if there are other vehicles in front of it, then it is forced to decrease its speed;
- ○
- if ${\mathrm{v}}_{\mathrm{ji}}\left(t\right)>{\mathrm{W}}_{\mathrm{ji}}\left(t\right)$ then ${\mathrm{v}}_{\mathrm{ji}}\left(t+1\right)\leftarrow {\mathrm{W}}_{\mathrm{ji}}\left(t\right)$, where ${\mathrm{W}}_{\mathrm{ji}}\left(t\right)$ is the nearest neighbour in the front of vehicle on the lane $\mathrm{j}$.

- Random events—each vehicle may (at some probability) decrease its velocity without a reason found in front of the vehicle (random reduction of speed by 1):
- ○
- if $\mathrm{p}<{\mathrm{p}}_{0}$ then ${\mathrm{v}}_{\mathrm{ji}}\left(\mathrm{t}+1\right)\leftarrow {\mathrm{v}}_{\mathrm{ji}}\left(\mathrm{t}\right)-1$, where ${\mathrm{p}}_{0}$ is a probability of random event and $\mathrm{p}$ is a random variable uniformly distributed over (0,1).

- Shifting—each of above steps additionally includes moving the vehicle to a new position: ${\mathrm{x}}_{\mathrm{ji}}\left(\mathrm{t}+1\right)\leftarrow {\mathrm{x}}_{\mathrm{ji}}\left(\mathrm{t}\right)+{\mathrm{v}}_{\mathrm{ji}}\left(\mathrm{t}\right)$.

#### 4.3. Experimental Results

## 5. Interpretation of the Results and Future Works

- Modelling of pedestrian traffic, ship traffic, air traffic, from the point of view of the moving objects, and not the space taken up by them;
- Modelling of economic relations between entities (where interdependence is most often a relation not connected with the closeness of the entities);
- Modelling of relations and behaviours of social media portals users (a community, especially young people, more and more often focus on mutual relationships in the net rather than on relationships in the real world).

## 6. Conclusions

- In d-dimensional space (if the neighbourhood specified by a graph is defined in such a way so as to correspond to the neighbourhood in classical CA, e.g., Moore’s or von Neumann’s neighbourhood);
- In virtual or relation-based space—where neighbourhood does not correspond to the relation of the cells location in the space, but it is relation-based.

## Acknowledgments

## Conflicts of Interest

## References

- Wolfram, S. A New Kind of Science; Wolfram Media: Champaign, IL, USA, 2002. [Google Scholar]
- Ilachinsky, A.; Halpern, P. Structurally Dynamic Cellular Automata. Complex Syst.
**1987**, 1, 503–527. [Google Scholar] - Alonso-Sanz, R. A Structurally Dynamic Cellular Automaton with Memory in the Triangular Tessellation. Complex Syst.
**2007**, 17, 1–15. [Google Scholar] - Bersini, H.; Detours, V. Asynchrony induces stability in cellular automata based models. In Artificial Life IV: Proceedings of the Fourth International Workshop on the Synthesis and Simlulation of Living Systmes, Cambridge, MA, USA; MIT Press: Cambridge, MA, USA, 1994; pp. 382–387. [Google Scholar]
- Cornforth, D.; Green, D.G.; Newth, D.; Kirley, M. Do Artificial Ants March in Step? Ordered Asynchronous Processes and Modularity, Biological Systems. In Proceedings of the 18th International Conference on Artificial Life, Sydney, Australia, 9–13 December 2002; Standish, B., Abbass, A., Eds.; pp. 28–32. [Google Scholar]
- Couclelis, H. From cellular automata to urban models: New principles for model development and implementation. Environ. Plan. B Plan. Des.
**1997**, 24, 165–174. [Google Scholar] [CrossRef] - Takeyama, M.; Couclelis, H. Map dynamics: Integrating cellular automata and GIS through Geo–Algebra. Int. J. Geogr. Inf. Sci.
**1997**, 11, 73–91. [Google Scholar] [CrossRef] - O’Sullivan, D. Graph-cellular automata: A generalised discrete urban and regional model. Environ. Plan. B Plan. Des.
**2001**, 28, 687–705. [Google Scholar] [CrossRef] - Neumann, J.V. Theory of Self-Reproducing Automata; University of Illinois Press: Champaign, IL, USA, 1966. [Google Scholar]
- Wolfram, S. Computation theory of cellular automata. Commun. Math. Phys.
**1984**, 96, 15–57. [Google Scholar] [CrossRef] - Wolfram, S. Universality and complexity in cellular automata. Physica D
**1984**, 10, 1–35. [Google Scholar] [CrossRef] - Gutowitz, H. Cellular automata and the sciences of complexity, part I. Complexity
**1996**, 1, 16–22. [Google Scholar] [CrossRef] - Gutowitz, H. Cellular automata and the sciences of complexity, part II. Complexity
**1996**, 1, 29–35. [Google Scholar] [CrossRef] - Nandi, S.; Kar, B.K.; Chaudhuri, P.P. Theory and applications of cellular automata in cryptography. IEEE Trans. Comput.
**1994**, 43, 1346–1357. [Google Scholar] [CrossRef] - Seredynski, F.; Bouvry, P.; Zomaya, A.Y. Cellular automata computations and secret key cryptography. Parallel Comput.
**2004**, 30, 753–766. [Google Scholar] [CrossRef] - Georgoudas, I.; Sirakoulis, G.C.; Scordilis, E.; Andreadis, I. A cellular automaton simulation tool for modelling seismicity in the region of Xanthi. Environ. Model. Softw.
**2007**, 22, 1455–1464. [Google Scholar] [CrossRef] - Petrica, L. FPGA Optimized Cellular Automaton Random Number Generator. J. Parallel Distrib. Comput.
**2017**, 111, 251–259. [Google Scholar] [CrossRef] - Toffoli, T.; Margolus, N. Cellular Automata Machines: A New Environment for Modeling; MIT Press: Cambridge, MA, USA, 1987. [Google Scholar]
- Wuensche, A. Classifying cellular automata automatically. Complexity
**1999**, 4, 47–66. [Google Scholar] [CrossRef] - Sutner, K. Classification of cellular automata. Encycl. Complex. Syst. Sci.
**2009**, 3, 755–768. [Google Scholar] - Gilman, R.H. Classes of linear automata. Ergod. Theory Dyn. Syst.
**1987**, 7, 105–118. [Google Scholar] [CrossRef] - Cattaneo, G.; Formenti, E.; Margara, L. Topological definitions of deterministic chaos. In Cellular Automata; Springer: Dordrecht, The Netherlands, 1999; pp. 213–259. [Google Scholar]
- Javid, M.A.J.; Alghamdi, W.; Ursyn, A.; Zimmer, R.; al-Rifaie, M.M. Swarmic approach for symmetry detection of cellular automata behaviour. Soft Comput.
**2017**, 21, 5585–5599. [Google Scholar] [CrossRef] - Hoffmann, R.; Völkmann, K.P.; Waldschmidt, S. GCA: Global Cellular Automata GCA. A Flexible Parallel Model. In International Conference on Parallel Computing Technologies; Springer: London, UK, 2001; pp. 66–73. [Google Scholar]
- Barredo, J.I.; Kasanko, M.; McCormick, N.; Lavalle, C. Modelling dynamic spatial processes: Simulation of urban future scenarios through cellular automata. Landsc. Urban Plan.
**2003**, 64, 145–160. [Google Scholar] [CrossRef] - Stevens, D.; Dragićević, S. A GIS-based irregular cellular automata model of land-use change. Environ. Plan. B Plan. Des.
**2007**, 34, 708–724. [Google Scholar] [CrossRef] - Santé, I.; García, A.M.; Miranda, D.; Crecente, R. Cellular automata models for the simulation of real-world urban processes: A review and analysis. Landsc. Urban Plan.
**2010**, 96, 108–122. [Google Scholar] [CrossRef] - Triantakonstantis, D.; Mountrakis, G. Urban growth prediction: A review of computational models and human perceptions. J. Geogr. Inf. Syst.
**2012**, 4, 555–587. [Google Scholar] [CrossRef] - Barreira-González, P.; Barros, J. Configuring the neighbourhood effect in irregular cellular automata based models. Int. J. Geogr. Inf. Sci.
**2017**, 31, 617–636. [Google Scholar] [CrossRef] - Dahal, K.R.; Chow, T.E. Characterization of neighborhood sensitivity of an irregular cellular automata model of urban growth. Int. J. Geogr. Inf. Sci.
**2015**, 29, 475–497. [Google Scholar] [CrossRef] - Barreira-González, P.; Gómez-Delgado, M.; Aguilera-Benavente, F. From raster to vector cellular automata models: A new approach to simulate urban growth with the help of graph theory. Comput. Environ. Urban Syst.
**2015**, 54, 119–131. [Google Scholar] [CrossRef] - Róka, Z. One-way cellular automata on Cayley graphs. Theor. Comput. Sci.
**1994**, 132, 259–290. [Google Scholar] [CrossRef] - Marr, C.; Hütt, M.T. Topology regulates pattern formation capacity of binary cellular automata on graphs. Phys. A Stat. Mech. Appl.
**2005**, 354, 641–662. [Google Scholar] [CrossRef] - Rinaldi, P.; Dalponte, D.; Vénere, M.; Clausse, A. Graph-based cellular automata for simulation of surface flows in large plains. Asian J. Appl. Sci.
**2012**, 5, 224–231. [Google Scholar] - Rinaldi, P.R.; Dalponte, D.D.; Vénere, M.J.; Clausse, A. Cellular automata algorithm for simulation of surface flows in large plains. Simul. Model. Pract. Theory
**2007**, 15, 315–327. [Google Scholar] [CrossRef] - Liao, M.J.; Wang, K.Y.; Meng, X.Q. Simulation of ticket hall queuing behavior in transit station based on cellular automata model. In Proceedings of the 2010 International Conference on E-Product E-Service and E-Entertainment (ICEEE), Henan, China, 7–9 November 2010; pp. 1–4. [Google Scholar]
- Martínez, M.J.F.; Merino, E.G.; Sánchez, E.G.; Sánchez, J.E.G.; del Rey, A.M.; Sánchez, G.R. A graph cellular automata model to study the spreading of an infectious disease. In Mexican International Conference on Artificial Intelligence; Springer: Berlin/Heidelberg, Germany, 2012; pp. 458–468. [Google Scholar]
- Leporati, A.; Mariot, L. 1-Resiliency of bipermutive cellular automata rules. In International Workshop on Cellular Automata and Discrete Complex Systems; Springer: Berlin/Heidelberg, Germany, 2013; pp. 110–123. [Google Scholar]
- Sethi, B.; Das, S. Modeling of asynchronous cellular automata with fixed-point attractors for pattern classification. In Proceedings of the 2013 International Conference on High Performance Computing and Simulation (HPCS), Helsinki, Finland, 1–5 July 2013; pp. 311–317. [Google Scholar]
- Marr, C.; Hütt, M.T. Cellular automata on graphs: Topological properties of ER graphs evolved towards low-entropy dynamics. Entropy
**2012**, 14, 993–1010. [Google Scholar] [CrossRef] - Tretyakova, A.; Seredynski, F.; Bouvry, P. Graph Cellular Automata approach to the Maximum Lifetime Coverage Problem in wireless sensor networks. Simulation
**2016**, 92, 153–164. [Google Scholar] [CrossRef] - Małecki, K.; Jankowski, J.; Rokita, M. Application of Graph Cellular Automata in Social Network Based Recommender System. In International Conference on Computational Collective Intelligence; Springer: Berlin/Heidelberg, Germany, 2013; pp. 21–29. [Google Scholar]
- Weimar, J.R. Cellular automata for reaction-diffusion systems. Parallel Comput.
**1997**, 23, 1699–1715. [Google Scholar] [CrossRef] - West, D.B. Introduction to Graph Theory; Prentice Hall: Upper Saddle River, NJ, USA, 2001; Volume 2. [Google Scholar]
- Nagel, K.; Schreckenberg, M. A cellular automaton model for freeway traffic. J. Phys. I
**1992**, 2, 2221–2229. [Google Scholar] [CrossRef] - Hoogendoorn, S.; Bovy, P. State-of-the-art of vehicular traffic flow modelling. Proc. Inst. Mech. Eng. Part I J. Syst. Control Eng.
**2001**, 215, 283–303. [Google Scholar] [CrossRef] - Biham, O.; Middleton, A.A.; Levine, D. Self-organization and a dynamical transition in traffic-flow models. Phys. Rev. A
**1992**, 46, R6124–R6127. [Google Scholar] [CrossRef] [PubMed] - Schadschneider, A.; Schreckenberg, M. Traffic flow models with ‘slow-to-start’rules. Ann. Phys.
**1997**, 509, 541–551. [Google Scholar] [CrossRef] - Chopard, B.; Luthi, P.O.; Queloz, P. Cellular automata model of car traffic in a two-dimensional street network. J. Phys. A
**1996**, 29, 2325–2336. [Google Scholar] [CrossRef] - Jost, D.; Nagel, K. Probabilistic Traffic Flow Breakdown in Stochastic Car Following Models. In Proceedings of the Transportation Research Board 82nd Annual Meeting compendium of papers CD-ROM, Washington, DC, USA, 12–16 January 2003; pp. 3–42. [Google Scholar]
- Fukui, M.; Ishibashi, Y. Traffic flow in 1D cellular automaton model including cars moving with high speed. J. Phys. Soc. Jpn.
**1996**, 65, 1868–1870. [Google Scholar] [CrossRef] - Nagel, K.; Wolf, D.E.; Wagner, P.; Simon, P. Two-lane traffic rules for cellular automata: A systematic approach. Phys. Rev. E
**1998**, 58, 1425–1437. [Google Scholar] [CrossRef] - Lan, L.; Chang, C.W. Inhomogeneous cellular automata modeling for mixed traffic with cars and motorcycles. J. Adv. Transp.
**2005**, 39, 323–349. [Google Scholar] [CrossRef] - Vasic, J.; Ruskin, H.J. Cellular automata simulation of traffic including cars and bicycles. Phys. A Stat. Mech. Appl.
**2012**, 391, 2720–2729. [Google Scholar] [CrossRef] - Rickert, M.; Nagel, K.; Schreckenberg, M.; Latour, A. Two lane traffic simulations using cellular automata. Phys. A Stat. Mech. Appl.
**1996**, 231, 534–550. [Google Scholar] [CrossRef] - Chowdhury, D.; Wolf, D.E. Praticle hopping models for two-lane traffic with two kinds of vehicles: Effects of lane-changing rules. Phys. A Stat. Mech. Appl.
**1997**, 235, 417–439. [Google Scholar] [CrossRef] - Knospe, W.; Santen, L.; Schadschneider, A.; Schreckenberg, M. Disorder effects in cellular automata for two-lane traffic. Phys. A Stat. Mech. Appl.
**1999**, 265, 614–633. [Google Scholar] [CrossRef] - Wang, Y.M.; Zhou, L.S.; Lv, Y.B. Cellular automaton traffic flow model considering flexible safe space for lane-changing. J. Syst. Simul.
**2008**, 20, 1159–1162. [Google Scholar] - Wang, Y.M. Studies on Traffic Organization Planning and Traffic Flow Simulation under the Influence of Major Public Emergencies; Beijing Jiaotong University: Beijing, China, 2009. [Google Scholar]
- Xu, H.X.; Zhang, D.M. A cellular automaton model based on improved rules of flexible safe lane-changing distance. J. Shenyang Univ. (Nat. Sci. Ed.)
**2014**, 26, 369–371. [Google Scholar] - Xu, H.; Xu, M. A cellular automata traffic flow model based on safe lane-changing distance constraint rule. In Proceedings of the 2016 IEEE Advanced Information Management, Communicates, Electronic and Automation Control Conference (IMCEC), Xi’an, China, 3–5 October 2016; pp. 1253–1256. [Google Scholar]
- Daganzo, C. In traffic flow, cellular automata = kinematic waves. Transp. Res. Part B
**2006**, 40, 396–403. [Google Scholar] [CrossRef] - Wang, R.; Liu, M. A realistic cellular automata model to simulate traffic flow at urban roundabouts. In International Conference on Computational Science; Springer: Berlin/Heidelberg, Germany, 2005; Volume 3515, pp. 420–427. [Google Scholar]
- Feng, Y.; Liu, Y.; Deo, P.; Ruskin, H.J. Heterogeneous Traffic Flow Model for a Two-Lane Roundabout and Controlled Intersection. Int. J. Mod. Phys. C
**2007**, 18, 107–117. [Google Scholar] [CrossRef] - Małecki, K.; Wątróbski, J. Cellular Automaton to Study the Impact of Changes in Traffic Rules in a Roundabout: A Preliminary Approach. Appl. Sci.
**2017**, 7, 742. [Google Scholar] [CrossRef] - Liu, M.Z.; Zhao, S.B.; Wang, R.L. A cellular automaton model for heterogeneous and incosistent driver behavior in urban traffic. Commun. Theor. Phys.
**2012**, 58, 744–748. [Google Scholar] [CrossRef] - Małecki, K.; Iwan, S. Development of Cellular Automata for Simulation of the Crossroads Model with a Traffic Detection System. In International Conference on Transport Systems Telematics; Springer: Berlin/Heidelberg, Germany, 2012; Volume 329, pp. 276–283. [Google Scholar]
- Heeroo, K.N.; Gukhool, O.; Hoorpah, D. A Ludo Cellular Automata model for microscopic traffic flow. J. Comput. Sci.
**2016**, 16, 114–127. [Google Scholar] [CrossRef] - Małecki, K. The Use of Heterogeneous Cellular Automata to Study the Capacity of the Roundabout. In International Conference on Artificial Intelligence and Soft Computing; Springer: Cham, Switzerland, 2017; pp. 308–317. [Google Scholar]
- Iwan, S.; Małecki, K. Utilization of cellular automata for analysis of the efficiency of urban freight transport measures based on loading/unloading bays example. Transp. Res. Procedia
**2017**, 25, 1021–1035. [Google Scholar] [CrossRef] - Iwan, S.; Kijewska, K.; Johansen, B.G.; Eidhammer, O.; Małecki, K.; Konicki, W.; Thompson, R.G. Analysis of the environmental impacts of unloading bays based on cellular automata simulation. Transp. Res. D Transp. Environ.
**2017**. [Google Scholar] [CrossRef]

**Figure 1.**Changing the graph structure: (

**a**) exemplary graph; (

**b**) after vertex removal; (

**c**) after edge removal; (

**d**) after vertex addition; (

**e**) after edge addition.

**Figure 2.**An example of a graph describing the relational neighbourhood of objects in a modeled system. The vertices of the graph correspond to the cells of cellular automata (CA).

**Figure 3.**Objects and corresponding relations mapped to cells of r–GCA: (

**a**) relation based neighbourhood graph and (

**b**) corresponding activity matrix of CA cells (1: activated cell, 0: deactivated cell).

**Figure 6.**A graph made as per the situation in Figure 5.

**Figure 16.**Types of neighbourhoods in a graph cellular automaton (relation-based graph cellular automation (r–GCA)): analogous to Moore’s (

**a**) or von Neumann’s neighbourhood (

**b**) in a classical CA; in r–GCA independent from the distance in the d-dimensional space of the cells (

**c**,

**d**).

Characteristic | Cellular Automata | |||
---|---|---|---|---|

Homogeneous CA | Structurally Dynamic CA [2,3] | Asynchronous CA [4,5] | Graph CA [8] | |

Grid of cells | In d-dimensional space (d ≥ 1) | 2–dimensional space | In d-dimensional space (d ≥ 1), 2-dimensional | Irregular structure, in 2-dimensional space |

State of automaton | Depends on states of all cells | Depends on states of all cells | Depends on states of all cells | Depends on states of all cells |

Set of states for each cell | Identical | Identical | Identical | Identical |

Change of state of cells | Synchronous | Synchronous | Asynchronous | Synchronous |

Grid of automaton | Unchanging over time | Unchanging over time | Unchanging over time | Unchanging over time |

Neighbourhood diagram for entire grid | Regular | Quasi-regular. Neighbourhood described by a set of neighbourhoods | Regular | Neighbourhoods described by a graph |

Rule complexity | Elementary | Elementary | Elementary | Elementary or complex (depending on automaton) |

Combining with automata of the same type | Impossible | Impossible | Impossible | Possible as a hierarchical graph combination. |

**Table 2.**Simulation results for the road presented in Figure 15.

Speed [km/h] | Number of Vehicles | Time [M:SS] |
---|---|---|

30 | 1065 | 5:48 |

50 | 1087 | 3:56 |

70 | 1114 | 2:47 |

90 | 1128 | 2:13 |

© 2017 by the author. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (http://creativecommons.org/licenses/by/4.0/).

## Share and Cite

**MDPI and ACS Style**

Małecki, K.
Graph Cellular Automata with Relation-Based Neighbourhoods of Cells for Complex Systems Modelling: A Case of Traffic Simulation. *Symmetry* **2017**, *9*, 322.
https://doi.org/10.3390/sym9120322

**AMA Style**

Małecki K.
Graph Cellular Automata with Relation-Based Neighbourhoods of Cells for Complex Systems Modelling: A Case of Traffic Simulation. *Symmetry*. 2017; 9(12):322.
https://doi.org/10.3390/sym9120322

**Chicago/Turabian Style**

Małecki, Krzysztof.
2017. "Graph Cellular Automata with Relation-Based Neighbourhoods of Cells for Complex Systems Modelling: A Case of Traffic Simulation" *Symmetry* 9, no. 12: 322.
https://doi.org/10.3390/sym9120322