I have a fairly basic question but i cant seem to get it working. I have a simple model in which trucks come into a queue, and unload via a server. Because the trucks do arive at various times, the queue can be full or not based on the incoming trucks. Only one truck can unload so if two or more trucks arrive within short time they will have to wait.
My question is about experimentation. I want the experimentation to show the number of times a truck had to wait more than 3 hours in the queue. I cant choose this function in the standard settings (only avgstay and maxstay are available). I have tried several things with status but it doesnt work. What code could should i use to let the experiment count the number of times a truck had to wait over 3 hours?
Kind Regards,
Dennis
Staytime in experimentation
Re: Staytime in experimentation
Dear Dennis,
Use a Label in the queue to remember the times that a truck wait for long. For example, in the exit trigger in the queue:
And in Experimentation, choose this label.
Remember to initialize it on Reset
KR
Josie
Use a Label in the queue to remember the times that a truck wait for long. For example, in the exit trigger in the queue:
Code: Select all
If(
time - EntryTime(i) > 3,
Label([WaitLong], c) := Label([WaitLong], c) +1
)
Remember to initialize it on Reset
KR
Josie
-
- Posts: 21
- Joined: Monday 23 April, 2012 - 15:20
Re: Staytime in experimentation
i have tried the suggestion but it doesnt work. I have added the model in the attachedment maybe you see what the problem is. It should only give the amount of the times a truck waited more than 3 hours.
thank you in advance,
Dennis
thank you in advance,
Dennis
- Attachments
-
- blaasautoshuidig.mod
- (21.83 KiB) Downloaded 338 times
Re: Staytime in experimentation
In Experimentation, when you choose Label waitlong, "cs" should be used to refer to wachtrij, not "c"
KR,
Josie
KR,
Josie