1 Introduction

On March 11, 2020, the World Health Organization declared a global COVID-19 pandemic, a disease caused by the SARS-COV-2 virus. From the first case report in Wuhan, China, at the end of 2019 until the last days of May 2021, there were already more than 168 million cases and more than 3.5 million deaths worldwide.

Governments around the world are taking different measures to deal with this new disease. Contact tracing, the isolation of infected cases and their close contacts, is one of the most used tools to contain disease spread. In addition, some public activities such as concerts, sporting events, and religious events have also been banned. In some cases, more disruptive measures like the closing of schools and workplaces were taken.

Several different epidemiological indicators such as the doubling time of cases, the value of the reproductive number, the average daily incidence of cases, and/or the availability of hospital beds trigger partial lockdowns (Anderson et al. 2020; Wilder-Smith and Freedman 2020). The combination of such control measures usually produces a declining trend in the number of incidence which may be followed by some relaxation in social distancing measures leading to a further increase of cases.

In recent months, many mathematical models have been developed to predict future trends and explore the effect of different social distancing measures. Most of them are based on modifications of the classic SEIR model (Susceptible, Exposed, Infected, Recovered), with the incorporation of some extra epidemiological classes such as: undetected infected individuals, hospitalized individuals, asymptomatic individuals, among others (Kucharski et al. 2020; Prem et al. 2020; Zhao and Feng 2020). These models are generally based on differential equations without incorporating spatial and/or social contact structures. In these types of models, the effect of measures of social distancing is modeled by varying some parameters as the infection rate during the course of the epidemic (see for example Lin et al. (2020), Acuña-Zegarra et al. (2020), and Giordano et al. (2020)). On the other hand, in recent months, more realistic models were developed considering an agent-based model approach to evaluate the effect of control measures in the disease dynamics (see for example Aleta et al. (2020); Kerr et al. (2021); Hinch et al. (2021)) and to estimate the economic impact under different types of interventions (Silva et al. 2020).

In this work, we are interested in developing a computational model to evaluate the effect of different strategies to prevent hospital resources saturation in small or mid-size cities. We developed an agent-based model that incorporates a basic social structure consisting of households, workplaces, schools, and supermarkets or similar stores. Infectious individuals may be asymptomatic, present only mild symptoms or develop more severe disease forms and, therefore, seek medical attention. A proportion of these later cases will require hospitalization.

Control tools considered in our work are contact tracing/case isolation, school closures, and partial lockdowns for workplaces. In our modelling approach, hospital bed occupancy levels dictate the beginning and finalization of any of these measures. An analysis on parameters uncertainty is in the Appendix C. In addition, different household and workplace distributions were considered to determine their effect on disease dynamics. The model proposed in this article was developed entirely by the authors and programmed in C language.

This paper is arranged as follows. In the next section we describe the population structure and the individual’s routine, how the population is structured in epidemiological classes and how the disease transmission is modelled. In Sect. 3, the parameters, the distribution of the population, and the different scenarios considered for the simulations are described. In turn, the numerical results obtained for each of them and an analysis of how the population distribution affects these results are presented in this section. Finally, the discussion of the results and conclusions are presented in Sects. 4 and 5, respectively.

2 Methods

2.1 Population structure

We developed an agent-based model for an homogeneous population without age structure. Individuals were allocated to households of size H. A proportion of the population was assumed to attend a school (it may represent a kindergarten, an elementary school, high school, or a college) distributed in classrooms of 30 students with one teacher. A school is composed of a group of 10 classrooms. The rest of the individuals were allocated to randomly chosen workplaces of size W. Some of these workplaces were considered as stores, like supermarkets, which were visited by the individuals of the populations with some frequency (one store per 100 persons).

2.2 Individual’s routine

