Keywords

1 Introduction

Research concerning mathematical modeling of the spread of infectious and contagious diseases has started almost one century ago [16]. The goal was the development of dynamic models that are able to capture and explain the various factors that can influence the intensity and span of the disease, in a given population of individuals.

A well known case that threatened humanity at the beginning of the twentieth century is the “1918 Flu Pandemic”, also known as the “Spanish Flu”. It lasted for more than 2 years causing the death of more than 500 million people [19]. Another very actual case, experienced nowadays by the whole humanity is “Coronavirus disease 2019” or “COVID 19” contagious respiratory and vascular disease, also known as “Severe Acute Respiratory Syndrome Coronavirus 2” or “SARS-CoV-2” [14]. It triggered a huge research interest in biomedical and computing sciences, and the need of development of detailed simulation models of the dynamics of the spread of the disease, including the design and analysis of various mitigation strategies and policies [2, 10].

Agent-based modeling and simulation (ABMS), is a well established approach that provides multiple application opportunities in natural systems including, among others, the simulation of stochastic diffusion processes in continuous and nonlinear environments [3]. ABMS enables the domain experts to choose between various levels of granularity of modeling at the macroscopic, mesoscopic or microscopic level. This flexibility allows focusing on various elements of the target system, by trading-off capturing of details and exploiting of efficiency of the modeling. It worth noting that the ABMS techniques and tools played a crucial role in the development of virus spread simulations using novel ABMS platforms, like GAMA, MESA and JS-son [2, 8, 10, 12, 13, 15].

The core of our proposal is a generic spatial Susceptible-Infected-Recovered (SIR) model of epidemics spread in a population. In particular we exploit our initial results in ABMS of core spatial SIR models for epidemics spread in a population, presented in [5]. Here we expand our work by adding an infection spread mitigation control agent and modeling the effects of its mitigation strategies and policies. Our proposal follows a control system approach representing the “intelligence” of the system. Various decisions and strategies, for limiting the epidemics, are conceptualized as dynamic controls that are defined based on the status information, acquired from the system using available social sensors. The upgraded multi-agent model is simulated using the GAMA multi-agent platform [20], following the methodology proposed in [5].

The paper is structured as follows. Section 2 contains an overview of relevant related works. Section 3 generalizes the generic SIR model from [5] by adding a spatial attenuation function to the infection propagation part. We propose and model the strategy of infection mitigation and management, modeling the behavior of the control agent supporting this strategy. Section 4 contains experimental results for the baseline system (without infection mitigation and management, considering a scenario with 15000 rather than 10000 agents, as in [5]), as well as for the same system including the control part. Section 5 presents the conclusions and points to future works.

2 Related Works

Compartmental models originate from the early work of Kermack and McKendrick [16]. They are used by epidemiologists and mathematicians to abstract the spreading process of infectious diseases, and to simplify their mathematical analysis. These models propose to structure the spreading process of the epidemics within the population by compartments, depending on the state of the population individuals. Examples of compartments are: Susceptible, Infectious, and Recovered, usually labeled as S, I and R. These models are defined as differential or difference equations that capture the dynamics of the population transfer between compartments, according to the degree, or stage, of the infection. Such a model can be utilized to theoretically, or experimentally, investigate the spread of the epidemic both in time and in (geo)space [21].

Compartmental models can be classified according to several criteria: i) depending on spatial and temporal characteristics of the model: temporal and spatial-temporal; ii) depending on the nature of modeling: discrete and continuous; iii) depending on model uncertainty: deterministic and stochastic; iv) depending on granularity of modeling: microscopic, mesoscopic and macroscopic.

Related models of diffusion processes were investigated using multi-agent simulation, including agent-based emotion contagion [4], information propagation in large teams [11] and BDI models for predator-prey systems [6].

