netlogo - Why doesn't this always create a triangle? -
i expect code create triangle each time, instead many times goes through wrap-around, creating zigzag line or disconnected angle pieces. why that? bug?
create go button (not forever button) run code
to go clear-all create-turtles 3 ask turtles [ setxy random-xcor random-ycor create-links-to (other turtles)] end
the links take shortest path, may go around world edges, (in default world topology) connected each other.
go "settings..." dialog , turn off wrapping if isn't behavior wanted.
see http://ccl.northwestern.edu/netlogo/docs/programming.html#topology details.
Comments
Post a Comment