Individuals leave home at 7 am and go directly to their workplace or school. People in the schools divide the time between the classroom and breaks, until 2 pm. People who attend other workplaces stay at them until 5 pm, except those who work at supermarkets and stay there until 6:00 pm. After leaving their workplace or school, one person per house (chosen at random) may spend one hour in a store (one visit to stores per household and no more than one visit every four days). During the day, all individuals may have some number of casual contacts, representing contacts in public transportation or other public areas.

2.3 Epidemiological classes

Susceptible individuals may become infected by contact with infectious cases. Newly infected individuals enter in the latent, not infectious state. After the latency period, they become infectious but pre-symptomatic. A proportion \(\sigma _a\) of the infectious individuals remains asymptomatic or develop only mild symptoms and, therefore, are usually not detected by the health system. The rest of the infectious individuals who develop clinical symptoms are likely to seek medical attention.

We considered two clinical classes, a first sub-clinical stage, where only mild symptoms are observed, and a clinical phase where symptoms are apparent. Some of these last types of cases (a proportion \(\sigma _h\)) present symptoms severe enough to become hospitalized. Finally, individuals recover or die. We assume that recovered individuals develop long-term immunity.

According to Li et al. (2020), the time spent in each infected class has a bell-shaped distribution. In our case, we considered Gamma distributions for these periods with mean and variance listed in Table 2.

The mean duration of the latent period was set in 4 days, which is in the range reported by Kucharski et al. (2020), Li et al. (2020) and Lauer et al. (2020). For the infectious period, there are different estimations. We choose a mean duration of 7.5 days with a variance of 9 days (Zhao and Feng 2020; Ivorra et al. 2020; World Health Organization 2020; He et al. 2020). For the hospitalization time, we considered a distribution according to the data observed for Argentina (Ministerio de Salud de la Nación 2020). For the simulations, these periods were controlled in order to that the latency, infectious, and hospitalization period were at least one day. Thus, all the individuals spend at least 1 day in any of these epidemiological states. In addition, a maximum value of 15 and 20 days was considered for the latent and infectious periods, respectively.

The progression from pre-symptomatic to subclinical and clinical classes allows for an easy way to consider different transmission probabilities at different stages of the disease progression. A diagram for the progression in the epidemiological classes is presented in Fig. 1.

Fig. 1
figure 1

Progression in the epidemiological classes. Susceptible (S), Latent (L), Pre-symptomatic (Ps), Asymptomatic (A), Sub-clinical (Sc), Clinical (C), Hospitalized (H), Recovered (R)

2.4 Modeling disease transmission and parameter estimation

2.4.1 Probabilities of infection

The probability of transmission per contact per unit of time in a household \(\beta _H\) was numerically estimated from the data in the secondary attack rate Liu et al. (2020); Jing et al. (2020) as described in Appendix A. In a given environment, susceptible individuals have a probability of infection per unit of time and per infectious contact, depending on the type of the environment and the infectious class of the active case. We considered the worst-case scenario in which all the infectious classes have the same infectivity. The probability of transmission is decomposed as the maximum value (\(\beta _H\)) weighted by a coefficient which depends on the type of the environment, \(\rho _j\), where \(j \in \{H, W, St, S\}\), for households, workplaces, stores, and schools, respectively. We set \(\rho _H = 1\) for a household, and \(\rho _j \le 1\) for the other environments. Three different cases were evaluated regarding the risk of infection in each environment (\(\rho \) values). In the first case, we considered that the risk of infection is the same in all the environments (\(\rho _H = 1\) for all j). In the other two cases, we used different \(\rho _j\) values for different environments. In both cases a value of \(\rho _S = 1/8\) was considered for schools, while for stores this value was set to \(\rho _{St} = 1/4\). For workplaces, two different values were considered: \(\rho _W = 1/2\) (case 1) and \(\rho _W = 1/3\) (case 2). It is important to note that for store’s workers the value used in these places is the same as in any other workplace.

2.4.2 Latency and infectious periods

