Flu Disease

No preview image

1 collaborator

Default-person Ryan Hoy (Author)

Tags

(This model has yet to be categorized with any tags)
Visible to everyone | Changeable by the author
Model was written in NetLogo 6.0.4 • Viewed 169 times • Downloaded 15 times • Run 0 times
Download the 'Flu Disease' modelDownload this modelEmbed this model

Do you have questions or comments about this model? Ask them here! (You'll first need to log in.)


WHAT IS IT?

This is a simulation to model the spread of the flu disease based off of different factors within a population.

HOW IT WORKS

The model uses data coming from sliders to affect the impact of a disease on a population.

HOW TO USE IT

Set your sliders to determine the factors of the population and the properties of the disease. After you have set the slider, click "setup" and then click "go". Try to do many different test runs for the best results.

THINGS TO NOTICE

Use the monitors and the to see how many sick, healthy, and immune people there are at any given time.

THINGS TO TRY

Try experimenting with the sliders like the number of people, radius and infection chance of the disease, etc.

EXTENDING THE MODEL

I could add doctors that move around and vaccinate people. Also, another interesting feature I could add is people that choose to not be vaccinates or to not vaccinate their children

NETLOGO FEATURES

I created a breed called "people" so that I can call them easier and I also added "age" to the turtles so they can die of old age.

RELATED MODELS

Check the netLogo models library for more virus simulations.

CREDITS AND REFERENCES

https://www.cdc.gov/flu/about/burden/2017-2018.htm

https://www.cdc.gov/flu/about/disease/65over.htm

Comments and Questions

Please start the discussion about this model! (You'll first need to log in.)

Click to Run Model

breed [people person]
turtles-own [age]

to setup
  ca
  reset-ticks
  create-people numPeople[
    set shape "person"
    setxy random-xcor random-ycor
    set color blue
  ]
  ask n-of (%PeopleInfected / 100 * count people) people [set color red]
  ask n-of numClinics patches [set pcolor white]
  ask n-of (numPeople / 2 ) people [set shape "woman"]
end 

to move
  ask turtles[
    fd 1
    rt random 91 - 45
  ]
end 

to go
  tick
  move
  infectPerson
  death
  vaccinate
  heal
  reproduce
  Oldness
  if not any? turtles with [color = red] [stop]
end 

to heal
  ask people with [color = red]
  [
    if (breed = people) [
        if (random 100 < chanceOfRecovering and color != white) [set color blue]
      ]
    ]
end 

to infectPerson
  ask people with [color = red]
  [
    if (breed = people) [
      ask people in-radius radiusOfInfection [
        if (random 100 < chanceOfInfection and color != white) [set color red]
      ]
    ]
  ]
end 

to death
  ask turtles with [color = red]
  [ifelse (age > 65 or age < 3)
      [if random 20 = 0 [die]]
      [if random 10 = 0 [die]]
  ]
end 

to vaccinate
  ask turtles with [color = blue and pcolor = white]
  [set color white]
end 

to reproduce
  ask people with [shape = "woman" and age > 18]
  [
    if any? people-here with [shape = "person" and age > 18] and count people-here with [shape = "person"] = 1
    [
      hatch 1 [
        set shape one-of ["person" "woman"]
        set age 1
        set color blue
        print "birth"
      ]
    ]
  ]
  ask people with [shape = "person" and age > 18]
  [
    if any? people-here with [shape = "woman" and age > 18] and count people-here with [shape = "person"] = 1
    [
      hatch 1 [
        set shape one-of ["person" "woman"]
        set age 1
        set color blue
      ]
    ]
  ]
end 

to Oldness
  ask turtles [
    if age > maxAge
    [die]
    set age age + 1
  ]
end 

There is only one version of this model, created about 5 years ago by Ryan Hoy .

Attached files

File Type Description Last updated
Screen Shot 2019-02-20 at 2.58.03 PM.png png Image of Simulation about 5 years ago, by Ryan Hoy Download

This model does not have any ancestors.

This model does not have any descendants.