Temporal Heterogeneities Increase the Prevalence of Epidemics on Evolving Networks

Empirical studies suggest that contact patterns follow heterogeneous inter-event times, meaning that intervals of high activity are followed by periods of inactivity. Combined with birth and death of individuals, these temporal constraints affect the spread of infections in a non-trivial way and are dependent on the particular contact dynamics. We propose a stochastic model to generate temporal networks where vertices make instantaneous contacts following heterogeneous inter-event times, and leave and enter the system at fixed rates. We study how these temporal properties affect the prevalence of an infection and estimate R0, the number of secondary infections, by modeling simulated infections (SIR, SI and SIS) co-evolving with the network structure. We find that heterogeneous contact patterns cause earlier and larger epidemics on the SIR model in comparison to homogeneous scenarios. In case of SI and SIS, the epidemics is faster in the early stages (up to 90% of prevalence) followed by a slowdown in the asymptotic limit in case of heterogeneous patterns. In the presence of birth and death, heterogeneous patterns always cause higher prevalence in comparison to homogeneous scenarios with same average inter-event times. Our results suggest that R0 may be underestimated if temporal heterogeneities are not taken into account in the modeling of epidemics.


INTRODUCTION
Living in society implies that individuals are constantly interacting with each other.
Interactions may take different forms, but those involving proximity or direct contact are of special interest because they are potential bridges for propagating infections.
Empirical data suggest that contact patterns and consequently the network structure depend on the environment and context of the contacts [1]. The way people find sexual partners [2,3] is not necessarily the same as they interact in a conference [4], museum exposition [4], school [5], hospital [6,7], or simply in daily life [8]. In common, these interactions have the property of being highly heterogeneous in the sense that individuals interact to different people at irregular times [2][3][4][5][6][7][8]. In the jargon of networks, each person, for example, has a different number of contacts, belongs to a different network cluster, or interacts with others at different rates [1,9].
Most research on networks has assumed that contacts are fixed, or static, and the topology at different levels contains the relevant structures to regulate the spreading processes, like a viral infection [1,9]. This approach works well as a first approximation in many circumstances, including when the process propagates much faster than the network evolves [10] (e.g. contacts of school children or patients in hospitals within a day), or when the activity patterns are homogeneous. In fact, for some regular activities people seem to be predictable [11] and consequently tend to have the same partners and contact structure on a typical day. Nevertheless, in some contexts, for example, people involved in commercial sex [3], or in tourism business, or hospital staff and long-term hospitalized patients [6], are constantly contacting different individuals during short intervals. In other words, the contact patterns change faster than the infective state of a person. There is further evidence that contact patterns are not regular but follow heterogeneous inter-event times, which means that intense activity (sometimes called bursts) may be followed by longer intervals of isolation or inactivity [3,4,7,12,13]. This property makes it difficult to distinguish on empirical data whether an individual is absent for some period or simply left the system (i.e. censoring [14]).
There is extensive literature about temporal patterns being considered on mathematical models of propagation of infectious diseases, some examples include, dynamic contact patterns, with or without considering the distance between two contacts [8,[15][16][17][18], seasonal effects affecting Influenza [19,20], pair formation models [17,21], birth and death [19,22]. The role of the heterogeneous inter-event times, on the other hand, has been addressed only recently by few theoretical and data-driven studies. In particular, it has been suggested that, in case of power-law inter-event time distributions, the number of new infected individuals in SI-dynamics decays as a power-law in the long-time limit irrespective of the degree distribution of the network [23,24]. These studies are essentially concerned with the long-term effect of the spreading, and not with the early stages of an epidemic outbreak. A study using an empirical network of sexual contacts suggests that, in comparison to homogeneous contact patterns, heterogeneous contacts speedup the spread of simulated infections [25] while the opposite happens, though the relative difference is small, in a contact network of conference attendees [26]. These results on sexual contacts, conference attendees, and other similar studies using diverse communication patterns as proxies for contact networks and SI-like simulations [27][28][29], are based on contrasting the evolution of the infection dynamics in the original network with the same dynamics on randomized versions of the temporal network (null models) where the time stamps are reshuffled retaining some (e.g. daily patterns) or no temporal constraints. Therefore, the relative difference and importance of the temporal characteristics, to shape the spread of infections, depends on the randomization protocol and therefore, results may be misleading. One example is the fact that the average inter-event time changes after the randomization. If some individuals are in the system originally at times !t < t < T final " !t (with 0 < !t < T final ), the reshuffling of time stamps results on contacts being active at new times 0 < t* < T final . This effect is observed in networks where newcomers are constantly entering and old members leaving the system [3,6]. In that case, the randomization of the time stamps causes an increase in the average inter-event times because the vertices that originally appeared, for example, in the beginning of the network, now may be found at any time t * . If samples of the empirical network are subsequently repeated to extend the original network in the time domain, this turnover mechanism creates artificial cyclic effects and possibly abrupt changes in the network since the identity of vertices in the final and initial parts of the network are substantially different.
To avoid conclusions based on particular samples of empirical networks, it is desirable to study the spread of infections in a minimalistic model containing only the temporal properties of interest. In this paper, we propose a simple and intuitive model of a temporal network, where the vertices are available ("on" state) only at certain times and inactive ("off" state) otherwise, co-evolving with an infection dynamics.
We mainly focus in the susceptible-infective-recovered (SIR) epidemics but as relevant case-studies, we also present results of the susceptible-infective (SI) model, typically used in the previous studies on heterogeneous inter-event times, and a reinfection model given by the susceptible-infective-susceptible (SIS) dynamics.

TEMPORAL NETWORK MODEL
A temporal network may be defined as a dynamic network where the vertices are available ("on" state) only at certain times and inactive ("off" state) otherwise [30].
The links are not fixed and change as time goes by. In our model, each vertex follows a stochastic process where subsequent "on" states depends on a certain inter-event time distribution P(!t) . In other words, we have a process where the probability of a vertex being active at time !, depends on the last time t ' it was active, i.e. !t = t " t ' .
For computational reasons, time is discrete t = {1, 2,...,T final } and we generate the next "on" state when the vertex is active, i.e. if a vertex is active at t ' , we select the next time it will be active t sampling !t from P(!t) [31]. As soon as a vertex is active, it chooses uniformly between other active vertices, connects to one of them during one time step, and destroys the link afterwards turning back to "off" state. Such evolving network is therefore only constrained by the inter-event time and results in randomly mixed networks without degree heterogeneities and correlations; after few steps everyone have contacted everyone else at least once. The inter-event time distribution depends on the process of interest. For a realistic scenario, we use a power-law with exponential cutoff P(!t) " !t #! exp(#" het !t) (! >> " = 0.001), hereafter referred to as ! het case, which is a typical example of a class of broad distributions and is also claimed to describe empirical data of sexual contacts [3], close contacts [4,7] and other forms of human communication [12,13,[27][28][29]. This type of inter-event time distribution are suggested to appear e.g. due to nonhomogeneous Poissonian processes constrained by cyclic activity [12], or due to preferential queuing models where individuals choose to perform highest priority tasks more often than random tasks [13]. As a baseline for comparison, we consider the exponential distribution P(!t) " exp(#! hom !t) with the same average !t as ! het . Exponential inter-event times appear on Poissonian processes where the chance of being active depends only on the probability ! hom = 1 !t (which means that t and t ' are unrelated in the Poissonian case) that corresponds to homogeneous inter-event times ( ! hom ). Since our models use discrete time, we use the equivalent geometric distribution for the simulations. The most adequate functional form for the inter-event time distribution depends on the system of interest but for simplicity we use the two limiting scenarios of complete randomness (Poisson) and burstness (power-law).
Independently of the evolution of these contacts, we define a turnover probability to account for the removal of the vertex. For simplicity, the lifetime of a vertex also follows a Poissonian process, where the removal probability is . A new vertex automatically replaces (birth) a removed vertex (death) in order to maintain the total number of vertices N constant. Therefore, the prevalence is given by As initial conditions, all vertices start with random values for t and t death . The initial transient quickly disappears after few time steps and is discarded.

