SIR model

Click Here to Download this Answer Instantly

visual studio
For this, you will be designing and implementing a system, in either C or C++, to simulate an outbreak across a geographic area. Specifically, you will be using a cellular automata, with a Moore Neighborhood Configuration, to model geographic region, and a SIR model to model the health states of the populace. Your model should visually output how the region’s population changes over time, the final S, I, R, V counts, the day of the outbreak’s peak, and the day the outbreak ended.
Your program must provide the following functionality and adhere to the following constraints:
-Allow the user to choose the file describing the initial setup of the simulation
-The first line indicates the required number of infectious agents in a susceptible agent’s neighborhoodfor the susceptible agent to become infectious on the next day
The second line indicates how many days an agent remains infectious before it becomes recovered on the following day, i.e. if the infectious period is 2, then the agent becomes recovered after being infectious for 2 days
-The third line indicates the display frequently for how frequently the region should be displayed in days
-All subsequent lines will indicate the starting health states of the different agents in the region:
s: susceptible
i: infectious
r: recovered
v: vaccinated
-Agents that are one square away from some other agent are considered to be in that agent’s neighborhood
-Agents on the left and right boundaries of the region should be considered adjacent, i.e. the region is not a flatmap but more like a cylinder
-An agentcan have one of four health states: susceptible, infectious, recovered, vaccinated
-An agent can only move through the states as follows: S > I > R
-A susceptible agent becomes infectious if they have threshold or greater number of infectious agents in their neighborhood on any given day
-An infectious agent becomes recovered after infectious period number of days
-Vaccinated agents are permanently vaccinated and cannot change states
-The simulation should run untilthe number of infectious agents is 0, indicating the outbreak has ended
– There should only be S, R, and/or V agents left over
-The initial setup of the region represents the simulation at day 0
-Your program should output the following:
-The initial status of the region
i.e. day 0
-The status of the region every X days, where X is the display frequency from the input file
-The final state of the region once the outbreak has ended, i.e. the first day that there are 0 infectiousagents
-The final counts of the number of susceptible, infectious, recovered, and vaccinated agents once the outbreak has ended, i.e. the first day that there are 0 infectious agents
-The day the outbreak ended
-The first day of the outbreak’s peak in terms of number of infectious agents, i.e. the firstday with the highest count of infectious agents