All periods considered are random variables modeled with Gamma distributions with significant variance values. In other words, for each simulation, the values for the different waiting periods widely vary between individuals. The mean value of the latency period may produce a shift in the epidemic curves but not in the peaks. The duration of the infectious period may have a significant impact on the force of infection but in our case we fixed the value of the probability of transmission per contact and per unit of time from the data in the secondary attack rate. Changing the mean infectious period translates to a change in the probability of infection to leave the secondary attack rate unchanged.

2.4.3 Proportion of non-detected cases

Asymptomatic cases and mild cases that do not seek medical attention are not detected by the health system except by contact tracing. The percentage of asymptomatic cases, i.e., never experience symptoms, remains uncertain (Centers for Disease Control and Prevention 2020) and there are different estimations with high variation ranging from 10% to 73% depending on what symptoms are included in the definition of the suspect case and when the patients were tested (Centers for Disease Control and Prevention 2020; He et al. 2021; Poletti et al. 2020). We assumed that a constant proportion of new cases are asymptomatic or develop only mild symptoms and, therefore, are not detected for the public health system.

2.4.4 Proportion of hospitalized cases and hospitalization length of stay

The proportion of cases detected which require hospitalization is a parameter that depends on many factors such as the age of the patients and their co-morbidities, and different values have been reported for different countries and cities (Zhao and Feng 2020; CDC COVID-19 Response Team 2020; Moghadas et al. 2020). The probability of hospitalization estimated from data can represent up to 1/3 of the detected cases (CDC COVID-19 Response Team 2020).

Hospital length of stay also has great variability. We considered that this period is gamma distributed with mean 12 days and a significant standard deviation of 72 days (Ministerio de Salud de la Nación 2020).

2.5 Modeling contact tracing, case isolation and lockdowns

We assumed a conservative scenario where only a passive contact tracing is implemented. We considered that clinical cases are detected at the rate \(r_d\). Thus, the probability of detection in an interval of time \(\Delta t\) is given by \(1-e^{-r_d \Delta t}\). When a case is detected their entire household is isolated (for a fixed period of time \(T_{ct}\)) as well as all their workplace contacts (but not their corresponding household contacts). If the detected case is an individual who attends school or works in a store, only their household contacts are isolated. Isolated individuals remain at home most of the time, and therefore, their casual contact rates are substantially reduced.

After the isolation period ends, isolated individuals are tested. If the test result is positive, the individual will remain isolated and will be tested every 2 days until a negative result is obtained. If an individual in isolation, who was not previously detected, test positive, their family is also isolated for a fixed period of time \(T_{ct}\). In all cases, a negative result is necessary to end the isolation.

A partial lockdown consisted of the closure of a percentage of the workplaces and/or schools. Individuals are isolated, and their casual contacts are reduced. A partial lockdown begins when a fraction of the emergency rooms are occupied and relaxed when a lower value for this fraction is reached. Lockdown policies modify people’s routines. People who are not attending their workplaces or schools may visit stores at any time of the day.

3 Results

3.1 Parameters and scenarios considered

For the simulations, a population of 100 thousand inhabitants was considered. These inhabitants were distributed in households of different sizes in accord with the empirical distribution observed for La Banda (Fig. 2), an Argentinian city in Santiago del Estero province, with approximately 100.000 inhabitants (Instituto Nacional de Estadística y Censo 2010). The mean of the distribution is equal to 3.94. For the distribution of workplace size, we do not have empirical information, so a Poisson distribution with a mean equal to 8 truncated from 1 to 15 was considered. As mentioned before, some workplaces were considered as stores (1 per 100 persons). In all cases considered, each store has a staff of 8 workers. A brief study about how the distributions of houses and workplaces sizes affect the epidemic dynamics is presented in Sect. 3.3.

Fig. 2
figure 2

Distribution of inhabitants per house for La Banda city, Santiago del Estero, Argentina according to Instituto Nacional de Estadística y Censo (2010)

We considered that 25% of the population is attending school, so we have a total of 834 classrooms with 30 students and one teacher each. The rest of the population is distributed in workplaces considering one store every 100 people. The population is composed of 25000 school-attending individuals, 834 teachers, 8000 store workers, and 66166 regular workers.

