Beginners Interactive NetLogo Dictionary (BIND)
Farsi / Persian
NetLogo Models Library:
This model demonstrates one way to locate a continental divide. A continental divide separates a continent into two regions based on two bodies of water. Rain in one region flows into one body of water and rain in the other region flows into the other.
In the example data, the continent is North America and the two bodies of water used to calculate the divide are the Pacific and Atlantic oceans.
The model is initialized with an elevation map. Then both oceans systematically rise, bit by bit. The two floods run towards each other over the continent and eventually crash. The continental divide is precisely where the two floods collide.
SETUP initializes the model. Elevations are stored in the patches and they are colored appropriately. Also, the two floods are started off on the coasts.
GO runs the model. When the floods cannot advance any more with the given height of the water, the water level is raised a little bit. Eventually, when the whole continent has been flooded and the continental divide has been found, the model stops automatically.
The two floods move at different rates.
The first 100 meters of flood covers more land than the last 100 meters. What about in between?
Land that's flooded later isn't necessarily higher elevation. (Why?)
Use the speed slider to slow the model down and watch what happens in more detail.
Increase the patch-size to get a better view of the action. (Because the elevation data assumes specific dimensions, you can't change the number of patches in the model.)
Make a slider to control how much water-height changes when the flooding at a given water-height has stopped.
Make a slider for controlling how many colors from FLOODED-GROUND-COLOR-LIST get used. With a smaller number, the flooded land's elevation is easier to see. With a larger number, the progression of flooding is easier to see.
Is there a difference if
neighbors is used instead of
neighbors4? Make a switch to toggle between the two options and compare them.
Try the model with a more detailed dataset.
Allow the user of the model to specify different bodies of water than the Atlantic and Pacific oceans. For example, it'd be interesting to see which water flows into the Gulf of Mexico and which flows into the Atlantic.
Allow the user to import maps of other parts of the world.
Note the use of turtles to represent the edges of the flood. Instead of asking all the patches to find the ones on each edge, we only need to ask the turtles to act. Since at any given moment only a few patches are at a flood edge, this is much faster.
Note the used of
foreach on multiple lists to initialize the elevation data in the patches.
This model was inspired by Brian Hayes' article "Dividing the Continent" in American Scientist, Volume 88, Number 6, page 481. An online version can be found here: https://www.jstor.org/stable/27858114
Thanks to Josh Unterman for his work on this model.
If you mention this model or the NetLogo software in a publication, we ask that you include the citations below.
For the model itself:
Please cite the NetLogo software as:
Copyright 2007 Uri Wilensky.
This work is licensed under the Creative Commons Attribution-NonCommercial-ShareAlike 3.0 License. To view a copy of this license, visit https://creativecommons.org/licenses/by-nc-sa/3.0/ or send a letter to Creative Commons, 559 Nathan Abbott Way, Stanford, California 94305, USA.
Commercial licenses are also available. To inquire about commercial licenses, please contact Uri Wilensky at email@example.com.