Staytime in experimentation

All topics specific to modeling questions in Enterprise Dynamics
Post Reply
DennisvLankeren
Posts: 21
Joined: Monday 23 April, 2012 - 15:20

Staytime in experimentation

Post by DennisvLankeren »

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
Josie
Posts: 31
Joined: Friday 30 December, 2011 - 09:40

Re: Staytime in experimentation

Post by Josie »

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:

Code: Select all

If(
  time - EntryTime(i) > 3,
  Label([WaitLong], c) := Label([WaitLong], c) +1
)
And in Experimentation, choose this label.
Remember to initialize it on Reset

KR
Josie
DennisvLankeren
Posts: 21
Joined: Monday 23 April, 2012 - 15:20

Re: Staytime in experimentation

Post by DennisvLankeren »

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
Attachments
blaasautoshuidig.mod
(21.83 KiB) Downloaded 338 times
Josie
Posts: 31
Joined: Friday 30 December, 2011 - 09:40

Re: Staytime in experimentation

Post by Josie »

In Experimentation, when you choose Label waitlong, "cs" should be used to refer to wachtrij, not "c"

KR,
Josie
Post Reply