L15 16 Queueing

download L15 16 Queueing

of 61

Transcript of L15 16 Queueing

  • 7/30/2019 L15 16 Queueing

    1/61

    21012101--495495Advanced Topics in CE IAdvanced Topics in CE I

    Intro to Queuing TheoryIntro to Queuing Theory

    Manoj Lohatepanont, Sc.D.Manoj Lohatepanont, Sc.D.

    Chulalongkorn UniversityChulalongkorn University

  • 7/30/2019 L15 16 Queueing

    2/61

    Chulalongkorn University 2Manoj Lohatepanont 2007

    OutlineOutline Introduction to QueuingIntroduction to Queuing

    ApplicationsApplications Queuing SystemQueuing System

    DeterministicDeterministic

    StochasticStochastic Probability DistributionProbability Distribution

    LittleLittles Laws Law

    Queuing SystemsQueuing Systems

    M/M/1M/M/1 M/G/1M/G/1

    M/M/sM/M/s

  • 7/30/2019 L15 16 Queueing

    3/61

    Chulalongkorn University 3Manoj Lohatepanont 2007

    Queuing TheoryQueuing Theory What is Queuing Theory?What is Queuing Theory?

    A mathematical study ofA mathematical study ofqueuesqueues QueueQueueis a waiting line especially of persons or vehiclesis a waiting line especially of persons or vehicles

    awaiting processingawaiting processing

    When does queue occur?When does queue occur? A queue forms when current demand for a service exceedsA queue forms when current demand for a service exceeds

    the current capacity to provide that servicethe current capacity to provide that service

    Why study Queuing Theory?Why study Queuing Theory? Help provide decision or guideline on system capacityHelp provide decision or guideline on system capacity

  • 7/30/2019 L15 16 Queueing

    4/61

    Chulalongkorn University 4Manoj Lohatepanont 2007

    Why Is Queuing Decision Difficult?Why Is Queuing Decision Difficult?

    ProbabilisticProbabilistic nature of the problemnature of the problem

    It is often impossible to predict accurately when andIt is often impossible to predict accurately when andhow many customers will show up, and how long ithow many customers will show up, and how long it

    will take to service each customerwill take to service each customer

    E.g., checkout queues at supermarketsE.g., checkout queues at supermarkets Providing too much capacity costs moneyProviding too much capacity costs money

    Providing too little capacity leads to long wait inProviding too little capacity leads to long wait in

    queues, which in turn leads to other undesirablequeues, which in turn leads to other undesirableconsequencesconsequences

  • 7/30/2019 L15 16 Queueing

    5/61

    Chulalongkorn University 5Manoj Lohatepanont 2007

    How Does Queuing Theory Help?How Does Queuing Theory Help?

    Queuing theory itself does not directly provideQueuing theory itself does not directly provide

    optimaloptimalsolutionsolution

    Rather, it provides vital information aboutRather, it provides vital information about

    various characteristics of the queue to decisionvarious characteristics of the queue to decisionmakersmakers

    Average waiting timeAverage waiting time

    Average queue lengthAverage queue length

  • 7/30/2019 L15 16 Queueing

    6/61

    Chulalongkorn University 6Manoj Lohatepanont 2007

    ApplicationsApplications Traffic analysisTraffic analysis

    Industrial plantsIndustrial plants

    Retail storesRetail stores

    ServiceService--Oriented IndustriesOriented Industries Telephone switchboardTelephone switchboard

    Aircraft Takeoff/Landing SequenceAircraft Takeoff/Landing Sequence Expressway Toll PlazaExpressway Toll Plaza

  • 7/30/2019 L15 16 Queueing

    7/61

    Chulalongkorn University 7Manoj Lohatepanont 2007

    QueueQueue A queue is formed whenA queue is formed when

    demand exceeds service capacity for a period of timedemand exceeds service capacity for a period of time the arrival time headway is less than the service timethe arrival time headway is less than the service time

    at a locationat a location

    A queue needs not be physical waiting lineA queue needs not be physical waiting lineTelephone switchboardTelephone switchboard

    Car repair shopCar repair shop

    NonNon--Physical QueuePhysical Queue

  • 7/30/2019 L15 16 Queueing

    8/61

    Chulalongkorn University 8Manoj Lohatepanont 2007

    Queuing SystemQueuing System

    QueueQueue

    Server 1Server 1

    Queuing SystemQueuing System

    Server 2Server 2

  • 7/30/2019 L15 16 Queueing

    9/61

    Chulalongkorn University 9Manoj Lohatepanont 2007

    CustomersCustomers

    Queuing SystemQueuing System

    QueueQueue ServersServers

    Queuing SystemQueuing System

    InputInput

    SourceSource

    ServedServed

    CustomersCustomers

  • 7/30/2019 L15 16 Queueing

    10/61

    Chulalongkorn University 10Manoj Lohatepanont 2007

    Input SourceInput Source Size of Input Source (Calling Population)Size of Input Source (Calling Population)

    Infinite (Unlimited)Infinite (Unlimited)The size of input source is relatively largeThe size of input source is relatively large

    Implicit assumption of most queuing modelsImplicit assumption of most queuing models

    Finite (Limited)Finite (Limited)

    The size of input source is relatively smallThe size of input source is relatively small

    This assumption should be used when the rate at whichThis assumption should be used when the rate at which

    the input source generates new customers is significantlythe input source generates new customers is significantly

    affected by the number of customers in the queuingaffected by the number of customers in the queuingsystemsystem

  • 7/30/2019 L15 16 Queueing

    11/61

    Chulalongkorn University 11Manoj Lohatepanont 2007

    Arrival ProcessArrival Process InterarrivalInterarrivalTimeTime

    The time between two consecutive arrivals ofThe time between two consecutive arrivals ofcustomerscustomers

    MeanMeanInterarrivalInterarrivalTimeTime

    1/1/ time/customertime/customer 20 min/customer20 min/customer

    Mean Arrival RateMean Arrival Rate

    customers/time unitcustomers/time unit 0.05 customers/min0.05 customers/min

    Time

    1/ 1/ 1/

  • 7/30/2019 L15 16 Queueing

    12/61

    Chulalongkorn University 12Manoj Lohatepanont 2007

    QueueQueue Queue CapacityQueue Capacity

    InfiniteInfinite Queue size can grow relatively largeQueue size can grow relatively large

    Implicit assumption of most queuing modelsImplicit assumption of most queuing models

    FiniteFinite

    Queue size is limited by a relatively small numberQueue size is limited by a relatively small number

    This assumption should be used when there is a relativelyThis assumption should be used when there is a relatively

    small limit on how large the length of the queue can growsmall limit on how large the length of the queue can grow

  • 7/30/2019 L15 16 Queueing

    13/61

    Chulalongkorn University 13Manoj Lohatepanont 2007

    Queue DisciplineQueue Discipline The order in which members of the queue areThe order in which members of the queue are

    selected for serviceselected for service First In, First Out (FIFO)First In, First Out (FIFO)

    Most commonMost common

    Last In, First Out (LIFO)Last In, First Out (LIFO)

    Service in Random Order (SIRO)Service in Random Order (SIRO)

  • 7/30/2019 L15 16 Queueing

    14/61

    Chulalongkorn University 14Manoj Lohatepanont 2007

    ServersServers Number of ServersNumber of Servers

    One (s = 1)One (s = 1)

    Multiple (s > 1)Multiple (s > 1)

    Service TimeService Time Elapsed time from the commencement of service to its completionElapsed time from the commencement of service to its completion for afor a

    customercustomer

    Mean Service TimeMean Service Time

    1/1/ time/customertime/customer 10 min/customer10 min/customer

    Mean Service RateMean Service Rate

    customers/time unitcustomers/time unit 0.1 customers/min0.1 customers/min

    Time

    1/ 1/ 1/

  • 7/30/2019 L15 16 Queueing

    15/61

    Chulalongkorn University 15Manoj Lohatepanont 2007

    Deterministic QueueDeterministic Queue SupposeSuppose

    Mean arrival rateMean arrival rate = 0.67 customer/min= 0.67 customer/min 1/1/ = 1.5 min= 1.5 min

    Mean service rateMean service rate = 1 customer/min= 1 customer/min

    users

    1

    2

    3

    Time(min)0 1 2 3 4 5 6 7 8

  • 7/30/2019 L15 16 Queueing

    16/61

    Chulalongkorn University 16Manoj Lohatepanont 2007

    IfIf >> What happen whenWhat happen when >> ?? = 0.67; =0.5 = 0.67; =0.5

    In deterministic caseIn deterministic case

    users

    1

    2

    3

    4

    Time(min)0 1 2 3 4 5 6 7 8

  • 7/30/2019 L15 16 Queueing

    17/61

    Chulalongkorn University 17Manoj Lohatepanont 2007

    Probabilistic QueueProbabilistic Queue Queue can occur even whenQueue can occur even when

  • 7/30/2019 L15 16 Queueing

    18/61

    Chulalongkorn University 18Manoj Lohatepanont 2007

    Steady StateSteady State If the queuing system is allowed to operate for aIf the queuing system is allowed to operate for a

    long time, it can be expected, under certainlong time, it can be expected, under certainconditions, to reachconditions, to reach an equilibriuman equilibrium oror steady statesteady state

    Steady state means that the probability that youSteady state means that the probability that you

    will observe a certain state of the system doeswill observe a certain state of the system does

    not depend on the time at which you monitornot depend on the time at which you monitor

    the systemthe system

  • 7/30/2019 L15 16 Queueing

    19/61

    Chulalongkorn University 19Manoj Lohatepanont 2007

    UtilizationUtilization We define utilization of a queuing system asWe define utilization of a queuing system as

    followsfollows

    wherewhere ss is the number of serversis the number of servers

    ss is, therefore, TOTAL service rateis, therefore, TOTAL service rate

    A steady state is achievable whenA steady state is achievable when < 1< 1

    s

    =

  • 7/30/2019 L15 16 Queueing

    20/61

    Chulalongkorn University 20Manoj Lohatepanont 2007

    Queuing TaxonomyQueuing Taxonomy Queuing models can be classified by threeQueuing models can be classified by three

    components:components: InterarrivalInterarrivalTime Distribution (A),Time Distribution (A),

    Service Time Distribution (B), andService Time Distribution (B), and

    Number of Servers (m)Number of Servers (m)

    using the following notation.using the following notation.

    A/B/mA/B/m

  • 7/30/2019 L15 16 Queueing

    21/61

    Chulalongkorn University 21Manoj Lohatepanont 2007

    InterarrivalInterarrival/Service Time Distribution/Service Time Distribution Probability Distribution ofProbability Distribution of

    InterarrivalInterarrivalTime (A)Time (A) Service Time (B)Service Time (B)

    Common DistributionsCommon Distributions

    D: DeterministicD: Deterministic

    M:M: [[NegativeNegative]] Exponential DistributionExponential Distribution

    EEkk:: kkthth--orderorder ErlangErlangDistributionDistribution

    HHkk:: kkthth--orderorder HyperexponentialHyperexponential DistributionDistribution

    G:G: generalgeneral DistributionDistribution

  • 7/30/2019 L15 16 Queueing

    22/61

    Chulalongkorn University 22Manoj Lohatepanont 2007

    M/M/1M/M/1 For example, M/M/1 queuing system refers toFor example, M/M/1 queuing system refers to

    the queuing system that hasthe queuing system that hasExponentially distributedExponentially distributedinterarrivalinterarrivaltimetime

    Times between arrivals are exponentially distributedTimes between arrivals are exponentially distributed

    Exponentially distributed service timeExponentially distributed service time

    Service times for customers are exponentially distributedService times for customers are exponentially distributed

    One serverOne server

  • 7/30/2019 L15 16 Queueing

    23/61

    Chulalongkorn University 23Manoj Lohatepanont 2007

    0

    0.5

    1

    1.5

    2

    2.5

    0 1 2 3 4

    t

    f(t)

    Exponential DistributionExponential Distribution Unsymmetrical distributionUnsymmetrical distribution

    E(T) =E(T) =1/1/ ==0.50.5

    = 2= 2

    f(tf(t) =) =ee--tt t >= 0t >= 0

  • 7/30/2019 L15 16 Queueing

    24/61

    Chulalongkorn University 24Manoj Lohatepanont 2007

    ExampleExample If theIf the interarrivalinterarrival time is exponentiallytime is exponentially

    distributed and its meandistributed and its mean interarrivalinterarrival time is 0.5time is 0.5min (arrival ratemin (arrival rate = 2 customers/min)= 2 customers/min) Customers arrive on average every 0.5 minuteCustomers arrive on average every 0.5 minute

    ~2/3 of the customers arrive less than 0.5 minute~2/3 of the customers arrive less than 0.5 minuteapartapart

    ~1/3 of the customers arrive more than 0.5 minute~1/3 of the customers arrive more than 0.5 minuteapartapart

  • 7/30/2019 L15 16 Queueing

    25/61

    Chulalongkorn University 25Manoj Lohatepanont 2007

    Memory LessMemory Less PropertyProperty The probability distribution of the remaining time untilThe probability distribution of the remaining time until

    the next event (e.g., arrival) occurs is always the same,the next event (e.g., arrival) occurs is always the same,regardless of how much time has passed (i.e., it doesregardless of how much time has passed (i.e., it doesnot remember how much time has passed)not remember how much time has passed)

    If theIf the interarrivalinterarrival time of a bus is exponentially distributed,time of a bus is exponentially distributed,then this property implies that the probability that a bus willthen this property implies that the probability that a bus will

    arrive in the next minute is the samearrive in the next minute is the same no matter how long youno matter how long youhave waitedhave waited at the bus stopat the bus stop

  • 7/30/2019 L15 16 Queueing

    26/61

    Chulalongkorn University 26Manoj Lohatepanont 2007

    Relationship to Poisson DistributionRelationship to Poisson Distribution

    If theIf the interarrivalinterarrival time is exponentiallytime is exponentially

    distributed with parameterdistributed with parameter , then the number, then the numberof arrivals (e.g., customers) (of arrivals (e.g., customers) (XX) in a specified) in a specified

    length of timelength of time TThas a Poisson distribution withhas a Poisson distribution withparameterparameter TT

    Also calledAlso called Poisson Arrival ProcessPoisson Arrival Process

    Prob(Prob(XX = n= n) =) =n!n!

    ee--TT((T)T)nn

  • 7/30/2019 L15 16 Queueing

    27/61

    Chulalongkorn University 27Manoj Lohatepanont 2007

    Poisson DistributionPoisson Distribution We can use Poisson distribution to verify ourWe can use Poisson distribution to verify our

    assumption of exponentially distributedassumption of exponentially distributedinterarrivalinterarrival timetime

    By comparing the number of users that arrive forBy comparing the number of users that arrive for

    service during a specific period of time with theservice during a specific period of time with thenumber that the Poisson distribution suggestsnumber that the Poisson distribution suggests

  • 7/30/2019 L15 16 Queueing

    28/61

    Chulalongkorn University 28Manoj Lohatepanont 2007

    Quantities of InterestQuantities of Interest There are four major quantities of interest in aThere are four major quantities of interest in a

    queuing systemqueuing system

    Expected waiting time in the queueExpected waiting time in the queueWWqq ==

    Expected system occupancy timeExpected system occupancy timeWW==

    Expected number of users in the queueExpected number of users in the queueLLqq ==

    Expected number of users in the systemExpected number of users in the systemLL==

  • 7/30/2019 L15 16 Queueing

    29/61

    Chulalongkorn University 29Manoj Lohatepanont 2007

    Basic CharacteristicsBasic Characteristics UtilizationUtilization

    WhereWhere ssis the number of serversis the number of servers

    LetLet PPnn be probability that there arebe probability that there are nn users in theusers in thesystem, thensystem, then

    These are true for all queuing modelsThese are true for all queuing models

    s

    =

    0

    n

    n

    L nP

    =

    =

  • 7/30/2019 L15 16 Queueing

    30/61

    Chulalongkorn University 30Manoj Lohatepanont 2007

    LittleLittles Laws Law John D.C. Little at MIT is generally creditedJohn D.C. Little at MIT is generally credited

    with being the first to prove thesewith being the first to prove these steadysteady--statestaterelationships formally in 1961relationships formally in 1961

    L =L = WW

    LLqq == WWqq

  • 7/30/2019 L15 16 Queueing

    31/61

    Chulalongkorn University 31Manoj Lohatepanont 2007

    M/M/1M/M/1

    InterarrivalInterarrival time is exponentially distributedtime is exponentially distributed

    Service time is exponentially distributedService time is exponentially distributed

    One ServerOne Server

    FCFSFCFS

    Assumptions

  • 7/30/2019 L15 16 Queueing

    32/61

    Chulalongkorn University 32Manoj Lohatepanont 2007

    M/M/1M/M/1 ProbabilityProbabilitythat there arethat there are nnusers in an M/M/1users in an M/M/1

    queue isqueue is

    Therefore, the expected number of users in theTherefore, the expected number of users in thesystem (at steady state) issystem (at steady state) is

    (1 ) nnP =

    0 0

    (1 )1

    n

    n

    n n

    L nP n

    = =

    = = = =

  • 7/30/2019 L15 16 Queueing

    33/61

    Chulalongkorn University 33Manoj Lohatepanont 2007

    M/M/1M/M/1 Once L is known all other quantities of interestOnce L is known all other quantities of interest

    can be computed from Littlecan be computed from Littles Law and thes Law and thefollowing relationshipsfollowing relationships

    These equations are bridges between the twoThese equations are bridges between the twoequations in Littleequations in Littles Laws Law

    1q

    W W

    = + qL L

    = +

  • 7/30/2019 L15 16 Queueing

    34/61

    Chulalongkorn University 34Manoj Lohatepanont 2007

    M/M/1M/M/1 Results can be summarized as followsResults can be summarized as follows

    Note also that the probability that the system isNote also that the probability that the system isidle isidle is

    L

    =

    2

    ( )qL

    =

    1W

    =

    ( )qW

    =

    0 1P

    =

  • 7/30/2019 L15 16 Queueing

    35/61

    Chulalongkorn University 35Manoj Lohatepanont 2007

    Example 1Example 1 At a small grocery store, customers arriveAt a small grocery store, customers arrive

    according to Poisson process with a mean of 15according to Poisson process with a mean of 15customers per hour. The length of time it takescustomers per hour. The length of time it takes

    to checkout is exponentially distributed withto checkout is exponentially distributed with

    mean equals 3 minutes.mean equals 3 minutes. M/M/1M/M/1

    = 15 customer/hr= 15 customer/hr = 20 customer/hr= 20 customer/hr

  • 7/30/2019 L15 16 Queueing

    36/61

    Chulalongkorn University 36Manoj Lohatepanont 2007

    Example 1Example 1 ComputeCompute

    Probability that the checkout counter is idleProbability that the checkout counter is idle

    Probability that the checkout counter is busyProbability that the checkout counter is busy

    0

    151 1 0.25

    20P

    = = =

    01 1 0.25 0.75P = =

  • 7/30/2019 L15 16 Queueing

    37/61

    Chulalongkorn University 37Manoj Lohatepanont 2007

    Example 1Example 1 Probability that at least one customer is waitingProbability that at least one customer is waiting

    to checkoutto checkout

    (1 ) nn

    P =

    1

    1 (1 0.75)0.75 0.1875P = =

    150.75

    20

    = = =

    0 1 0.75 0.25P = =

    2 0 11 ( ) 1 (0.25 0.1875) 0.5625nP P P = + = + =

  • 7/30/2019 L15 16 Queueing

    38/61

    Chulalongkorn University 38Manoj Lohatepanont 2007

    Example 1Example 1 Average number of customers waiting toAverage number of customers waiting to

    checkoutcheckout2

    ( )q

    L

    =

    215 225

    2.2520(20 15) 100

    qL = = =

  • 7/30/2019 L15 16 Queueing

    39/61

    Chulalongkorn University 39Manoj Lohatepanont 2007

    Example 1Example 1 Suppose it costs the operator 3 Baht for eachSuppose it costs the operator 3 Baht for each

    minute that a customer spends waiting in theminute that a customer spends waiting in thequeue. What is the average cost per customer?queue. What is the average cost per customer?

    q qL W=

    2.250.15 /

    15

    q

    q

    LW hr customer

    = = =

    0.15 60 3 27 /Cost baht customer = =

  • 7/30/2019 L15 16 Queueing

    40/61

    Chulalongkorn University 40Manoj Lohatepanont 2007

    Example 1Example 1 For an additional of 400 Baht per hour, the operatorFor an additional of 400 Baht per hour, the operator

    can decrease the average service time to 2 minutes. Iscan decrease the average service time to 2 minutes. Isthe additional expenditure worthwhile?the additional expenditure worthwhile?

    = 30 customer/hr= 30 customer/hr

    15 150.033

    ( ) 30(30 15) 450q

    W

    = = = =

    0.033 60 3 6 /Cost baht customer = =27 6 21 /Savings baht customer = =21 15 315 /Savings baht hr = =

  • 7/30/2019 L15 16 Queueing

    41/61

    Chulalongkorn University 41Manoj Lohatepanont 2007

    Example 1Example 1 Alternative solutionAlternative solution

    Difference = 405Difference = 405 -- 90 = 315 baht/hr90 = 315 baht/hr

    AFTERAFTERBEFOREBEFORE

    2.25qL = 0.5qL =

    2.25 60 3

    405 /

    Cost

    baht hr

    =

    =

    0.5 60 3

    90 /

    Cost

    baht hr

    =

    =

  • 7/30/2019 L15 16 Queueing

    42/61

    Chulalongkorn University 42Manoj Lohatepanont 2007

    M/G/1M/G/1

    InterarrivalInterarrival time is exponentially distributedtime is exponentially distributed

    Service time is described only byService time is described only by

    -- an average service time, andan average service time, and

    -- a variancea varianceOne ServerOne Server

    FCFSFCFS

    Assumptions

  • 7/30/2019 L15 16 Queueing

    43/61

    Chulalongkorn University 43Manoj Lohatepanont 2007

    M/G/1M/G/1 In general, if the service time can be describedIn general, if the service time can be described

    by two quantitiesby two quantities Mean (1/Mean (1/))

    Variance (Variance (22))

    the expected queue length can be estimatedthe expected queue length can be estimatedfromfrom

    ( )

    2 2 2

    2 1qL

    +=

  • 7/30/2019 L15 16 Queueing

    44/61

    Chulalongkorn University 44Manoj Lohatepanont 2007

    M/G/1M/G/1

    As in the previous case, all other quantities ofAs in the previous case, all other quantities of

    interest can be calculated using Littleinterest can be calculated using Littles Law ands Law andthe following relationshipsthe following relationships

    Note also that the probability that the system isNote also that the probability that the system isidle isidle is

    1q

    W W

    = + qL L

    = +

    0 1P =

  • 7/30/2019 L15 16 Queueing

    45/61

    Chulalongkorn University 45Manoj Lohatepanont 2007

    Example 2Example 2

    Aircraft arrivals and departures at BangkokAircraft arrivals and departures at BangkokInternational Airport can be approximated as a PoissonInternational Airport can be approximated as a Poissonprocess at the average rate of 40 plane/hr. It takes theprocess at the average rate of 40 plane/hr. It takes theair traffic controller 1.2 min on average to land orair traffic controller 1.2 min on average to land ordispatch an aircraft with variance equals to 1.96 mindispatch an aircraft with variance equals to 1.96 min22..

    Assume FCFS queue discipline.Assume FCFS queue discipline. M/G/1M/G/1

    = 40 plane/hr= 40 plane/hr

    = 50 plane/hr= 50 plane/hr 22 = 0.00054444 hr= 0.00054444 hr22

  • 7/30/2019 L15 16 Queueing

    46/61

    Chulalongkorn University 46Manoj Lohatepanont 2007

    Example 2Example 2

    Average number of plane waiting for landing orAverage number of plane waiting for landing or

    takeofftakeoff

    ( )( )

    ( )

    2 2 2

    22 4050

    40 50

    2 1

    40 0.00054

    2 13.78

    qL

    plane

    +=

    +

    =

    =

  • 7/30/2019 L15 16 Queueing

    47/61

    Chulalongkorn University 47Manoj Lohatepanont 2007

    Example 2Example 2

    Average wait timeAverage wait time

    q qL W=

    3.780.094 /

    40q

    q

    LW hr plane

    = = =

  • 7/30/2019 L15 16 Queueing

    48/61

    Chulalongkorn University 48Manoj Lohatepanont 2007

    Example 2Example 2

    It is estimated that it costs 81,000 baht per hourIt is estimated that it costs 81,000 baht per hour

    for an aircraft to wait in the queue. What is thefor an aircraft to wait in the queue. What is thetotal cost of aircraft waiting to land or takeoff attotal cost of aircraft waiting to land or takeoff atthe airport?the airport?

    3.78 81, 000 306, 000 /Cost baht hr = =

  • 7/30/2019 L15 16 Queueing

    49/61

    Chulalongkorn University 49Manoj Lohatepanont 2007

    Example 2Example 2

    Common mistakesCommon mistakes

    0.094 81, 000 7, 650 / /Cost baht hr plane= =

    3.78qL plane=

    7, 650 3.78 28, 900 /Cost baht hr = =

    28, 900 / 306, 000 /baht hr baht hr

  • 7/30/2019 L15 16 Queueing

    50/61

    Chulalongkorn University 50Manoj Lohatepanont 2007

    M/M/sM/M/sAssumptionsInterarrivalInterarrival time is exponentially distributedtime is exponentially distributed

    Service time is exponentially distributedService time is exponentially distributed

    There are s serversThere are s servers

    FCFSFCFS

    / /

  • 7/30/2019 L15 16 Queueing

    51/61

    Chulalongkorn University 51Manoj Lohatepanont 2007

    M/M/sM/M/s

    When there areWhen there are ssservers, all with the sameservers, all with the same

    service rateservice rate

    ( ) ( )10 0

    11/

    ! ! 1

    n ss

    n s

    Pn s

    =

    = +

    ( )( ) ( )

    1

    0 2

    1 !

    s

    qL Ps s

    +

    =

    / /

  • 7/30/2019 L15 16 Queueing

    52/61

    Chulalongkorn University 52Manoj Lohatepanont 2007

    M/M/sM/M/s

    As in the previous cases, all other quantities ofAs in the previous cases, all other quantities of

    interest can be calculated using Littleinterest can be calculated using Littles Law ands Law andthe following relationshipsthe following relationships

    Note, however, thatNote, however, that

    1q

    W W

    = +q

    L L

    = +

    s

    =

    E l 3

  • 7/30/2019 L15 16 Queueing

    53/61

    Chulalongkorn University 53Manoj Lohatepanont 2007

    Example 3Example 3

    At a Burger Mary outlet, mean arrival rate of customersAt a Burger Mary outlet, mean arrival rate of customers

    is 60 customers per hour and each takes on average 3is 60 customers per hour and each takes on average 3minutes to complete order. Arriving customers formminutes to complete order. Arriving customers form

    one sneak queue in front of 4 cashiers. Assumeone sneak queue in front of 4 cashiers. Assume

    interarrivalinterarrival and service times are exponentiallyand service times are exponentiallydistributed.distributed.

    M/M/sM/M/s

    = 60 customer/hr= 60 customer/hr

    = 20 customer/hr= 20 customer/hr

    s = 4s = 4

    E l 3E l 3

  • 7/30/2019 L15 16 Queueing

    54/61

    Chulalongkorn University 54Manoj Lohatepanont 2007

    Example 3Example 3

    How would the average queue length and timeHow would the average queue length and time

    in the system change if a fifth cashier is opened.in the system change if a fifth cashier is opened.We first check whether steady state is achievableWe first check whether steady state is achievable

    600.75

    4 20s

    = = =

    Idl P b bili ( 4)Idl P b bili ( 4)

  • 7/30/2019 L15 16 Queueing

    55/61

    Chulalongkorn University 55Manoj Lohatepanont 2007

    Idle Probability (s=4)Idle Probability (s=4)

    ( ) ( )

    ( ) ( )

    [ ]

    1

    0

    0

    43 60 60

    20 20

    600 4 20

    11/

    ! ! 1

    1

    1/ ! 4! 1

    1 / 13 3.375 4

    1/26.5

    0.038

    n ss

    n s

    n

    n

    P

    n s

    n

    =

    =

    = +

    = + = +

    ==

    E d Q L h ( 4)E d Q L h ( 4)

  • 7/30/2019 L15 16 Queueing

    56/61

    Chulalongkorn University 56Manoj Lohatepanont 2007

    Expected Queue Length (s=4)Expected Queue Length (s=4)

    ( )

    ( ) ( )( )

    ( )

    1

    0 2

    56020

    26020

    1 !

    0.038 3! 4

    243

    0.038 6 1

    1.53

    s

    qL P

    s s

    customers

    + =

    =

    = =

    Idl P b bili ( 5)Idl P b bilit ( 5)

  • 7/30/2019 L15 16 Queueing

    57/61

    Chulalongkorn University 57Manoj Lohatepanont 2007

    Idle Probability (s=5)Idle Probability (s=5)

    ( ) ( )

    ( ) ( )

    [ ]

    1

    0

    0

    54 60 60

    20 20

    600 5 20

    11/

    ! ! 1

    1

    1/ ! 5! 1

    1/ 16.375 2.025 2.5

    1/21.44

    0.047

    n ss

    n s

    n

    n

    P

    n s

    n

    =

    =

    = +

    = + = +

    ==

    E t d Q L thE t d Q L th

  • 7/30/2019 L15 16 Queueing

    58/61

    Chulalongkorn University 58Manoj Lohatepanont 2007

    Expected Queue LengthExpected Queue Length

    ( )

    ( ) ( )( )

    ( )

    1

    0 2

    66020

    26020

    1 !

    0.047 4! 5

    729

    0.047 24 4

    0.35

    s

    qL P

    s s

    customers

    + =

    =

    = =

    E t d Ti i S tE p t d Tim in S t m

  • 7/30/2019 L15 16 Queueing

    59/61

    Chulalongkorn University 59Manoj Lohatepanont 2007

    Expected Time in SystemExpected Time in System

    S=4S=4

    S=5S=5

    0.35 0.006 / 0.35 /60

    qq

    LW hr cus m cus

    = = = =

    1.530.025 / 1.53 /

    60

    q

    q

    LW hr cus m cus

    = = = =

    Additi n l Q in Ch t i tiAdditional Queuing Characteristics

  • 7/30/2019 L15 16 Queueing

    60/61

    Chulalongkorn University 60Manoj Lohatepanont 2007

    Additional Queuing CharacteristicsAdditional Queuing Characteristics

    BalkingBalking

    Occur when a customer arrives at a finite queue that is fullyOccur when a customer arrives at a finite queue that is fullyoccupiedoccupied

    Or when a customer decides not to join the queue because itOr when a customer decides not to join the queue because itis too longis too long

    RenegingReneging Occur when a customer leaves the system without beingOccur when a customer leaves the system without being

    servedserved

    JockeyingJockeying

    Occur when a customer switches between queues thinkingOccur when a customer switches between queues thinkings/he will receive service faster by so doings/he will receive service faster by so doing

    Final QuestionFinal Question

  • 7/30/2019 L15 16 Queueing

    61/61

    Chulalongkorn University 61Manoj Lohatepanont 2007

    Final QuestionFinal Question

    Why does the use of express lanes make sense?Why does the use of express lanes make sense?

    SupermarketSupermarket Expressway EntranceExpressway Entrance

    Self Service CheckSelf Service Check--in at Airport (to a certain extent)in at Airport (to a certain extent)