120 likes | 248 Views
Previously. Optimization Probability Review Inventory Models Markov Decision Processes Queues. Agenda. Hwk Additional Topics Simulation. Additional Topics?. service rate µ. departures. arrivals. rate . queue. servers. c. system. Queues.
E N D
Previously • Optimization • Probability Review • Inventory Models • Markov Decision Processes • Queues
Agenda • Hwk • Additional Topics • Simulation
service rate µ departures arrivals rate queue servers c system Queues • M/M/s (arrivals / service / # servers)M=exponential dist., G=general • W = E[T], Wq = E[Tq] waiting time in system (queue) • L = E[N], Lq = E[Nq] #customers in system (queue) • = /(cµ) utilization (fraction of time servers are busy)
What can we calculate? • W and L • Utilization • Distribution of L (for M/M/s) • How often Tq>c (for M/M/s) • Networks (for M/M/s) • Staffing necessary. Cost trade-offs.
What can we not do? • Distribution of Tq • Networks (for G/G/s) • Rush-hour effects • Priority classes • Balking, Reneging, Jockeying • Batching • Queue capacity
Simulation (Ch 15) • Interested in quantity X (it is random) • Run simulation to get realizations of X: • X1, X2, X3, … , Xn • Evaluate output: • look at average E[X] ≈ AVERAGE(X1,…,Xn) • standard deviation [X] ≈ STDEV(X1,…,Xn) • distribution of realizations
Examples What is X? • Time from check-in to boarding • Rush-hour effects • Probability waiting time > 1 hr
Agenda • Confidence intervals • for output evaluation • Generating realizations
Independent Case • Suppose X1, X2, X3, … , Xn are independent, • an = AVERAGE(X1,…,Xn) • sn = STDEV(X1,…,Xn) • Central limit theorem: • an - E[X] ≈ normal distribution • mean 0, standard deviation sn / n1/2 • Confidence interval for E[X] • P( E[X] < an+y) ≈ P( N(0,sn2/n) < y) • with probability p, E[X] not in [an-y , an+y] • y = -NORMINV(p/2, 0, sn / n1/2)
Example • X = # customers in line at lunch place at noon • Data X1,…,X20 from last month (n=20) • an=5.5, sn=2 • Want 90% confidence interval for E[X]: • y = -NORMINV(5%,0, 2/√20) ≈ 0.7 • E[X] in [4.8,6.2] with 90% probability
Rare Event • Estimate the probability that all the ambulances are busy when a call arrives • X = 1 if ambulance not available when call arrives, 0 if available • Suppose n=1000, an=7/1000 • sn = 0.08 • 90% confidence interval is [0.3%,1.1%] • What n is needed for 10% error bound? • 10% error y=0.1% (factor 4 smaller) 16x samples needed n = 16000