; { Modifications from the original Wealth Distribution Model made by } ; { Michael Gizzi, Tom Lairson and Richard Vail between July 15 and October 25, } ; { 2003 are indicated using { }. } ; { Summary of changes made. Numbers are used to correlate code changes. } ; { 1. Add the Quintile Wealth histogram. } ; { 2. Add random increase in patch productivity. } ; { - 40% chance of increase of 1 every 50 years. } ; { - to a level of max-grain } ; { 3. Add random increase in population. } ; { - 10% chance of increase of 1 when a turtle dies. } ; { - y axis number on Class Histogram is the current number of turtles. } ; { 4. Add the ability for turtles to settle and become more productive. } ; { - if wealth > 50 and max-grain-here of patch > 20 and unsettled, } ; { a turtle settles. } ; { - S appears on patch when it is settled the turtle stops. } ; { - Settlers take all the harvest, they don't share. } ; { - When settlers die their patch becomes open. } ; { 5. Add up to two employees for turtles who have settled. } ; { - unemployeed turtles on a settled patch will get a job if wealth > 10 } ; { and there are not already two employees. } ; { - productivity of land improves } ; { - the employed turtle stops. } ; { - Settler gets 50 % and employees share 50%. } ; { - When employees die a position becomes vacant. } ; { - When settlers die employees are released, but may settle immediately. } ; { 6. Minor Display Modifications } ; { - Stop each run at num-steps for comparisions } ; { - Top 1 % monitor } ; { - Add the quintile plot } ; { 7. Capture wealth for inheritance } ; { - For death by old age capture the old-wealth } ; { - transfer it to the new generation of turtles } ; { - share 50 / 50 with new siblings } ; { - add generation counter (number of times inherited wealth) } ; { - add % gen 0 monitor (percent that starved in the last life) } ; { after the first generation dies off } ; { 8. If the turtles starve 30 % of them will die. } ; { - % generation 0 indicates how inheritence is going and how many starve. } ; { 9. Add choices and buttons for various changes, for experimentation. } ; { - patch-productivity increases - on or off. } ; { - pop-growth - none, equal, starvation. } ; { - settling? - none, settlers, employees. } ; { - inherit? - on or off. } globals [ clock ; keeps the number of times through the go procedure max-grain ; maximum amount any patch can hold { 2. used for growth limit } top-one ; { 6. top one % monitor } wealthiest ; { 9. wealth of the wealthiest turtle } gini-count ] patches-own [ grain-here ; the current amount of grain on this patch max-grain-here ; the maximum amount of grain this patch can hold psettled ; { 4. patch is settled } pemployed ; { 5. number of employees } ] turtles-own [ age ; how old a turtle is wealth ; the amount of grain a turtle has life-expectancy ; maximum age that a turtle can reach metabolism ; how much grain a turtle eats each time vision ; how many patches ahead a turtle can see quintile ; { 1. the wealth quintile of each turtle } settled ; { 4. turtle has settled } employed ; { 5. turtle is employed } generation ; { 7. how many generations has this turtle inherited wealth } ] ;;; ;;; SETUP AND HELPERS ;;; to setup ca ;; set global variables to appropriate values set max-grain 50 set clock 0 ;; call other procedures to set up various parts of the world setup-patches setup-turtles setup-plots ;; plot the initial state of the world update-plots end ;; set up the initial amounts of grain each patch has to setup-patches ;; give some patches the highest amount of grain possible -- ;; these patches are the "best land" ask patches [ set max-grain-here 0 set psettled false ; { 4. patch is not settled } set pemployed 0 ; { 5. no employees to start with } if (random 100.0) <= percent-best-land [ set max-grain-here max-grain set grain-here max-grain-here ] ] ;; spread that grain around the window a little and put a little back ;; into the patches that are the "best land" found above repeat 5 [ ask patches with [max-grain-here != 0] [ set grain-here max-grain-here ] diffuse grain-here 0.25 ] repeat 10 [ diffuse grain-here 0.25 ] ;; spread the grain around some more ask patches [ set grain-here floor grain-here ;; round grain levels to whole numbers set max-grain-here grain-here ;; initial grain level is also maximum recolor-patch ] end to recolor-patch ;; patch procedure -- use color to indicate grain level set pcolor scale-color yellow grain-here 0 max-grain end ;; set up the initial values for the turtle variables to setup-turtles set-default-shape turtles "person" no-display ;; so we don't see the turtles until they're recolored cct num-people [ setxy (random screen-size-x) (random screen-size-y) set generation 0 ; { 7. start generation count at 0 } set-initial-turtle-vars set age random life-expectancy ] recolor-turtles requintile-turtles ; { 1. setup turtle quintiles } display end to set-initial-turtle-vars set age 0 rt random 360.0 set life-expectancy life-expectancy-min + random (life-expectancy-max - life-expectancy-min + 1) set metabolism 1 + random metabolism-max set wealth metabolism + random 50 set vision 1 + random max-vision set quintile "Q1" ; { 1. initialize turtle quintiles } set settled false ; { 4. initialize turtle has not settled } set label "" ; { 4. initialize turtle has not settled } set employed false ; { 5. initialize turtle is not employed } end ;; Set the class of the turtles -- if a turtle has less than a third ;; the wealth of the richest turtle, color it red. If between one ;; and two thirds, color it green. If over two thirds, color it blue. to recolor-turtles locals [max-wealth] set max-wealth max values-from turtles [wealth] set wealthiest max-wealth ; { 9. wealth of the wealthiest turtle } ask turtles [ ifelse (wealth <= max-wealth / 3) [ set color red ] [ ifelse (wealth <= (max-wealth * 2 / 3)) [ set color green ] [ set color blue ] ] ] end to requintile-turtles ; { 1. new procedure for quintile plots } ;; procedure to divide the turtles in to 5 quintiles of population based on wealth ;; Q5 are the wealthist 20% of the population - Q1 is the least wealth locals [ sorted-wealth Q5-divide Q4-divide Q3-divide Q2-divide reference index-n top-divide] set reference 0 set sorted-wealth sort values-from turtles [wealth] ; sort the turtles by wealth set sorted-wealth reverse sorted-wealth ; reverse so the wealthest is first set index-n ( floor ( 0.01 * count turtles ) ) ; { 6. find how many turtles are in 1% of the population set top-divide ( item index-n sorted-wealth ) set top-one ( 100 * ( sum values-from turtles with [wealth > top-divide] [ wealth ] ) / ( sum values-from turtles [wealth] )) set index-n ( floor ( 0.20 * count turtles ) ) ; find how many turtles are in 20% of the population set reference index-n set Q5-divide 0 set Q4-divide 0 set Q3-divide 0 set Q2-divide 0 set Q5-divide ( item index-n sorted-wealth ) ; the wealth of the turtle that is the least wealth of the top 20 % becomes } ; the break between Q5 and Q4. This means at times that if several turtles } ; near the break in a quintile have equal wealth, they will all be } ; categorized in the higher quintile. } set index-n (index-n + reference) set Q4-divide ( item index-n sorted-wealth ) set index-n (index-n + reference) set Q3-divide ( item index-n sorted-wealth ) set index-n (index-n + reference) set Q2-divide ( item index-n sorted-wealth ) ask turtles [ ifelse ( wealth >= Q5-divide ) [ set quintile "Q5" ] [ ifelse ( wealth >= Q4-divide ) [ set quintile "Q4" ] [ ifelse ( wealth >= Q3-divide ) [ set quintile "Q3" ] [ ifelse ( wealth >= Q2-divide ) [ set quintile "Q2" ] [ set quintile "Q1" ] ] ] ; Q1 is the residual ]] end ; { 1. new procedure for quintile plots } ;;; ;;; GO AND HELPERS ;;; to go set clock clock + 1 if patch-productivity = true [random-growth]; { 9. random growth on or off } if settling? = "employees" [ ; { 9. employees allowed jobs } ask turtles with [ not settled and not employed ] [ without-interruption [find-job ] ] ] ask turtles [ turn-towards-grain ] ;; choose direction holding most grain within the turtle's vision ;; grow grain every grain-growth-interval clock ticks if clock mod grain-growth-interval = 0 [ ask patches [ grow-grain ] ] harvest ask turtles [ without-interruption [ move-eat-age ; { 3. take out die } death ; { 3. new procedure for death } ifelse settling? = "none" [] ; { 9. settlers settle } [settle ]; { 4. the settle routine } ]] recolor-turtles requintile-turtles ; { 1. update for changes in quintile composition } update-plots if clock = num-steps [stop] ; {6. Stop each run at num-steps } if clock = 2 * num-steps [stop] ; { for comparisions } if clock = 3 * num-steps [stop] end ;; determine the direction which is most profitable for each turtle in ;; the surrounding patches within the turtles' vision to turn-towards-grain ;; turtle procedure locals [best-direction best-amount] set heading 0 set best-direction 0 set best-amount grain-ahead set heading 90 if (grain-ahead > best-amount) [ set best-direction 90 set best-amount grain-ahead ] set heading 180 if (grain-ahead > best-amount) [ set best-direction 180 set best-amount grain-ahead ] set heading 270 if (grain-ahead > best-amount) [ set best-direction 270 set best-amount grain-ahead ] set heading best-direction end to-report grain-ahead ;; turtle procedure locals [total how-far] set total 0 set how-far 1 repeat vision [ set total total + grain-here-of patch-at (dx * how-far) (dy * how-far) set how-far how-far + 1 ] report total end to settle ; { 4. the settle routine turtle procedure } if wealth > 50 and max-grain-here-of patch-here > 20 and psettled-of patch-here = false [ set settled true set label "S" ask patch-here [set psettled true ] ] end ; { 4. the settle routine turtle procedure } to grow-grain ;; patch procedure ;; if a patch does not have it's maximum amount of grain, add ;; num-grain-grown to its grain amount if any turtles-here with [ settled ] ; { 4. Setters grow twice as much } [ set grain-here grain-here + num-grain-grown ] ; { if there is capacity } if any turtles-here with [ employed ] ; { 5. employees grow even more } [ set grain-here grain-here + (( pemployed * 2 * num-grain-grown ) + pemployed ) ] if (grain-here < max-grain-here) [ set grain-here grain-here + num-grain-grown ;; if the new amount of grain on a patch is over its maximum ;; capacity, set it to its maximum if (grain-here > max-grain-here) [ set grain-here max-grain-here ] recolor-patch ] end ;; each turtle harvests the grain on its patch. if there are multiple ;; turtles on a patch, divide the grain evenly among the turtles to harvest ; have turtles harvest before any turtle sets the patch to 0 ask turtles ; { 4. distribution rule changes if patch is settled } [ ifelse value-from patch-here [psettled] = false [ set wealth floor (wealth + (grain-here / (count turtles-here))) ] [ ifelse pemployed-of patch-here > 0 [ ask turtles-here with [settled] [ set wealth wealth + ( grain-here * 0.50 ) ; { 5. settlers with employees } ] ; { 5. share grain 50/50 with employees } ask turtles-here with [employed] [ set wealth wealth + (( grain-here * 0.50 ) / count turtles-here with [employed] ) ] set grain-here 0 ] [ ask turtles-here with [settled] [set wealth wealth + grain-here ; { 4. settler takes it all } set grain-here 0 ] ] ] ] ;; now that the grain has been harvested, have the turtles make the ;; patches which they are on have no grain ask turtles [ set grain-here 0 recolor-patch ] end to move-eat-age ;; turtle procedure { 3. the old move-eat-age-die } ; { 3. without death } if settled = false and employed = false ; { 4. the settlers stop moving} [fd 1] ; { 5. the employees stop moving} ;; consume some grain according to metabolism set wealth (wealth - metabolism) ;; grow older set age (age + 1) end to death ; { 3. new procedure for death } ;; check for death conditions: if you have no grain or ;; you're older than the life expectancy or if some random factor ;; holds, then you "die" and are "reborn" (in fact, your variables ;; are just reset to new random values) locals [old-wealth] ; { 7. Capture wealth for inheritance } if (wealth < 0) [ ; { 7. Split death conditions } set generation 0 ; { 8. restart generations } kill-settler ; { 4. new procedure for settler death } kill-employee ; { 5. new procedure for employee death } if pop-growth = "starvation" [ ; { 9. allow population reduction } ifelse random 100 < 30 [die] ; { 8. 30 % of the time they just die } [hatch 1 [set-initial-turtle-vars] die ] ] if pop-growth = "equal" [ ; { 8. 10 % of the time they double } ifelse random 100 < 10 [hatch ( 1 + ( random 2 ) ) [ set-initial-turtle-vars ] die ] [ set-initial-turtle-vars ] ] if pop-growth = "none" [set-initial-turtle-vars] ] if (age >= life-expectancy) [ set old-wealth wealth set generation generation + 1 kill-settler ; { 4. new procedure for settler death } kill-employee ; { 5. new procedure for employee death } ifelse pop-growth = "none" [set-initial-turtle-vars] [ ifelse random 100 < 10; { 3. chance of population increase } [ hatch ( 1 + ( random 2 ) ) [ set-initial-turtle-vars if inherit? = true [set wealth floor (old-wealth / 2)] ] ; { 7. siblings share old wealth } die ] [ set-initial-turtle-vars if inherit? = true [set wealth old-wealth] ] ] ] end ; { 3. new procedure for death } to kill-settler ; { 4. new procedure for settler death } if settled = true [ set psettled-of patch-here false ask turtles-here [ set employed false ; { 5. to take care of employees } set pemployed-of patch-here 0 ] ] end ; { 4. new procedure for settler death } to kill-employee ; { 5. new procedure for employee death } if employed = true [ set pemployed-of patch-here pemployed - 1 ] end ; { 5. new procedure for employee death } to random-growth ; { 2. new procedure for random growth } every 50 [ ask patches [ if random 100 < 40 [ set max-grain-here max-grain-here + 1 ] if max-grain-here > max-grain [ ; { 2. limits max-grain-here to max-grain } set max-grain-here max-grain ] ] ] end ; { 2. new procedure for random growth } to find-job ; { 5. new turtle procedure for employment } if wealth > 10 ; criteria for being employeed [ if psettled-of patch-here and pemployed-of patch-here < 2 ; maximum of two employees [ ask turtles-here with [settled] [ if wealth > 50 [ set pemployed pemployed + 1 set employed-of myself true ] ] ] ] end ; { 5. new turtle procedure for employment } ;;; ;;; PLOTTING ;;; to setup-plots set-current-plot "Class Plot" set-plot-y-range 0 count turtles ; { 3. Replace num-people with count turtles. } set-current-plot "Class Histogram" set-plot-y-range 0 count turtles ; { 3. Replace num-people with count turtles. } set-current-plot "Quintile Wealth" ; { 1. setup turtle quintile plot } set-plot-y-range 0 100 ; { 1. setup turtle quintile plot } end to update-plots update-class-plot update-class-histogram update-lorenz-and-gini-plots update-quintile-histogram ; { 1. update turtle quintile plot } end to update-quintile-histogram ; { 1. sums the wealth of members of each quintile } locals [ total-wealth ] ; { and makes it a percentage of the total } set total-wealth sum values-from turtles [ wealth ] set-current-plot "Quintile Wealth" plot-pen-reset set-plot-pen-color black plot ( 100 * ( sum values-from turtles with [quintile = "Q1" ] [wealth] ) / total-wealth ) set-plot-pen-color black plot ( 100 * ( sum values-from turtles with [quintile = "Q2"] [wealth] ) / total-wealth ) set-plot-pen-color black plot ( 100 * ( sum values-from turtles with [quintile = "Q3" ] [wealth] ) / total-wealth ) set-plot-pen-color black plot ( 100 * ( sum values-from turtles with [quintile = "Q4" ] [wealth] ) / total-wealth ) set-plot-pen-color black plot ( 100 * ( sum values-from turtles with [quintile = "Q5" ] [wealth] ) / total-wealth ) set-plot-y-range 0 100 end ; { 1. new procedure for quintile plots } ;; this does a line plot of the number of people of each class to update-class-plot set-current-plot "Class Plot" set-current-plot-pen "low" plot count turtles with [color = red] set-current-plot-pen "mid" plot count turtles with [color = green] set-current-plot-pen "up" plot count turtles with [color = blue] end ;; this does a histogram of the number of people of each class to update-class-histogram set-current-plot "Class Histogram" set-plot-y-range 0 count turtles ; { 3. Fix histogram plot with count turtles. } plot-pen-reset set-plot-pen-color red plot count turtles with [color = red] set-plot-pen-color green plot count turtles with [color = green] set-plot-pen-color blue plot count turtles with [color = blue] end to update-lorenz-and-gini-plots locals [total-wealth sorted-wealths wealth-sum-so-far index gini-index-reserve ] set-current-plot "Lorenz Curve" clear-plot ;; draw a straight line from lower left to upper right set-current-plot-pen "equal" plot 0 plot 100 set-current-plot-pen "lorenz" set-plot-pen-interval 100 / count turtles ; { 3. Replace num-people with count turtles. } plot 0 set sorted-wealths sort values-from turtles [wealth] set total-wealth sum sorted-wealths set wealth-sum-so-far 0 set index 0 set gini-index-reserve 0 ;; now actually plot the Lorenz curve -- along the way, we also ;; calculate the Gini index repeat count turtles [ ; { 3. Replace num-people with count turtles. } set wealth-sum-so-far (wealth-sum-so-far + item index sorted-wealths) plot (wealth-sum-so-far / total-wealth) * 100 set index (index + 1) set gini-index-reserve gini-index-reserve + (index / count turtles ) - ; { 3. Replace num-people with count turtles. } (wealth-sum-so-far / total-wealth) ] ;; plot Gini Index set-current-plot "Gini-Index v. Time" plot (gini-index-reserve / count turtles ) / area-of-equality-triangle ; { 3. Replace num-people with count turtles. } set gini-count (gini-index-reserve / count turtles ) / area-of-equality-triangle end to-report area-of-equality-triangle ;; not really necessary to compute this when count turtles is large; ;; if count turtles is large, could just use estimate of 0.5 report (count turtles * (count turtles - 1) / 2) / (count turtles ^ 2) ; { 3. Replace num-people with count turtles. } end ; *** NetLogo Model Copyright Notice *** ; ; This model was created as part of the project: CONNECTED MATHEMATICS: ; MAKING SENSE OF COMPLEX PHENOMENA THROUGH BUILDING OBJECT-BASED PARALLEL ; MODELS (OBPML). The project gratefully acknowledges the support of the ; National Science Foundation (Applications of Advanced Technologies ; Program) -- grant numbers RED #9552950 and REC #9632612. ; ; Copyright 1998 by Uri Wilensky. All rights reserved. ; ; Permission to use, modify or redistribute this model is hereby granted, ; provided that both of the following requirements are followed: ; a) this copyright notice is included. ; b) this model will not be redistributed for profit without permission ; from Uri Wilensky. ; Contact Uri Wilensky for appropriate licenses for redistribution for ; profit. ; ; This model was converted to NetLogo as part of the project: ; PARTICIPATORY SIMULATIONS: NETWORK-BASED DESIGN FOR SYSTEMS LEARNING IN ; CLASSROOMS. The project gratefully acknowledges the support of the ; National Science Foundation (REPP program) -- grant number REC #9814682. ; Converted from StarLogoT to NetLogo, 2001. Updated 2003. ; ; To refer to this model in academic publications, please use: ; Wilensky, U. (1998). NetLogo Wealth Distribution model. ; http://ccl.northwestern.edu/netlogo/models/WealthDistribution. ; Center for Connected Learning and Computer-Based Modeling, ; Northwestern University, Evanston, IL. ; ; *** End of NetLogo Model Copyright Notice *** @#$#@#$#@ GRAPHICS-WINDOW 181 10 601 451 20 20 10.0 1 10 0 0 CC-WINDOW 611 293 995 442 Command Center BUTTON 8 10 63 43 setup setup NIL 1 T OBSERVER BUTTON 120 10 175 43 go go T 1 T OBSERVER SLIDER 8 82 176 115 max-vision max-vision 1 15 5 1 1 NIL SLIDER 8 218 176 251 grain-growth-interval grain-growth-interval 1 10 1 1 1 NIL SLIDER 8 116 176 149 metabolism-max metabolism-max 1 25 15 1 1 NIL SLIDER 8 48 176 81 num-people num-people 2 1000 250 1 1 NIL SLIDER 8 287 176 320 percent-best-land percent-best-land 5.0 25.0 10.0 1.0 1 % SLIDER 8 184 176 217 life-expectancy-max life-expectancy-max 1 100 83 1 1 NIL MONITOR 45 326 132 375 time elapsed clock 0 1 PLOT 4 453 212 615 Class Plot Time Turtles 0.0 50.0 0.0 250.0 true true PENS "low" 1.0 0 -65536 true "mid" 1.0 0 -11352576 true "up" 1.0 0 -16776961 true SLIDER 8 252 176 285 num-grain-grown num-grain-grown 1 10 4 1 1 NIL SLIDER 8 150 176 183 life-expectancy-min life-expectancy-min 1 100 1 1 1 NIL PLOT 214 453 414 615 Class Histogram Classes Turtles 0.0 3.0 0.0 1000.0 false false PENS "default" 1.0 1 -65536 true PLOT 415 453 598 615 Lorenz Curve Pop % Wealth% 0.0 100.0 0.0 100.0 false false PENS "lorenz" 1.0 0 -65536 true "equal" 100.0 0 -16777216 true PLOT 600 453 804 615 Gini-Index v. Time Time Gini 0.0 50.0 0.0 1.0 true false PENS "default" 1.0 0 -16776961 true PLOT 806 453 1006 615 Quintile Wealth Quintile % W 0.0 5.0 0.0 100.0 true false PENS "Q1" 1.0 1 -16777216 false "Q2" 1.0 1 -16777216 true "Q3" 1.0 1 -16777216 true "Q4" 1.0 1 -16777216 true "Q5" 1.0 1 -16777216 true MONITOR 796 171 869 220 % settled 100 * count turtles with [ settled ] / count turtles 2 1 MONITOR 880 171 964 220 % employed 100 * count turtles with [employed] / count turtles 2 1 MONITOR 797 66 854 115 top 1% top-one 2 1 MONITOR 797 12 877 61 avg wealth sum values-from turtles [wealth] / count turtles 0 1 SLIDER 610 11 782 44 num-steps num-steps 0 1000 1000 1 1 NIL SWITCH 610 49 781 82 patch-productivity patch-productivity 1 1 -1000 SWITCH 611 229 714 262 inherit? inherit? 1 1 -1000 CHOICE 610 87 748 132 pop-growth pop-growth "none" "equal" "starvation" 0 CHOICE 610 170 748 215 settling? settling? "none" "settlers" "employees" 0 MONITOR 885 12 977 61 total wealth sum values-from turtles [wealth] 0 1 MONITOR 794 229 859 278 % gen 0 100 * count turtles with [ generation < 1 ] / count turtles 0 1 MONITOR 899 66 977 115 wealthiest wealthiest 0 1 TEXTBOX 869 222 990 289 after life-expectancy this indicates percent of turtles that starved in the last generation TEXTBOX 33 393 159 441 will stop at num-steps, 2 x num-steps and 3 x num-steps MONITOR 794 120 851 169 Gini gini-count 3 1 @#$#@#$#@ WHAT IS IT? ----------- This model simulates the distribution of wealth. "The rich get richer and the poor get poorer" is a familiar saying that expresses inequity in the distribution of wealth. In this simulation, we see Pareto's law, in which there are a large number of "poor" or red people, fewer "middle class" or green people, and many fewer "rich" or blue people. ; { Modifications from the original Wealth Distribution Model made by } ; { Michael Gizzi, Tom Lairson and Richard Vail between July 15 and October 25, } ; { 2003 are indicated using { }. } ; { For a summary of changes made set the procedures tab. } ; { Numbers are used to correlate the code changes. } ; { 7. Capture wealth for inheritance } ; { - For death by old age capture the old-wealth } ; { - transfer it to the new generation of turtles } ; { - share 50 / 50 with new siblings } ; { - add generation counter (number of times inherited wealth) } ; { - add % gen 0 monitor (percent that starved in the last life) } ; { after the first generation dies off } ; { 8. If the turtles starve 30 % of them will die. } ; { - % generation 0 indicates how inheritence is going and how many starve. } ; { 9. Add choices and buttons for various changes, for experimentation. } ; { - patch-productivity increases - on or off. } ; { - pop-growth - none, equal, starvation. } ; { - settling? - none, settlers, employees. } ; { - inherit? - on or off. } { We plan to make significant modifications to this model. } { As we make modifications to this model, they will be discussed below in inset brackets. } { Coding of the modifications is noted in comments on the procedures. } HOW IT WORKS ------------ This model is adapted from Epstein & Axtell's "Sugarscape" model. It uses grain instead of sugar. Each patch has an amount of grain and a grain capacity (the amount of grain it can grow). People collect grain from the patches, and eat the grain to survive. How much grain each person accumulates is his or her wealth. The model begins with a roughly equal wealth distribution. The people then wander around the landscape gathering as much grain as they can. Each person attempts to move in the direction where the most grain lies. Each time tick, each person eats a certain amount of grain. This amount is called their metabolism. People also have a life expectancy. When their lifespan runs out, or they run out of grain, they die and produce a single offspring. The offspring has a random metabolism and a random amount of grain, ranging from the poorest person's amount of grain to the richest person's amount of grain. (There is no inheritance of wealth.) To observe the equity (or the inequity) of the distribution of wealth, a graphical tool called the Lorenz curve is utilized. We rank the population by their wealth and then plot the percentage of the population that owns each percentage of the wealth (e.g. 30% of the wealth is owned by 50% of the population). Hence the ranges on both axes are from 0% to 100%. Another way to understand the Lorenz curve is to imagine that there are 100 dollars of wealth available in a society of 100 people. Each individual is 1% of the population and each dollar is 1% of the wealth. Rank the individuals in order of their wealth from greatest to least: the poorest individual would have the lowest ranking of 1 and so forth. Then plot the proportion of the rank of an individual on the y-axis and the portion of wealth owned by this particular individual and all the individuals with lower rankings on the x-axis. For example, individual Y with a ranking of 20 (20th poorest in society) would have a percentage ranking of 20% in a society of 100 people (or 100 rankings) -- this is the point on the y-axis. The corresponding plot on the x-axis is the proportion of the wealth that this individual with ranking 20 owns along with the wealth owned by the all the individuals with lower rankings (from rankings 1 to 19). A straight line with a 45 degree incline at the origin (or slope of 1) is a Lorenz curve that represents perfect equality -- everyone holds an equal part of the available wealth. On the other hand, should only one family or one individual hold all of the wealth in the population (i.e. perfect inequity), then the Lorenz curve will be a backwards "L" where 100% of the wealth is owned by the last percentage proportion of the population. In practice, the Lorenz curve actually falls somewhere between the straight 45 degree line and the backwards "L". ; { Modifications from the original Wealth Distribution Model made by } ; { 1. Another way to visualize this is to look at the percent of wealth } ; { controlled by quintiles of the population. The Quintile Wealth histogram } ; { shows this. The wealthest 20% will control more than 20 percent of the } ; { wealth. The poorest 20% will control less. Moves in Quintile Wealth are } ; { similar to the Lorenz curve. For clarity it is worth noting that the } ; { Quintile of a turtle is only roughly related to the class noted above. } ; { When the richest turtle has much more wealth than most of the rest of the } ; { turtles, the lower class is huge, but will be distributed across several } ; { quintiles. Comparison to Bill Gates makes most of us look very very poor. } For a numerical measurement of the inequity in the distribution of wealth, the Gini index (or Gini coefficient) is derived from the Lorenz curve. To calculate the Gini index, find the area between the 45 degree line of perfect equality and the Lorenz curve. Divide this quantity by the total area under the 45 degree line of perfect equality (this number is always 0.5 -- the area of 45-45-90 triangle with sides of length 1). If the Lorenz curve is the 45 degree line then the Gini index would be 0; there is no area between the Lorenz curve and the 45 degree line. If, however, the Lorenz curve is a backwards "L", then the Gini-Index would be 1 -- the area between the Lorenz curve and the 45 degree line is 0.5; this quantity divided by 0.5 is 1. Hence, equality in the distribution of wealth is measured on a scale of 0 to 1 -- more inequity as one travels up the scale. ; { 2. A random 40% chance for the max-grain-here to increase by 1 unit happens } ; { every 50 ticks. This is to simulate improvement in technology over time. } ; { The questions is does this sort of growth allow for improvement for the } ; { lowest class, or quartile? ; { 3. Population is fixed in the original model at 250. A random 10% chance for } ; { population to increase by 1 every time a turtle dies was added to explore } ; { What is the effect of increased population on distribution of wealth? } ; { When population growth was added to the model, it was necessary to use } ; { a count of turtles to keep the Lorenz curve and the Gini index useful. } ; { 4. Allows turtles who are wealthy enough to settle on a rich patch, and } ; { and become more stable and productive, by increasing grain production. } ; { This, of course, opens questions about distribution to others in the patch.} ; { In the settled model the settler gets all of the harvest from the patch. } ; { When settlers die, the patch becomes open for settlement by another turtle.} ; { 5. Allows up to two employees to be hired by settled turtles. Potential } ; { employees must cross the patch with at least 10 wealth. This increases } ; { land productivity, up to the max-grain-here limit of the patch. Settlers } ; { Settlers share 50/50 with employees. When an employee dies the position is } ; { opened. } ; { 6. This change added some displays to the model including a monitor for the } ; { showing the wealth percent of total wealth controlled by the top 1% of the } ; { of the population, the super rich. And the plot of quintile wealth. } ; { 7. What is the effect of inheritance? When a turtle dies of old age its } ; { wealth is captured - in the original model it just evaporates. This is } ; { transferred to a next generation - if two turtles are produced the wealth } ; { shared between the siblings 50/50. If a turtle dies of starvation the } ; { generation is reset to zero. A monitor was added to show the percent of } ; { turtle with no generations of inherited wealth. After startup effects this } ; { shows the percent of turtles that starved in the last generation. } ; { 8. When turtles die from starvation 30 % of them will die, with out off- } ; { spring. This was added to moderate the growth of population. } ; { 9. Exploring the impact of all of these changes at once led to confusion. So } ; { some switches and choice menus were added so that each modification could } ; { be on or off. } HOW TO USE IT ------------- The PERCENT-BEST-LAND slider determines the initial density of patches that are seeded with the maximum amount of grain. This maximum is adjustable via the MAX-GRAIN variable in the SETUP procedure in the procedures window. The GRAIN-GROWTH-INTERVAL slider determines how often grain grows. The NUM-GRAIN-GROWN slider sets how much grain is grown each time GRAIN-GROWTH-INTERVAL allows grain to be grown. The NUM-PEOPLE slider determines the initial number of people. LIFE-EXPECTANCY-MIN is the shortest number of ticks that a person can possibly live. LIFE-EXPECTANCY-MAX is the longest number of ticks that a person can possibly live. The METABOLISM-MAX slider sets the highest possible amount of grain that a person could eat per clock tick. The MAX-VISION slider is the furthest possible distance that any person could see. GO starts the simulation. The TIME ELAPSED monitor shows the total number of clock ticks since the last setup. The CLASS PLOT shows a line plot of the number of people in each class over time. The CLASS HISTOGRAM shows the same information in the form of a histogram. The LORENZ CURVE plot shows the Lorenz curve of the population at a particular time as well as the 45 degree line of equality. The GINI-INDEX V. TIME plot shows the Gini index at the time that the Lorenz curve is drawn. The LORENZ CURVE and the GINI-INDEX V. TIME plots are updated every 5 passes through the GO procedure. ; { 6. The simulation will automatically stop after the chosen NUM-STEPS. When } ; { the number of steps is finished, hitting the GO button again will continue } ; { the simulation for another NUM-STEPS, and again for a third round. } ; { 9. The PATCH-PRODUCTIVITY switch controls modification 2, slow growth of } ; { patch capacity. The POPULATION-GROWTH choice menu allows for the original } ; { static population (NONE); an EQUAL 10% chance of two off-spring when a } ; { turtle dies; or STARVATION where there is a 30% chance of no off-spring } ; { when a turtle starves and 10% chance of two off-spring when a turtle dies } ; { of old age. The SETTLING? choice menu allows for the original model with } ; { no settlers (NONE); SETTLERS which allows settlers as discribed in } ; { modification 4; or EMPLOYEES which allows for both settlers and employees } ; { as described in modifications 4 and 5. The INHERIT? switch turns } ; { inheritance on or off. Any combination of switches can be setup. } THINGS TO NOTICE ---------------- Notice the distribution of wealth. Are the classes equal? This model usually demonstrates Pareto's Law, in which most of the people are poor, fewer are middle class, and very few are rich. Why does this happen? Do poor families seem to stay poor? What about the rich and the middle class people? Watch the CLASS PLOT to see how long it takes for the classes to reach stable values. As time passes, does the distribution get more equalized or more skewed? (Hint: observe the Gini index plot.) Try to find resources from the U.S. Government Census Bureau for the U.S.' Gini coefficient. Are the Gini coefficients that you calculate from the model comparable to those of the Census Bureau? Why or why not? Is there a trend in the plotting of the Gini index with respect to time? Does the plot oscillate? Or does it stabilize to a certain number? ; { 4. The number of settlers is heavily influenced by the PERCENT-BEST-LAND } ; { 8. Inheritance has some interesting effects, if the PERCENT-BEST-LAND is over } ; { about 15%. } THINGS TO TRY ------------- Are there any settings that do not result in a demonstration of Pareto's Law? Play with the NUM-GRAIN-GROWN slider, and see how this affects the distribution of wealth. How much does the LIFE-EXPECTANCY-MAX matter? Change the value of the MAX-GRAIN variable (in the SETUP procedure in the procedures tab). Do outcomes differ? Experiment with the PERCENT-BEST-LAND and NUM-PEOPLE sliders. How do these affect the outcome of the distribution of wealth? Try having all the people start in one location. See what happens. Try setting everyone's initial wealth as being equal. Does the initial endowment of an individual still arrive at an unequal distribution in wealth? Is it less so when setting random initial wealth for each individual? Try setting all the individual's wealth and vision to being equal. Do you still arive at an unequal distribution of wealth? Is it more equal in the measure of the Gini index than with random endowments of vision? EXTENDING THE MODEL ------------------- Have each newborn inherit a percentage of the wealth of its parent. ; { 8. The addition of inheritance is a stab at this, but lots of things could be } ; { tried. } Add a switch or slider which has the patches grow back all or a percentage of their grain capacity, rather than just one unit of grain. Allow the grain to give an advantage or disadvantage to its carrier, such as every time some grain is eaten or harvested, pollution is created. Would this model be the same if the wealth were randomly distributed (as opposed to a gradient)? Try different landscapes, making SETUP buttons for each new landscape. Try allowing metabolism or vision or another characteristic to be inherited. Will we see any sort of evolution? Will the "fittest" survive? Try adding in seasons into the model. That is to say have the grain grow better in a section of the landscape during certain times and worse at others. How could you change the model to achieve wealth equality? ; { This was the focus of many of our changes and experiments. } The way the procedures are set up now, one person will sometimes follow another. You can see this by setting the number of people relatively low, such as 50 or 100, and having a long life expectancy. Why does this phenomenon happen? Try adding code to prevent this from occurring. (HINT: When and how do people check to see which direction they should move in?) ; { There is still a lot of room for exploration in this model. Many choices were } ; { were made that could be sliders. For example, effects of how settlers and } ; { employees share wealth, or the number of employees could be very fruitful. } NETLOGO FEATURES ------------------ Examine how the landscape of color is created -- note the use of the "scale-color" reporter. Each patch is given a value, and "scale-color" reports a color for each patch that is scaled according to its value. Note the use of lists in drawing the Lorenz Curve and computing the Gini index. ; { Note the use of choice menus to set up experiments with various modifications.} ; { Significant time would have been saved if we had thought of this earlier. } SUGGESTIONS FOR USING BEHAVIOR SPACE WITH THIS MODEL ------------------- ; This model cries out for scientific investigation of the various possible outcomes, in terms of changes in the ; gini-index when running different combinations of experiments. ; Multiple runs with the same settings are necessary to get a better sense of the impact of randomness on the ; model. Behavior space is the ideal tool to accomplish this, but does not have a built-in method of running ; several runs of the model with the same settings. An easy way to overcome this limitation is to add a slider ; to the model called "runs." While this slider has no impact on the model's code, it can be used in behavior ; space as the slider values to be varied. For example, set up the model to run a particular experiment; tell ; Behavior Space to vary "Runs" from 1 - 25 (for twenty five runs of the model), and set an exit condition of X ; time clicks (try 500 or 1000). For the reporter, change "count turtles" to "gini-count" and you'll be able to ; track the change in the gini-index over X time clicks, and X runs of the model. CREDITS AND REFERENCES ---------------------- For an explanation of Pareto's Law, see http://www.xrefer.com/entry/445978. This model is based on a model described in Epstein, J. & Axtell R. (1996). Growing Artificial Societies: Social Science from the Bottom Up. Washington, DC: Brookings Institution Press. To refer to this model in academic publications, please use: Gizzi, Michael; Lairson, Tom; and Vail, Richard, Mesa State College, Center for Agent-Based Modeling, 1100 North Avenue, Grand Junction, CO. October 2003. http://www.modelingcomplexiy.org. Modifications to a original model created by: Wilensky, U. (1998). NetLogo Wealth Distribution model. http://ccl.northwestern.edu/netlogo/models/WealthDistribution. Center for Connected Learning and Computer-Based Modeling, Northwestern University, Evanston, IL. @#$#@#$#@ default true 0 Polygon -7566196 true true 150 5 40 250 150 205 260 250 arrow true 0 Polygon -7566196 true true 150 0 0 150 105 150 105 293 195 293 195 150 300 150 box true 0 Polygon -7566196 true true 45 255 255 255 255 45 45 45 circle true 0 Circle -7566196 true true 35 35 230 person false 0 Circle -7566196 true true 155 20 63 Rectangle -7566196 true true 158 79 217 164 Polygon -7566196 true true 158 81 110 129 131 143 158 109 165 110 Polygon -7566196 true true 216 83 267 123 248 143 215 107 Polygon -7566196 true true 167 163 145 234 183 234 183 163 Polygon -7566196 true true 195 163 195 233 227 233 206 159 spacecraft true 0 Polygon -7566196 true true 150 0 180 135 255 255 225 240 150 180 75 240 45 255 120 135 thin-arrow true 0 Polygon -7566196 true true 150 0 0 150 120 150 120 293 180 293 180 150 300 150 truck-down false 0 Polygon -7566196 true true 225 30 225 270 120 270 105 210 60 180 45 30 105 60 105 30 Polygon -8716033 true false 195 75 195 120 240 120 240 75 Polygon -8716033 true false 195 225 195 180 240 180 240 225 truck-left false 0 Polygon -7566196 true true 120 135 225 135 225 210 75 210 75 165 105 165 Polygon -8716033 true false 90 210 105 225 120 210 Polygon -8716033 true false 180 210 195 225 210 210 truck-right false 0 Polygon -7566196 true true 180 135 75 135 75 210 225 210 225 165 195 165 Polygon -8716033 true false 210 210 195 225 180 210 Polygon -8716033 true false 120 210 105 225 90 210 turtle true 0 Polygon -7566196 true true 138 75 162 75 165 105 225 105 225 142 195 135 195 187 225 195 225 225 195 217 195 202 105 202 105 217 75 225 75 195 105 187 105 135 75 142 75 105 135 105 @#$#@#$#@ NetLogo 1.3 @#$#@#$#@ @#$#@#$#@ @#$#@#$#@