EPIDEMICS MODELS
On top of the evolving network, we define an infectious process. We focus our study on general properties of the susceptible-infected-recovered (SIR) dynamics (adequate to model e.g. one wave of Influenza, Measles, or Hepatitis B) [19,21]. For comparison to previous studies based on empirical networks, we consider the limit case of susceptible-infected (SI) dynamics (which is also valid as a first approximation of an early stage of HIV propagation). Due to its importance to model several common infections (e.g. Influenza, Chlamydia, Gonorrhea) by accounting for the possibility of reinfection, we also investigate some properties of the susceptibleinfective-susceptible (SIS) model [19,21]. The study of specific infections with realistic parameters and the most proper compartmental models go beyond the scope of the present article, therefore, we focus on more theoretical aspects of these standard models to understand the impact of heterogeneous temporal contacts on general spread dynamics.
On the SIR model, a vertex infects instantaneously a susceptible partner, upon contact, with probability ! = 1 ( ! is the per-contact infection probability), and an infected vertex is completely recovered after !t I time steps. In the SI model, !t I " # , and in the SIS model, the vertex becomes susceptible after the infective period !t I allowing reinfections. Note that recover means that the vertex cannot infect or be infected, but still makes connections until being removed by death. Initially, one vertex is set to the infective state and the remaining N !1 vertices are set susceptible. Newcomers are always set to susceptible state. We generate 50 ensembles of the temporal network and for each ensemble, select all vertices active in the first time step; for example, N = 1000 gives on average ~250 active vertices that are used as infection seeds.
This results on approximately 50 ! 250 = 12500 different initial conditions.

