I would like to control the timing of turtle generation with a decrement-timer using variables obtained from the gamma distribution. The following is sample program syntax.
to setup-turtles
set number-of-turtles 0
set-default-shape turtles "circle"
set gamma-A 0
end
to go
let numle count [turtles-at 0 0] of patch min-pxcor 0
if numle = 0 [
if gamma-A = 0 [
set gamma-A random-gamma (α) (β)
create-car
ask turtles [
set gamma-A gamma-A - 1
set number-of-turtles number-of-turtles + 1
]
]
]
tick
end
If the patch at the left end of the road is empty and the decrement-timer is 0, it will generate a turtle. Then it activates the decrement- timer. The road starts at the left end and ends at the right end. However, with this syntax, it is not possible to generate the second and subsequent turtles. I would be pleased if you give me advice. Thank you.