breed [consumers consumer] breed [hash-firms hash-firm] breed [bean-firms bean-firm] consumers-own [EndowK h-k b-k alphak Inck Expk Savk ch-k cb-k h-*k b-*k Inc*k hdk bdk stopk dhk dbk positionH positionB hRk bRk] hash-firms-own [MoneyHj CapHj FCostsHj f_Hj FHj TCostHj SHj RHj hsj ProfitHj pHj hj NetWorthHj mHj dHj DivHj CapPercentHj MarkUpHj ZHj qji CHj r_Hj eHj pji Responseji MarkUpsHj CapPercentsHj i'Hj chsj costumerH demandsh] bean-firms-own [MoneyBn CapBn FCostsBn f_Bn FBn TCostBn SBn RBn bsn ProfitBn pBn bn NetWorthBn mBn dBn DivBn CapPercentBn MarkUpBn ZBn qni CBn r_Bn eBn pni Responseni MarkUpsBn CapPercentsBn i'Bn cbsn costumerB demandsB] globals [J N K roH roB temp pLH pLB temp1 temp2 mx moneyH moneyB moneyK seed itemp output.file] to print-in-file file-type K file-type "," file-type J file-type "," file-type N file-type "," file-type sum ([Inck] of consumers) file-type "," file-type sum ([MoneyHj] of hash-firms) file-type "," file-type sum ([MoneyBn] of bean-firms) file-type "\n" end to setup clear-all set output.file "Ace.txt" set seed new-seed show seed random-seed seed ; random-seed 1669568798 set J number-hash-firms set N number-bean-firms set K number-consumers set roH hash-capacity-price set roB bean-capacity-price create-consumers K [ set Endowk (random-float max-starting-endowments) + 1 set h-k min-hash-needs set b-k min-bean-needs set alphak random-float 1 set Inck Endowk set Inc*k Inck set ch-k 0 set cb-k 0 set h-*k h-k set b-*k b-k set stopk False ] create-hash-firms J [ set MoneyHj (random-float hash-max-starting-money) + 1 set CapHj (random-float hash-max-starting-capacity) + 1 set f_Hj (random-float bean-max-mult-fixed-cost) set FHj (random-float hash-max-add-fixed-cost) set SHj (random-float hash-max-quad-total-cost) set RHj (random-float hash-max-line-total-cost) set mHj (random-float 1) set dHj (random-float 1) set ZHj (random max-number-strategies) + 2 set qji (n-values ZHj [1]) set pji (n-values ZHj [0]) set CHj (random 10000) + 1 set r_Hj (random-float 1) set eHj (random-float 1) set Responseji (n-values ZHj [0]) set CapPercentsHj (n-values ZHj [(((random 96) + 5) / 100)]) set MarkUpsHj (n-values ZHj [(((random 95) + 5) / 100)]) set DivHj 0 set costumerH [] set demandsH 0 ] create-bean-firms N [ set MoneyBn (random-float bean-max-starting-money) + 1 set CapBn (random-float bean-max-starting-capacity) + 1 set f_Bn (random-float bean-max-mult-fixed-cost) set FBn (random-float bean-max-add-fixed-cost) set SBn (random-float bean-max-quad-total-cost) set RBn (random-float bean-max-line-total-cost) set mBn (random-float 1) set dBn (random-float 1) set ZBn (random max-number-strategies) + 2 set qni (n-values ZBn [1]) set pni (n-values ZBn [0]) set CBn (random 10000) + 1 set r_Bn (random-float 1) set eBn (random-float 1) set Responseni (n-values ZBn [0]) set CapPercentsBn (n-values ZBn [(((random 96) + 5) / 100)]) set MarkUpsBn (n-values ZBn [(((random 95) + 5) / 100)]) set DivBn 0 set costumerB [] set demandsB 0 ] reset-ticks file-open output.file print-in-file end to-report update-cap-investment [Money Cap Profit Div d m ro] set Money (1 - d) * (Money + m * Profit) set Cap Cap + (1 - m) * Profit / ro set Div d * (Money + m * Profit) report (list Money Cap Div) end to-report update-pre-savings [Money Cap Profit Div d] set Money (1 - d) * (Money + Profit) set Cap Cap set Div d * (Money + Profit) report (list Money Cap Div) end to-report update-contractionary [Money Cap Profit Div ro] let I 0 if Money + Profit >= 0[ set I 1 ] set Cap (Cap + ((1 - I) * (Money + Profit) / ro)) set Money I * (Money + Profit) set Div 0 report (list Money Cap Div) end to-report profit-allocate [Money Cap Profit Div NetWorth d m ro sales] Set NetWorth Money + ro * Cap + Profit if NetWorth > 0 [ if (Profit >= 0) and sales = Cap[ set temp (update-cap-investment Money Cap Profit Div d m ro) ] if (Profit >= 0) and sales < Cap[ set temp (update-pre-savings Money Cap Profit Div d) ] if (Profit < 0)[ set temp (update-contractionary Money Cap Profit Div ro) ] ] if Networth <= 0 [ report (list 0 0 0 Networth) ] report (list (item 0 temp) (item 1 temp) (item 2 temp) NetWorth) end to-report update-Response [Response Profit Z e. q i'] let i 0 while [i < Z] [ ifelse (i = i') [ set Response replace-item i Response ((1 - e.) * Profit) ] [ set Response replace-item i Response ((e. * (item i q)) / (Z - 1)) ] set i i + 1 ] report Response end to-report update-q [Z q r_ Response] let i 0 while [i < Z] [ set q replace-item i q ((1 - r_) * (item i q) + (item i Response)) set i i + 1 ] set mx (max (list (max q) abs (min q))) set i 0 while [i < Z] [ set q replace-item i q ((item i q) / mx) set i i + 1 ] report q end to-report update-p [p q Z C] let expi n-values Z [0] let i 0 while [i < Z] [ set expi replace-item i expi exp((item i q) / C) set i i + 1 ] set i 0 let sumi sum (expi) while [i < Z] [ set p replace-item i p ((item i expi) / sumi) set i i + 1 ] report p end to-report inv-CapPercent [CapPercent Cap production] set production CapPercent * Cap report production end to-report inv-MarkUp [MarkUp S R production price] let MC (2 * S * production + R * production) set price MC / (1 - MarkUp) report price end to-report set-offer [Z p CapPercents CapPercent MarkUps MarkUp Cap production S R price] let cum-sum p let i 1 while [i < Z] [ set cum-sum (replace-item i cum-sum ((item i cum-sum) + (item (i - 1) cum-sum))) set i i + 1 ] let prob random-float 1 set i 0 while [(item i cum-sum) < prob] [ set i i + 1 ] set CapPercent (item i CapPercents) set MarkUp (item i MarkUps) set production (inv-CapPercent CapPercent Cap production) set price (inv-MarkUp MarkUp S R production price) report (list CapPercent MarkUp production price i) end to-report update-FCosts [Cap f_ F] report (f_ * Cap + F) end to-report update-TCost [FCosts production S R] report (S * (production ^ 2) + R * production + FCosts) end to-report update-Profit [price sales TCost] report (price * sales - TCost) end to-report update-pLH report item 0 [phj] of (hash-firms with [chsj != 0]) with-min [phj] end to-report update-pLB report item 0 [pbn] of (bean-firms with [cbsn != 0]) with-min [pbn] end to-report update-demands [h-* b-* Inc* a] ifelse ((all? hash-firms [chsj = 0]) and (any? bean-firms with [cbsn != 0])) [ ifelse ((h-* <= 0) and (pLB * b-* <= Inc*)) [ report (list 0 (Inc* / pLB) False) ] [ report (list 0 0 True) ] ] [ ifelse ((all? bean-firms [cbsn = 0]) and (any? hash-firms with [chsj != 0])) [ ifelse ((b-* <= 0) and (pLH * h-* <= Inc*)) [ report (list (Inc* / pLH) 0 False) ] [ report (list 0 0 True) ] ] [ ifelse (pLH * h-* + pLB * b-* <= Inc*) [ let a1 (list ((1 - a) * h-* + a * (Inc* - b-* * pLB) / pLH) (a * b-* + (1 - a) * (Inc* - h-* * pLH) / pLB) False) ifelse (item 0 a1) <= 0 [ report (list 0 (Inc* / pLB) False) ] [ ifelse (item 1 a1) <= 0 [ report (list (Inc* / pLH) 0 False) ] [ report a1 ] ] ] [ report (list 0 0 True) ] ] ] end to-report update-dhk set temp random count (hash-firms with [chsj != 0]) with-min [pHj] report item temp (sort ([who] of (hash-firms with [chsj != 0]) with-min [pHj])) end to-report update-dbk set temp random count (bean-firms with [cbsn != 0]) with-min [pBn] report item temp (sort ([who] of (bean-firms with [cbsn != 0]) with-min [pBn])) end to update-costumer-demands [time firm dk] ifelse time = 1[ ifelse firm = "hash"[ ask hash-firm dk [ set costumerH lput ([who] of myself) costumerH set demandsH (demandsH + ([hdk] of myself)) ] ] [ ask bean-firm dk [ set costumerB lput ([who] of myself) costumerB set demandsB (demandsB + ([bdk] of myself)) ] ] ] [ ask (hash-firms with [chsj != 0]) with-min [pHj] [ set costumerH shuffle costumerH set demandsH 0 ] ask (bean-firms with [cbsn != 0]) with-min [pBn] [ set costumerB shuffle costumerB set demandsB 0 ] ] end to-report update-temp1-temp2 [hd bd dh db] set temp1 0 set temp2 0 if hdk > 0 [ set positionH position ([who] of self) ([costumerH] of hash-firm dh) set temp 0 while [temp <= positionH] [ set temp1 (temp1 + ([hd] of consumer (item temp ([costumerH] of hash-firm dh)))) set temp temp + 1 ] ] if bdk > 0 [ set positionB position ([who] of self) ([costumerB] of bean-firm db) set temp 0 while [temp <= positionB] [ set temp2 (temp2 + ([bd] of consumer (item temp ([costumerB] of bean-firm db)))) set temp temp + 1 ] ] report (list temp1 temp2) end to-report update-Rk [dk tempi cs] report min (list dk max (list 0 (cs - (tempi - dk)))) end to-report update-hdk-bdk [hd bd hr br h-* b-*] ifelse ((hR >= h-*) and (bR >= b-*)) or ((hR < h-*) and (bR < b-*)) [ set hd hR set bd bR ] [ ifelse (hR < h-*) [ set hd hR set bd max (list 0 b-*) ] [ set hd max (list 0 h-*) set bd bR ] ] report (list hd bd) end to-report update-Inc*k [Inc* hd bd] set temp (Inc* - (hd * pLH) - (bd * pLB)) if temp <= 10 ^ (- 25) [set temp 0] report temp end to update-demands2 [firm dk] ifelse firm = "hash"[ ask hash-firm dk [ set demandsH (demandsH + ([hdk] of myself)) ] ] [ ask bean-firm dk [ set demandsB (demandsB + ([bdk] of myself)) ] ] end to update-cs ask (hash-firms with [chsj != 0]) with-min [pHj] [ set chsj (chsj - demandsH) if chsj <= 0[ set chsj 0 ] ] ask (bean-firms with [cbsn != 0]) with-min [pBn] [ set cbsn (cbsn - demandsB) if cbsn <= 0[ set cbsn 0 ] ] end to go if (ticks > 1500)[stop] ask hash-firms [ if ticks != 0 [ set temp (profit-allocate MoneyHj CapHj ProfitHj DivHj NetWorthHj dHj mHj roH hj) set MoneyHj (item 0 temp) set CapHj (item 1 temp) set DivHj (item 2 temp) set NetWorthHj (item 3 temp) if NetWorthHj <= 0 [ Set J J - 1 die ] set Responseji (update-Response Responseji ProfitHj ZHj eHj qji i'Hj) set qji (update-q ZHj qji r_Hj Responseji) ] set pji (update-p pji qji ZHj CHj) set temp (set-offer ZHj pji CapPercentsHj CapPercentHj MarkUpsHj MarkUpHj CapHj hsj SHj RHj pHj) set CapPercentHj (item 0 temp) set MarkUpHj (item 1 temp) set hsj (item 2 temp) set pHj (item 3 temp) set i'Hj (item 4 temp) set chsj hsj ] ask bean-firms [ if ticks != 0 [ set temp (profit-allocate MoneyBn CapBn ProfitBn DivBn NetWorthBn dBn mBn roB bn) set MoneyBn (item 0 temp) set CapBn (item 1 temp) set DivBn (item 2 temp) set NetWorthBn (item 3 temp) if NetWorthBn <= 0 [ Set N N - 1 die ] set Responseni (update-Response Responseni ProfitBn ZBn eBn qni i'Bn) set qni (update-q ZBn qni r_Bn Responseni) ] set pni (update-p pni qni ZBn CBn) set temp (set-offer ZBn pni CapPercentsBn CapPercentBn MarkUpsBn MarkUpBn CapBn bsn SBn RBn pBn) set CapPercentBn (item 0 temp) set MarkUpBn (item 1 temp) set bsn (item 2 temp) set pBn (item 3 temp) set i'Bn (item 4 temp) set cbsn bsn ] if ticks != 0 [ set temp 0 ask hash-firms [ set temp temp + DivHj] ask bean-firms [ set temp temp + DivBn] ask consumers [ set Inck Endowk + Savk + (temp / K) set Inc*k Inck set ch-k 0 set cb-k 0 set h-*k h-k set b-*k b-k set stopk False ] ] while [(((any? hash-firms with [chsj != 0]) or (any? bean-firms with [cbsn != 0])) and (any? consumers with [Inc*k != 0])) and (any? consumers with [stopk = False])] [ ; the process continues while there are firms with unsold goods and consumers with money ifelse (any? hash-firms with [chsj != 0]) [ set pLH update-pLH ; finding the lowest price for hash from a firm with hash to sell ] [ set pLH 100000000000 ] ifelse (any? bean-firms with [cbsn != 0]) [ set pLB update-pLB ; finding the lowest price for bean from a firm with bean to sell ] [ set pLB 100000000000 ] ask (hash-firms with [chsj != 0]) with-min [pHj] [set costumerH [] ] ; resets costumerH list of hash firms for this round ask (bean-firms with [cbsn != 0]) with-min [pBn] [set costumerB [] ] ; resets costumerB list of bean firms for this round ask consumers with [Inc*k != 0] [ if Not (stopk) [ set temp (update-demands h-*k b-*k Inc*k alphak) set hdk (item 0 temp) set bdk (item 1 temp) set stopk (item 2 temp) if (stopk) and ((h-*k > 0) or (b-*k > 0))[ set K K - 1 die ; the consumer dies if he can't buy more hash(bean) and hasn't met is minimum hash(bean) need ] if hdk > 0 [ set dhk update-dhk update-costumer-demands 1 "hash" dhk ; update costumer list and demands of hash-firm dhk based on what the consumer wants and can buy ] if bdk > 0 [ set dbk update-dbk update-costumer-demands 1 "bean" dbk ; update costumer list and demands of bean-firm dbk based on what the consumer wants and can buy ] ] ] update-costumer-demands 2 0 0 ; randomly orders the consumer list and resets demands for a later update (second and third argument is not used) ask consumers with [Inc*k != 0] [ if Not (stopk) [ set temp update-temp1-temp2 hdk bdk dhk dbk set temp1 item 0 temp ; defines the amount of hash that the choosen firm must have to fully satisfy the consumer demand set temp2 item 1 temp ; defines the amount of bean that the choosen firm must have to fully satisfy the consumer demand if Not ((temp1 <= [chsj] of hash-firm dhk) and (temp2 <= [cbsn] of bean-firm dbk)) [ set hRk update-Rk hdk temp1 [chsj] of hash-firm dhk ; defines the amount hash that the consumer can buy under rationing set bRk update-Rk bdk temp2 [cbsn] of bean-firm dbk ; defines the amount bean that the consumer can buy under rationing set temp update-hdk-bdk hdk bdk hrk brk h-*k b-*k set hdk item 0 temp set bdk item 1 temp ] set ch-k ch-k + hdk ; current amount of hash purchased set cb-k cb-k + bdk ; current amount of bean purchased set h-*k (h-*k - hdk) ; removes from the current need of hash the amount of hash bought set b-*k (b-*k - bdk) ; removes from the current need of bean the amount of bean bought set Inc*k update-Inc*k Inc*k hdk bdk ; removes from the current money the amount spent buying goods update-demands2 "hash" dhk ; update demands after finding out if their minimum needs will be satisfied or not update-demands2 "bean" dbk ; update demands after finding out if their minimum needs will be satisfied or not ] ] update-cs ; updates firms current goods for sale ] ask consumers [ set expk Inck - Inc*k set savk Inc*K ] ask hash-firms [ set hj hsj - chsj set FCostsHj (update-FCosts CapHj f_Hj FHj) set TCostHj (update-TCost FCostsHj hsj SHj RHj) set ProfitHj (update-Profit pHj hj TCostHj) ] ask bean-firms [ set bn bsn - cbsn set FCostsBn (update-FCosts CapBn f_Bn FBn) set TCostBn (update-TCost FCostsBn bsn SBn RBn) set ProfitBn (update-Profit pBn bn TCostBn) ] ;] tick file-open output.file print-in-file end @#$#@#$#@ GRAPHICS-WINDOW 812 10 1057 210 6 6 13.0 1 10 1 1 1 0 1 1 1 -6 6 -6 6 0 0 1 ticks 30.0 SLIDER 1 10 185 43 number-consumers number-consumers 1 100 50 1 1 NIL HORIZONTAL SLIDER 186 10 370 43 number-hash-firms number-hash-firms 1 100 50 1 1 NIL HORIZONTAL SLIDER 371 10 555 43 number-bean-firms number-bean-firms 1 100 50 1 1 NIL HORIZONTAL SLIDER 186 44 370 77 hash-capacity-price hash-capacity-price 0 100 50 0.1 1 NIL HORIZONTAL SLIDER 371 44 555 77 bean-capacity-price bean-capacity-price 0 100 50 0.1 1 NIL HORIZONTAL SLIDER 1 112 185 145 max-starting-endowments max-starting-endowments 1 1000000 100000 1 1 NIL HORIZONTAL SLIDER 1 44 185 77 min-hash-needs min-hash-needs 1 10 5 1 1 NIL HORIZONTAL SLIDER 1 78 185 111 min-bean-needs min-bean-needs 1 10 5 1 1 NIL HORIZONTAL SLIDER 186 78 370 111 hash-max-starting-money hash-max-starting-money 1 1000000 1000000 1 1 NIL HORIZONTAL SLIDER 371 78 555 111 bean-max-starting-money bean-max-starting-money 1 1000000 1000000 1 1 NIL HORIZONTAL SLIDER 186 112 370 145 hash-max-starting-capacity hash-max-starting-capacity 1 100 100 1 1 NIL HORIZONTAL SLIDER 371 112 555 145 bean-max-starting-capacity bean-max-starting-capacity 1 100 100 1 1 NIL HORIZONTAL SLIDER 186 146 370 179 hash-max-add-fixed-cost hash-max-add-fixed-cost 0 100 50 1 1 NIL HORIZONTAL SLIDER 371 146 555 179 bean-max-add-fixed-cost bean-max-add-fixed-cost 0 100 50 1 1 NIL HORIZONTAL SLIDER 186 180 370 213 hash-max-mult-fixed-cost hash-max-mult-fixed-cost 0 25 12 1 1 NIL HORIZONTAL SLIDER 371 180 555 213 bean-max-mult-fixed-cost bean-max-mult-fixed-cost 0 25 12 1 1 NIL HORIZONTAL SLIDER 186 214 370 247 hash-max-quad-total-cost hash-max-quad-total-cost 0 10 5 1 1 NIL HORIZONTAL SLIDER 371 214 555 247 bean-max-quad-total-cost bean-max-quad-total-cost 0 10 5 1 1 NIL HORIZONTAL SLIDER 186 248 370 281 hash-max-line-total-cost hash-max-line-total-cost 0 25 12 1 1 NIL HORIZONTAL SLIDER 371 248 555 281 bean-max-line-total-cost bean-max-line-total-cost 0 25 12 1 1 NIL HORIZONTAL SLIDER 1 248 185 281 max-number-strategies max-number-strategies 0 20 10 1 1 NIL HORIZONTAL BUTTON 54 336 118 369 Setup setup NIL 1 T OBSERVER NIL NIL NIL NIL 1 BUTTON 54 374 118 407 Step go NIL 1 T OBSERVER NIL NIL NIL NIL 1 BUTTON 54 412 118 445 Go go T 1 T OBSERVER NIL NIL NIL NIL 0 PLOT 642 36 1153 288 Consumers and firms numbers NIL NIL 0.0 10.0 0.0 10.0 true false "" "" PENS "default" 1.0 0 -13345367 true "" "plot K" "pen-1" 1.0 0 -13840069 true "" "plot J" "pen-2" 1.0 0 -2674135 true "" "plot N" PLOT 642 303 1153 455 plot 1 NIL NIL 0.0 10.0 0.0 10.0 true false "" "" PENS "default" 1.0 0 -13345367 true "" "plot sum ([Inck] of consumers)" "pen-1" 1.0 0 -13840069 true "" "plot sum ([MoneyHj] of hash-firms)" "pen-2" 1.0 0 -2674135 true "" "plot sum ([MoneyBn] of bean-firms)" MONITOR 642 460 1153 505 NIL sum ([Inck] of consumers) + sum ([MoneyHj] of hash-firms) + sum ([MoneyBn] of bean-firms) 17 1 11 BUTTON 54 298 118 331 New File set output.file user-new-file NIL 1 T OBSERVER NIL NIL NIL NIL 1 BUTTON 54 450 118 483 Close File file-close-all NIL 1 T OBSERVER NIL NIL NIL NIL 1 @#$#@#$#@ ## WHAT IS IT? (a general understanding of what the model is trying to show or explain) ## HOW IT WORKS (what rules the agents use to create the overall behavior of the model) ## HOW TO USE IT (how to use the model, including a description of each of the items in the Interface tab) ## THINGS TO NOTICE (suggested things for the user to notice while running the model) ## THINGS TO TRY (suggested things for the user to try to do (move sliders, switches, etc.) with the model) ## EXTENDING THE MODEL (suggested things to add or change in the Code tab to make the model more complicated, detailed, accurate, etc.) ## NETLOGO FEATURES (interesting or unusual features of NetLogo that the model uses, particularly in the Code tab; or where workarounds were needed for missing features) ## RELATED MODELS (models in the NetLogo Models Library and elsewhere which are of related interest) ## CREDITS AND REFERENCES (a reference to the model's URL on the web if it has one, as well as any other necessary credits, citations, and links) @#$#@#$#@ default true 0 Polygon -7500403 true true 150 5 40 250 150 205 260 250 airplane true 0 Polygon -7500403 true true 150 0 135 15 120 60 120 105 15 165 15 195 120 180 135 240 105 270 120 285 150 270 180 285 210 270 165 240 180 180 285 195 285 165 180 105 180 60 165 15 arrow true 0 Polygon -7500403 true true 150 0 0 150 105 150 105 293 195 293 195 150 300 150 box false 0 Polygon -7500403 true true 150 285 285 225 285 75 150 135 Polygon -7500403 true true 150 135 15 75 150 15 285 75 Polygon -7500403 true true 15 75 15 225 150 285 150 135 Line -16777216 false 150 285 150 135 Line -16777216 false 150 135 15 75 Line -16777216 false 150 135 285 75 bug true 0 Circle -7500403 true true 96 182 108 Circle -7500403 true true 110 127 80 Circle -7500403 true true 110 75 80 Line -7500403 true 150 100 80 30 Line -7500403 true 150 100 220 30 butterfly true 0 Polygon -7500403 true true 150 165 209 199 225 225 225 255 195 270 165 255 150 240 Polygon -7500403 true true 150 165 89 198 75 225 75 255 105 270 135 255 150 240 Polygon -7500403 true true 139 148 100 105 55 90 25 90 10 105 10 135 25 180 40 195 85 194 139 163 Polygon -7500403 true true 162 150 200 105 245 90 275 90 290 105 290 135 275 180 260 195 215 195 162 165 Polygon -16777216 true false 150 255 135 225 120 150 135 120 150 105 165 120 180 150 165 225 Circle -16777216 true false 135 90 30 Line -16777216 false 150 105 195 60 Line -16777216 false 150 105 105 60 car false 0 Polygon -7500403 true true 300 180 279 164 261 144 240 135 226 132 213 106 203 84 185 63 159 50 135 50 75 60 0 150 0 165 0 225 300 225 300 180 Circle -16777216 true false 180 180 90 Circle -16777216 true false 30 180 90 Polygon -16777216 true false 162 80 132 78 134 135 209 135 194 105 189 96 180 89 Circle -7500403 true true 47 195 58 Circle -7500403 true true 195 195 58 circle false 0 Circle -7500403 true true 0 0 300 circle 2 false 0 Circle -7500403 true true 0 0 300 Circle -16777216 true false 30 30 240 cow false 0 Polygon -7500403 true true 200 193 197 249 179 249 177 196 166 187 140 189 93 191 78 179 72 211 49 209 48 181 37 149 25 120 25 89 45 72 103 84 179 75 198 76 252 64 272 81 293 103 285 121 255 121 242 118 224 167 Polygon -7500403 true true 73 210 86 251 62 249 48 208 Polygon -7500403 true true 25 114 16 195 9 204 23 213 25 200 39 123 cylinder false 0 Circle -7500403 true true 0 0 300 dot false 0 Circle -7500403 true true 90 90 120 face happy false 0 Circle -7500403 true true 8 8 285 Circle -16777216 true false 60 75 60 Circle -16777216 true false 180 75 60 Polygon -16777216 true false 150 255 90 239 62 213 47 191 67 179 90 203 109 218 150 225 192 218 210 203 227 181 251 194 236 217 212 240 face neutral false 0 Circle -7500403 true true 8 7 285 Circle -16777216 true false 60 75 60 Circle -16777216 true false 180 75 60 Rectangle -16777216 true false 60 195 240 225 face sad false 0 Circle -7500403 true true 8 8 285 Circle -16777216 true false 60 75 60 Circle -16777216 true false 180 75 60 Polygon -16777216 true false 150 168 90 184 62 210 47 232 67 244 90 220 109 205 150 198 192 205 210 220 227 242 251 229 236 206 212 183 fish false 0 Polygon -1 true false 44 131 21 87 15 86 0 120 15 150 0 180 13 214 20 212 45 166 Polygon -1 true false 135 195 119 235 95 218 76 210 46 204 60 165 Polygon -1 true false 75 45 83 77 71 103 86 114 166 78 135 60 Polygon -7500403 true true 30 136 151 77 226 81 280 119 292 146 292 160 287 170 270 195 195 210 151 212 30 166 Circle -16777216 true false 215 106 30 flag false 0 Rectangle -7500403 true true 60 15 75 300 Polygon -7500403 true true 90 150 270 90 90 30 Line -7500403 true 75 135 90 135 Line -7500403 true 75 45 90 45 flower false 0 Polygon -10899396 true false 135 120 165 165 180 210 180 240 150 300 165 300 195 240 195 195 165 135 Circle -7500403 true true 85 132 38 Circle -7500403 true true 130 147 38 Circle -7500403 true true 192 85 38 Circle -7500403 true true 85 40 38 Circle -7500403 true true 177 40 38 Circle -7500403 true true 177 132 38 Circle -7500403 true true 70 85 38 Circle -7500403 true true 130 25 38 Circle -7500403 true true 96 51 108 Circle -16777216 true false 113 68 74 Polygon -10899396 true false 189 233 219 188 249 173 279 188 234 218 Polygon -10899396 true false 180 255 150 210 105 210 75 240 135 240 house false 0 Rectangle -7500403 true true 45 120 255 285 Rectangle -16777216 true false 120 210 180 285 Polygon -7500403 true true 15 120 150 15 285 120 Line -16777216 false 30 120 270 120 leaf false 0 Polygon -7500403 true true 150 210 135 195 120 210 60 210 30 195 60 180 60 165 15 135 30 120 15 105 40 104 45 90 60 90 90 105 105 120 120 120 105 60 120 60 135 30 150 15 165 30 180 60 195 60 180 120 195 120 210 105 240 90 255 90 263 104 285 105 270 120 285 135 240 165 240 180 270 195 240 210 180 210 165 195 Polygon -7500403 true true 135 195 135 240 120 255 105 255 105 285 135 285 165 240 165 195 line true 0 Line -7500403 true 150 0 150 300 line half true 0 Line -7500403 true 150 0 150 150 pentagon false 0 Polygon -7500403 true true 150 15 15 120 60 285 240 285 285 120 person false 0 Circle -7500403 true true 110 5 80 Polygon -7500403 true true 105 90 120 195 90 285 105 300 135 300 150 225 165 300 195 300 210 285 180 195 195 90 Rectangle -7500403 true true 127 79 172 94 Polygon -7500403 true true 195 90 240 150 225 180 165 105 Polygon -7500403 true true 105 90 60 150 75 180 135 105 plant false 0 Rectangle -7500403 true true 135 90 165 300 Polygon -7500403 true true 135 255 90 210 45 195 75 255 135 285 Polygon -7500403 true true 165 255 210 210 255 195 225 255 165 285 Polygon -7500403 true true 135 180 90 135 45 120 75 180 135 210 Polygon -7500403 true true 165 180 165 210 225 180 255 120 210 135 Polygon -7500403 true true 135 105 90 60 45 45 75 105 135 135 Polygon -7500403 true true 165 105 165 135 225 105 255 45 210 60 Polygon -7500403 true true 135 90 120 45 150 15 180 45 165 90 sheep false 15 Circle -1 true true 203 65 88 Circle -1 true true 70 65 162 Circle -1 true true 150 105 120 Polygon -7500403 true false 218 120 240 165 255 165 278 120 Circle -7500403 true false 214 72 67 Rectangle -1 true true 164 223 179 298 Polygon -1 true true 45 285 30 285 30 240 15 195 45 210 Circle -1 true true 3 83 150 Rectangle -1 true true 65 221 80 296 Polygon -1 true true 195 285 210 285 210 240 240 210 195 210 Polygon -7500403 true false 276 85 285 105 302 99 294 83 Polygon -7500403 true false 219 85 210 105 193 99 201 83 square false 0 Rectangle -7500403 true true 30 30 270 270 square 2 false 0 Rectangle -7500403 true true 30 30 270 270 Rectangle -16777216 true false 60 60 240 240 star false 0 Polygon -7500403 true true 151 1 185 108 298 108 207 175 242 282 151 216 59 282 94 175 3 108 116 108 target false 0 Circle -7500403 true true 0 0 300 Circle -16777216 true false 30 30 240 Circle -7500403 true true 60 60 180 Circle -16777216 true false 90 90 120 Circle -7500403 true true 120 120 60 tree false 0 Circle -7500403 true true 118 3 94 Rectangle -6459832 true false 120 195 180 300 Circle -7500403 true true 65 21 108 Circle -7500403 true true 116 41 127 Circle -7500403 true true 45 90 120 Circle -7500403 true true 104 74 152 triangle false 0 Polygon -7500403 true true 150 30 15 255 285 255 triangle 2 false 0 Polygon -7500403 true true 150 30 15 255 285 255 Polygon -16777216 true false 151 99 225 223 75 224 truck false 0 Rectangle -7500403 true true 4 45 195 187 Polygon -7500403 true true 296 193 296 150 259 134 244 104 208 104 207 194 Rectangle -1 true false 195 60 195 105 Polygon -16777216 true false 238 112 252 141 219 141 218 112 Circle -16777216 true false 234 174 42 Rectangle -7500403 true true 181 185 214 194 Circle -16777216 true false 144 174 42 Circle -16777216 true false 24 174 42 Circle -7500403 false true 24 174 42 Circle -7500403 false true 144 174 42 Circle -7500403 false true 234 174 42 turtle true 0 Polygon -10899396 true false 215 204 240 233 246 254 228 266 215 252 193 210 Polygon -10899396 true false 195 90 225 75 245 75 260 89 269 108 261 124 240 105 225 105 210 105 Polygon -10899396 true false 105 90 75 75 55 75 40 89 31 108 39 124 60 105 75 105 90 105 Polygon -10899396 true false 132 85 134 64 107 51 108 17 150 2 192 18 192 52 169 65 172 87 Polygon -10899396 true false 85 204 60 233 54 254 72 266 85 252 107 210 Polygon -7500403 true true 119 75 179 75 209 101 224 135 220 225 175 261 128 261 81 224 74 135 88 99 wheel false 0 Circle -7500403 true true 3 3 294 Circle -16777216 true false 30 30 240 Line -7500403 true 150 285 150 15 Line -7500403 true 15 150 285 150 Circle -7500403 true true 120 120 60 Line -7500403 true 216 40 79 269 Line -7500403 true 40 84 269 221 Line -7500403 true 40 216 269 79 Line -7500403 true 84 40 221 269 wolf false 0 Polygon -16777216 true false 253 133 245 131 245 133 Polygon -7500403 true true 2 194 13 197 30 191 38 193 38 205 20 226 20 257 27 265 38 266 40 260 31 253 31 230 60 206 68 198 75 209 66 228 65 243 82 261 84 268 100 267 103 261 77 239 79 231 100 207 98 196 119 201 143 202 160 195 166 210 172 213 173 238 167 251 160 248 154 265 169 264 178 247 186 240 198 260 200 271 217 271 219 262 207 258 195 230 192 198 210 184 227 164 242 144 259 145 284 151 277 141 293 140 299 134 297 127 273 119 270 105 Polygon -7500403 true true -1 195 14 180 36 166 40 153 53 140 82 131 134 133 159 126 188 115 227 108 236 102 238 98 268 86 269 92 281 87 269 103 269 113 x false 0 Polygon -7500403 true true 270 75 225 30 30 225 75 270 Polygon -7500403 true true 30 75 75 30 270 225 225 270 @#$#@#$#@ NetLogo 5.0.5 @#$#@#$#@ @#$#@#$#@ @#$#@#$#@ @#$#@#$#@ @#$#@#$#@ default 0.0 -0.2 0 0.0 1.0 0.0 1 1.0 0.0 0.2 0 0.0 1.0 link direction true 0 Line -7500403 true 150 150 90 180 Line -7500403 true 150 150 210 180 @#$#@#$#@ 0 @#$#@#$#@