To evaluate the impact on the disease dynamics of the different measures, we considered several control strategies as detailed in Table 1. The strategy E1 corresponds to doing nothing, and therefore, we have a free epidemic. In strategy E2, only contact tracing and case isolation is implemented. In scenarios E3, E4, and E5 different, combinations of partial lockdowns of schools and workplaces are simulated. All the scenarios were simulated for two years (720 days), given that we consider that in that period of time a vaccine or other pharmaceutical solutions to the disease will be found.

Table 1 Description of the different scenarios considered for the simulations

In our model, schools are the most significant driver of the epidemic. Schools are closed when 35% of the hospital beds are occupied and are reopened when this percentage drops below 5%. A percentage of workplaces, other than schools and stores, are closed when 50% of the hospital bed are occupied and reopen when occupancy is below 40%.

In some cities with strong systems of public health, the availability of hospital beds is around eight beds per thousand inhabitants or higher (World Bank 2020). However, in most small cities (mainly in non-developed countries) as the considered in this work, availability of hospital beds is significantly lower. We considered the case of four hospital beds per thousand population.

As mentioned before, three different cases in relation with the risk of infection were considered. One in which the risk is the same in all environments, and two in which there is heterogeneity in the values. Other parameters values used in the simulations are listed in Table 2. For \(\sigma _a\) and \(\sigma _h\) values, we considered a combination that represents the worst-case scenario. A discussion about how these values affect the results obtained in the simulation can be found in Sect. 3.4.

Table 2 Description of the parameters, their range of values used in the simulations, and their source

3.2 Results for the different cases considered

3.2.1 Case 0 (\(\rho _j = 1\) for all j)

When \(\rho _j = 1\) for all j, the saturation of the health system is practically impossible to avoid. The doubling time of the free epidemic was estimated in 2 days considering the exponential phase of the epidemic growth between days 20 and 30, with a final epidemic size greater than 0.99. These results strongly suggest that assuming \(\rho _j = 1\) for all j is a very unrealistic case.

In scenario E5 (schools closed and 50% of the workplaces closed), the most conservative considered in this work, the peak of bed occupancy is equal to 1595 beds, close to quadrupling the capacity of the health system, when closures are triggered at 140 (schools) and 200 (workplaces) occupancy beds.

We also considered an extreme scenario in which schools and 50% of the workplaces are closed at the beginning of the simulation, and these remain closed throughout the simulation. In this scenario, a large proportion of the population can only come into contact with people outside their household only through casual contacts or contacts in stores. Even in this case, the health system collapses assuming four beds per thousand population (Fig. 3), a relatively high value for most small to mid-size cities in non-developed countries.

Fig. 3
figure 3

Dynamics of hospitalized individuals for the special scenario for the case 0. The horizontal line is the total number of available hospital beds for covid 19 patients

3.2.2 Cases 1 and 2 (\(\rho _W = 1/2\) and \(\rho _W = 1/3\))

For cases 1 and 2, the doubling time for the free epidemic was estimated in 5 days from the exponential phase of the simulated epidemic growth in case 1, and in 5.5 for case 2 (see Appendix B). These values are in the range of the doubling times observed by Li et al. (2020); Volz et al. (2020); Wu et al. (2020). The dynamics of hospitalized individuals for each scenario is shown in Fig. 4 (case 1) and Fig. 7 (case 2).

For the free epidemic scenario, almost everyone in the population is infected (95% in case 1 and 91% in case 2). Under our passive contact tracing strategy, which only tracks and isolates people in the workplace and the household of the detected case, the epidemic final size is reduced to about 78% in case 1 and 70% in case 2. However, this reduction is far from enough to prevent a collapse of the health system (Figs. 4 and 7).

Fig. 4
figure 4

Dynamics of hospitalized individuals for each scenario considering \(\rho _W = 1/2\) (case 1). The horizontal line is the total amount of hospital beds

