i have a headache with this problem in Excel
i have to create a simulation of orders that come randomly every 5mn, the time to treat every order is 3.9mn
if the orders are uniforme i don't have any problems to create a simulation but every time i have 0 orders in an interval of time my simulation fails.
time to treat an order=3.9mn
random orders every 5mn:
order flow: 2 2 2 2 2 2 2 2 2 2 2 2
time (mn) : 5 10 15 20 25 30 35 40 45 50 55 60
orders done: 1 2 3 5 6 7 8 10 11 12 14 15
to calculate if the order is done for example for the first and second order
= INT(5/3.9)=1 (in 5mn i have just one order done)
= INT(10/3.9)=2 (in 10mn i have 2 orders done)
up here no problem, but once my random orders change i can't find a function to create the series of orders done.
order flow: 1 0 6 2 0 1 3 0 1 2 4 0 1
time (mn) : 5 10 15 20 25 30 35 40 45 50 55 60 65
orders done: 1 1 2 3 4 6 7 8 9 12 13 14 16
i remark that every time i don't have any order to treat, the serie of uniform one 1 2 3 5... starts from the beginning only adding what was already prepared, but i don't how to translate this in function.
i hope that my problem is clear, thanks
I think to have understood your problem, but for what you said the second sequence you write is wrong. From time 45 min and 50 min there is an increment of 3 orders in 5 minutes, that's impossible since you can process maximum 5/3,9 = 1,282 orders per 5 minutes.
I don't know if there is a formula for calculate what you need but take a look at my table.
And consider this formula for the first column (the function SE() is IF() in my language):
for B3 -> =SE(B4=0;0;SE(B4=1;1;5/3,9))
for B4 -> =B1
for B5 -> =B4-B3
for B7 -> =INT(B3) -- for C7 -> INT(C3) -- and so on for D7, F7, ...
for column C, D and the others use this formula in C and expand it to the others columns:
for C3 -> =SE(C1=0;SE(B5=0;B3;SE(B5<(5/3,9);B3+B5;B3+(5/3,9)));SE((C1+B5)<(5/3,9);B3+C1+B5;B3+5/3,9))
for C4 -> =B4+C1
for C5 -> =C4-C3
You have to consider the numbers in every column as the state of the odrers/queue at the end of the 5 min time slot. You can see the total orders recieved, the queue of the orders that are not yet done, the orders done and the orders finished (in fact in 5 min if you recieved 2 orders you have finished one but you have processed more than one...).
This works assuming that the orders arrive at the beginning of the 5 minute time slotss…if the orders arrive at the third minute of the five considered as "time slot" you can't calculate how many orders you can process unless you specify when this orders arrive during the 5 minutes slot.
About the formulas...well it's just evaluating the different cases that can verify:
Hope this is the solution of your problem ;)
Ettore
Edit:
Just realized that are not needed all those tests, this is enough for C3 end extended to D3, E3, ...
=SE((C1+B5)<(5/3,9);B3+C1+B5;B3+5/3,9)
;)
Collected from the Internet
Please contact [email protected] to delete if infringement.
Comments