Fleeing From Fire
Do you have questions or comments about this model? Ask them here! (You'll first need to log in.)
WHAT IS IT?
ABM of evacuation from a burning rock concert hall. Source: Chapter 4 Crushing in David Knoke. 2025. Network Collective Action: Agent-Based Models of Pandemics, Riots, Social Movements, Insurrections and Insurgencies. Cham, Switzerland: Springer Nature.
HOW IT WORKS
Blue agents are concert attenders randomly scattered around the hall. When fire begins, all agents move toward the nearest of three exits. As they converge on an exit, the density of people occuping a patch may rise to a level where death from compression asphyxiation occurs.
HOW TO USE IT
Set the DieNumber between 2 and 10. When a patch is occupied by N blue agents, one dies randomly and turns black. If a blue agent reaches an exit door, it turns green and goes outside.
THINGS TO NOTICE
Are agents closert to an exit more likely to survive than agents farther away?
THINGS TO TRY
What happens to the death and survival rates when the DieNumber is raised or lowered? Use the N-Attenders slide to vary the size of the audience. How do the death and survival rates change with crowd density?
EXTENDING THE MODEL
What would be the outcome if some agents move at a slower speed than others, for example, older and disabled attenders?
NETLOGO FEATURES
RELATED MODELS
Alazbah, Afnan and Bassam Zafar. 2019. “Pilgrimage (Hajj) Crowd Management Using Agent-Based Method.” International Journal on Foundations of Computer Science & Technology 9:1-17.
Liu, Yuanyuan and Toshiyuki Kaneda. 2020. “Using Agent-Based Simulation for Public Space Design Based on the Shanghai Bund Waterfront Crowd Disaster.” Artificial Intelligence for Engineering Design, Analysis and Manufacturing 34(2):176-190.
Young, Eileen and Benigno Aguirre. 2021. “PrioritEvac: An Agent-Based Model (ABM) for Examining Social Factors of Building Fire Evacuation.” Information Systems Frontiers 23:1083-1096.
CREDITS AND REFERENCES
Comments and Questions
;; Fleeing From Fire ;; David Knoke, University of Minnesota ;; August 16, 2024 breed [attenders attender] ;; People try to leave the enclosed room when a fire breaks out breed [flames flame] ;; The stage is on fire!! globals [ colors initial-blue initial-green bluepct greenpct escapedpct ;; percent escaped crushedpct ;; percent crushed exit-1-x exit-1-y exit-2-x exit-2-y exit-3-x exit-3-y interior-patches ;; Inside of building exterior-patches ;; Outside of building number-attenders number-crushedattenders number-escapedattenders ] attenders-own [ target-exit escaped-attender? crushed-attender? ] to setup clear-all ;; Create interior-patches colored white set interior-patches patches with [ (pycor < 25 and pycor > -20) and (pxcor > -20 and pxcor < 20) ] ask interior-patches [set pcolor white] ;; Create exterior-patches colored yellow set exterior-patches patches with [ (pxcor < -20) or (pxcor > 20) or (pycor < -20) ] ask exterior-patches [set pcolor yellow] ;; Create flames on stage at top of room create-flames 1 [setxy 3 27 set shape "fire" set size 6] create-flames 1 [setxy -3 27 set shape "fire" set size 6] draw-walls initialize-attenders initialize-exits set-target-exits reset-ticks end to draw-walls ;; Make 4 walls , color interior white ask patches with [ (pxcor = 20 and pycor > -20 ) or (pxcor = -20 and pycor > -20) ] [set pcolor black] ask patches with [ pycor = 25 and ((pxcor > -21) and (pxcor < 21)) ] [set pcolor black] ask patches with [ pycor = -20 and ((pxcor > -21) and (pxcor < 21)) ] [set pcolor black] ask patches with [ pxcor = 20 and (pycor > 9 and pycor < 13) ] [set pcolor pink] ask patches with [ pxcor = -20 and (pycor > 9 and pycor < 13) ] [set pcolor pink] ask patches with [ pycor = -20 and (pxcor > -3 and pxcor < 3) ] [set pcolor pink] end to initialize-attenders ;; Create N attenders based on slide, then moving to random location inside building create-attenders N-Attenders [ set shape "person" set color blue setxy random-xcor random-ycor set size 3 set escaped-attender? false set crushed-attender? false set target-exit "" move-to one-of interior-patches ;; Count number of attenders of each color set initial-blue count attenders with [color = blue] ;; attenders inside club set initial-green count attenders with [color = green] ;; escaped ] end to initialize-exits set exit-1-x 20 set exit-1-y 11 set exit-2-x -20 set exit-2-y 11 set exit-3-x 0 set exit-3-y -20 end to set-target-exits ;; Attenders target the exit in their quadrant ask attenders [ if xcor >= 0 and ycor >= 0 [ set target-exit "exit 1" ] if xcor <= 0 and ycor >= 0 [ set target-exit "exit 2" ] if ycor <= 0 [ set target-exit "exit 3" ] ] end to go ;; Stop when no attenders remain in building if (count attenders with [color = blue] = 0) [stop] move deathattenders tally tick end to move ask attenders with [escaped-attender? = false] [ go-toward-exits ] end to go-toward-exits if target-exit = "exit 1" [ facexy 20 11 ifelse xcor < 20 [ forward 0.1 ] [ if target-exit = "exit 1" [ facexy exit-1-x exit-1-y ifelse xcor <= exit-1-x and ycor <= exit-1-y [ forward 0.1 ] [ set color green let yellow-patches (patches in-radius 10 with [pcolor = yellow] ) move-to one-of yellow-patches set escaped-attender? true ] ] ] ] if target-exit = "exit 2" [ facexy -20 11 ifelse xcor > -20 [ forward 0.1 ] [ if target-exit = "exit 2" [ facexy exit-2-x exit-2-y ifelse xcor >= exit-2-x and ycor >= exit-2-y [ forward 0.1 ] [ set color green let yellow-patches (patches in-radius 10 with [pcolor = yellow] ) move-to one-of yellow-patches set escaped-attender? true ] ] ] ] if target-exit = "exit 3" [ facexy -0 -20 ifelse xcor > 0 [ forward 0.1 ] [ if target-exit = "exit 3" [ facexy exit-3-x exit-3-y ifelse xcor <= exit-3-x and ycor >= exit-3-y [ forward 0.1 ] [ set color green let yellow-patches (patches in-radius 10 with [pcolor = yellow] ) move-to one-of yellow-patches set escaped-attender? true ] ] ] ] end ;;to crush ;; ask attenders with [count attenders-here >= DieNumber] ;; [ask one-of attenders-here [set color black] ;; ] ;;end to deathattenders ask attenders with [count turtles-here >= DieNumber] [ask one-of attenders-here [set color black] ] ask attenders with [color = black] [ set number-crushedattenders number-crushedattenders + 1 set number-escapedattenders initial-blue - number-crushedattenders ;; die ] end to tally ;; Percentages for BehavioralSpace experiments set bluepct count (attenders with [color = blue]) / (count attenders) * 100 set greenpct count (attenders with [color = green]) /(count attenders) * 100 set escapedpct count attenders with [color = green] / initial-blue * 100 set crushedpct count attenders with [color = black] / initial-blue * 100 end
There is only one version of this model, created 3 months ago by David Knoke.
Attached files
File | Type | Description | Last updated | |
---|---|---|---|---|
Fleeing From Fire.png | preview | Preview for 'Fleeing From Fire' | 3 months ago, by David Knoke | Download |
This model does not have any ancestors.
This model does not have any descendants.