Influencing the use of reusable dishes

No preview image

1 collaborator

Tags

(This model has yet to be categorized with any tags)
Visible to everyone | Changeable by the author
Model was written in NetLogo 6.3.0 • Viewed 28 times • Downloaded 3 times • Run 0 times
Download the 'Influencing the use of reusable dishes' modelDownload this modelEmbed this model

Do you have questions or comments about this model? Ask them here! (You'll first need to log in.)


Comments and Questions

Please start the discussion about this model! (You'll first need to log in.)

Click to Run Model

to setup
  clear-all                                                       ;; clear any existing elements and start from the beginning

  ask patches [set pcolor white]                                  ;; blank background

  create-turtles 1 [                                              ;; create the "restaurant"
    set shape "house"
    set color 74
    set size 3
    setxy 0 10
  ]

  create-turtles num-people-using-reusable [                      ;; create 14 people, because 14 out of 67 people always use reusable dishes
  setxy random-ycor random-ycor
  set shape "person"
  set color green

  ]

  create-turtles num-people-not-using-reusable [                  ;; create 53 people, because 53 out of 67 peole never or sometimes use reusable dishes
  setxy random-ycor random-ycor
  set shape "person"
  set color black
  ]

reset-ticks
end 

to go
  ask turtles with [shape = "person"] [                           ;; all people are moving around the model
    set heading random 360
    forward 1

    if color = green [move-to patch 0 10                          ;; if a person has the color pink then move to the restaurant and set color green, because reusable dishes were used
    setxy random-xcor random-ycor]                                ;; then set coordinates random again
    if any? other turtles-here with [color = black]               ;; if there a people with the color black on the same patch, then change color to green, because turtle was influenced
    [set color green]
  ]

  tick                                                            ;; a step has gone by
end 

There is only one version of this model, created 8 months ago by Johanna Helmreich.

Attached files

No files

This model does not have any ancestors.

This model does not have any descendants.