SIR DYNAMICS
We initially study the evolution of the SIR dynamics on the temporal network and investigate the prevalence of the infection within the population according to the different temporal properties of the contact patterns and the parameters of the epidemics. In the absence of death ( ! death = 0 ), the only temporal pattern is the heterogeneous inter-event times. Figure 1a shows the difference in the peak values !" = max " het (t peak-het ) # max " hom (t peak-hom ) for the two scenarios of inter-event times. Varying the infective interval Δ! I and the contacts heterogeneity, which is given by the slope ! of the power-law distribution (see Supporting Information T1 for the relation between !t and ! ), raise two distinct regimes where the peak of prevalence is higher for heterogeneous contact patterns ! het (positive values of !" ) for small values of !t I and ! , whereas higher values of the same parameters produce the opposite effect (negative values of !" ), with higher prevalence for the homogeneous scenario ! hom . The difference in the peak prevalence !" reaches up to 54% . The irregular contact patterns also cause an earlier peak of the maximum prevalence (Fig. 1b, where !t peak = t peak-het " t peak-hom such that negative values mean that the peak of τ het occurs earlier than of ! hom ). For 2 < ! < 3 , which covers values observed on empirical systems [3,4,7], t peak occurs 20 to 40 time steps earlier for moderate !t death . The region around ! < 2 in Figure 3b essentially comprises cases where the infection dies out quickly ( t peak-hom ! 0 ) for homogeneous patterns but not for heterogeneous. The evolution of the SIR epidemics in the two regions identified in Figure 1 is shown in more details using two specific configurations with ! = 2.5 , !t I = 5 " 3 !t (Fig.   2a) and !t I = 10 " 6 !t (Fig. 2b). The infection growth has a similar shape for both inter-event times with a slightly broader spread for ! het . The final fraction of susceptible vertices is higher for τ het irrespective of the values of !t I , which suggests that the earlier peak is responsible for avoiding the infection of the entire network.
The introduction of birth/death reduces the peak prevalence on both contact patterns but has more impact on the homogeneous case (Figs. 2c-f). For moderate turnover rate ! death , i.e. !t death " 6 !t (Figs. 2c and 2d), susceptible newcomers are responsible to create a small second wave of epidemics (peak is ~40% smaller than the first wave for both configurations), followed by a small oscillation of low prevalence for both cases but still higher for heterogeneous contacts. Similar results are observed for other configurations with !t death " 6 !t and ! > 2 (See Supporting Information T1), but !t peak decreases for increasing ! . When the turnover is higher !t death " 3 !t (Figs. 2e and 2f), the prevalence grows monotonically to a state of constant prevalence and high fraction of susceptible individuals ( 60% to 80% of vertices for the configurations shown). conditions. Both in the absence and in presence of death, the distribution of outbreaks P(!) is broader for the ! het in comparison to ! hom , but still with characteristic values (Fig. 3). The diversity increases with the death rate (Fig. 3b). Furthermore, in case of death, few vertices are removed before infecting their contacts, which results in a number of null outbreaks (Fig. 3b). In both scenarios, i.e. with and without death, there is a considerable overlap of the distributions indicating that according to the

SI AND SIS DYNAMICS
As two specific examples of infection dynamics, we study the impact of the temporal effects using the SI and SIS epidemics models. For the SI dynamics (Fig. 4a), in case of absence of death, the heterogeneous patterns τ het causes a higher prevalence during an initial period, where about 85% of the population is infected, followed by a slow increase till the remaining network is reached. The homogeneous scenario ! hom causes a slower growth in the initial interval, however, allows the infection to reach the entire network much earlier. If death is included, ! het causes higher prevalence for the entire period and also removes the asymptotic slow growth observed in the absence of death (Fig. 4a). The heterogeneous inter-event time maintains non-zero prevalence for a vast range of !t death , while homogeneous contact patterns may result on null average outbreaks, especially for !t death " !t . The SIS model shows a similar result in the sense that an initial higher prevalence ! for ! het , in comparison to ! hom , is followed by a lower ! in the steady state after a short oscillatory transient (Fig. 4b). The removal of vertices has a stronger impact on the prevalence ! for the homogeneous case; for increasing turnover (i.e. decreasing !t death ), after a transition point !t death * , ! gets higher for ! het in comparison to ! hom .

