ENGM 732 Queuing Applications
Motivation Idea: We want to minimize the total cost of a queuing system Let SC = cost of service WC = cost of waiting TC = total cost of system
Motivation Idea: We want to minimize the total cost of a queuing system Let SC = cost of service WC = cost of waiting TC = total cost of system min E[TC] = E[SC] + E[WC]
Motivation E[TC] = E[SC] + E[WC] E[TC] E[SC] E[WC] Service Level Cost
Example Suppose we have 10 CNC machines, 8 of which are required to meet the production quota. If more than 2 machines are down, the estimated lost profit is $400 per day per additional machine down. Each server costs $280 per day. Time to failure is exponential ( =0.05). Service time on a failed machine is also exponential ( =0.5). Should the firm have 1 or 2 repairmen ?
Example (rate diagrams) /20 8/20 8/20 7/20 1/20 1/2 1/2 1/2 1/2 1/ /20 8/20 8/20 7/20 1/20 1/ M/M/1 Queue M/M/2 Queue
Example (rate diagrams) /20 8/20 8/20 7/20 1/20 1/2 1/2 1/2 1/2 1/2 M/M/1 Queue PCP nn 0 CC n nn nn n n n
Example (rate diagrams) /20 8/20 8/20 7/20 1/20 1/2 1/2 1/2 1/2 1/2
Example (rate diagrams) /20 8/20 8/20 7/20 1/20 1/2 1/2 1/2 1/2 1/2
Example (rate diagrams) /20 8/20 8/20 7/20 1/20 1/2 1/2 1/2 1/2 1/2
Example (rate diagrams) /20 8/20 8/20 7/20 1/20 1/2 1/2 1/2 1/2 1/2
Example (rate diagrams) /20 8/20 8/20 7/20 1/20 1/
Waiting Costs ( g(N) form ) The current rate at which costs are being incurred is determined primarily by the current state N. gN n nn (),,, (),,,..., R S T
Example (rate diagrams) /20 8/20 8/20 7/20 1/20 1/2 1/2 1/2 1/2 1/2
Example (rate diagrams) /20 8/20 8/20 7/20 1/20 1/2 1/2 1/2 1/2 1/2
Example (rate diagrams) /20 8/20 8/20 7/20 1/20 1/2 1/2 1/2 1/2 1/ /20 8/20 8/20 7/20 1/20 1/
Waiting Costs ( g(N) form ) The current rate at which costs are being incurred is determined primarily by the current state N.
Waiting Costs For g(n) linear; g(n) = C w nP n EWCEgN gnP n n [][()] () 0
Waiting Costs For g(n) linear; g(n) = C w nP n EWCEgN gnP n n [][()] () 0 E gnPCnP C CL n n wn n wn n w []() 00 0
Example 2 A University is considering two different computer systems for purchase. An average of 20 major jobs are submitted per day (exp with rate =20). Service time is exponential with service rate dependent upon the type of computer used. Service rates and lease costs are shown below. ComputerService RateLease Cost MBI computer ( = 30) $5,000 / day CRAB computer ( = 25)$3,750 / day
Example 2 Scientists estimate a delay in research costs at $500 / day. In addition, due to a break in continuity, an additional component is given for fractional days. h(w) = 500w + 400w 2 where w = wait time for a customer
Waiting Costs ( h(w) model ) Ehwforcustomerwait hwfwdw w [()] ()() z expectedcost 0
Waiting Costs ( h(w) model ) Since customers arrive per day Ehwforcustomerwait hwfwdw w [()] ()() z expectedcost 0 EWCEhw hwfwdw w [][()] ()() z 0
Waiting Costs ( h(w) model ) Recall, for an M/M/1 queue, the distribution of the wait time is given by fwe w w ()() () EWChwfwdw wwe w w []()() ()() () z z
Example 2 (rate diagram) MBI Comp. CRAB Comp.
MBI Computer ( – = 10) EWCwwedw w []() z
MBI Computer ( – = 10) EWCwwedw wedwwe w ww []() ()() z zz
MBI Computer ( – = 10) z EWCwwedw wedwwe we we w ww ww []() ()() ()() zz zz
MBI Computer ( – = 10) z
CRAB Computer ( – = 5) z EWCwwedw w []()
CRAB Computer ( – = 5) z EWCwwedw we we w ww []() ()() zz
CRAB Computer ( – = 5) z EWCwwedw we we w ww []() ()(), (), () zz
CRAB Computer ( – = 5) z EWCwwedw we we w ww []() ()(), (), (), $, zz
Expected Total Cost EWC MBI CRAB [],, ETC MBI CRAB [],,,,,,
Decision Models Unknown s Let C s = cost per server per unit time Obj: Find s s.t. min E[TC] = sC s + E[WC]
Example (Repair Model) min E[TC] = sC s + E[WC] ssCsE[WC]E[TC]
Decision Models Unknown & s Let f( ) = cost per server per unit time A = set of feasible Obj: Find , s s.t. min E[TC] = sf( ) + E[WC]
Example For MBI = 30 CRAB = 25 f(),,,, ETCfEWC[]()[],,,,,,
Example For MBI = 30 CRAB = 25 f(),,,, ETCfEWC[]()[] ,,,,
Decision Models Unknown & s Choose both the number of servers and the number of service facilities Ex: What proportion of a population should be assigned to each service facility # restrooms in office building # storage facilities
Decision Models Unknown & s Let C s = marginal cost of server / unit time C f = fixed cost of service / facility – unit time p = mean arrival rate for population n = no. service facilities = p /
Decision Models Unknown & s Cost / facility = fixed + marginal cost of service + expected waiting cost + travel time cost = C f + C s +E[WC] + C t E[T]
Decision Models Unknown & s Cost / facility = C f + C s +E[WC] + C t E[T] Min E[TC] = n{ C f + C s +E[WC] + C t E[T] }
Example Alternatives one tool crib at location 2 two cribs at locations 1 & 3 three cribs at locations 1, 2, &
Example Each mechanic is assigned to nearest crib. Walking rate = 3 mph 12 3 ET alt [].,.,.,
Example Fixed cost / crib = $16 / hr (C f ) Marginal cost / crib= $20 / hr (C s ) Travel cost = $48 / hr (C t ) p = 120 / hr. = 120 / hr (1 crib) 12 3
Example 12 3 ETCnsEWCCET nsE n ET t []{[][]} {[]()[]}
Example 12 3 ETCnsEWCCET nsE n ET t []{[][]} {[]()[]} EWCCL w [] ETCnsL n ET[]{()[]} But,
Example 12 3 ETCnsL n ET[]{()[]} Consider 1 facility, 2 servers ( M/M/2 ) P 0 = L q = L = L q + / = 1.333
Example 12 3 P 0 = L q = L = L q + / = ETCLET[]{()()[]} (.)()(.).
Example 12 3