Replication in Agent Based Models Using Formal Methods and Multiple Updating Strategies

Total Page:16

File Type:pdf, Size:1020Kb

Replication in Agent Based Models Using Formal Methods and Multiple Updating Strategies Replication in Agent Based Models using Formal Methods and Multiple Updating Strategies Joseph Kehoe BSc MSc A Thesis submitted for the degree of Doctor of Philosophy Supervisors: Dr. Martin Crane, Prof. Heather Ruskin School of Computing Dublin City University June 2017 Declaration I hereby certify that this material, which I now submit for assessment on the pro- gramme of study leading to the award of PhD is entirely my own work, and that I have exercised reasonable care to ensure that the work is original, and does not to the best of my knowledge breach any law of copyright, and has not been taken from the work of others save and to the extent that such work has been cited and acknowledged within the text of my work. Signed: (Candidate) ID No.: 58118713 Date: 5th May 2015 i Abstract Replication in Agent Based Models using Formal Methods and Multiple Updating Strategies Joseph Kehoe Agent based Modelling is now a standard form of modelling in the field of so- cial simulations. One of the outstanding issues in this field is known as the Repli- cation Problem. Simply stated this is the inability of researchers to independently replicate the results of Agent Based Models published by other researchers. This thesis outlines a two-part proposed solution to this problem that uses formal meth- ods to precisely specify Agent Based Models and employs multiple updating strate- gies to demonstrate that any simulation results are independent of updating strat- egy. A novel synchronous updating algorithm is presented that allows synchronus updating to be extended from Cellular Automata based simulations to Agent Based Simulations. Asymptotic analysis of the novel synchronous algorithm shows that it is Θ(n log n) in time and Θ(n) in space. It is demonstrated that the new algo- rithm does not suffer from the deficiencies of existing asynchronous algorithms and that it also allows collision detection to be incorporated into agent behaviours. The applicability of this approach is demonstrated by specifying and then repro- ducing the results of Sugarscape, a well known and complex Agent Based Social Simulation. The first formal specification of Sugarscape is presented and used to identify the ambiguities that have made replication of the original results so diffi- cult. A framework is developed that implements the new algorithm alongside ex- isting asynchronus algorithms and is used to implement Sugarscape and compare the different updating approaches. This is the first synchronous implementation of Sugarscape and the only synchronous implementation of any Agent Based Model of comparable complexity. It is also the first comparison of synchronous and asyn- chronus updating applied to the same Agent Based Model. Keywords: Agent Based Models, Agent Based Social Simulations, Replica- tion Problem, Formal Methods, Z Notation, Synchronous Updating, Asynchronous Updating, Algorithms. i Contents 1 Introduction 2 1.1 Agent-Based Modelling . .2 1.2 Ensuring Reproducibility of Results . .4 1.3 Outline of Thesis . .6 2 Agent Based Models (ABM) 7 2.1 Introduction . .7 2.2 Computer Simulations . .7 2.2.1 What are Simulations? . .7 2.2.2 The Purpose of Simulation . 10 2.3 What are Agent Based Models? . 12 2.3.1 Characteristics . 12 2.3.2 Topologies . 13 2.3.3 Neighbourhood . 15 2.3.4 History of ABM . 16 2.4 Alternatives to ABM . 20 2.4.1 Introduction . 20 2.4.2 Dynamic Micro-Simulation (DMS) . 21 2.4.3 Equation-Based Modelling (EBM) . 21 2.4.4 Discrete Event Simulation (DES) . 22 2.5 Toolkits . 23 2.5.1 Introduction . 23 2.5.2 NetLogo . 24 2.5.3 Repast . 25 2.5.4 Mason . 26 2.5.5 Ascape . 27 2.5.6 Other Toolkits . 27 2.6 The Replication Problem . 28 2.6.1 Overview, Design concepts, and Details . 29 2.6.2 Model Alignment . 30 2.6.3 A Model Driven Approach . 31 2.6.4 Executable Papers . 31 2.6.5 Data Sharing . 32 ii 2.6.6 Reproducibility versus Replication . 32 2.7 Application Areas . 33 2.7.1 ABSS . 33 2.7.2 Computer Games . 34 2.8 Comparing Synchronous and Asynchronous Updating . 35 2.8.1 Asynchronous Updating . 36 2.8.2 Synchronous Updating . 37 2.9 Synchronous ABM . 39 2.9.1 Influences and Reaction . 39 2.9.2 Synchronous IBM . 40 2.9.3 Transactional Cellular Automata . 41 2.9.4 Pedestrian Traffic . 42 2.9.5 Turmites . 42 2.9.6 Synchronous Objects . 44 2.9.7 Combined Synchronous and Asynchronous . 45 2.10 Summary . 45 3 Concurrency 48 3.1 Introduction . 48 3.2 Issues in Concurrency . 49 3.3 Measuring Concurrent Performance . 51 3.3.1 Concurrency Metrics . 51 3.3.2 Strong Scalability: Amdahl’s Law . 53 3.3.3 Weak Scalability: Gustafson-Barsis’ Law . 54 3.3.4 Asymptotic Analysis . 56 3.3.5 OpenMP . 59 3.4 Heterogeneous Processing in Agent Based Models . 60 3.5 Summary . 62 4 Sugarscape 63 4.1 Sugarscape’s Place in ABM . 63 4.2 The Definition of Sugarscape . 64 4.3 The Lattice . 64 4.4 The Agents . 65 4.5 The Rules . 66 4.5.1 Growback . 66 4.5.2 Seasonal Growback . 66 4.5.3 Pollution Formation . 66 4.5.4 Pollution Diffusion . 67 4.5.5 Replacement . 67 4.5.6 Movement . 68 4.5.7 Agent Mating . 68 4.5.8 Agent Inheritance . 69 4.5.9 Agent Culture . 69 iii 4.5.10 Agent Combat . 70 4.5.11 Credit . 71 4.5.12 Agent disease processes . 73 4.5.13 Agent Trade . 74 4.6 Conclusion . 75 5 Formally Specifying Agent Based Models 76 5.1 Introduction . 76 5.2 The Replication Problem . 76 5.3 Formal Specification . 77 5.4 Specifying Sugarscape . 78 5.4.1 Overview . 78 5.4.2 Types and Constants . 80 5.4.3 State . 82 5.4.4 Initial State . 88 5.4.5 Specifying Behaviours . 89 5.4.6 Synchronous Rule Specification . 92 5.4.7 Specifying Conflict Resolution . 95 5.4.8 Specifying Asynchronous Updating Strategies . 97 5.4.9 Overview of Specification Process . 103 5.5 Results of the Specification . 104 5.6 Issues . 105 5.7 Conclusion . 106 6 Extending Synchronous Updating to Agent Based Modelling 109 6.1 Introduction . 109 6.2 Distinguishing Sequential and Concurrent Updating . 110 6.3 DES versus ABM . 114 6.4 Asynchronous versus Synchronous . 115 6.5 Instantaneous Information Leakage between Neighbourhoods . 117 6.5.1 Probability of Instantaneous Information Transfer Accross Local Boundaries . 120 6.6 Conflict Resolution . 125 6.7 Rule Classification . 127 6.8 Synchronous Algorithms . 129 6.8.1 Independent Actions . 130 6.8.2 Read-Dependent Actions . 131 6.8.3 Write-Dependent Actions . 134 6.8.4 Synchronous DES . 145 6.8.5 Issues with Asymptotic Complexity . 145 6.9 Conclusion . 148 iv 7 Sugarscape: A Case Study in Replication 150 7.1 Introduction . 150 7.2 The Framework . 151 7.2.1 Using the Framework . 153 7.2.2 Framework Overview . 156 7.3 Results from reproducing Sugarscape . 158 7.3.1 Carrying Capacity . 158 7.3.2 Effect of Metabolism and Vision on Carrying Capacity . 164 7.3.3 Comparing effects of SU and AU on Carrying Capacity . 166 7.3.4 Convergence of Culture . 169 7.3.5 Mating and Evolution . 170 7.4 Conclusion . 176 8 Conclusion 180 8.1 Overview of Thesis . 180 8.2 What we Achieved . 181 8.2.1 Improving Replication of ABM through Formal Specification181 8.2.2 Detecting Artefacts through Multiple Updating Strategies 182 A Empirical Benchmarks 185 A.1 Overview of Benchmarks . 185 A.1.1 Sequential Benchmarks.
Recommended publications
  • Gamagram: Graphical Modeling with the GAMA Platform Patrick Taillandier
    GAMAGraM: Graphical modeling with the GAMA platform Patrick Taillandier To cite this version: Patrick Taillandier. GAMAGraM: Graphical modeling with the GAMA platform. The 4th Interna- tional Conference on Complex Systems and Applications, Jun 2014, France. 6 p. hal-01055569 HAL Id: hal-01055569 https://hal.archives-ouvertes.fr/hal-01055569 Submitted on 13 Aug 2014 HAL is a multi-disciplinary open access L’archive ouverte pluridisciplinaire HAL, est archive for the deposit and dissemination of sci- destinée au dépôt et à la diffusion de documents entific research documents, whether they are pub- scientifiques de niveau recherche, publiés ou non, lished or not. The documents may come from émanant des établissements d’enseignement et de teaching and research institutions in France or recherche français ou étrangers, des laboratoires abroad, or from public or private research centers. publics ou privés. Proceedings of ICCSA 2014 Normandie University, Le Havre, France - June 23-26, 2014 GAMAGRAM: GRAPHICAL MODELING WITH THE GAMA PLATFORM Patrick Taillandier ∗† Abstract. These last years have seen the multiplication of plat- The paper is organized as follows: Section 2 presents forms dedicated to the conception and simulation of agent-based the context of this work, in particular the existing agent- models for studying complex systems. If these platforms allowed based modeling platforms and the graphical modeling lan- to democratize this modeling approach, they are often complex to guages. Section 3 is dedicated to the presentation of the use by non-computer scientists as most of them require to define GAMAGraM plugin. At last, Section 4 concludes and models by writing numerous code lines.
    [Show full text]
  • Towards an Agent-Based Manufacturing Control Strategy: a Simulation Study Mechanical Engineering
    Towards an agent-based manufacturing control strategy: a simulation study Guilherme Cordeiro Lopes Thesis to obtain the Master of Science Degree in Mechanical Engineering Supervisors: Prof. João Carlos Prata dos Reis Prof. Susana Margarida da Silva Vieira Examination Committee Chairperson: Prof. Paulo Jorge Coelho Ramalho Oliveira Supervisor: Prof. João Carlos Prata dos Reis Members of the Committee: Prof. João Manuel Gouveia de Figueiredo Prof. Carlos Baptista Cardeira November 2018 ii Aos meus pais, aos meus avos.´ iii iv Acknowledgments To Professor Joao˜ Reis and Susana Vieira, for all the guidance, support and availability throughout the thesis. To my family for always supporting and encouraging me to go further. A special thank you to my parents and grandparents, to whom I dedicate this thesis, for all they have given me so far. They are the base support of my life. To Daniela, all these years always by my side, giving me the strength to overcome the hardest moments and the joy of sharing the happiest ones. To all my friends who helped turning this journey into the best years of my life. v vi Resumo Com o advento de tecnologias emergentes como a Internet das Coisas, redes de sensores sem fios, computac¸ao˜ em nuvem, Internet movel´ e Inteligenciaˆ Artificial, e a sua introduc¸ao˜ no mundo da industria,´ um novo paradigma chegou: a quarta revoluc¸ao˜ industrial. Com o objectivo de usar estas novas tecnolo- gias para alcanc¸ar a fabrica´ inteligente, flex´ıvel e reconfiguravel´ do futuro, capaz de produzir produtos customizados e em pequenos lotes de forma eficiente e rentavel,´ alguns sistemas avanc¸ados de con- trolo de manufactura temˆ sido propostos.
    [Show full text]
  • Building a Collaboration Platform Using Agent-Based Modelling
    SCHOOL OF SCIENCE AND ENGINEERING BUILDING A COLLABORATION PLATFORM USING AGENT-BASED MODELLING Capstone Design December 2016 Chaimae Aklibous Supervised by Professor Mourhir Asmaa i BUILDING A COLLABORATION PLATFORM USING AGENT-BASED MODELLING Capstone Project Report Approved by the Supervisor Asmaa Mourhir ii ACKNOWLEDGEMENTS Before concluding the journey of my four years and a half of studies, I am filled with enthusiasm and gratitude to write this note for all the people who supported and helped me to realize this capstone project. I would like first and foremost to direct my appreciation to Professor Asmaa Mourhir who was always there to answer my questions and provide guidance. Also, I take this opportunity to express the profound gratitude from my deep heart to my beloved parents for their love and continuous support-both spiritually and materially. Also, I would like to express my special appreciation and thanks to my two friends Foutouh Najoua and KARAZI Meryam for their support. I do not think this would have been possible without them. iii ABSTRACT The purpose of this capstone project is building a collaboration platform using Agent Modelling to arrange and interpret the concepts related to the modelling of environmental issues and the development of scenarios. Motivated towards this goal, the platform shall include a set of features that will allow stakeholders or users to create models, generate scenarios, and share the results among them. Agent-based modelling represents a major tool to create complex models and run simulations, which gives specific observations about certain environmental issues. Also, it has other important uses, such as message passing, and this the feature that will be exploited within this project.
    [Show full text]
  • A Multi-Modal Urban Traffic Agent-Based Framework to Study Individual Response to Catastrophic Events
    CORE Metadata, citation and similar papers at core.ac.uk Provided by Open Archive Toulouse Archive Ouverte Open Archive Toulouse Archive Ouverte OATAO is an open access repository that collects the work of Toulouse researchers and makes it freely available over the web where possible This is an author’s version published in: http://oatao.univ-toulouse.fr/22662 Official URL DOI : https://doi.org/10.1007/978-3-030-03098-8_28 To cite this version: Chapuis, Kévin and Taillandier, Patrick and Gaudou, Benoit and Drogoul, Alexis and Daudé, Eric A Multi-modal Urban Traffic Agent-Based Framework to Study Individual Response to Catastrophic Events. (2018) In: 21st International Conference on Principles and Practice of Multi-Agent Systems (PRIMA 2018), 29 October 2018 - 2 November 2018 (Tokyo, Japan). Any correspondence concerning this service should be sent to the repository administrator: [email protected] A multi-modal urban traffic agent-based framework to study individual response to catastrophic events Kevin Chapuis 1,4, Patrick Taillandier 2, Benoit Gaudou 1,3,4, Alexis Drogoul 1,4, and Eric Daud´e 5 1 Sorbonne University, IRD, UMMISCO, F-93143, Bondy, France 2 MIAT, University of Toulouse, INRA, Castanet-Tolosan, France 3 University Toulouse Capitole, IRIT, Toulouse, France 4 USTH - AVAST, ICTLab, Hanoi, Vietnam 5 CNRS, Rouen University, UMR IDEES, Rouen, France Abstract. Urban traffic is made of a variety of mobility modes that have to be taken into account to explore the impact of catastrophic event. From individual mobility behaviors to macroscopic traffic dynam- ics, agent-based modeling provides an interesting conceptual framework to study this question.
    [Show full text]
  • Comparison of Three Agent-Based Platforms on the Basis of a Simple Epidemiological Model (Wip)
    COMPARISON OF THREE AGENT-BASED PLATFORMS ON THE BASIS OF A SIMPLE EPIDEMIOLOGICAL MODEL (WIP) Kishoj Bajracharya, Raphael Duboz Asian Institute of Technology Pathum Thani, Thailand [email protected], [email protected] Keywords: Agent-based platform, Multi-agent system, SIR cases. To verify the correctness of 3 platforms, we should Model, Disease spread modeling, Verification control the scheduling of actions of agent-based SIR model in these platforms. Simulations are performed under the same Abstract model and the same set of experimental parameters and then With the extensive use of agent-based modeling and simula- comparisons of the results are done by using statistical anal- tion, there are many agent-based platforms available. The ob- ysis. This paper is structured as follows. First, we begin with jective of this paper is to compare 3 agent-based platforms: the related works in Section 2. In Section 3, we introduce the NetLogo, Repast, and Cormas based on the results of the agent-based platforms in short. This is followed by method- simulation obtained from the same set of experimental sce- ology for the comparison of agent-based platforms in Section narios. For this purpose, agent-based SIR model is chosen 4. Section 5 deals with the results of simulations and compar- to study the pattern of the spread of an infectious disease ison of the agent-based platforms. Finally, we conclude the within certain population over time. The methodology for the paper with conclusion in Section 6 and recommendation for comparison is to design and implement the same agent-based future implementation in Section 7.
    [Show full text]
  • The MASON Simulation Toolkit: Past, Present, and Future
    The MASON Simulation Toolkit: Past, Present, and Future Sean Luke1, Robert Simon1, Andrew Crooks1, Haoliang Wang1,ErmoWei1, David Freelan1, Carmine Spagnuolo2, Vittorio Scarano2, Gennaro Cordasco3, and Claudio Cioffi-Revilla1 1 George Mason University, Washington, DC, USA sean, simon @cs.gmu.edu hwang17, ewei,{ dfreelan, acrooks2,} ccioffi @gmu.edu { } 2 Universit`adegli Studi di Salerno, Salerno, Italy [email protected] [email protected] 3 Universit`adegli Studi della Campania “Luigi Vanvitelli”, Naples, Italy [email protected] Abstract. MASON is a widely-used open-source agent-based simulation toolkit that has been in constant development since 2002. MASON’s architecture was cutting-edge for its time, but advances in computer technology now o↵er new opportunities for the ABM community to scale models and apply new modeling techniques. We are extending MASON to provide these opportunities in response to community feedback. In this paper we discuss MASON, its history and design, and how we plan to improve and extend it over the next several years. Based on user feedback will add distributed simulation, distributed GIS, optimization and sen- sitivity analysis tools, external language and development environment support, statistics facilities, collaborative archives, and educational tools. Keywords: Agent-Based Simulation Open Source Library · · 1 Introduction MASON is an open source single-process simulation core and visualization toolkit in Java, designed to be used for a wide range of models, but with a special emphasis on agent-based models involving up to millions of agents. MASON has support for geographical information systems (GIS) and social networks, among other areas. Agent-based models (or ABMs) have taken hold not just in the sciences [17, 18, 10], but also in engineering areas such as distributed systems, swarm robotics, multiagent learning, and artificial life: for example, swarms of drones, driverless cars, air traffic control, and factory floor robots [11, 19, 16].
    [Show full text]
  • The MASON Simulation Toolkit: Past, Present, and Future
    The MASON Simulation Toolkit: Past, Present, and Future Sean Luke1, Robert Simon1, Andrew Crooks1, Haoliang Wang1, Ermo Wei1, David Freelan1, Carmine Spagnuolo2, Vittorio Scarano2, Gennaro Cordasco3, and Claudio Cioffi-Revilla1 1 George Mason University, Washington, DC, USA {sean, simon}@cs.gmu.edu {hwang17, ewei, dfreelan, acrooks2, ccioffi}@gmu.edu 2 Universit`a degli Studi di Salerno, Salerno, Italy [email protected] [email protected] 3 Universit`a degli Studi della Campania “Luigi Vanvitelli”, Naples, Italy [email protected] Abstract. MASON is a widely-used open-source agent-based simulation toolkit that has been in constant development since 2002. MASON’s architecture was cutting-edge for its time, but advances in computer technology now offer new opportunities for the ABM community to scale models and apply new modeling techniques. We are extending MASON to provide these opportunities in response to community feedback. In this paper we discuss MASON, its history and design, and how we plan to improve and extend it over the next several years. Based on user feedback will add distributed simulation, distributed GIS, optimization and sen- sitivity analysis tools, external language and development environment support, statistics facilities, collaborative archives, and educational tools. Keywords: Agent-Based Simulation · Open Source · Library 1 Introduction MASON is an open source single-process simulation core and visualization toolkit in Java, designed to be used for a wide range of models, but with a special emphasis on agent-based models involving up to millions of agents. MASON has support for geographical information systems (GIS) and social networks, among other areas. Agent-based models (or ABMs) have taken hold not just in the sciences [17, 18, 10], but also in engineering areas such as distributed systems, swarm robotics, multiagent learning, and artificial life: for example, swarms of drones, driverless cars, air traffic control, and factory floor robots [11, 19, 16].
    [Show full text]
  • MASON Northlands: a Geospatial Agent-Based Model of Coupled Human-Artificial-Natural Systems in Boreal and Arctic Regions
    MASON NorthLands: A Geospatial Agent-Based Model of Coupled Human-Artificial-Natural Systems in Boreal and Arctic Regions Claudio Cioffi-Revilla, J. Daniel Rogers, Paul Schopf, Sean Luke, Jeff Bassett, Atesmachew Hailegiorgis, William Kennedy, Peter Revay, Meghan Mulkerin, Madeline Shaffer, Ermo Wei Center for Social Complexity and Program in Computational Social Science, George Mason University, Fairfax, Virginia 22314, USA [email protected] http://krasnow.gmu.edu/socialcomplexity/faculty/csc-faculty-dr-cioffi/ Abstract. Current climate change causes significant biophysical effects in the Northern Hemisphere, especially in the Boreal and Arctic regions. Rising and more variable temperatures, permafrost thawing, and snow loading are major hazards affecting human societies on multiple spatial, temporal, and risk-related scales. The MASON NorthLands computa- tional simulation model is motivated by fundamental science and policy research questions. Preliminary results demonstrate causal processes re- lating ambient and soil temperature increases to measurable social im- pacts, mediated by biophysical effects of climate change on the built environment, as in a coupled human-artificial-natural system (CHANS). Keywords: Agent-based modeling, climate change, Boreal region, Arc- tic, migration, permafrost, Arctic Council, coupled human-artificial-natural systems, complex adaptive systems 1 Introduction The effect of climate change on humans is one of the most significant, complex, and enduring scientific puzzles in the history of civilization, as well as one
    [Show full text]
  • GAMA 1.6: Advancing the Art of Complex Agent-Based Modeling
    GAMA 1.6: Advancing the art of complex agent-based modeling and simulation Arnaud Grignard, Patrick Taillandier, Benoit Gaudou, Duc An Vo, Nghi Huynh Quang, Alexis Drogoul To cite this version: Arnaud Grignard, Patrick Taillandier, Benoit Gaudou, Duc An Vo, Nghi Huynh Quang, et al.. GAMA 1.6: Advancing the art of complex agent-based modeling and simulation. Pacific Rim international Conference on Multi-Agents (PRIMA), Dec 2013, Dunedin, New Zealand. pp.117-131, 10.1007/978- 3-642-44927-7_9. hal-00932406 HAL Id: hal-00932406 https://hal.archives-ouvertes.fr/hal-00932406 Submitted on 17 Jan 2014 HAL is a multi-disciplinary open access L’archive ouverte pluridisciplinaire HAL, est archive for the deposit and dissemination of sci- destinée au dépôt et à la diffusion de documents entific research documents, whether they are pub- scientifiques de niveau recherche, publiés ou non, lished or not. The documents may come from émanant des établissements d’enseignement et de teaching and research institutions in France or recherche français ou étrangers, des laboratoires abroad, or from public or private research centers. publics ou privés. Distributed under a Creative Commons Attribution - ShareAlike| 4.0 International License GAMA 1.6: Advancing the art of complex agent-based modeling and simulation Arnaud Grignard1, Patrick Taillandier3, Benoit Gaudou4, Duc An Vo2, Nghi Quang Huynh5, Alexis Drogoul2 1 UMI 209 UMMISCO/MSI, UPMC, France 2 UMI 209 UMMISCO/MSI, IRD, Vietnam 3 UMR 6266 IDEES, CNRS/University of Rouen, France 4 UMR 5505 IRIT, CNRS/University of Toulouse, France 5 DREAM-CTU/IRD, CICT, Can Tho University, Vietnam Abstract.
    [Show full text]