Agent technologies include tools and platforms for software development, modeling and simulation [7, 17, 18]. Multi-agent systems can model emergent phenomena, and provide a natural representation of the system under observation. They are flexible, allowing the development of dynamic models and simulations. ABMS were traditionally employed for modeling and simulation of diverse human and social systems, combining strategic thinking with flow and diffusion processes, in many areas of business, society, biology, and physics [3]. A recent survey of modern ABMS tools is given in [1].

In the context of the recent COVID pandemic, several multi-agent simulations have been proposed, some of them based on GAMA platform [2, 10, 22]. Moreover, control system approaches have been found useful to theoretically investigate the control dynamic of a computer virus [9].

3 Multi-agent SIR Model

3.1 Core Spatial SIR Model

Let us consider the general core spatial SIR model introduced in [5] that contains:

  • S compartment, denoting the set of susceptible individuals. They are not infected. When they enter in contact with infectious individuals, they can become infected. The population of susceptible individuals, at time t, is denoted by \(S_t\).

  • I compartment, denoting the set of infected individuals. They are infected and capable of infecting other susceptible individuals. The population of infected individuals, at time t, is denoted by \(I_t\).

  • R compartment, denoting the set of “removed” individuals. This set includes all individuals that either recovered, became resistant, or died. The population of removed individuals at time t is denoted by \(R_t\).

The aim of the model is to capture the population dynamics in space and time. Here:

$$\begin{aligned} \begin{aligned}&\varDelta S = S_{t + \varDelta t} - S_t \\&\varDelta I = I_{t + \varDelta t} - I_t \\&\varDelta R = R_{t + \varDelta t} - R_t \end{aligned} \end{aligned}$$
(1)

Moreover, the total population of individuals at time t, denoted with \(N_t\), is defined by:

$$\begin{aligned} \begin{aligned}&N_{t} = S_t + I_t + R_t \end{aligned} \end{aligned}$$
(2)

The spread of the disease is modeled by function F, representing the “force of infection”. In each step, a fraction F of susceptible individuals, from set \(S_{t}\), gets infected. Obviously, the set F depends on the current population of susceptible individuals \(S_t\), as well as on the current set of infections \(I_t\). Hence, the amount of susceptible individuals that get infected, in the current step, can be written as \(F(S_t,I_t)\). The infected individuals will be “transferred” from the S compartment to the I compartment. Hence:

$$\begin{aligned} \begin{aligned}&\varDelta S = -F(S_t,I_t) \end{aligned} \end{aligned}$$
(3)

Let us also assume that a proportion \(\gamma \in (0,1)\) of infected individuals (denoted in what follows with \(\gamma \cdot I_t\)) is removed (either because they became resistant or they died). Adding Eq. (3) to this system, it follows that:

$$\begin{aligned} \begin{aligned}&\varDelta S = -F(S_t,I_t) \\&\varDelta I = F(S_t,I_t) - \gamma \cdot I_t \\&\varDelta R = \gamma \cdot I_t \end{aligned} \end{aligned}$$
(4)

This system is discrete, so time has a discrete variation \(t_0=0,t_1=h,\dots ,t_n=n\cdot h, \dots \), where \(h>0\) is the constant time step. In what follows, we denote the values of model variables at time \(t_n\) simply with subscript n, where n is the current step number. For example, the number of infected individuals at step n is \(I_n\).

3.2 Modeling Infection Spread

The specification of F depends on the considered model. We have chosen a spatial model, in which each individual has a certain physical location. This allows capturing the local spread of the disease, in which a certain amount of individuals, in the spatial vicinity of an infected individual, will get infected. Moreover, our individuals are “mobile”, i.e. they are allowed to change their location in each step. Thus, “locality” of infection propagation, and “mobility” of individuals, enable our simple model to capture both the spatial and the temporal dimensions of the spread of the disease.

Let us denote with i.x the physical coordinate of an individual i and let d be a distance function, in the space of physical locations (for example the Euclidean distance). We denote with V(x) a vicinity of x, i.e. the set of physical locations that are “close” to x, according to some specific rule. Here, one possibility is to define V(x) as the set of locations inside the ball of radius \(\epsilon \), centered at x, i.e.:

$$\begin{aligned} \begin{aligned}&B(x,\epsilon ) = \{y | d(x,y) \le \epsilon \} \end{aligned} \end{aligned}$$
(5)

Let us now consider an individual j and let I(j) be the set of all infected individuals from the vicinity of j, defined as:

$$\begin{aligned} \begin{aligned}&I(j) = \{i | i.x \in B(j.x,\epsilon ) \} \end{aligned} \end{aligned}$$
(6)

Let \(p_i,q_i\in (0,1)\) be the probabilities that a certain individual i will transmit the infection in its vicinity and, respectively, will be infected if is present nearby. Let us assume that the transmission of the disease from an infected individual i to an individual j located at a distance x from i is also affected by a spatial attenuation function \(\phi (x)\) defined as:

$$\begin{aligned} \begin{aligned}&\phi (x) : \mathbb {R}^+ \longrightarrow [0,1] \\&\phi (0) = 1 \\&\lim _{x \rightarrow \infty } \phi (x) = 0 \\&x \le y \Rightarrow \phi (x) \ge \phi (y) \end{aligned} \end{aligned}$$
(7)

Let us denote by \(d_{ij}\) the distance between individuals i and j, defined as:

$$\begin{aligned} \begin{aligned} d_{ij} = d(i.x,j.x) \end{aligned} \end{aligned}$$
(8)

Following simple probabilistic reasoning, it is easy to see that the probability that a susceptible individual j will get infected is defined by:

$$\begin{aligned} \begin{aligned} q_j \cdot (1 - \prod _{i \in I(j)} (1-p_i \cdot \phi (d_{ij})) \end{aligned} \end{aligned}$$
(9)

Note that Eq. (9) generalizes the simple interaction model introduced in [5], where it was considered that the probability of infection of a susceptible individual, in the vicinity of an infected individual, is constant.

Observe that (9) is a well-defined probability value, in the interval \([0,q_i]\), and that this value is 0 when \(I(j)=\emptyset \). This corresponds to the intuition that there is no infection propagation to a susceptible individual when there are no infected peers in its vicinity.

3.3 Discussion

Let us denote with \(\beta \) the average infection probability, determined by Eq. (9). This value depends on the average number of individuals in the vicinity of the considered individual, as well as on probabilities p and q. Moreover, the infection will affect only the susceptible individuals from the population. Hence, \(\beta \) should be weighted with the fraction \(\frac{S_t}{N_t}\). Then we could estimate \(F(S_t,I_t)\) as:

$$\begin{aligned} \begin{aligned}&F(S_t,I_t) = \beta \cdot \frac{S_t}{N_t} \cdot I_t \end{aligned} \end{aligned}$$
(10)

Replacing (10) in the second equation of (4) it can be established that:

$$\begin{aligned} \begin{aligned}&\varDelta I = \left( \frac{\beta }{\gamma } \cdot \frac{S_t}{N_t} - 1\right) \cdot \gamma \cdot I_t \end{aligned} \end{aligned}$$
(11)

A simple mathematical analysis of Eq. (11) shows that the ratio \(\frac{\beta }{\gamma }\) is the “reproduction rate” (i.e. \(R_0 = \beta /\gamma \)) from the classical SIR model, defined using differential equations [16]. The difference between the two models is that, here, \(\beta \) is a random variable that is determined by the spatial definition of what is meant by the “vicinity” of an individual. Moreover, the dynamic model is discrete and stochastic, rather than continuous and deterministic.

Note also that the value of parameter \(\gamma \) determines the average duration of the infection of an individual (removal time), i.e. the number of steps from the moment it became infected until it is removed. The expected value of this random variable is:

$$\begin{aligned} \begin{aligned} T_r&= 1\cdot \gamma + 2 \cdot \gamma \cdot (1-\gamma ) + 3 \cdot \gamma \cdot (1-\gamma )^2 + \dots \\&= \gamma \cdot (1 + 2 \cdot (1-\gamma ) + 3 \cdot (1-\gamma )^2 + \dots ) = \gamma \cdot Q \end{aligned} \end{aligned}$$

However:

$$\begin{aligned} \begin{aligned} Q&= (1 + (1-\gamma ) + (1-\gamma )^2 + \dots ) + (1-\gamma ) \cdot Q = 1/\gamma + (1-\gamma ) \cdot Q \\ \end{aligned} \end{aligned}$$

Solving the equation we obtain \(Q = 1/\gamma ^2\) and substituting it in expression of \(T_r\) results:

$$\begin{aligned} \begin{aligned} T_r&= 1/\gamma \end{aligned} \end{aligned}$$
(12)

3.4 Infection Management

The proposed approach for infection spread management assumes three steps: situation assessment, detection and mitigation. The system block diagram is shown in Fig. 1.

Fig. 1.
figure 1

Block diagram of infection management system.

Situation assessment is based on the information obtained from social sensors. Basically, individuals with symptoms and their peers, determined for example using techniques of contact tracing, are tested. Hence, the system monitors the variation of the number of infections, and is able to estimate the rate of infection spread. Obviously, the accuracy of obtained estimators depends on the capacity and precision of the testing.

In the stochastic system, the moving average of the last \(k\ge 1\) steps can be used to estimate the infection rate, i.e.:

$$\begin{aligned} \begin{aligned} \varDelta I_n&= I_n - I_{n-1} \quad \mathrm {for} \,\, n\ge 1\\ \overline{\varDelta I_n}&= \frac{\sum _{i=1}^k \varDelta I_{n+i-1}}{k} \quad \mathrm {for} \,\, \mathrm {a}\,\, \mathrm {given}\,\, k\ge 1 \end{aligned} \end{aligned}$$
(13)

Note that \(\overline{\varDelta I_n}\) can be computed iteratively as follows:

$$\begin{aligned} \begin{aligned} \overline{\varDelta I_{n+1}}&= \overline{\varDelta I_n} + \frac{\varDelta I_{n+1}-\varDelta I_{n-k+1}}{k} \end{aligned} \end{aligned}$$
(14)

Equation (14) can be implemented in O(1) time, and with O(k) memory, using a circular queue represented as an array \(\mathcal {Q}\) of size k, and its pointer l to store the last k values of \(\varDelta I\); as shown in (15). The new value of \(\varDelta I\), determined in the current simulation step, is \(\varDelta I_{new}\). The update of \(\mathcal {Q}\) is done as follows (here, \(\leftarrow \) denotes the programming assignment):

$$\begin{aligned} \begin{aligned} m&\leftarrow (l+1) \mod k \\ \overline{\varDelta I}&\leftarrow \overline{\varDelta I}+\frac{\varDelta I_{new} - \mathcal {Q}_m}{k} \\ \mathcal {Q}_m&\leftarrow \varDelta I_{new} \\ l&\leftarrow m \end{aligned} \end{aligned}$$
(15)

The value of k is set as proportional to \(T_r\), using a constant \(k^{mem} > 0\), as follows:

$$\begin{aligned} \begin{aligned} k = k^{mem} \cdot T_r\end{aligned} \end{aligned}$$
(16)

Detection is achieved by comparing, in each simulation step, the infection rate (per 1000 individuals) with a given threshold. Initially, the threshold \(\delta _{in}>0\) is used. So, if the condition \(\overline{\varDelta I}> \delta _{in}\) holds, the process enters the emergency (mitigation) stage.

Mitigation is achieved by declaring an “emergency situation” that assumes adoption of special measures, involving the self-protection of individuals, and limitation of their mobility (up to its prohibition). The situation is also continuously monitored in the mitigation stage, by comparing, in each step, the infection rate (per 1000 individuals) with the second threshold value \(\delta _{out}\). If the condition \(\overline{\varDelta I}< \delta _{out}\) holds, the process reenters the normal stage. Note that, in order to be sure that the infection is decreasing when reentering the normal state, a negative threshold is used, i.e. \(\delta _{out} < 0\). Additionally, the “emergency situation” is kept for a minimum number of steps \(T_e\) that is defined as proportional (using given parameter \(k^1_e>1\)) with removal time \(T_r\) defined by (12):

$$\begin{aligned} \begin{aligned} T_e = k^1_e \cdot T_r \end{aligned} \end{aligned}$$
(17)

Note that the values of the thresholds are updated each time the system leaves the “emergency situation”, using a preset coefficient \(0<k^2_e<1\) as follows:

$$\begin{aligned} \begin{aligned}&\delta _{in} \leftarrow \delta _{in} \cdot k^2_e \\&\delta _{out} \leftarrow \delta _{out} / k^2_e \end{aligned} \end{aligned}$$
(18)

The initial values of \(\delta _{in}\) and \(\delta _{out}\) are defined as follows (\(k_{in}\) and \(k_{out}\) are two positive constants such that \(k_{out}\) is smaller than \(k_{in}\)):

$$\begin{aligned} \begin{aligned}&\delta _{in}&= k_{in} \cdot (N / 1000) \\&\delta _{out}&= - k_{out} \cdot (N / 1000) \end{aligned} \end{aligned}$$
(19)

3.5 Multi-agent Representation

The mapping of the model onto a multi-agent representation is straightforward. Basically, each individual is represented as an agent. The compartment, to which each individual is assigned, is captured as the agent state, i.e. S, I or R. Initially most of the agents are in state S, few of them are in state I, and neither is in state R. At the end of the simulation, when the process stabilizes, each agent is either in state S or in state R. So state I is a “transitory state” of the agents. Moreover, if after the stabilization process all the agents are in state R, it means that the epidemic reached the whole population.

Fig. 2.
figure 2

State transition diagram of individual (left). State transition diagram of controller (right)

The state transition diagram of each individual is modeled as a finite state automaton (see, left part of Fig. 2). Transitions are triggered synchronously for all the agents, at each simulation step. Note that state transitions are stochastic, with exact probabilities determined by the parameters of the model. Hence, in fact, the behavior of the agents can be captured by a Markov chain.

Infection propagation (from an agent representing an infected individual, to an agent representing a susceptible individual) is achieved by agent interaction. Basically, each agent representing an infected individual sends an “infection message” to all susceptible agents in its vicinity, with the computed probability, according to Eq. (9).

The transition of an agent, from state I to state R, is achieved by letting the agent itself update its state from I to R with probability \(\gamma \).

Agents in the system are mobile, as they represent also mobility of the individuals in the population. Hence, by design, they are endowed with a spatial mobility behavior.

Similarly, the state transition diagram of the controller is modeled as a finite state automaton (see, right part of Fig. 2). State N models the normal situation of the system, while E models the “emergency situation”. The transitioning back and forth between these two states can take place at each simulation step, being triggered by conditions \(\overline{\varDelta I}>\delta _{out}\) and, respectively, \(t\ge T_e\wedge \overline{\varDelta I}<\delta _{out}\). Note that variable t represents the time (in number of steps) elapsed since the triggering of the “emergency situation”. Variable t is initialized to 1, during the transition from state N to state E, and it is incremented for each step performed while system is in state E.

4 Results and Discussion

4.1 GAMA Implementation

In GAMA [20], models are specifications of simulations that can be executed and controlled using “experiments”, defined by experiment plans. Experiments facilitate the intuitive visualization, as well as the extraction of useful simulation results.

Implementation of the, above proposed, pandemic model contains:

  • The global section representing the agent environment. Here the definitions of all the model parameters, as well as other implementation-dependent parameters that were needed for the model visualization, like for example visual attributes used for agents visualization, have been included.

  • The initialization section for setting up the initial population of agents, representing the initial populations of susceptible and infected individuals.

  • The class defining the agents that instantiate the individuals of our model, together with their internal state and behavior.

  • The section defining our experiment, visualizing the results, and extracting the simulation information. Here, a “gui” experiment has been implemented, -to allow the graphical visualization and animation of the simulation.

Each individual is modeled by an agent of Host species that contains the following attributes and behaviors:

  • Boolean attributes is_susceptible, is_infected, and is_immune such that exactly one of them is true, for representing agent states S, I and R. Susceptible individuals have is_susceptible=true, while infected individuals have is_infected=true.

  • Mobility is achieved by endowing agents with moving skill. It defines the required actions for spatially mobile agents. In particular, the wander action, for moving the agent forward to a random location at the distance computed based on its speed in a random direction (an angle, in degrees) determined using its amplitude attribute, has been used. Here, if the current value of the direction is h and the value of the amplitude is a, the new value of h is chosen from the interval \([h-a/2,h+a/2]\). Moreover, \(a = 360\) was used, to allow full coverage of all directions.

  • State transitions are achieved by the user-defined skills infect and remove that define the transition of an agent from state S to I, and from state I to R. Agents vulnerable for getting the infection were determined by enumerating all agents located at a given maximum distance, from an infected agent, using the at_distance operator.

  • Initially, agents representing susceptible individuals are randomly distributed on a square-bounded 2D space.

Controller parameters are maintained as global attributes of the simulation environment, as follows:

  • Boolean attribute is_emergency is used to distinguish between the normal (N) and the emergency state (E) of the controller.

  • Values of \(k_{in}\) and \(k_{out}\) to compute initial values of thresholds \(\delta _{in}\) and \(\delta _{out}\) using Eqs. (19) are defined as: \(k_{in} = 0.40\) and \(k_{out} =0.02\).

  • Values of \(k^1_e\) and \(k^2_e\) used in Eqs. (17) and (18) that control the span of the emergency situation are defined as: \(k^1_e = 1.1\) and \(k^2_e = 0.9\).

  • The value of parameter \(k^{mem}\) that defines the memory of the moving average \(\overline{\varDelta I}\) using Eq. (16) was set to \(k^{mem} = 0.5\). This produces a value \(k=10\) for the “memory” of computing the moving average \(\overline{\varDelta I}\).

  • The queue representing the “memory” of computing the moving average \(\overline{\varDelta I}\), implemented as a list of k values.

Overall, three visualizations of the simulation results are provided (see, Fig. 3):

  • 2D spatial visualization of the agents. Susceptible agents are shown in green, infected agents are shown in red, while removed agents are shown in blue.

  • The dynamics of susceptible, infected and removed individuals, the simulation time-line using the same color code.

  • The dynamics of the instantaneous and moving averages of the infection rate.

Fig. 3.
figure 3

System GUI.

4.2 Experimental Setup

The simulation is controlled by the following parameters that dictate the speed and magnitude of the epidemics spread:

  • Size d of the agents’ environment (a \(d \times d\) rectangle); \(d = 120\) was used in experiments.

  • Population size N, including initial number of susceptible individuals \(S_0\), and infected individuals \(I_0\). Note that \(N = S_0+I_0\) and \(I_0 \ll S_0\). To keep things simple and observable \(I_0=2\) was set. This made possible to observe the epidemics spread starting from two distinct source points that define two independent infection outbreaks. Note that the size of the 2D space was kept constant. Hence, the population size dictates the population density that is expected to directly influence the spatial-temporal dynamics of the epidemics. In all experiments \(S_0 = 15000\) was used.

  • Since the considered model is a stochastic system, each simulation was repeated multiple times, while keeping fixed the initial locations of the infection outbreaks, at: \((0.25 \cdot d,0.25 \cdot d)\) and \((0.75 \cdot d, 0.75 \cdot d)\).

  • The radius \(\epsilon \) defining “active vicinity” of an infected agent was set to \(\epsilon = 0.8\).

  • The probabilities that an agent will transmit, respectively will get the infection (see Eq. (9)), \(p_i\) and \(q_i\) were constant for all individuals. However, note that: i) before the outbreak these probabilities have high values \(p^H=q^H=0.90\); ii) during the emergency situation these probabilities have low values \(P^L = q^L = 0.30\), and iii) after the first emergency situation, as people got to know about the danger of the infection, these probabilities have average values \(p^M = q^M = 0.75\) (many people are likely to proactively take into account protection measures).

  • The speed v of the wandering process was set to \(v^{H} = 1.0\) during the normal situation and to \(v^{L}=0.1\) during the emergency situation. Note that the angle that gives the range of the direction of the wandering was kept constant and equal to \(360^{\circ }\).

  • Coefficient \(\gamma \), defining number of infected individuals removed at each iteration; was set to \(\gamma = 0.05\).

  • Spatial attenuation function \(\phi (x)\) (see Eq. (7)) was chosen as follows:

    $$\begin{aligned} \phi (x) = \left\{ \begin{array}{ll} 1 - \frac{\log (1+\alpha \cdot x)}{\log (1+\alpha \cdot \epsilon )} &{} \quad 0 \le x \le \epsilon \\ 0 &{} \quad x > \epsilon \end{array} \right. \end{aligned}$$

    with constant parameter \(\alpha \) defined as \(\alpha = 10.0\).

4.3 Experimental Results

Due to space limitation we report results of a representative experiment evaluating the effect of managing the infection spread, using the proposed mechanisms. Initially we ran the simulation without the controls. Here, probabilities for transmitting and getting the infection were set to \(p^H = q^H = 0.90\), and then to \(p^L = q^L = 0.75\). The results for the first case are shown in Fig. 4. Quite similar results have been observed also in the second case. In both cases, the infection propagated to almost entire population. Only a few individuals remained untouched (456 in the first case and 1003 in the second case; from the total of 15002 individuals).

Fig. 4.
figure 4

Results of simulation without control system.

In the second part of the experiment, the control subsystem was turned on. The simulation was repeated 6 times to observe the effect of the controls under the uncertainties of the model. Note that among multiple simulations that were executed, we have retained 6 simulations that are characterized by 2 outbreaks (not all runs generated two outbreaks, corresponding to the 2 initially infected individuals).

The results of a single simulation run that included the control system are presented in Fig. 5. Here, 5 emergency situations were determined between cycles 32–92, 147–213, 278–350, 429–510 and 661–762. These situations can be observed as a decreasing slope of the thick curve in Fig. 5d, representing the variation of the moving average \(\overline{\varDelta I}\). The number of susceptible individuals, that were not touched by the infection was 12899 for this simulation, and this value can be roughly observed in Fig. 5c.

Fig. 5.
figure 5

Results of simulation with control system.

Figures 5a and 5b depict the agent population immediately after the end of the \(4^{th}\) emergency situation and immediately after the start of the \(5^{th}\) emergency situation. Interestingly, one of the outbreaks was extinguished, while the second remains active.

The simulation finished after an of 619.66 cycles (minimum 444 and maximum 874) with an average number of 13465 susceptible individuals (minimum 12080 and maximum 14156), not touched by the infection. The average number of “emergency situations” that were determined by the control system, during the simulation, was 4.16 (minimum 3 and maximum 6).

5 Concluding Remarks

We have developed a multi-agent simulation of the spatial SIR model for epidemics spread management in a population, using the GAMA agent-platform. We have used the simulation system to experimentally investigate a scenario, in which the spread of the infection is mitigated by mobility limitation and by enforcement of protection. While the simulation revealed the usefulness of the approach, we also noticed that it is very sensible to the settings of the parameters of the control system. The approach also depends on the accuracy of the social sensors, used for monitoring and detecting the speed of the infection. We plan to extend our simulation by relaxing the rationality and caution assumptions of the agents and adding different agent profiles, as well as by refining the parameters that control the virus transmission.