In case 1 (\(\rho _W = 1/2\)), closing only schools is not enough to avoid a collapse of the health system, and a further partial lockdown of at least a 50% of workplaces is necessary.

According to Fig. 5, the final epidemic size decreases as the partial lockdown increases. As we can see, the passive and conservative contact tracing policy considered reduced 17.7% the final epidemic size, going from 95% to 78%. A further closure of schools reduces it to about 30%. The difference between a lockdown of 25% or 50% is 2.9% of the population, being the final epidemic size approximately 60.6% in E4 and 57.7% in E5.

Fig. 5
figure 5

Epidemic size for each scenario considering \(\rho _W = 1/2\) (case 1)

A different situation occurs if a lower value of \(\rho _W\) is considered, as in case 2 (\(\rho _W = 1/3\)). Closing 25% of the workplaces, the health system would operate close to its maximum capacity and could collapse due to the need for beds for other diseases different to COVID-19. Under these conditions, closing 50% of workplaces ensures a good response from the health system.

Fig. 6
figure 6

Epidemic size for each scenario considering \(\rho _W = 1/3\) (case 2)

Fig. 7
figure 7

Dynamics of hospitalized individuals for each scenario considering \(\rho _W = 1/3\) (case 2). The horizontal line is the total amount of hospital beds

For the lower value of \(\rho _W=1/3\) considered, disease transmission in households and schools dominate the dynamics concerning the contribution of workplaces. In general, the epidemic size of each scenario is lower considering a lower value of \(\rho _W\) (comparison of Figs. 5 and 6), an expected result. A non-trivial result considering \(\rho _W\) equals 1/3 (instead of \(\rho _W= 1/2\)) is that closing the schools and only 25% of workplaces is enough to prevent the health system collapse.

An evidence of the decrease of the importance of workplaces in the epidemic dynamics, is that the curve of hospitalized individuals closing only schools (E3) is higher in case 1 (\(\rho _{w}= 1/2\), Fig. 4) than in case 2 (\(\rho _{w}= 1/3\), Fig. 7).

A partial lockdown of schools and workplaces involves a general loss of class days and working days that are summarized for each case in Table 3. In case 1, the schools are closed on day 69 of the 720 simulated days and remain closed for a period of 192, 208, and 416 days for scenarios E3, E4, and E5, respectively. In scenario E3, the schools are not closed again, but in scenario E4 are closed again for 80 days (from day 398 to day 478), while in scenario E5, it occurs for about 2 months (from day 603 to day 664). On the other hand, workplaces are closed on day 75 of the simulation in both scenarios (E4 and E5). In E4, after opening on day 207, these are not closed again, while in E5 these are open on day 177, and then these are closed again for 20 days (from day 222 to day 242). Considering a lower value for \(\rho _W\), the disease spreads through the population slower. The lockdown of schools and workplaces begins approximately two weeks later than in case 1, on day 85 for schools and on day 89 for workplaces. From Fig. 7, we can see that the more aggressive the closure policy, the sooner a new peak occurs in the curve for hospitalized people. The times when those new peaks begin correspond to the times when schools reopen.

From Table 3, we can see that to avoid the saturation of the health system in case 1 (E5), we need more days with schools and workplaces closed than in case 2 (E4 and E5). On the other hand, considering that in E5 we are closing twice as many workplaces as in E4, but half the time, we might conclude that, from an economic point of view, the closure of 25% or 50% of the workplaces has the same economic impact.

Table 3 Loss of class and work days in each scenario according to dynamics in Figs. 4 and 7 for a simulation of 720 days of duration

An important feature of the dynamics simulated with the model is the great impact that closing school has on the disease dynamics, as can be seen in the difference between peaks in the bed occupancy curve for E3 and E2 in Figs. 4 and 7. So, we can conclude that in the cases considered in this work, schools are the main driver of disease dynamics, and closing them has a great impact in the chain of transmission.

