Simple Urban ABM
Do you have questions or comments about this model? Ask them here! (You'll first need to log in.)
WHAT IS IT?
This simple urban ABM let's you explore how different agent types and their interactions influence growth patterns.
HOW IT WORKS
The urban ABM considers three land cover classes: built-up, agriculture, green. The landscape is represented by square cells.
During setup, built-up area is randomly distributed within concentric rings around the middle of the landscape, with density decreasing towards the outskirts of the city. Green and agricultural areas are randomly assigned in larger clusters. This city serves as the starting point for further urban growth.
The agents in the model represent newcomers entering the city and settling in a new home. We distinguish three agent types: - Young professionals - Families - Retirees The three agent types have different preferences for living close to green space and close to the city center (called CBD - central business district - in the user interface). Agents can only settle on agricultural land and turn this into built-up land.
Agents take their decisions based on perceived utility of the available land. The utility of a spot is calculated as
utility = preference-for-green * (1 - distance to green) + preference-for-CBD * (1 - distance to CBD)
The distance values are standardised so that their minimum values are 0 and their maximum values are 1.
The preferences are as follows: - Young professionals: preference for green 0; preference for city centre 1 - Families: preference for green 1; preference for city centre 1 - Retirees: preference for green 1; preference for city centre 0
Agents move to the spot with the highest utility. If there is a draw among spot, one of these spots is randomly chosen.
HOW TO USE IT
Start with section "Setup and explore city". Once you have familiarized yourself with thecity, explore the buttons on the right: "Run ABM in steps". You can decide how many agents shall enter the simulation in one time step. You can also decide which type(s) shall enter the city. You do so by turning on or off each agent type
Press the button "newcomers find homes" to let agents decide new locations in one time step. You can investigate which type is located where by pressing the button "show-newcomer-types".
THINGS TO NOTICE
How does the urban landscape develop if you only let one of the types enter? How does that change if you let only another type enter?
THINGS TO TRY
Explore what happens when you decrease the number of agents entering per time step. Does the spatial pattern of agent types change?
EXTENDING THE MODEL
There are many ways this simple agent-based model could be extended.
Obviously, we could add spatial data to create a real-world case study. The decision-making of the agents could be more complex, and different types could be introduced. And we could export the city landscapes we have created for further use in a GIS.
NETLOGO FEATURES
RELATED MODELS
CREDITS AND REFERENCES
This model was written by Nina Schwarz to teach about urban agent-based models. Please cite as follows: Schwarz, N. (2025): Urban growth agent-based model.
License for this model: CC BY 4.0, https://creativecommons.org/licenses/by/4.0/
Comments and Questions
turtles-own [ settled? pref-CBD pref-green] breed [young-professionals young-professional] breed [families family] breed [retirees retiree] globals [number-newcomers] patches-own [landcover distance-cent distance-green utility] ; landcover classes: built-up, agri, green to setup clear-all random-seed random-number set number-newcomers 500 ask patches [ set landcover "agri"] ask patch 0 0 [ ask n-of 200 patches in-radius 30 [ set landcover "built-up" ] ] ask patch 0 0 [ ask n-of 100 patches in-radius 10 [ set landcover "built-up" ] ] ask patch 0 0 [ ask n-of 20 patches in-radius 50 [ set landcover "built-up" ] ] ask patches with [ landcover != "built-up"] [set landcover one-of ["agri" "green" "agri"] ] ;; Inspired by code example Patch Clusters repeat 20 [ ask patches ; with [ landcover != "built-up"] [ set landcover [landcover] of one-of neighbors4 ] ] ; then impose the city on top again ask patch 0 0 [ ask n-of 200 patches in-radius 30 [ set landcover "built-up" ] ] ask patch 0 0 [ ask n-of 100 patches in-radius 10 [ set landcover "built-up" ] ] ask patch 0 0 [ ask n-of 20 patches in-radius 50 [ set landcover "built-up" ] ] show-landcover ; calculate distance to center ask patches [ set distance-cent distance patch 0 0 ] let max-dc max [ distance-cent ] of patches ask patches [ set distance-cent ( distance-cent / max-dc ) ] ; calculate distance to green ask patches [ set distance-green 0 ] ask patches with [ landcover != "green"] [ let dist 1 while [ distance-green = 0 ] [ if any? patches in-radius dist with [ landcover = "green"] [ set distance-green dist] set dist ( dist + 1) ] ] ; min-max standardisation let max-dg max [ distance-green] of patches ask patches [set distance-green (distance-green / max-dg ) ] ask patches [ set utility 0 ] set-default-shape turtles "circle" reset-ticks end to go ; create new agents per type create-newcomers ; get the unsettled ones settled, change the landcover ifelse ( order-of-newcomers-choice = "young professionals first" ) [ ask young-professionals with [ settled? = false ] [ settle-somewhere] ask families with [ settled? = false ] [ settle-somewhere] ask retirees with [ settled? = false ] [ settle-somewhere] ] [ifelse ( order-of-newcomers-choice = "families first") [ ask families with [ settled? = false ] [ settle-somewhere] ask young-professionals with [ settled? = false ] [ settle-somewhere] ask retirees with [ settled? = false ] [ settle-somewhere] ] [ ask turtles with [ settled? = false ] [ settle-somewhere] ] ] show-landcover tick end to create-newcomers let count-types 0 if (enter-young-professionals = true) [ set count-types count-types + 1 ] if (enter-families = true) [ set count-types count-types + 1 ] if (enter-retirees = true) [ set count-types count-types + 1 ] if count-types > 0 [ if (enter-young-professionals = true) [ add-young-professionals round number-newcomers / count-types ] if (enter-families = true) [ add-families round number-newcomers / count-types ] if (enter-retirees = true) [ add-retirees round number-newcomers / count-types ] ] end to add-young-professionals [number] create-young-professionals number [ set settled? false set pref-CBD 1 set pref-green 0 set color blue set hidden? true ] end to add-families [number] create-families number [ set settled? false set pref-CBD 1 set pref-green 1 set color gray set hidden? true ] end to add-retirees [number] create-retirees number [ set settled? false set pref-CBD 0 set pref-green 1 set color black set hidden? true ] end to settle-somewhere ; 1. identify which cells can be changed let usable-patches patches with [ landcover = "agri"] let temp-pref-CBD pref-CBD let temp-pref-green pref-green ; 2. calculate utility of these patches ask usable-patches [ set utility ( ; FIXME temp-pref-CBD * (1 - distance-cent) + temp-pref-green * (1 - distance-green) ) ] ;3. move to patch with highest utility let my-home max-one-of usable-patches [utility] ask my-home [ set landcover "built-up" ] move-to my-home set settled? true end to show-landcover ask patches with [ landcover = "agri"] [ set pcolor yellow ] ask patches with [ landcover = "built-up"] [ set pcolor red] ask patches with [ landcover = "green"] [ set pcolor green] ask turtles [ set hidden? true ] end to show-dist-CBD ask patches [set pcolor scale-color black distance-cent 1 0 ] end to show-newcomer-types ask turtles [ set hidden? false set size 2] end
There is only one version of this model, created about 17 hours ago by Gianluc Ambros.
Attached files
No files
This model does not have any ancestors.
This model does not have any descendants.
Download this model