powered by NetLogo

view/download model file: patch-patterns.nlogo

WHAT IS IT?

This section could give a general understanding of what the model is trying to show or explain.


HOW IT WORKS

This section could explain what rules the agents use to create the overall behavior of the model.


HOW TO USE IT

This section could explain how to use the model, including a description of each of the items in the interface tab.


THINGS TO NOTICE

This section could give some ideas of things for the user to notice while running the model.


THINGS TO TRY

This section could give some ideas of things for the user to try to do (move sliders, switches, etc.) with the model.


EXTENDING THE MODEL

This section could give some ideas of things to add or change in the procedures tab to make the model more complicated, detailed, accurate, etc.


NETLOGO FEATURES

This section could point out any especially interesting or unusual features of NetLogo that the model makes use of, particularly in the Procedures tab. It might also point out places where workarounds were needed because of missing features.


RELATED MODELS

This section could give the names of models in the NetLogo Models Library or elsewhere which are of related interest.


CREDITS AND REFERENCES

This section could contain a reference to the model's URL on the web if it has one, as well as any other necessary credits or references.


PROCEDURES

;;; patch-patterns.nlogo, cr 23 jan 2012 in 4.1.3 by rha on pro
;;; for ross cds course lecture 6
;;; default graphics: pxycor max 16 (33 x 33), size 13 pixels

to setup
  ca
end

to wings
  import-drawing "images/winged.png"
end

to patt-1
  ask patches [ if pxcor > 0 [ set pcolor white ]]
end

to patt-2
  ask patches [ if pycor > 0 [ set pcolor yellow ]]
end

to patt-3
  ask patches [ if pxcor + pycor > 0 [ set pcolor red ]]
end

to patt-4
  ask patches [ if pxcor - pycor > 0 [ set pcolor blue ]]
end

to patt-5
  ask patches [ if pxcor mod 2 = 0 [ set pcolor magenta ]]
end

to patt-6
  ask patches [ if pycor mod 2 = 0 [ set pcolor green ]]
end
;;; end of code