model27.01.

No preview image

1 collaborator

Default-person Maxim Derkach (Author)

Tags

(This model has yet to be categorized with any tags)
Model group ResiliBaem | Visible to everyone | Changeable by group members (ResiliBaem)
Model was written in NetLogo 6.1.1 • Viewed 28 times • Downloaded 1 time • Run 0 times
Download the 'model27.01.' 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

turtles-own [
  house
  goal
  collected-heat
  age
  car-like ;: value 1-10
  pubble-like ;: value 1-10
  walk-like ;: value 1-10
  bike-like ;: value 1-10
  ]

workers-own[
  workplace
  work-from-home
  has-children
  has-car
]

seniors-own[
  has-car
]

children-own[
  p-school
]

patches-own [
  popularity ;; unnötig
  trafficStop
  land-cover ; if value 1 = building, if value 2 = road, if value 3 = green area
  temperature
  sales ;; from grocery
  ]

globals [buildings
  populous
 ; work-home-distance ; crasht mit dem interface variable
]


breed [
  workers
  worker
]

breed [
  seniors
  senior
]

breed [
  children
  child
]

to setup
  clear-all
  reset-ticks
  ;import-pcolors "traffic.png"
  ;ask patches [
   ;if pcolor = 104 [set trafficStop 1]
  ;]
  set-current-directory user-directory
  import-pcolors "heatmap.png"
    ;ask patches [set temperature pcolor]
    ;import-pcolors "landcover.png"
    ;ask patches [
      ;(ifelse pcolor = green [set land-cover 3]
        ;pcolor = yellow [set land-cover 1]
        ;pcolor = grey [set land-cover 2]
        ;)
    ;]
  set buildings (list)
  ;ask patches [
    ;set pcolor green
    ;set popularity 1
    ;set temperature 0
    ;set sales 0
  ;]

  create-workers initial-number-workers
[
    ;ask patch (random-xcor)(random-ycor) [become-workplace]
    set xcor random-xcor
    set ycor random-ycor
    set house one-of patches
    ;set collected-heat random (temperature)
    ;set goal one-of patches
    ;set color blue
    ;set size 2
    ;set income 1
  ]
end 

    ;let places patches with [ land-cover = 1] ; ist es sinnvoller das global zu machen?
    ;set house one-of patches ; home-base patch
    ;set workPlace one-of places with [distance house < work-home-distance]  ;with expected this input to be a true/false block but got a true/false instead
    ;set workplace one-of patches with [distance <= work-home-distance]
    ;set work-from-home random 2 ;uU mit % in commuteRange integrierbar, e.g. commuteRange = X with Y% workfromhome
    ;set has-children random 5 ; % o.ä. einbauen, aktiviert Kita(s) als Ziel, erhöht shop use, etc
    ;set has-car random 2 ; einbauen %Wert, use limit : X% Straßenpatches + uU theoretische Garagen?
    ;set car-like random 11 ;uU noch eingrenzen, Test if necessary..
    ;set pubble-like random 11 ; s.o.
    ;set bike-like random 11
    ;set walk-like random 11
 ; goal ; uU use to build travelroute

to go
  ask turtles
    [fd random 2]
  tick
end 

to home-work-distance
end 

There is only one version of this model, created 3 months ago by Maxim Derkach.

Attached files

No files

This model does not have any ancestors.

This model does not have any descendants.