3.3 Effect of population distribution

In this section, we briefly explore the effects of household and workplace people distribution on the dynamics.

One of the distributions of inhabitants per house corresponds to the empirical distribution observed for Tandil (Fig. 8), a city of approximately 100 thousand inhabitants in the Buenos Aires province in Argentina. This distribution of house sizes has a mean equal to 2.93. In this case, for the workplaces size distribution, we consider the same truncated Poisson distribution with mean equal to 8, as before. The third distribution considered was the ‘homogeneous case’ in which all houses have four inhabitants, and all workplaces have eight members.

Fig. 8
figure 8

Distribution of inhabitants per house for Tandil city, Buenos Aires, Argentina according to Instituto Nacional de Estadística y Censo (2010)

If the epidemic dynamics in these two new situations (Tandil and the homogeneous case) is simulated, the case ‘La Banda’ has the lowest doubling time of cases in a situation of a free epidemic (considering the first exponential phase of growth) in all the cases and the highest final epidemic size in most cases (Table 4). On the other hand, we can see that, in all the cases, the epidemic final size is higher in the ‘homogeneous’ case than in Tandil. However, the doubling time of cases in Tandil is lower than in the ‘homogeneous’ case, only for cases 1 and 2, while in the case 0, the situation is the opposite. It is important to mention that the doubling time of cases is a good indicator for the exponential phase of the epidemic growth, while the final epidemic size considers all its evolution.

Table 4 Doubling time of cases for the exponential phase of epidemic growth for a free epidemic situation (final epidemic size) for each case and population distribution considered

If the different scenarios are compared for the same parameter values, La Banda always needs more restrictions to avoid saturation of the health system than Tandil and the homogeneous case. As shown above, in case 1, in La Banda, it is necessary to consider closing schools and a 50% of the workplaces, however, in Tandil and the homogeneous case, it is enough closing school and a 25% of the workplaces, as can be seen in Fig. 9 (top). In this figure, we can see that the dynamics of hospitalized individuals considering scenario E4 (in case 1) for Tandil and the homogeneous case is more similar to scenario E5 than to E4 in La Banda.

Fig. 9
figure 9

Dynamics of hospitalized individuals for the different population distributions considering case 1 (up) and case 2 (bottom)

The differences are greater if we compare the E3 scenario in case 2 for the three population distributions. We can see that in Tandil and in the homogeneous case it is enough to close schools to avoid the health system saturation (Fig. 9 - bottom). At the same time, in La Banda, this control measure is notoriously insufficient, and it is needed to close at least 25% of the workplaces (Fig. 7).

As before, in case 0 (\(\rho _j = 1\) for all j), a saturation of the health system is practically impossible to avoid regardless of the population distribution considered.

If the impact of the contact trace/case isolation measure is compared for cases 1 and 2, in the different population distributions, we can see that it has a greater impact in Tandil producing a reduction in the epidemic final size of a 24% in case 1 and a 27% in case 2, than in La Banda and the homogeneous case where the reduction is approximately the same in both case, 17% in case 1 and 21% in case 2.

A non-trivial result is the similarity obtained for the epidemic dynamics considering the population distribution of Tandil and the homogeneous case. We can see that in both cases, the saturation of the health system is avoided applying the same scenario (more examples of that situation can be found in C). However, the final epidemic size reached in the homogeneous case is always higher than in Tandil if the same parameters and scenarios are considered.

The differences between the results obtained for the different population distributions can be explained considering the contribution to the non-zero variance’s disease dynamics. We can see that La Banda and the homogeneous case have approximately the same mean size of houses (3.94 and 4, respectively) and workplaces (8 in both cases). However, the homogeneous case has zero variance in both cases, while La Banda has a non-zero variance, and that is the reason why it has faster and aggressive dynamics.

3.4 Results for other parameter values