ESTIMATION OF R 0
We estimate R 0 by counting the number of secondary infections, during 200 time steps, produced by a single initially infected vertex in a completely susceptible population [19]. Figure 5 shows R 0 for heterogeneous and homogeneous contact patterns, in the absence and in presence of death. For SIR and SI (which is simply used as a limiting case of SIR when !t I " # ), the values of R 0 are higher in the presence of death. With the exception of SI in the absence of death (Fig. 5c), all other configurations show R 0 ! 1 for ! " 2 in the homogeneous case. For values of ! " 3.5 , R 0 is indistinguishable for both contact patterns for all epidemics models, while in the range 1.5 ! " ! 3 , R 0 is generally higher for ! het in comparison to ! hom , with the exception of SI without death, where the opposite effect is observed.

DISCUSSION
Contact patterns are characterized by a high degree of heterogeneity both at topological and temporal levels [1][2][3][4][5][6][7][8][9][10][11][12][13]. An individual typically interacts with a number of partners during a period of time, but the interval between two interactions does not necessarily follows a characteristic value [3][4][5][6]. Furthermore, given the same period of time, some individuals may enter or leave the system at different times [3,19,22]. The two observations raise the question about to which extend modeling high-resolution temporal information affects the dynamics of spread of infections. As much as the contact structure (e.g. degree distribution [32] or community structure [33]) shapes the spreading of infections, heterogeneous inter-contact times also When death is included, infected vertices are replaced by susceptible vertices.
Increasing the death rate causes a higher replacement of infected vertices, leaving more susceptible vertices available for infection. Consequently, on average it is expected that the same vertex, following heterogeneous inter-event times, contacts more different vertices during its lifetime than if following homogeneous inter-event times, even though the average inter-event time is the same for both scenarios, as defined in the model. Therefore, the difference in the prevalence of infection, by considering both contact patterns, is more pronounced in networks with high vertex turnover rate. This is the case of sexual networks related to commercial sex [3] or contact networks of people hospitalized in the same ward [6] where the percentage of active vertices detected both in the initial and final 5% of the sampled edges is, We have also estimated R 0 , the average number of secondary infections produced by a single infective source in a completely susceptible population. For different levels of heterogeneity (measured by the exponent α of the power-law), we generally found R 0 SIR < R 0 SI . The difference in R 0 for heterogeneous and homogeneous contact patterns is larger for ! " 2.5 . In the absence of death, for all values of ! > 1.5 in the SI dynamics, R 0 is larger for homogeneous contacts. In all other configurations, heterogeneous patterns result on higher values of R 0 . In the range of parameters meaningful for real contact patterns, i.e. 2 < ! < 3, our model gives R 0 values close to those estimated for common diseases [37,38]. Nevertheless, the important result is that according to our results, traditional models that assume temporally homogeneous contacts and fixed population generally underestimate the value of R 0 . This effect is particularly relevant in systems where the dynamics of contacts are highly heterogeneous, as is the case of people involved in commercial sex, hospitals, or tourism related activities.
We have proposed a simple temporal network model with heterogeneous inter-contact times and birth/death dynamics. The simulation of standard epidemics models (SIR, SI, SIS) has shown that generally, these irregular contacts are responsible to earlier and higher outbreaks in comparison to homogeneous temporal activity, although slowing down may be observed under some limiting configurations as the asymptotic

Values of !! used in the simulations
In the simulations, we use the same Δ! for the heterogeneous and homogeneous contact patterns. For a given !, we calculate Δ! (Fig. S1) by sampling 100000000 In practice, since we use discrete times, times are sampled from a geometric distribution. Random generators can be found on numerical packages for diverse programming languages, otherwise, see ref. [R1].  We perform the simulations of the epidemics on the temporal network for different sizes ! of the network to see if there is a dependence of R ! and !. By using values of ! = {1000, 2000, 4000, 8000, 16000} , we see that our estimation of R ! is independent of the network size for SIR epidemics, and therefore, a reliable estimate (Fig. S3). For SI epidemics, R ! increases asymptotically with the network size, which is expected since once infected, a vertex will continue infecting throughout the dynamics. Strictly speaking R ! is inadequate to characterize the SI dynamics long after the initial infection, but is included as a comparison means between the two contact patterns (Fig. S4).