Kinetic Models for Epidemic Dynamics in the Presence of Opinion Polarization

Understanding the impact of collective social phenomena in epidemic dynamics is a crucial task to effectively contain the disease spread. In this work, we build a mathematical description for assessing the interplay between opinion polarization and the evolution of a disease. The proposed kinetic approach describes the evolution of aggregate quantities characterizing the agents belonging to epidemiologically relevant states and will show that the spread of the disease is closely related to consensus dynamics distribution in which opinion polarization may emerge. In the present modelling framework, microscopic consensus formation dynamics can be linked to macroscopic epidemic trends to trigger the collective adherence to protective measures. We conduct numerical investigations which confirm the ability of the model to describe different phenomena related to the spread of an epidemic.


Introduction
During the outbreak of SARS-CoV-2 pandemic, we observed how, as cases escalated, collective compliance to the so-called non-pharmaceutical interventions (NPIs) was crucial to ensure public health in the absence of effective treatments, see, e.g. Albi et al. (2021), Bellomo and Chaplain (2022), Bertaglia et al. (2021), Gatto et al. (2020), Viguerie et al. (2021) and Zanella et al. (2021). Nevertheless, the effectiveness of lockdown measures heavily depended on the beliefs/opinions of individuals regarding protective behaviour, which are thus linked to personal situational awareness (Durham and Casman 2012;Tchuenche et al. 2011). Recent experimental results have shown that social norm changes are often triggered by opinion alignment phenomena (Tunçgenç et al. 2021). In particular, the perceived adherence of individuals' social network has a strong impact on the effective support of the protective behaviour. The individual responses to threat are a core question to set up effective measures prescribing norm changes in daily social contacts (Dezecache et al. 2020), and cases escalation is a factor that may be perceived in different ways. For these reasons, it appears natural to couple classical epidemiological models with opinion dynamics in order to understand the mutual influence of these phenomena.
In recent years, the study of emerging properties of large systems of agents has obtained a growing interest in heterogeneous communities in social and life sciences, see, e.g. Bolley et al. (2011), Barré et al. (2017), Carrillo et al. (2010a, b), Chalub et al. (2004), Cordier et al. (2005), Ciallella et al. (2021), Degond and Motsch (2008), Fornasier et al. (2011), Ha and Tadmor (2008) and Motsch and Tadmor (2014). In particular, thanks to their cooperative nature, the dynamics leading to opinion formation phenomena have been often described through the methods of statistical mechanics (Ben-Naim et al. 2003;Castellano et al. 2009;Hegselmann and Krause 2002;Sznajd-Weron and Sznajd 2000;Weidlich 2000). Among other approaches, kinetic theory provided a sound theoretical framework to investigate the emerging patterns of such systems (Düring et al. 2009;Düring and Wolfram 2015;Toscani 2006). In this modelling setting, the microscopic, individual-based, opinion variations take place through binary interaction schemes involving the presence of social forces, whose effects are observable at the macroscopic scale (Pareschi et al. 2019). The equilibrium distribution describes the formation of a relative consensus about certain opinions (Pareschi and Toscani 2013;Toscani 2006;Toscani et al. 2018). In this direction, it is of paramount importance to obtain reduced complexity models whose equilibrium distribution is explicitly available under minimal assumptions (Furioli et al. 2019;Toscani 2006). The deviation from global consensus appears in the form of opinion polarization, i.e. the divergence away from central positions towards extremes (Loy et al. 2022). This latter feature of the agents' opinion distribution is frequently observed in problems of choice formation (Aletti et al. 2007).
The derivation of classical compartmental epidemiological dynamics from particle systems has been recently explored as a follow-up question on the effectiveness of available modelling approaches. Indeed, epidemics, as well as many other collective phenomena, can be easily thought as a result of repeated interactions between a large number of individuals that eventually modify their epidemiological state. The transition rates between epidemiologically relevant states are furthermore influenced by several phenomena linked to the disease itself and to the social behaviour of individuals. Without attempting to revise the whole literature, we mention Albi et al. (2022), Bertaglia et al. (2021), Della Marca et al. (2022a), Dimarco et al. (2020Dimarco et al. ( , 2021Dimarco et al. ( , 2022, Loy and Tosin (2021) and the references therein for an introduction to the subject. Among them, contact dynamics are particularly relevant for contact-based disease transmissions.
In this work, we introduce a novel kinetic model that takes into account opinion formation dynamics of the individuals' protective behaviour coupled with epidemic spreading. These dynamics will result structurally linked due to the mutual influence of opinion formation processes and the transmission of the infection. The effects of behavioural dynamics on epidemic models have been investigated at the population level, see Poletti et al. (2009). In particular, the formation of opinion clustering is connected to vaccination hesitancy, see, e.g. Buonomo et al. (2022) and the references therein. In this direction, we mention the recent results in Della Marca et al. (2022b), Giambiagi Ferrari et al. (2021), Kontorovsky et al. (2022) and Zhou et al. (2019) where agent-based dynamics are upscaled at the level of observable epidemiological quantities.
Kinetic equations are capable of providing efficient methods to bridge the microscopic, often unobservable, scale of individual agents, where elementary fundamental dynamics take place, and the macroscopic scale of observable manifestations. Indeed, in classical kinetic theory, the possibility to derive hydrodynamic descriptions of particles' systems is of paramount importance for providing real-time predictions. In the context of multiagent systems, the problem of deriving macroscopic equations is underexplored and has to face additional challenges in the definition of the social forces involved in the interactions. In order to get analytical insights on the macroscopic behaviour of the system, the derivation of reduced complexity models is a key point. Hence, thanks to the derived surrogate models we can derive equilibrium profiles that are coherent with the ones defined at the kinetic level. In this work, we exploit the Fokker-Planck modelling approach that has been introduced in Toscani (2006) for opinion formation processes. We remark that, at variance with Dimarco et al. (2021Dimarco et al. ( , 2022, the interactions between agents are structurally binary to mimic compromise behaviour. The new derived macroscopic models encode all the information of the opinion-based interactions and describe coherent transition rates penalizing agents clustering on a weak protective behaviour. We will observe how opinion polarization can trigger an increasing spread of infection in society.
In more details, the paper is organized as follows: in Sect. 2, we introduce a kinetic epidemic model where agents are characterized by their epidemiological state and their opinion. Hence, a reduced complexity operator is derived to compute the large time opinion distribution of the system of agents and we discuss minimal assumptions to observe opinion polarization. In Sect. 3, we derive a macroscopic system of equations by considering an equilibrium closure method. The derived macroscopic model expresses the evolution at the epidemic scale of the conserved quantities in the operator for opinion exchanges. Finally, in Sect. 4 we present several numerical tests showing the coherence of the presented closure strategy with the initial kinetic model in suitable scales. Furthermore, in the latter section we explore the possibility of considering more complex interaction functions in the opinion exchange process together with the influence of opinion polarization on the spreading of the disease.

A Kinetic Model Approach for Consensus Formation and Epidemic Dynamics
In this section, we introduce a kinetic compartmental model for the spreading of an infectious disease that is coupled with the evolution of the opinions of individuals. We consider a system of agents that can be subdivided in the following epidemiologically relevant states: susceptible (S) agents are the ones that can contract the disease, infectious agents (I) are responsible for the spread of the disease, exposed (E) agents have been infected but are still not contagious and, finally, removed (R) agents cannot spread the disease. Each agent is endowed of a continuous opinion variable w ∈ I which varies continuously in I = [−1, 1], where −1 and 1 denote two opposite beliefs on the protective behaviour. In particular, w = −1 means that the agents do not believe in the necessity of protections (like wearing masks or reducing daily contacts), whereas w = 1 is linked to maximal agreement on protective behaviour. We also assume that agents characterized by high protective behaviour are less likely to contract the infection.
With the aim to incorporate the impact of opinion evolution in the dynamics of infection, we denote by f J (w, t) the distribution of opinions at time t ≥ 0 of agents in the compartment J ∈ C = {S, E, I , R}. In particular, f J = f J (w, t) : [−1, 1] × R + → R + is such that f J (w, t)dw represents the fraction of agents with opinion in [w, w + dw] at time t ≥ 0 in the J th compartment. Furthermore, we impose while the mass fractions of the population in each compartment and their moment of order r > 0 are given by In the following, to simplify notations, we will indicate with m J (t), J ∈ C, the mean opinion in the compartment J corresponding to r = 1. We assume that the introduced compartments of the model can have different impact in the opinion dynamics. The kinetic model for the coupled evolution of opinions and infection is given by the following system of kinetic equations , , , where τ > 0 and Q J (·, ·) characterizes the evolution of opinions of agents that belong to the compartment J ∈ C. In the next section, we will specify the form of these operators describing binary opinion interactions among agents. The parameter σ E > 0 is such that 1/σ E measures the mean latent period for the disease, whereas γ > 0 is such that 1/γ > 0 is the mean infectious period (Diekmann and Heesterbeek 2000). In (2), the transmission of the infection is governed by the local incidence rate where κ(w, w * ) is a nonnegative decreasing function measuring the impact of the protective behaviour among different compartments. A leading example for the function κ(w, w * ) can be obtained by assuming where β > 0 is the baseline transmission rate characterizing the epidemics and α > 0 is a coefficient linked to the efficacy of the protective measures. In Fig. 1, we represent the introduced function κ(·, ·) for several values of α > 0. We may observe how for α ≡ 0 the influence of opinion dynamics on the epidemiological model disappears. We highlight that in the simple case α = 1 we get with K ( f S , f I ) ≡ 0 in the case m I ≡ 1 or in the case where all susceptible agents are concentrated in the maximal protective behaviour w = 1.

Kinetic Models for Opinion Formation
The dynamics of opinion formation have often been described by resorting to methods of statistical physics, see, e.g. Castellano et al. (2009) and Galam (1997). In particular, kinetic theory provides a sound theoretical background to model fundamental interactions among agents and to provide a convenient dynamical structure for related We sketch the function κ(w, w * ) in (4) for α = 1 2 (left) and α = 1 (right). In both cases, we fixed the coefficient β = 1 2 follow-up questions on control problems and network formation (Albi et al. 2017;Toscani 2006). In the aforementioned kinetic models, the opinion variation of large systems of agents depends on binary interactions whose are driven by social forces determining the formation of consensus about certain opinions. The emerging distribution of opinions can be evaluated at the macroscopic level (Motsch and Tadmor 2014;Pareschi and Toscani 2013). Recent advancements have been devoted to include external influences in opinion formation models to capture realistic complex phenomena. Without intending to review the very huge literature on the topic, we mention Ben-Naim et al. (2003), Cristiani and Tosin (2018), Düring et al. (2009), Düring and Wolfram (2015) and the references therein.
The elementary interactions between agents weight two opposite behaviours: the first is the compromise propensity, i.e. the tendency to reduce the opinion distance after interaction, and the second is the self-thinking, corresponding to unpredictable opinion deviations. In details, an interaction between two individuals in the compartments J ∈ C with opinion pair (w, w * ) leads to an opinion pair (w , w * ) defined by the relations where λ J ∈ (0, 1) and P(w, w * ) ∈ [0, 1] is an interaction function. In (5), we further introduce the local diffusion function D(w), and η J ,η J are independent and identically distributed centred random variables with finite variance η J = η J = σ 2 J , where we indicate with · the expected value with respect to the distribution of the random variables.
As observed in Pareschi et al. (2019), we have that the mean opinion is conserved for symmetric interaction functions, P(w, w * ) = P(w * , w) for all w, w * ∈ [−1, 1]. Indeed, from (5) we get which reduces to w + w * = w + w * under the aforementioned assumptions. Furthermore, if we consider the mean energy, we get meaning that the energy is not conserved on average in a single binary interaction. In the absence of the stochastic component, σ 2 J ≡ 0, we get that for symmetric interactions the mean energy is dissipated The physical admissibility of interaction rules (5) is provided if |w |, |w * | ≤ 1 for |w|, |w * | ≤ 1. We observe that since |w * | ≤ 1, from which we get that the sufficient condition for |w | ≤ 1 is provided by which is satisfied if a constant c > 0 exists and is such that for all w, w * ∈ [−1, 1]. Since 0 ≤ P(·, ·) ≤ 1 by assumption, the first condition in (7) can be enforced by requiring that Therefore, it is sufficient to consider the support of the random variables determined by |η J | ≤ c(1 − λ J ). The second condition in (7) forces D(±1) = 0. Other choices for the local diffusion function have been investigated in Pareschi et al. (2019) and Toscani (2006). The collective trends of a system of agents undergoing binary interactions (5) are determined by a Boltzmann-type model having the form with τ > 0 and where ( w, w * ) are pre-interaction opinions generating the post-interaction opinions (w, w * ) and J is the Jacobian of the transformation ( w, w * ) → (w, w * ).

Derivation of a Fokker-Planck Model
The equilibrium distribution of the kinetic model (8) is very difficult to obtain analytically. For this reason, several reduced complexity models have been proposed. In this direction, a deeper insight on the equilibrium distribution of the kinetic model can be obtained by introducing a rescaling of both the interaction and diffusion parameters having roots in the so-called grazing collision limit of the classical Boltzmann equation (Cercignani 1988;Pareschi and Toscani 2013). The resulting model has the form of an aggregation-diffusion Fokker-Planck-type equation, encapsulating the information of microscopic dynamics. For the obtained surrogate model, the study of asymptotic properties is typically easier than the original kinetic model. We start by observing that we can conveniently express the operators Q J (·, ·) in weak form. Let ϕ(w) denote a test function; thus, for J ∈ C we have where w is defined in (5). The prototype of a symmetric interaction function P is given by the constant function P ≡ 1. In this case, we may obtain analytic insight on the large time distribution of the system by resorting to a reduced complexity Fokker-Planck-type model (Toscani 2006). We introduce the so-called quasi-invariant regime where > 0 is a scaling coefficient. We have where min{w, w } <w < max{w, w }. Plugging the above expansions in the Boltzmann-type model, we have where where now 1 R(g J , g J ) → 0 under the additional hypothesis |η J | 3 < +∞, see Cordier et al. (2005) and Toscani (2006). Consequently, for → 0 + , from the above equation we have Now, with a slight abuse of notation, we restore t ≥ 0 as time variable and f J as distribution. In view of the smoothness of ϕ, integrating back by parts the terms on the right hand side, we finally get the Fokker-Planck-type model We can observe that the steady state of the Fokker-Planck-type model (11) is analytically computable under suitable hypotheses on the local diffusion function. If D(w) = √ 1 − w 2 , then the large time behaviour of the model is given by a beta distribution having the form where B(·, ·) indicates the beta function. It is worth to highlight that the first two moments of the obtained beta distribution are defined as follows: We can observe that the obtained model is suitable to describe classical consensustype dynamics. This behaviour is observed if the compromise force is stronger than the one characterizing self-thinking, i.e. σ 2 J < λ J . On the other hand, if self-thinking is stronger than the compromise propensity, i.e. σ 2 J > λ J , we observe opinion polarization of the society. In Fig. 2, we depict the equilibrium distribution (12) for several choices of the parameter ν J > 0. In the right figure, we assume that m J = 0, whereas, in the left figure, we consider the asymmetric case with m J = 0.2. We may observe that opinion polarization is obtained in the case ν J > 1 as discussed.

Remark 1
In the more general case where interaction between agents is weighted by a nonconstant function P(w, w * ) ∈ [0, 1], we may obtain the nonlocal Fokker-Plancktype model In this case, it is difficult to get an analytical formulation of the steady state distribution.

Macroscopic Opinion-Based SEIR Dynamics
Once the equilibrium distribution of the operatorsQ J ( f J , f J )(w, t) is characterized, we can study the behaviour of the original system (2). In this section, we compute the evolution of observable macroscopic equations of the introduced kinetic model for epidemic dynamics with opinion-based incidence rate.

Derivation of Moment-Based Systems
Let us rewrite the original model (2) with the reduced complexity Fokker-Planck-type operators defined in Sect. 2.2. We obtain the following model , , where K (·, ·) is defined in (3) and the collision-like operatorsQ J (·, ·), J ∈ C, are derived in Sect. 2.2. The system of kinetic equations (14) is further complemented by no-flux boundary conditions at w = ±1 and contains the information on the spreading of the epidemic in terms of the distribution of opinions of a population of agents.
Integrating model (2) with respect to the w variable and recalling that if the interaction function is symmetric, the Fokker-Planck operators are mass and momentum preserving in the presence of no-flux boundary conditions coherently with what we observed for the microscopic binary scheme (6). Hence, we obtain the evolution of where we observe that Unlike the classical SEIR model, the system for the evolution of mass fractions in (15) is not closed since the evolution of ρ J , ρ J ∈ C depends on the evolution of the local mean opinions m J , J ∈ C. The closure of system (15) may be formally obtained by resorting to a limit procedure. The main idea is to observe that the typical time scale of the opinion dynamics is faster than the one of the epidemic, and therefore τ 1. Consequently, for small values of τ the opinion distribution of the J th compartment reaches its local beta-type equilibrium with a mass fraction ρ J and local mean opinion m J as verified in Sect. 2.2. In particular, we observe exponential convergence of the derived Fokker-Planck equation (11) towards the local Maxwellian parameterized by the conserved quantities, i.e. ρ J and m J , see Furioli et al. (2019). We highlight that this assumption is coherent with what stated in the work Poletti et al. (2009) since epidemic transmission is generally slower than the propagation of information.
Hence, to get the evolution of mean values we can multiply by w and integrate (14) to get system which now depends on the second-order moment, making this system not closed. It is now possible to close this expression by using the energy of the beta-type local equilibrium distribution as in (13). We have where ν S = σ 2 /λ S and m J is the local mean opinion in the J th compartment (1) Hence, we have where the time evolution of the fraction ρ S has been derived in the first equation of (15). The evolution of the local mean m S is therefore given by We may apply an analogous procedure for the remaining local mean values in the compartments of exposed, infected and recovered to obtain Remark 2 In the case of consensus of the susceptible agents, i.e. for ν S → 0 + , we can observe that d dt m S (t) = 0 which leads to m S (t) = m S (0) for all t ≥ 0. The spread of the infection therefore depends only on the protective behaviour of the agents on the compartment I ∈ C. Furthermore, the trajectory of the second equation is decreasing in time since Remark 3 If the local incidence rate K ( f S , f I ) in (3) is such that κ(w, w * ) ≡ β > 0 than we easily observe that the evolution of mass fractions are decoupled with the local mean opinions since in this case integrating (2) we get Therefore, model (2) for constant κ(w, w * ) ≡ β reduces to the classical SEIR compartmental model.

Remark 4
In the case of non-symmetric interaction function P(w, w * ), the system of macroscopic equations loses the information on the evolution of the mean values.
A possible prototype of non-symmetric P proposed in Pareschi et al. (2019) is the linear perturbation of a constant, i.e. P(w, w * ) = P(w * ) = pw * + q, q ∈ [0, 1] and | p| ≤ min{q, 1 − q}. In this case, in Pareschi et al. (2019) it is shown that the mean opinion is not conserved and that the asymptotic distribution functions are given by a Dirac delta distribution δ(w − 1) if p > 0 or by a Dirac delta δ(w + 1) if p < 0.

The Macroscopic Model with Saturated Incidence Rate
It is not restrictive to suppose that infected agents possess enforced situational awareness. For this reasons, we may consider the case in which m I (t) =m I ∈ (0, 1). From the first equation of (17), we get Hence, plugging (18) into the system for the mass fractions (15) we get whereβ In this case, model (19) is a generalization of classical models with saturated incidence rate, see Capasso and Serio (1978) and Korobeinikov and Maini (2005). In this setting, we derive the basic reproduction number by defining and D(ρ S , ρ I ) is concave since ∂ 2 ∂ρ 2 I D(ρ S , ρ I ) ≤ 0 for all ρ S , ρ I > 0. Hence, the basic reproduction number R 0 of the model is given by For the computation of the basic reproduction number R 0 using the method of nextgeneration matrix, we refer to Bellomo and Chaplain (2022). The method goes back to Diekmann et al. (1990), and we also refer to Diekmann et al. (2009) for an application to the SEIR model.
The consensus of the population on the adoption of protective measures is capable of reducing the epidemic peak together with the total number of infected agents. Finally, we will investigate numerically the impact of opinion polarization on the defined dynamics.
From the methodological point of view, we will consider classical direct simulation Monte Carlo (DSMC) methods to show how, in the quasi-invariant limit defined in (9), the large time distribution of the Boltzmann-type model (8) is consistent with the one obtained from the reduced complexity Fokker-Planck model (11). In the following, we will first concentrate on the case of interactions leading to a beta distribution of the form (12). As a follow-up question, we will explore the observable effects of nonlinear interaction functions.
Hence, in order to approximate the dynamics of the kinetic SEIR model (2) for small values of τ > 0, we resort to classical strong stability preserving schemes combined to recently developed semi-implicit structure-preserving schemes for nonlinear Fokker-Planck equations (Pareschi and Zanella 2018), see also Loy and Zanella (2021) for further applications. These methods are capable of reproducing large time statistical properties of the exact steady state with arbitrary accuracy together with the preservation of the main physical properties of the solution, like positivity and entropy dissipation. Indeed, we highlight how in the present setting the development of DSMC methods would encounter severe time step restrictions depending on the values of τ > 0. We point the interested reader to Pareschi and Russo (2001) for a more detailed discussion on the topic.

Test 1: Large Time Behaviour of Kinetic Opinion Formation Models
In this section, we test the consistency of the quasi-invariant limit to obtain a reduced complexity Fokker-Planck model. In particular, we concentrate on a kinetic model for opinion formation where the binary scheme is given by (5) in the simplified case P ≡ 1 and for D(w) = √ 1 − w 2 . As discussed in Sect. 2.2, for quasi-invariant interactions as in (9) and in the limit → 0 + , the emerging distribution can be computed through the Fokker-Planck model (11) and is given by the beta distribution (12).
We rewrite the Boltzmann-type model (8) as follows: where τ > 0 is a positive constant and where ( w, w * ) are the pre-interaction opinions generating the post-interaction opinions (w, w * ) according to the binary interaction rule (5) and J is the Jacobian of the transformation ( w, w * ) → (w, w * ). To compute the large time numerical solution of the introduced Boltzmann-type model, we consider N = 10 6 particles and we  (9) is considered for = 10 −1 , 10 −3 . In Fig. 3, we depict the densities reconstructed from the DSMC approach with N = 10 6 particles at time T = 5 and assuming t = = 10 −3 , 10 −1 . In the top row, we considered the initial distribution such that m J (0) = 1 −1 f (w, 0)dw = 0 which is conserved in time. In the bottom row, we consider the initial distribution such that m J = 0.2. We further assume that λ J = 1 and σ 2 J = 0.25 in the left column, whereas σ 2 J = 2 in the right column. Hence, under the introduced choice of parameters we have considered ν J = 0.25 (left column) and ν J = 2 (right column). The emerging distribution is compared with the beta distribution defined in (12). We may observe how, for decreasing values of → 0 + , we correctly approximate the large time solution of the surrogate Fokker-Planck-type problem.

Test 2: Consistency of the Macroscopic Limit
In this test, we compare the evolution of mass and local mean of the distributions f J , J ∈ C, solution to (2), with the evolution of the obtained macroscopic system (15)-(17).
We are interested in the evolution f J (w, t), J ∈ C, w ∈ [−1, 1], t ≥ 0 solution to (2) and complemented by the initial condition f J (w, 0) = f 0 J . We consider a time discretization of the interval [0, t max ] of size t > 0. We denote by f n J (w) the approximation of f J (w, t n ). Hence, we introduce a splitting strategy between the opinion consensus step f * and the epidemiological step performed with an RK4 method. In the following, we will adopt a Strang splitting approach. We consider the following artificial parameters characterizing the epidemiological dynamics β = 0.4, σ E = 1/2, γ = 1/12. These values are strongly dependent on the infectious disease under investigation. We highlight that, without having the intention to use real data for the calibration of the presented model, these values are coherent with several recent works for the COVID-19 pandemic (Albi et al. 2022;Buonomo and Della Marca 2020;Dimarco et al. 2022).

Test 2a: Equilibrium Closure
In this test, we assume a constant interaction function P(·, ·) ≡ 1 such that the Fokker-Planck model is characterized by a beta equilibrium distribution (12) as shown in Sect. 2.2. To define the initial condition, we introduce the distributions and we consider with ρ E (0) = ρ I (0) = ρ R (0) = 10 −2 and ρ S = 1 − ρ E (0) − ρ I (0) − ρ R (0). We solve numerically (22)-(23) over the time frame [0, t max ], and we introduce the grid w i ∈ [−1, 1] with w i+1 − w i , where w > 0, i = 1, . . . , N w . We introduce also a time discretization such that t n = n t, t > 0, and n = 0, . . . , T with T t = t max . For all the details on the considered numerical scheme, we point the interested reader to Pareschi and Zanella (2018). Hence, for several values of τ > 0, we compare the evolution of the computed observable quantities defined as with the ones in (15)-(17) whose dynamics have been determined through a suitable kinetic closure in the limit τ → 0 + . In (25), we highlight the dependence on the scale parameter τ > 0 through a superscript. It is important to remark that the introduced closure strategy is essentially based on the assumption that opinion dynamics are faster than the ones characterizing the epidemic. Furthermore, we fix as initial values of the coupled system (15)-(17) the values ρ J (0) and m J (0), for all J ∈ C.
In Fig. 4, we present the evolution of the macroscopic system (15)-(17) and of the observable quantities (25) for several τ = 10 −5 , 1, 100. The consensus dynamics are characterized by λ J = 1, σ 2 J = 10 −3 for all J ∈ C, such that ν S = 10 −3 . We can easily observe how, for small values of τ 1, the macroscopic model obtained through a  (24), whereas we fixed λ J = 1 and σ 2 J = 10 −3 for all J ∈ C beta-type equilibrium closure is coherent with the evolution of mass and mean of the kinetic model (2). In Fig. 5, we show the evolution of the kinetic distributions f S (w, t) and f I (w, t) for t ∈ [0, 100]. The parameters characterizing the opinion and epidemic dynamics are coherent with the ones chosen for Fig. 4. We may easily observe how for τ = 100 the distributions are far from the beta equilibrium (12), whereas for τ = 10 −5 the kinetic distributions f J are of beta type. Therefore, for small τ 1, the opinion exchanges are faster than the epidemic dynamics and we are allowed to assume a beta-type closure as in (16).

Test2b: The Bounded Confidence Case
In this test, we consider an interaction function of the form where χ(·) is the indicator function and ∈ [0, 2] is a confidence threshold parameter above which the agents' with opinions w and w * do not interact. In the case, = 0 only agents sharing the same opinion interact, whereas for = 2 the interaction function is such that P(·, ·) ≡ 1 since |w − w * | ≤ 2 for all w, w * ∈ [−1, 1]. Bounded confidence-type dynamics have been introduced in Hegselmann and Krause (2002)  (22) has been performed through a semi-implicit SP scheme over the a grid of N w = 201 nodes and t = 10 −1 . Initial distributions defined in (24) and have been studied to observe the loss of global consensus. Indeed, for large times, the agents' opinion forms several clusters whose number and size depend on the parameter > 0 and the initial opinions. We highlight that since bounded confidence interactions (26) are symmetric, the mean opinion is preserved in time (Pareschi et al. 2019).
Proceeding as in Sect. 2.2, the Fokker-Planck description of a system of agents in the compartment J ∈ C characterized by bounded confidence interactions is given by the following nonlocal operator cf. Remark 1. The equilibrium distribution of the corresponding nonlocal model is not explicitly computable, and the resulting macroscopic models for the evolution of observable quantities may deviate from the ones defined in Sect. 3. Let us consider the with ρ E (0) = 0.01, ρ I (0) = 0.01, ρ R (0) = 0.01 and ρ In Fig. 6, we show the evolution of the kinetic distributions f S (w, t) and f I (w, t), t ∈ [0, 100] determined by bounded confidence interactions described by the nonlocal Fokker-Planck-type operator (27), with = 1 2 , λ J = 1, and σ 2 J = 10 −3 for all J ∈ C. We may observe how the opinion dynamics lead to two separate clusters centred in −0.5 and in 0.5. Furthermore, coherently with the modelling assumptions characteriz-  (22) has been performed through a semi-implicit SP scheme over the a grid of N w = 201 gridpoints and t = 10 −1 . Initial distributions defined in (28) ing the incidence rate K ( f S , f I )(w, t) in (3) and (4), the cluster with negative opinions looses mass since it is linked to agents with weak protective behaviour. The infection is therefore propagated to these agents and the kinetic distribution f I (w, 0) gains mass for w < 0. We highlight how the approximated equilibrium density is not coherent with a beta distribution. Therefore, the evolution of the macroscopic quantities cannot be obtained through a classical closure method and we need to solve the full kinetic model (Fig. 7).

Test 2c: Infection-Driven Bounded Confidence Model
We consider in the nonlocal operator (27) the case in which the interaction function depends on the fraction of infected cases ρ I (t). To this end, we consider the bounded confidence function where (ρ I ) is a dynamical confidence threshold depending on the epidemic. We further assume that consensus emerges for sufficiently high values of ρ I , mimicking the fact the adoption of a protective behaviour is triggered by the evolution of the epidemic. In particular, we consider with 1 < 2 ∈ [0, 2]. Therefore, opinion clustering is expected if ρ I ≤ C I and consensus if ρ I > C I . In Fig.8, we show the evolution of ρ I (t) and ρ R (t) in the case of bounded confidence interactions with infection-driven threshold. The initial conditions are defined in (26). In particular, we consider λ J = 1, σ 2 J = 10 −3 and 1 = 1 10 and 2 = 1 2 , so that that the compromise propensity is higher once the cases escalate. To understand the impact of the parameter C I , we consider C I = K × 10 −2 with K = 1, 5 2 , 5. We may observe how the epidemic peak is reduced for small values of C I > 0. At the same time, the number of recovered agents is reduced for small C I > 0. We report also the evolution of the kinetic density f S (w, t), t ∈ [0, 200] determined by model (14) withQ J (·, ·) defined in (27) and infection-driven bounded confidence interaction function (29). We can observe that the introduced dynamics imply a sharp switch in the compromise process whose effects are also observable the population level.

Test 3: The Impact of Opinion Polarization on the Infection Dynamics
In this test, we exploit the derived macroscopic system of mass fractions and mean opinions (15)-(17) to investigate the relation between opinion polarization and large number of recovered individuals. We recall that, assuming P ≡ 1, opinion polarization is observed if ν S > 1, see Sect. 2.2. Hence, we consider two main cases, supposing that the mean agents' opinions in all the compartments are exactly alike: the case m J (0) = −0.5, meaning that the agents in each compartment have a bias towards weak protective behaviour, and the case m J (0) = 0.5, meaning that all the agents are biased towards protective behaviour.
In Fig. 9, we present the large time mass fractions of recovered individuals ρ R (T ) obtained as solution to (15)-(17) over the time interval [0, T ], T = 300, t = 10 −2 , where we fixed the value ν S ∈ [0, 10]. In the left figure we consider the case m J (0) = −0.5, whereas in the right figure we consider the case m J (0) = 0.5. We can observe how the effect of opinion polarization strongly depends on the macroscopic initial opinion of the population on protective behaviour. In details, if the mean opinion is biased towards the adoption of protective behaviour, i.e. m J (0) = 0.5, large values of ν S trigger an increasing number of recovered individuals, meaning that the infection has a stronger effect on the society in the presence of polarized opinions.
On the other hand, if the initial opinion of the population is biased towards the rejection of protective behaviour, i.e. m J (0) = −0.5, opinion polarization is a factor that can dampen the asymptotic number of recovered individuals. Indeed, opinion  (29) with infection-dependent confidence threshold (ρ I ) defined in (30). Top row: evolution of ρ I (t) = 1 −1 f I (w, t)dw (left) and ρ R (t) = 1 −1 f R (w, t)dw (right) for several values of C I = K × 10 −2 and K = 1, 5 2 , 5. Bottom row: evolution of the kinetic distributions for the susceptible compartment in the case C I = 10 −2 (left) and C I = 5 × 10 −2 (right). The evolution of the kinetic densities has been determined through the semi-implicit SP scheme with N w = 201 gridpoints and t = 10 −1 . Initial distributions defined in (28) with ρ I (0) = ρ E (0) = ρ R (0) = 10 −3 polarization in this case pushes a fraction of the population towards the two extreme positions and a fraction of agents will stick towards a maximal protective behaviour.

Conclusion
In this work, we considered the effects of opinion polarization on epidemic dynamics. We exploit the formalism of kinetic theory for multiagent system where a compartmentalization of the total number of agents is coupled with their opinion evolution. Kinetic models for opinion formation have been developed in detail and are capable of determining minimal conditions for which we can observe polarization of opinions, i.e. the divergence of opinions with respect to a neutral centre. Agents' opinions on the adoption of protective behaviour during epidemics are a central aspects for the collective compliance with non-pharmaceutical interventions. Thanks to classical methods of kinetic theory, we derived a system of equations that describe the evolution in time of observable quantities that are conserved during the opinion for- Fig. 9 Test 3. Impact of the coefficient ν S in the large time behaviour of the system (15)-(17) assuming different initial conditions on the mean opinions of the compartments, m J (0) = − 0.5 (left) and m J (0) = 0.5 (right) for all J ∈ C. The epidemiological parameters are the same of the previous tests and fixed as follows β = 0.4, σ E = 1/2, γ = 1/12. Furthermore, we fixed ρ E (0) = ρ I (0) = ρ R (0) = 0.01 and ρ S (0) = 1 − ρ E (0) − ρ I (0) − ρ R (0). The system of ODEs is solved through RK4 over a time interval [0, 300] with t = 10 −2 mation process. In particular, considering sufficiently simple interaction functions and local diffusion functions, we get a second-order system of equations for the evolution of mass fractions and mean opinions. This macroscopic system takes into account the social heterogeneities of agents in terms of their opinions and is derived from microscopic dynamics in a SEIR compartmentalization. Thanks to recently developed structure-preserving numerical methods, we showed the consistency of the approach by comparing the system of kinetic equations with the set of macroscopic equations. Furthermore, we analysed more complex interaction functions based on confidence thresholds. The effects of opinion polarization on the asymptotic number of recovered are measured and strongly depend on the initial mean opinion of the population. Indeed, if a positive bias towards protective behaviour is observed, opinion polarization is capable of worsening the infection, whereas if the population tends to reject protective mechanisms, opinion polarization may dampen the total number of infectious agents. Future works will regard more complex opinion formation processes based on leader-follower dynamics and dynamics opinion networks. In future works, we will tackle the calibration of the introduced modelling approach and possible opinion control strategy to prevent the epidemic outbreak. and indicate if changes were made. The images or other third party material in this article are included in the article's Creative Commons licence, unless indicated otherwise in a credit line to the material. If material is not included in the article's Creative Commons licence and your intended use is not permitted by statutory regulation or exceeds the permitted use, you will need to obtain permission directly from the copyright holder. To view a copy of this licence, visit http://creativecommons.org/licenses/by/4.0/.