In the previous analysis, we considered the worst-case scenarios according to available data. If the proportion of non-detected cases (\(\sigma _a\)) is reduced to 0.15, close to the lower bound reported (Centers for Disease Control and Prevention 2020), contact tracing and isolation is much more effective, and epidemics are prevented without the need to close or schools or workplaces (in cases 1 and 2). This happens for all the population distributions considered. Taking into account the conservative contact tracing modeled, this result seems unrealistic. When the rate of hospitalization is also in the lower bound of ten percent of the detected cases, the prevention of health system saturation is also easily achieved. A more detailed analysis of these situations can be seen in Appendix C.

4 Discussion

In most works, the effect of social distancing measures is modeled implicitly by changing some parameter values, like the transmission parameter. The advantage of our modeling approach is that the control measures are explicitly modeled by changing the individual’s behavior of the population.

In our model, a conservative contact tracing was implemented where it is reduced to household and workplaces contacts. In addition, only the contacts of the cases detected by the health system (clinical cases) are tracked. In our simulations, all household and workplace contacts are isolated for 14 days and return to normal activities only after a negative result for infection. Contact tracing and case isolation may be implemented more easily for low values of the infectious population. In our simulations, we have not taken into account the fact that it may be difficult to implement reliable contact tracing and isolation of suspected cases for high values of the infectious population.

Although the effect that schools have on the epidemic dynamics is still under discussion in the scientific literature, there is evidence that affirms that the reopening of schools without disease mitigation measures accelerates the spread of the disease in the population (see Edmunds (2020); Flasche and Edmunds (2021); Gurdasani et al. (2021) and references therein). This effect of the reopening of schools (without strong measures of social distancing) in the epidemic dynamics can be observed in the model’s results. The moments when new epidemic peaks begin correspond to the moment in which schools are reopened (Figs. 4, 7 and 9).

4.1 Population distribution, social structure and disease dynamics

How the population is distributed has a significant effect on the disease dynamics, as we show in Sect. 3.3.

When we considered that \(\sigma _h = 1/3\), \(\sigma _a = 2/3\) and the risk of transmission in workplaces equal to \(\beta _W = \frac{1}{3} \beta _H\) (case 2), school closures were enough to prevent hospitalization saturation considering the household distribution observed in Tandil (mean = 2.81, variance = 2.49) and the homogeneous case (mean = 4, variance = 0). In the same situation, considering the household distribution observed in La Banda (mean = 3.94, variance = 4.21), it is necessary to close at least 25% of workplaces. For a greater risk of transmission in workplaces (as in case 1), \(\beta _W = \frac{1}{2} \beta _H\), besides school closures, 25% of the workplaces also needed to be closed in the case ‘Tandil’ and in the homogeneous case to maintain the hospital beds below saturation. In contrast, while in the case ‘La Banda’, it is necessary to close a 50% of workplaces. On the other hand, as the proportion of non-detected cases (\(\sigma _a\)) decreases, contact tracing and isolation is much more effective, regardless of the population distribution considered.

Socially structured models, such as that developed in this work, have the advantage of being able to represent social relations within the population. These relationships define what the structure of contacts in the population is like. In the socially structured models, the contacts are persistent, while in the model without social structure, the contacts represent a homogeneous mixed of the population. Therefore, models that consider the population’s social structure produce lower epidemics when the same transmission parameters are considered.

4.2 Effect of social distancing measures on the epidemic size

Social structure of the model defines a specific network of contact between the individuals of the population for each moment of the day. The different control measures modify this network of contacts changing the number of contacts an individual may have. Thus, different epidemic sizes will be reached due to the differences in the number of contacts that the individuals have according to the chosen scenario.

In this sense, different control measures may delay the increase of infected and hospitalized people. However, it is not always true that stricter control measures produce smaller final epidemic sizes. In some situations, control measures focus on reducing the population mobility (as implemented in the model) generate epidemic with peaks as plateaus, producing larger epidemic sizes at the end of the epidemic. However, these plateaus avoid the saturation of the health system.

4.3 Limitations of the model

