Movilidad y propagacion de virus
Model was written in NetLogo 6.2.0
•
Viewed 152 times
•
Downloaded 16 times
•
Run 0 times
Do you have questions or comments about this model? Ask them here! (You'll first need to log in.)
Info tab cannot be displayed because of an encoding error
Comments and Questions
Please start the discussion about this model!
(You'll first need to log in.)
Click to Run Model
;:::::::::::::::::::::::::::::::::::::::::::::::: P R O P A G A C I Ó N D E V I R U S ::::::::::::::::::::::::::::::::::::::::::::::::::: ;::::::::::::::::::::::::::::::::::::::::::::::::Código y diseño: Dr. Javier Sadoval Félix::::::::::::::::::::::::::::::::::::::::::::::::::: ;::::::::::::::::::::::::::::::::::::::::::::::::::::Contacto: jarquisol@gmail.com::::::::::::::::::::::::::::::::::::::::::::::::::::::::::: globals [camas-disponibles] turtles-own [ enferma? inmune? movil? tiempo-enfermo tiempo-restante-para-internarse] to setup clear-all preparar-tortugas actualizar-visualizacion set camas-disponibles camas reset-ticks end to go ask turtles [ if movil? [fd .3] if enferma? [ infectar set tiempo-enfermo tiempo-enfermo + 1 set tiempo-restante-para-internarse tiempo-restante-para-internarse - 1 if tiempo-restante-para-internarse = 0 [ set camas-disponibles camas-disponibles - 1 set hidden? true] ] if enferma? and tiempo-enfermo = 300 [ set enferma? false set inmune? true if hidden? [set camas-disponibles camas-disponibles + 1] set hidden? false if movil? = false [set movil? true] ]] actualizar-visualizacion if count turtles with [enferma?] = 0 [ user-message "Ya no hay población enferma" stop] if camas-disponibles = 0 [ user-message "Ya no hay camas disponibles" stop] tick end to preparar-tortugas create-turtles poblacion [ setxy random-xcor random-ycor set movil? true set size 1 set shape "circle" set color green set inmune? false saludable ] ask n-of (poblacion * (%poblacion-fija / 100)) turtles [set movil? false] ask n-of 1 turtles with [movil? = true] [ enfermarse set tiempo-restante-para-internarse random 300] end to actualizar-visualizacion ask turtles [ ifelse enferma? [set color red ] [ifelse inmune? [set color grey ] [set color green]] ] end to saludable set enferma? false end to enfermarse set enferma? true set tiempo-enfermo tiempo-enfermo + 1 end to infectar if hidden? = false [ ask other turtles-here with [ not enferma? and not inmune? ] [ enfermarse set tiempo-restante-para-internarse random 150 ]] end
There is only one version of this model, created over 3 years ago by Javier Sandoval.
Attached files
File | Type | Description | Last updated | |
---|---|---|---|---|
Movilidad y propagacion de virus.png | preview | Preview for 'Movilidad y propagacion de virus' | over 3 years ago, by Javier Sandoval | Download |
This model does not have any ancestors.
This model does not have any descendants.