Abstract
In this work, we present our results in development of a domain-specific programming language for an agent-based infectious disease spread modeling with contact tracing transmission. We performed an analysis of methods and tools, accessible to a scientific community, which showed significant problems of currently developed approaches. Some methods provide significant performance, sacrificing ease-of-use, others offer simple programming interface but suffer with performance drawbacks. To address both of these issues, we designed a domain-specific programming language with simple and yet powerful syntax and minimal amount of boilerplate code. The chose of the underlying infectious disease spread model is based on a growing interest in agent-based models, which are becoming more popular due to higher simulation accuracy compared to classical compartmental models. At its core, each agent has its personal user-defined daily schedule, which dictates where the agent is situated at each simulation step based on numerous parameters, such as simulation “day”, agent’s inner state, inner states of linked to this agent compartments, which can be, for example, its house, place of work, school, etc. The underlying language’s engine uses this schedule to check, which agent pair were in contact with each other and where at each simulation step. The infectious disease, defined by a set of rules, which control how do these contacts affect inner states of both agents and how disease progresses in context of a single infected agent. We designed a compiler with Python as intermediate language for a simple programming interface and Numba support for machine language translation. Performed tests showed, that the language is capable of describing complex epidemiological models and the compiler is able to generate machine code efficiently enough to run simulations with medium number of entities. The main problem of a developed approach is the quadratic nature of algorithmic complexity of a contact tracing transmission process. We left optimization of it as a topic for a future research.
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
Notes
- 1.
All tests were done using a machine with Intel i7-8700K 3.7 GHz CPU.
- 2.
Comparison was performed by evaluating the ratio between highest power coefficients of a fitted regression model.
References
Swarm (2021). http://www.swarm.org/wiki/Main_Page
Alvarez, F.E., Argente, D., Lippi, F.: A simple planning problem for Covid-19 lockdown. Technical report, National Bureau of Economic Research (2020). https://doi.org/10.3386/w26981
Avilov, K., Solovey, O.Y.: Institute of Numerical Mathematics of Russian Academy Of Sciences Moscow Institute of Physics and Technology (State University)
Eisinger, D., Thulke, H.H.: Spatial pattern formation facilitates eradication of infectious diseases. J. Appl. Ecol. 45(2), 415 (2008). https://doi.org/10.1111/j.1365-2664.2007.01439.x
Harko, T., Lobo, F.S., Mak, M.: Exact analytical solutions of the susceptible-infected-recovered (SIR) epidemic model and of the sir model with equal death and birth rates. Appl. Math. Comput. 236, 184–194 (2014). https://doi.org/10.1016/j.amc.2014.03.030
Hethcote, H.W., Van den Driessche, P.: Some epidemiological models with nonlinear incidence. J. Math. Biol. 29(3), 271–287 (1991). https://doi.org/10.1007/BF00160539
Merler, S., Ajelli, M.: The role of population heterogeneity and human mobility in the spread of pandemic influenza. Proc. Roy. Soc. B: Biol. Sci. 277(1681), 557–565 (2010). https://doi.org/10.1098/rspb.2009.1605
Ng, W.L.: To lockdown? When to peak? Will there be an end? A macroeconomic analysis on Covid-19 epidemic in the united states. J. Macroecon. 65, 103230 (2020). https://doi.org/10.1016/j.jmacro.2020.103230
Papoulias, N., Stinckwich, S., Ziane, M., Roche, B., et al.: The Kendrick modelling platform: language abstractions and tools for epidemiology. BMC Bioinform. 20(1), 1–13 (2019). https://doi.org/10.1186/s12859-019-2843-0
Patlolla, P., Gunupudi, V., Mikler, A.R., Jacob, R.T.: Agent-based simulation tools in computational epidemiology. In: Böhme, T., Larios Rosillo, V.M., Unger, H., Unger, H. (eds.) IICS 2004. LNCS, vol. 3473, pp. 212–223. Springer, Heidelberg (2006). https://doi.org/10.1007/11553762_21
Railsback, S.F., Grimm, V.: Agent-Based and Individual-Based Modeling: A Practical Introduction. Princeton University Press, Princeton (2019)
Rǎdulescu, A., Williams, C., Cavanagh, K.: Management strategies in a Seir-type model of Covid 19 community spread. Sci. Rep. 10(1), 1–16 (2020). https://doi.org/10.1038/s41598-020-77628-4
Sun, W., Jiang, W., Trulls, E., Tagliasacchi, A., Yi, K.M.: ACNe: attentive context normalization for robust permutation-equivariant learning (2020). https://doi.org/10.48550/arXiv.1907.02545
Wilensky, U.: Netlogo 6.2.2 user manual (2022). http://ccl.northwestern.edu/netlogo/docs/
Author information
Authors and Affiliations
Corresponding author
Editor information
Editors and Affiliations
A Appendix
A Appendix
Here, we describe a formal grammar of a developed language.
The set of terminal symbols is defined as: \(\varSigma =\{0..9,a..z,A..Z,+,-,*,/,^,==,!=,\) \(<>\),<,>,\(<=\),\(>=\),\(=,(,),\{,\},[,],.,~,\$\),\(->\),\(<-\),\(|\}\).
The set of non-terminal symbols is defined as: \(N=\{\)“letter”, “digit”, “number”, “id”, “expression”, “program”, “distribution_declaration”, “distribution_disc_declaration”, “distribution_cont_declaration”, “function_ declaration”, “param_declaration”, “param_sampling”, “struct_declaration”, “transition”, “infection” \(\}\).
The start symbol S is “program".
Production rules, presented using railroad diagrams, are defined in Figs. 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20 and 21.
Rights and permissions
Copyright information
© 2023 The Author(s), under exclusive license to Springer Nature Switzerland AG
About this paper
Cite this paper
Sarnatskyi, V., Baklan, I. (2023). CTrace: Language for Definition of Epidemiological Models with Contact-Tracing Transmission. In: Babichev, S., Lytvynenko, V. (eds) Lecture Notes in Data Engineering, Computational Intelligence, and Decision Making. ISDMCI 2022. Lecture Notes on Data Engineering and Communications Technologies, vol 149. Springer, Cham. https://doi.org/10.1007/978-3-031-16203-9_25
Download citation
DOI: https://doi.org/10.1007/978-3-031-16203-9_25
Published:
Publisher Name: Springer, Cham
Print ISBN: 978-3-031-16202-2
Online ISBN: 978-3-031-16203-9
eBook Packages: Intelligent Technologies and RoboticsIntelligent Technologies and Robotics (R0)