extensions [sound] globals [ listaEstrofas mylist a contador listaEstrofasFinal listaEstrofasFinalFinal estrofaParaEscucharRitmica estrofaRitmicaDelPrograma estrofaParaEscuchar estrofaMelodicaDelPrograma numeroAutomata estrofaAutomata rango row ;; current row old-rule ;; previous rule rules-shown? ;; flag to check if rules have been displayed gone? ;; flag to check if go has already been pressed ] patches-own [on?] to startup ;; initially, nothing has been displayed set rules-shown? false set gone? false set old-rule rule end ;;;;;;;;;;;;;;;;;;;;;;;; ;;; Setup Procedures ;;; ;;;;;;;;;;;;;;;;;;;;;;;; to setup-general ;; setup general working environment clear-patches clear-turtles set row max-pycor ;; reset current row refresh-rules set gone? false set rules-shown? false ;; rules are no longer shown since the view has been cleared end to single-cell setup-general reset-ticks ask patches with [pycor = row] [set on? false set pcolor background] ;; initialize top row ask patch 0 row [ set pcolor foreground ] ;; setup single cell in top center ask patch 0 row [ set on? true ] end to setup-random setup-general reset-ticks ask patches with [pycor = row] ;; randomly place cells across the top of the world [ set on? ((random-float 100) < density) color-patch ] end to setup-continue let on?-list [] if not gone? ;; make sure go has already been called [ stop ] ;; copy cell states from the current row to a list set on?-list map [ p -> [ on? ] of p ] sort patches with [ pycor = row ] setup-general ask patches with [ pycor = row ] [ set on? item (pxcor + max-pxcor) on?-list ;; copy states from list to top row color-patch ] end ;;;;;;;;;;;;;;;;;;;;;;;;;; ;;; GO Procedures ;;; ;;;;;;;;;;;;;;;;;;;;;;;;;; to go if (rules-shown?) ;; don't do unless we are properly set up [ stop ] if (row = min-pycor) ;; if we reach the end, continue from the top or stop [ ifelse auto-continue? [ set gone? true display ;; ensure everything gets drawn before we clear it setup-continue ] [ ifelse gone? [ setup-continue ] ;; a run has already been completed, so continue with another [ set gone? true stop ] ;; otherwise just stop ] ] ask patches with [ pycor = row ] ;; apply rule [ do-rule ] set row (row - 1) ask patches with [ pycor = row ] ;; color in changed cells [ color-patch ] tick end to do-rule ;; patch procedure let left-on? [on?] of patch-at -1 0 ;; set to true if the patch to the left is on let right-on? [on?] of patch-at 1 0 ;; set to true if the patch to the right is on ;; each of these lines checks the local area and (possibly) ;; sets the lower cell according to the corresponding switch let new-value (iii and left-on? and on? and right-on?) or (iio and left-on? and on? and (not right-on?)) or (ioi and left-on? and (not on?) and right-on?) or (ioo and left-on? and (not on?) and (not right-on?)) or (oii and (not left-on?) and on? and right-on?) or (oio and (not left-on?) and on? and (not right-on?)) or (ooi and (not left-on?) and (not on?) and right-on?) or (ooo and (not left-on?) and (not on?) and (not right-on?)) ask patch-at 0 -1 [ set on? new-value ] end ;;;;;;;;;;;;;;;;;;;;;;;;;; ;;; Utility Procedures ;;; ;;;;;;;;;;;;;;;;;;;;;;;;;; to color-patch ;;patch procedure ifelse on? [ set pcolor foreground ] [ set pcolor background ] end to-report bindigit [number power-of-two] ifelse (power-of-two = 0) [ report floor number mod 2 ] [ report bindigit (floor number / 2) (power-of-two - 1) ] end to refresh-rules ;; update either switches or slider depending on which has been changed last ifelse (rule = old-rule) [ if (rule != calculate-rule) [ set rule calculate-rule ] ] [ extrapolate-switches ] set old-rule rule end to extrapolate-switches ;; set the switches based on the slider set ooo ((bindigit rule 0) = 1) set ooi ((bindigit rule 1) = 1) set oio ((bindigit rule 2) = 1) set oii ((bindigit rule 3) = 1) set ioo ((bindigit rule 4) = 1) set ioi ((bindigit rule 5) = 1) set iio ((bindigit rule 6) = 1) set iii ((bindigit rule 7) = 1) end to-report calculate-rule ;; set the slider based on the switches let result 0 if ooo [ set result result + 1 ] if ooi [ set result result + 2 ] if oio [ set result result + 4 ] if oii [ set result result + 8 ] if ioo [ set result result + 16 ] if ioi [ set result result + 32 ] if iio [ set result result + 64 ] if iii [ set result result + 128 ] report result end ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;; SHOW-RULES RELATED PROCEDURES ;; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; to show-rules ;; preview cell state transitions setup-general ask patches with [pycor > max-pycor - 12] [ set pcolor gray - 1 ] let i 0 foreach list-rules [ the-rule -> let px (min-pxcor + i * floor (world-width / 8) + floor (world-width / 16)) - 4 ask patch px (max-pycor - 4) [ sprout 1 [ set xcor xcor - 3 print-block item 0 the-rule ;; left cell set xcor xcor + 3 print-block item 1 the-rule ;; center cell set xcor xcor + 3 print-block item 2 the-rule ;; right cell setxy (xcor - 3) (ycor - 3) print-block item 3 the-rule ;; next cell state die ] ] set i (i + 1) ] set rules-shown? true end ;; turtle procedure to print-block [print-on?] ;; draw a 3x3 block with the color determined by the state ask patches in-radius 1.5 ;; like "neighbors", but includes the patch we're on too [ set on? print-on? color-patch ] end to-report list-rules ;; return a list of state-transition 4-tuples corresponding to the switches report (list lput ooo [false false false] lput ooi [false false true ] lput oio [false true false] lput oii [false true true ] lput ioo [true false false] lput ioi [true false true ] lput iio [true true false] lput iii [true true true ]) end to calcularPatches set rango ( list ) set estrofaAutomata (list) set numeroAutomata (list) set contador 0 set rango (range -128 128 1) let sumador 0 foreach rango [ x -> ask patch x -64 [ if-else pcolor > 1 [ set numeroAutomata lput 1 numeroAutomata ] [ set numeroAutomata lput 0 numeroAutomata ] ] ] foreach numeroAutomata [ x -> if x > 0 [ set sumador (sumador + 1 ) ] set contador (contador + 1) if (contador mod 10 = 0)[ set estrofaAutomata lput sumador estrofaAutomata set sumador 0 ] ] TocarCancionAutomata end ; Copyright 1998 Uri Wilensky. ; See Info tab for full copyright and license. to TocarCancionAutomata print estrofaAutomata foreach estrofaAutomata [ x -> if(x > 0)[ wait 1 / x sound:play-note "Rain" ( ( 60) + x * 3 ) 64 (1 / x ) ; sound:play-drum "ACOUSTIC SNARE" 600 ] ] end to Inicializar clear-all set estrofaRitmicaDelPrograma (list) set listaEstrofas ( list ) set mylist ( list ) set listaEstrofasFinalFinal ( list ) set estrofaMelodicaDelPrograma (list) system-dynamics-setup system-dynamics-go end to avanzar if (ticks) < Maximum [ if ( round(ticks) mod 3 = 0 ) [ set listaEstrofas lput mylist listaEstrofas set mylist ( list ) ] set estrofaMelodicaDelPrograma lput round(N * 10) estrofaMelodicaDelPrograma set estrofaRitmicaDelPrograma lput round(N) estrofaRitmicaDelPrograma set mylist lput round(N ) mylist system-dynamics-go system-dynamics-do-plot ] end to dividirLista set listaEstrofasFinalFinal ( list ) set contador 0 set listaEstrofasFinal ( list) foreach listaEstrofas [ estrofa -> foreach estrofa [ numero2 -> set contador (contador + 1) if (contador mod 4 = 0)[ set listaEstrofasFinal lput mylist listaEstrofasFinal set mylist ( list ) ] set mylist lput numero2 mylist ] ] foreach listaEstrofasFinal [x -> set listaEstrofasFinalFinal lput (round ( median x )) listaEstrofasFinalFinal ] set listaEstrofasFinalFinal remove 0 listaEstrofasFinalFinal end to tocarMelodia limpiarLista imprimir print estrofaParaEscucharRitmica let RitmoDeLaNota 0 foreach estrofaParaEscuchar [ x -> if (x > 0 )[ let RitmoActual item RitmoDeLaNota estrofaParaEscucharRitmica if(RitmoActual > 0 and Dynamic_Rhythm)[ wait 1 / ( RitmoActual + 1 ) sound:play-note "TRUMPET" (x + 30) 64 (1 / ( RitmoActual + 1) ) ] if(Dynamic_Rhythm = false)[ wait 0.2 sound:play-note "TRUMPET" (x + 30) 64 (0.22) ] set RitmoDeLaNota (RitmoDeLaNota + 1) ] ] end to TocarCancion limpiarLista foreach listaEstrofasFinalFinal [ x -> if (x > 0)[ repeat x [ wait 1 / x sound:play-drum "ACOUSTIC SNARE" 600 ] ] ] end to dividirListaRitmica let numeroTemporal 0 let listaTemporal (list) set estrofaParaEscucharRitmica (list) set contador 0 foreach estrofaRitmicaDelPrograma [ numero2 -> set numeroTemporal numero2 set contador (contador + 1) if (contador mod 4 = 0)[ set estrofaParaEscucharRitmica lput (round(median(listaTemporal))) estrofaParaEscucharRitmica set listaTemporal (list) ] set listaTemporal lput numeroTemporal listaTemporal ] ;foreach listaEstrofasFinal [x -> set listaEstrofasFinalFinal lput (round ( median x )) listaEstrofasFinalFinal set contador 0 end to dividirListaMelodica let numeroTemporal 0 let listaTemporal (list) set estrofaParaEscuchar (list) set contador 0 foreach estrofaMelodicaDelPrograma [ numero2 -> set numeroTemporal numero2 set contador (contador + 1) if (contador mod 4 = 0)[ set estrofaParaEscuchar lput (round(median(listaTemporal))) estrofaParaEscuchar set listaTemporal (list) ] set listaTemporal lput numeroTemporal listaTemporal ] ;foreach listaEstrofasFinal [x -> set listaEstrofasFinalFinal lput (round ( median x )) listaEstrofasFinalFinal end to limpiarLista foreach listaEstrofas [ x -> if ( length(x) <= 1 ) [set listaEstrofas remove x listaEstrofas] ] dividirLista end to imprimir dividirListaMelodica dividirListaRitmica end @#$#@#$#@ GRAPHICS-WINDOW 239 519 761 786 -1 -1 2.0 1 10 1 1 1 0 1 0 1 -128 128 -64 64 1 1 1 ticks 30.0 BUTTON 17 517 125 550 setup single single-cell NIL 1 T OBSERVER NIL NIL NIL NIL 1 BUTTON 17 552 135 585 setup random setup-random NIL 1 T OBSERVER NIL NIL NIL NIL 1 SWITCH 120 807 218 840 OOO OOO 0 1 -1000 SWITCH 20 807 120 840 OOI OOI 0 1 -1000 SWITCH 120 774 218 807 OIO OIO 1 1 -1000 SWITCH 20 774 120 807 OII OII 1 1 -1000 SWITCH 120 741 218 774 IOO IOO 1 1 -1000 SWITCH 20 741 120 774 IOI IOI 0 1 -1000 SWITCH 120 708 218 741 IIO IIO 1 1 -1000 SWITCH 20 708 120 741 III III 0 1 -1000 TEXTBOX 21 650 111 668 Rule Switches: 11 0.0 0 TEXTBOX 23 894 113 912 Colors: 11 0.0 0 SLIDER 20 671 218 704 rule rule 0.0 255.0 163.0 1.0 1 NIL HORIZONTAL SLIDER 125 552 231 585 density density 0.0 100.0 17.0 1.0 1 % HORIZONTAL BUTTON 18 599 89 632 NIL go T 1 T OBSERVER NIL NIL NIL NIL 0 BUTTON 22 849 121 882 show rules show-rules NIL 1 T OBSERVER NIL NIL NIL NIL 1 SWITCH 92 599 232 632 auto-continue? auto-continue? 1 1 -1000 INPUTBOX 24 913 144 973 foreground 55.0 1 0 Color INPUTBOX 149 913 265 973 background 0.0 1 0 Color BUTTON 362 909 479 942 Play Song calcularPatches\n NIL 1 T OBSERVER NIL NIL NIL NIL 1 SLIDER 855 27 1027 60 Repetition Repetition 0 40 10.0 1 1 NIL HORIZONTAL SLIDER 860 84 1032 117 Amplitude Amplitude 0 10 1.59 0.01 1 NIL HORIZONTAL SLIDER 859 155 1031 188 Frequency Frequency 0 300 26.8 0.1 1 NIL HORIZONTAL SLIDER 858 215 1030 248 Maximum Maximum 0 40 14.0 1 1 NIL HORIZONTAL PLOT 309 22 788 341 plot 1 NIL NIL 0.0 10.0 0.0 10.0 true false "" "" PENS "N" 1.0 0 -16777216 true "" "" BUTTON 57 56 134 89 Initialize Inicializar\n NIL 1 T OBSERVER NIL NIL NIL NIL 1 BUTTON 182 59 272 92 Plot Figure avanzar T 1 T OBSERVER NIL NIL NIL NIL 1 BUTTON 109 126 211 159 Play Song tocarMelodia NIL 1 T OBSERVER NIL NIL NIL NIL 1 SLIDER 870 275 1042 308 Noise Noise 0 40 0.0 0.1 1 NIL HORIZONTAL SWITCH 869 344 1026 377 Dynamic_Rhythm Dynamic_Rhythm 0 1 -1000 TEXTBOX 214 445 419 495 Automata Model\n 26 0.0 1 TEXTBOX 111 10 261 42 ODE Model 26 0.0 1 @#$#@#$#@ ## WHAT IS IT? This model of netlogo, try to explain the complexity in music with the formulation of two type of modeling, ODE and cellular automata. The idea behind this, is that, the more complex the function we get with the parameters in the ODE, or the more complex visualization we get with the automata, we should listen to a more complex "song". Simplicity (monotone): that refers to the monotony of the rythm and/or the low variety of notes Chaos (random): to this we refer to the abrupt change of musical notes that can also have an unharmonious rhythm We think, that the complexity in music, is usally found, in between simplicity and chaos. ## HOW IT WORKS (ODE) For the ODE itself, it use a base function as a sine, and three other parameters in it, frequency, repetition, and amplitude. * Frequency, makes the sine function repeat more * Amplitude, makes the function increase o decrease respect to the value * There is another parameter (Maximum),that is used to put a limit to the plot * Repetition, makes the whole function after the X point. It should be less than the maximum, in that way, the function should repeat it self after the X point. * Noise, is a parameter to make the base function, more random. It has a big sensivity, and usually after 7 it mess up the whole function. Then, this function is cutted every four numbers, and then a mode is calculated. In this way, there are less notes, but the sound is more intersting and less monotone. ## HOW IT WORKS (AUTOMATA) An automata is a algorithm that is based on simple rules. When this rules are repited multiple times, it usually create intersting figures. You can see the rules used with the buton "show rules". There are multiple rules and combinations of rule. This model in particular use the last row of the automata, because it usually is the most complex row of the automata itself Then, this row is cutted every ten numbers, and then a mode is calculated. In this way, there are less notes, but the sound is more intersting and less monotone. ## HOW TO USE IT(ODE) First thing to do is initialize the model, you can do it press the button "initialize", then you have to press the button ("Plot Figure") to see the graphic of the model, you can hear the song pressing the button ("Play Song") once the graph is completed. You can check on or off, for a Dynamic Rythm. if this is on, when the pitch is high, it will play the note faster. When the pitch is low, it will play the note slower. If it is off, it will play a monotone rythm. ## HOW TO USE IT(AUTOMATA) In first place you have to press the button "setup single" or "setup random" in case you want a more random visualization. When you use the "setup single" it will be an organizated visualization, and it always be the same. When you use the "setup random", there is a "density" slider, to get different random patterns based on rules. You can customize your setting selecting different "Rules Switches" or use the slider to get a rule by the number. Once you select your setting, if you click on the "go" button you will see in the screen the visualization of the cellular automata, and once its finished, you can click on "Play Song" to listen to the song that is made, by the last row of the visualization. There is another option that is "auto continue", this will make the visualization again and again,unless the option is in "off". This should be in off, for the model to be played in a correct way. ## THINGS TO NOTICE Once you click the "Play Song" button for the ODE model, or the automata model, you can see in the netlogo console an array of numbers, this will show the music pattern that will be played Sometimes, when the automata is played, the graph in the ODE, will be messed up. This is usually fixed, by making another plot. Sometimes, if the pitch is really high, it will messup the model itself, is better to quit netlogo, and open it again. ## THINGS TO TRY (ODE) you can change the amplitude, the frequency, the maximun value that can take the equation and the repetition to see how they affect the graphic, and you can change the value of repetition, that allows you repeat the ecuation at certain point, it is suggested to put a low maximum, to make song shorter. Another intersting thing, is to see how the randomeness can affect the complexity of a monotone function, and see if it can get complex insted of just chaotic. ## THINGS TO TRY (AUTOMATA) * automata rule 131 * automata rule 135 * automata rule 188 setup random density 95% * automata model rule 105 setup random density 71% * automata model rule 102 setup random density 15% * automata model rule 181 setup random density 42% ## EXTENDING THE MODEL To extend the model there are two important features that could be implemented: * Trying to add more instruments, and then mix them together to get a more interesting music, and analyse how the complexity change. * For the ODE modeling, add a feature that can change the function to different types, in order to be able to analyse the complexity in different settings and with more intersting changes * Use chords instead of rhythm , to see how in can be percived in different ways the musical complexity. ## NETLOGO FEATURES One of the features that this model use, is the extension sound that allow us to make music, and with it, make the song with the ODE and cellular automata ## RELATED MODELS The base model for cellular automata was taken from netlogo examples (computer science, cellular automata) in specific CA 1D Elementary * Wilensky, U. (1999). NetLogo. http://ccl.northwestern.edu/netlogo/. Center for Connected Learning and Computer-Based Modeling, Northwestern University, Evanston, IL. ## CREDITS AND REFERENCES * Instrumentational complexity of music genres and why simplicity sells url : http://journals.plos.org/plosone/article?id=10.1371/journal.pone.0115255 * Wolfram, S. 1986. Theory and Applications of Cellular Automata: Including Selected Papers 1983-1986. World Scientific Publishing Co., Inc., River Edge, NJ. * Wolfram, S. 2002. A New Kind of Science. Wolfram Media Inc. Champaign, IL @#$#@#$#@ 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 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 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 6.0.2 @#$#@#$#@ setup-random repeat world-height - 1 [ go ] @#$#@#$#@ 0.1 org.nlogo.sdm.gui.AggregateDrawing 7 org.nlogo.sdm.gui.StockFigure "attributes" "attributes" 1 "FillColor" "Color" 225 225 182 203 80 60 40 org.nlogo.sdm.gui.WrappedStock "N" "0" 1 org.nlogo.sdm.gui.ReservoirFigure "attributes" "attributes" 1 "FillColor" "Color" 192 192 192 47 80 30 30 org.nlogo.sdm.gui.RateConnection 3 77 95 134 96 191 98 NULL NULL 0 0 0 org.jhotdraw.figures.ChopEllipseConnector REF 3 org.jhotdraw.standard.ChopBoxConnector REF 1 org.nlogo.sdm.gui.WrappedRate "Amplitude * sin( Frequency * ( ( ticks mod ((Repetition) ) ) ) )" "deltaN" org.nlogo.sdm.gui.WrappedReservoir REF 2 0 org.nlogo.sdm.gui.RateConnection 3 275 103 330 109 386 116 NULL NULL 0 0 0 org.jhotdraw.standard.ChopBoxConnector REF 1 org.jhotdraw.figures.ChopEllipseConnector org.nlogo.sdm.gui.ReservoirFigure "attributes" "attributes" 1 "FillColor" "Color" 192 192 192 385 102 30 30 org.nlogo.sdm.gui.WrappedRate "random-float(Noise)" "asd" REF 2 org.nlogo.sdm.gui.WrappedReservoir 0 REF 12 org.nlogo.sdm.gui.ReservoirFigure "attributes" "attributes" 1 "FillColor" "Color" 192 192 192 149 223 30 30 org.nlogo.sdm.gui.RateConnection 3 171 226 193 179 216 132 NULL NULL 0 0 0 org.jhotdraw.figures.ChopEllipseConnector REF 15 org.jhotdraw.standard.ChopBoxConnector REF 1 org.nlogo.sdm.gui.WrappedRate "random-float(Noise)" "fasd" org.nlogo.sdm.gui.WrappedReservoir REF 2 0 @#$#@#$#@ @#$#@#$#@ @#$#@#$#@ 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 @#$#@#$#@