Queue modelling

All topics specific to modeling questions in Enterprise Dynamics
MarvinH
Posts: 93
Joined: Tuesday 25 January, 2011 - 11:07
Contact:

Re: Queue modelling

Post by MarvinH »

Hello!
EvEs0r wrote:Hi!

Back again with another question! I want to write the wait times of all customers to Excel. I've got this covered with a single run, but it seems impossible to do this in an experiment? ED is trying to reopen the model every single run...Is there a solution for this?

Thanks!
I'm not quite sure what goes wrong in your model. Please have a look at this topic, as it may be valuable for you as well:

Using Scenario Manager

Kind regards,

Marvin
EvEs0r
Posts: 11
Joined: Friday 25 May, 2012 - 11:31

Re: Queue modelling

Post by EvEs0r »

Solved the issue by just simple writing to a table atom ;-)

But yet another problem. I specified an arrival pattern for the source atom, by using IF-statements for different time intervals:

Code: Select all

If(<(Time, Hr(0.25)), NegExp(900/ArrivalList(1,1)), 
If(<(Time, Hr(0.5)), NegExp(900/ArrivalList(2,1)), 
If(<(Time, Hr(0.75)), NegExp(900/ArrivalList(3,1)), 
If(<(Time, Hr(1)), NegExp(900/ArrivalList(4,1)), 
Where ArrivalList is a table with the number of arrivals per 15 min. and as this is a Poisson proces, their inter-arrival times should be exponential.

The problem is that on average the source creates too few clients; about 5% too few. The problem could be that this is a non-stationary poisson proces, but how can this be programmed?
MarvinH
Posts: 93
Joined: Tuesday 25 January, 2011 - 11:07
Contact:

Re: Queue modelling

Post by MarvinH »

Hello again!

You could solve this by using an ArrivalList in combination with a MultiServer. On the ArrivalList, you simply use the Poisson distribution to determine the number of arrivals in a particular interval (in your model 15 minutes). Right behind the ArrivalList you connect a MultiServer, with "unlimited" capacity (i.e. capacity sufficient to handle the maximum number of arrivals in each interval), with a cycle time of Uniform(0, Hr(0.25)). This way the ArrivalList determines the number of arrivals each interval (from the Poisson distribution), and the MultiServer spreads the arrivals over the interval.

I hope this works out for you!

Kind regards,

Marvin
EvEs0r
Posts: 11
Joined: Friday 25 May, 2012 - 11:31

Re: Queue modelling

Post by EvEs0r »

Hi Marvin,

Tried your solution and it seemed to work; but when I have a lot arrivals in 15 min (like 150+), not all of them are coming out the multiserver in the same 15 mins - not even when i make the cycletime deterministic (for instance 10 seconds)...This doesn't seem right to me, and really unexplainable... It seems like the MultiServer doesn't start working the whole batch at the same time or so.

Can you help me with that?

Thanks!
MarvinH
Posts: 93
Joined: Tuesday 25 January, 2011 - 11:07
Contact:

Re: Queue modelling

Post by MarvinH »

Hello again!

By what you are stating, it is not explainable to me as well!

What is the capacity of the MultiServer? By default (when you drag in a new MultiServer), the capacity is 10. However, in case you provide 150 arrivals within 15 minutes and the capacity is 10 with a cycle time of 10, all arrivals should be taken care of within 15 minutes easily.

Could you maybe upload (part of) your model so that I can have a look at it?

Kind regards,

Marvin
EvEs0r
Posts: 11
Joined: Friday 25 May, 2012 - 11:31

Re: Queue modelling

Post by EvEs0r »

Hey!

The capacity is 10000, so that shouldn't be a problem! It really is weird... I've attached the model to this post

BTW, When I open my model, i first have to click every server, queue, source, and the function atom, to get things working properly - there is a initialization problem, which I can't figure out.

Thanks!
Attachments
ModelForum.mod
(178.53 KiB) Downloaded 274 times
MarvinH
Posts: 93
Joined: Tuesday 25 January, 2011 - 11:07
Contact:

Re: Queue modelling

Post by MarvinH »

Hello!

I have updated your model considering:
EvEs0r wrote:BTW, When I open my model, i first have to click every server, queue, source, and the function atom, to get things working properly - there is a initialization problem, which I can't figure out.
The issues were caused by the fact that you had defined some global variables in atoms that were at the bottom of the model tree. I have put all global variables within the Initialize atom and put this atom on top of the model tree, now the model opens without errors.
EvEs0r wrote:The capacity is 10000, so that shouldn't be a problem! It really is weird..
Indeed the capacity is sufficient. The fact that not all products leave the MultiServer is due to the SendTo statement of the MultiServer. When the number of arrivals in a particular period is large, it can happen that 4 atoms leave the MultiServer shortly after each other. As you are sending the atoms to the smallest queue (and assuming that all queues behind the MultiServer are empty), the first atom is sent to Queue1, the second to Queue2 and the third to Queue3. The fourth product however is sent to Queue4, which might be unavailable at the time as it is only opening at 02:30. This way the MultiServer is not able to sent the atom through.

The easiest way to solve this is by changing the SendTo statement of the MultiServer.

Kind regards,

Marvin
Attachments
ModelForum_update.mod
(184.29 KiB) Downloaded 290 times
EvEs0r
Posts: 11
Joined: Friday 25 May, 2012 - 11:31

Re: Queue modelling

Post by EvEs0r »

Hey,

Thanks for your quick reply. But what should I change the SendTo into? Seems to me that this is a standard model, and that there should be a solution for it. As it represents a supermarket, Shortest Queue seems the best choice. Isn't there a way to use Shortest Queue of all open Queues?

Thanks,
Yannick
MarvinH
Posts: 93
Joined: Tuesday 25 January, 2011 - 11:07
Contact:

Re: Queue modelling

Post by MarvinH »

Hello,

Indeed there is. I assume you are working with an older version of Enterprise Dynamics, in which this strategy is not implemented yet for the predefined "Smallest queue" strategy. Within the new version of ED, strategy 14 has the following code:

Code: Select all

IndexMin(NrOC(c), if(OCReady(Count,c), Content(out(Count,c)),1e50))
In case you use this strategy for the SendTo, the availability of the next queue should be taken into account.

Good luck!

Kind regards,

Marvin
EvEs0r
Posts: 11
Joined: Friday 25 May, 2012 - 11:31

Re: Queue modelling

Post by EvEs0r »

HI! Thanks! Works like a charm again!

But the changes you made to the model, result in the histograms not working anymore! So I tried setting the Init-atom to rank 1 by myself (which worked), but now only the Cycletime histogram works. For the other two histograms to work, I still have to click every server and queue to get them working. So it seems that the functions in the function editor atom aren't initialized properly.
What can cause this?

Thanks again!
Post Reply