key: cord-0940921-b5sbgaa8 authors: THAFASAL IJYAS, V P; MAYET, ABDULILAH MOHAMMAD title: Electronic circuit implementation of the compartmental models for population dynamics of COVID-19 like epidemics date: 2022-03-04 journal: Sādhanā DOI: 10.1007/s12046-022-01821-6 sha: ce5b6dc8996f519d44fdeffc03433dcca0f27a5e doc_id: 940921 cord_uid: b5sbgaa8 Modelling of population dynamics of epidemic diseases is crucial in developing effective strategies for curbing the diseases. It helps us identify the various parameters that can help control the epidemic if the modelling is done carefully. Physical modelling of the dynamics in the form of circuits and systems can augment the understanding of disease mechanisms. In this paper, we develop two electronic circuit models for realizing the dynamics of two compartmental models widely used in epidemiological studies. These models are important in the context of the current, rampant COVID-19 global pandemic. This innovative study will no doubt pave the way for developing electronic circuits and analog processing systems that can simulate the dynamics of more complex population models. The variants of the COVID-19 pandemic pose formidable challenges to the contemporary human civilization. The repercussions of this crisis percolate into all domains of human life on a global scale. While mankind is still groping for effective solutions to contain this threat and its impacts on life, an important aspect of finding such solutions is the identification of the crucial parameters that may provide the keys to reaching to such solutions. Such parameters are imbedded in the dynamics of the disease. An important way to understanding this dynamic is to study its impact on the population. Population has a specific meaning in dynamics. It refers to interacting groups in a model. The pioneering studies in population dynamics were conducted by Volterra in the 1930s and Lotka in the 1950s [1, 2] . A model for predicting an epidemic based on convolution of statistical functions is proposed in [3] . There have been many modelling techniques employed for studying population interactions. In [4] , the author proposes to model population interactions using bond graphs. Such models simplify the derivation of the related state equations and also has the added flexibility for investigating impact of structural changes in the models on the interactions. A related method that is widely used now is the compartmental model. In this model, the interaction between populations is modelled as flows. In [5] , the dynamics of COVID-19 in the specific context of Ukraine is investigated using compartmental modelling. The authors have used an SEIR (Susceptible-Exposed-Infected-Recovered) model for proposing solution for containing the disease. Compartmental models provide an efficient means for mathematical modelling of epidemiology. In this method, the population is divided into many compartments and the interaction between these compartments are also specified. The dynamics is often in the form of differential equations that capture the dynamics of the state of each population. This model gives a vivid picture of how populations change rapidly or slowly. It can also depict the effect of the variation of the rate parameters on the change in the population dynamics. The monitoring and prevention of COVID-19 using machine learning is discussed in [6] . The paper proposes a method for predicting the evolution of the disease outbreak in different scenarios. The model used is the SIR model. Recent advances in computing like artificial intelligence (AI), deep learning (DL), cloud computing etc., can also be used modelling, forecasting and providing health care in the COVID scenario. AI and deep learning algorithms are used to understand the propagation of COVID-19 in South Korea in [7] . AI is used in relation to the SEIR model in for the prediction of the trend of the COVID-19 epidemic in China in [8] . A comparison of the prediction of confirmed cases between machine learning, deterministic SIR models and stochastic SIR models is done in [9] . Hitherto, various modelling strategies have been used for understanding the COVID disease. Most of them are based on the formulation of the underlying dynamics of the spread of the disease among the population classes and confine to mathematical modelling. But, till now, the physical modelling of the *For correspondence epidemiological dynamics is not an adequately investigated area of research. A wave propagation model in an infinite ordered lattice representing a population is proposed in [10] . The paper gives a dissipative thermodynamic understanding of the COVID phenomenon. Yet, it does not provide us with a tangible self-contained physical system description that can capture the dynamics of the disease. There is no doubt that various physical quantities like heat, mass, humidity, light intensity could be metaphorically used to develop physical models of the disease dynamics. Yet, this area is more or less a largely unexplored one. Another interesting transposition could be into the domain of electrical and electronic circuits and systems. Circuits provide a powerful medium for modelling various phenomena. Circuits can be used to model neurons, transmission lines, quantum phenomena etc. Methods like bond graphs demonstrate the equivalence of electric circuits to many systems in other domains. The behavior of basic circuit elements can capture the dynamics of many systems. State space equations can be converted to equivalent circuits using active and passive elements like transistors, opamps, resistors, inductors, capacitors etc. Coupled differential equations representing nonlinear systems and even chaotic systems have been successfully implemented as electronic circuits. An example is the Chua's circuit explained in [11] . Many other chaotic systems of various orders have also been realized as circuits. Another related domain is analog computation. Analog computers have recently received a revived interest in relation to hybrid computers [12] . In this paper we develop electronic circuit models for representing the population dynamics of pandemic diseases in general and COVID-19 in particular. We make use of some existing prominent compartmental models to arrive at these circuits. We simulate the behavior of these circuits and compare and validate them by using the results obtained from the mathematical models. To the best knowledge of the authors, this is the first attempt to model the dynamics of the infectious diseases in the form of electronic circuits. In this section, we will discuss some prominent compartmental models that can be use to represent the transmission dynamics of the disease. These models are in the form of coupled differential equations that represent the states of various population entities. Specifically, we discuss two models : (1) SIR Model and (2) SIR-F Model. Even though these models were developed for characterizing infectious diseases in general, now they are widely used to study the COVID phenomenon also because of their efficacy in characterizing the various aspects of the disease. The SIR model [13] stands for three classes of population namely, the Susceptible, Infectious and Removed classes. The susceptible class of individuals comprises of all persons who are susceptible to the disease. When a susceptible individual contracts the disease, he will be transferred to the infectious class. The infectious class consists of all persons who have contracted the disease and are ill at a particular time. The removed class comprises of the persons who have recovered or have deceased. This may also contain the persons who have acquired immunity in some manner. The model equations are given below: Here, N is the total population given as The flow in this model is given as S ! I ! R. The parameter, b is the rate of infection or the rate at which individuals in the S-class is transferred to the I-class. Similarly, c is the rate of recovery, which means the rate at which the individuals from the I-class are transferred to the R-class. This basic model has been used to derive many other models for characterizing epidemics. There are many works in the related literature that discuss this model [6, 14] . The SIR-F model is another variant of the SIR model. It splits the R-class and creates another class for the deceased persons called the F (fatality)-class. The resulting model has four differential equations as compared to the three equations of the SIR model. The equations are as given below: Here, l is the mortality rate. This model is also used in analyzing COVID-19 [6] . We use these two models to develop their equivalent electronic circuits. The methodology and theoretical aspects related to the development of these circuits are explained in the following section. Differential equations can be modelled into electronic circuits using Opamps. An integrator can be used to represent a differential equation. Consider the integrator circuit given in figure 1 . For this circuit the relation between the input voltage (V IN ) and the output voltage (V OUT ) is given as Equivalently, This can be used to model the differential equations of the compartmental models of epidemics as is demonstrated in the following subsection. In figure 2 , we have depicted an equivalent electronic circuit representing the SIR model. Three integrators are built with opamps, OA1, OA2 and OA3 with the corresponding outputs S, I and R respectively. Obviously, the inputs to these opamps will be À dS dt , À dI dt and À dR dt respectively. The analog multiplier A1 multiplies the signals, S and I. Two inverters using OA4 and OA5 are used for getting the outputs I and R. Also, the following equations hold: Also, R 5 ¼ R 6 and R 7 ¼ R 8 for unity gain inverters. In figure 3 , the electronic circuit for SIR-F model is depicted. This circuit has four outputs S, I, R and F corresponding to the four population states of the SIR-F model. These four values are obtained at the outputs of the integrators represented by OA1, OA2, OA3 and OA4 respectively. If we consider Eqn. (2), the following identities hold for this circuit. Also, R 5 ¼ R 6 and R 7 ¼ R 8 for unity gain inverters. In this section, we discuss about the simulation of these above circuit models and the results obtained for them. We have used the Multisim circuit simulation software by National Instruments to simulate these circuits. Given in figure 4 are the waveform plots for the SIR model circuit depicted in figure 2 . The circuit simulation is done using Multisim. The population value is normalized to one. Thus, we have chosen an initial value of 0.997 for S. Also, I ¼ 0:03 and R ¼ 0, initially. These correspond to 99.7%, 0.3% and 0% of the population respectively for S , I and R. Also, the parameters, b ¼ 0:4 and c ¼ 0:04. From Eqn. (5) and figure 2, for a normalized value of the population, we have b ¼ 1 . We have chosen, because the magnitude of the first term in the equation for I is the same as the magnitude of the equation for S . The value of R 3 and R 4 are 25 X for the given value of c ¼ 0:04 and choosing the capacitor C 3 as 1mF. The inverter resistors are chosen such that R 5 ¼ R 6 and R 7 ¼ R 8 , for unity gain inversion. As can be seen, the recovered population approaches 100% after sometime with an intermediate short burst of infection, which dies down after sometime (green). This is so because in this model, once an individual is infected, he will not catch an infection again and will be moved to the R class from the I class. Thus, all individuals in the S class ultimately move to the R class. The waveforms obtained at the outputs of this electronic circuit is compared to that obtained by exact mathematical model. The differential equation of the SIR model given in Eqn. (1) are simulated using Python programming language. The same set of parameters are chosen for the simulation. It can be seen that the waveforms obtained from the electronic circuit follow a similar pattern as is obtained from the mathematical model. Further tuning of the circuit could bring it to an identical behavior as is the SIR model simulation. But what is remarkable is that a physical electronic realization of the dynamics of this model can be realized (figure 5). The waveform plots from the simulation of the electronic circuit of the SIR À F model given in figure 3 is shown in figure 5 . The values of the parameters are chosen as b ¼ 0:4, c ¼ 0:035 and l ¼ 0:005, where l is the mortality rate. Here again, we make use of a normalized population. The values of the resistors R 1 , R 2 and the capacitors C 1 ; C 2 ; C 3 are the same as that for the circuit for the SIR model. Similarly, R 3 ¼ R 5 ¼ 28:57 X, which is determined by the new value of c ¼ 0:035 according to Eqn. (5) . For, l ¼ 0:05, the values of the resistances R 4 and R 6 is 20 X. The values of the resistors R 7 ; R 8 ; R 9 ; R 1 0; R 1 1 and R 1 2 of the inverters are identical. In practice, it may sometimes be necessary to adjust the gains of these inverters to compensate for any parasitic effects in the circuit. Remarkably the dynamics of the compartmental model is essentially captured by this circuit also. This is demonstrated in figure 6 , where we have given the observed outputs from the simulation of the circuit using Multisim. b ¼ 0:4 corresponds to a very high infection rate. Thus, we can see that a mortality rate of around 15% is sustained in this model for the chosen set of parameters. In figure 7 , we have given the graph of the compartmental model plotted using Python. Our circuit could be seen to follow this model almost identically. In this paper, we have developed electronic circuits to simulate the behavior of the SIR and SIR-F compartmental models that capture the population dynamics in epidemiological studies. These models and their variants are relevant in the current context of the pandemic, COVID-19. This pioneering work for the realization of the dynamical models for epidemiological models as analog electronic circuits will no doubt pave the way for further studies in the direction of analog computation and processing of the epidemiological models through equivalent real physical systems. More sophisticated models can also be implemented as electronic circuits through careful design. This is a novel area of research and modelling in epidemiological studies. Lecons sur la theorie mathematique de la lutte pou lavie A combination of differential equations and convolution in understanding the spread of an epidemic Population interactions modelled by bond graphs Mathematical modelling of the dynamics and containment of COVID-19 in Ukraine Using the SIR Model and Machine Learning in Smart Health Care Analysis of COVID-19 spreading in South Korea using the SIR model with time-dependent parameters and deep learning, COVID-19 SARS-CoV-2 preprints from medRxiv and bioRxiv Modified SEIR and AI prediction of the epidemics trend of COVID-19 in China under public health interventions Comparative prediction of confirmed cases with COVID-19 pandemic by machine learning, deterministic and stochastic SIR models Contribution to COVID-19 spread modelling: a physical phenomenological dissipative formalism Three steps to chaos -Part 2: A Chua's circuit primer (PDF) Not Your Father's Analog Computer A Contribution to the Mathematical Theory of Epidemics Mathematical modeling for infectious viral disease: The COVID-19 perspective The authors are thankful to the Institute of Research and Consulting Studies at the King Khalid University, Abha for supporting this research through the Grant Number 40-85-S-2020.