It is important to remark that risk of transmission for each environment was kept constant in each simulation. However, those risks are likely to vary with time. Individual behavior may change according to risk perception, and workplaces and institutions may enforce different social distancing measures. In many places, re-opening the schools was accompanied by a reduction in the number of students per classroom and other social distancing measures. Changes in the risk of transmission have a significant impact on disease dynamics.

Loss of immunity and re-infection were two processes that we did not consider in the model. Re-infection was documented for COVID-19, but it is a rare phenomenon affecting a very small fraction of the cases. According to a recent study, possible reinfections account for less than one percent of the cases (see for example Graham et al. (2021); Hansen et al. (2021) and references therein). In these cases, the symptomatology is different (compared with the first infection), and re-infected people develop only mild symptoms (in some cases imperceptible) in most cases. Because of this, only a very small fraction of the re-infected individuals will be detected by the health system, taking into account the conservative detection policy implemented in the model. In this sense, incorporating the re-infection process implies the development of a more complex model accounting for different asymptomatic and hospitalized rates for the first and the second infection of an individual.

From some numerical simulations (not included in this work), we can see that the potential effects of re-infection are within stochastic fluctuations when short time frames are considered (as those considered here). A different and more complex model has to be developed to incorporate the re-infection process in longer time frames in a realistic way, including competition between virus variants and vaccination.

We considered a homogeneous population, but age is a significant indicator for hospitalization. We considered a worst-case scenario where all individuals are equally likely to develop severe forms of the disease. Also, we assumed that individuals belonging to any households are randomly assigned to workplaces or schools. This approximation is only plausible for relatively small populations. In the simulations, we considered the case of a city with a size of 100000 (but essentially the same results were obtained for a 500000 population size). For larger populations, some degree of spatiality should be considered.

5 Conclusions

Control of COVID-19 epidemics in large cities poses significant challenges as seen around the world. In this work, we focused on small to mid-size cities initially without community virus circulation. We developed an agent-based model for a homogeneous population but where individuals belong to households and spend some of their time in workplaces, schools, and stores. In each of these environments, we assumed a constant risk of infection proportional to the number of infectious individuals in them. Households have the greatest risk of infection. We considered different scenarios with different values for the risk of transmission in other environments like workplaces, schools, or stores. The risk of transmission in a household (\(\beta _H\)) was estimated from data on the secondary attack rates, as shown in Appendix A. We also considered that individuals have some average number of daily casual contacts, others than those which may take place at stores.

We considered only two relevant cases for the course of the disease. Some individuals develop only mild symptoms and, therefore, are not detected, while other infected persons present more severe symptoms and seek medical attention. A fraction of those will require hospitalization. According to the available bibliography, realistic distributions were considered for the different waiting periods like exposed or infectious periods.

The effect of different strategies was evaluated by simulation. Contact tracing and case isolation is assumed to be always implemented. Additionally, several grades of lockdowns were simulated, consisting of the closure of schools and workplaces. The hospital beds availability determined levels of the lockdowns. We considered the relatively conservative case of 4 hospital beds (for SARS-CoV-2 patients) per 1000 population.

When we consider the same risk of transmission in all the environments, the health system saturation is practically impossible to avoid. This situation of extremely high infectiousness appears to be unrealistic and not reported for mid-size cities.

But infectiousness in classrooms and workplaces is likely smaller than in households. Social distancing measures, like wearing masks, a limited number of persons per area, etc., are factors that substantially reduce the risk of infection (see for example Hendrix (2020)). Additional measures like reducing the number of students per classroom, ventilation, etc., can further reduce the risk of transmission.

Our results suggest that the distribution of the population in homes and workplaces is a key factor to take into account when studying the impact of control measures. It has been shown that the same measure has a different impact on populations that have different distributions.

The model presented here can be used for the local decision-makers to evaluate the effect of different control measures. According to the results for the different population distributions, to apply the model to a specific city, it must be parametrized taking into account the population structure and demographic dynamics of the corresponding city.