Final Queuing Theory

67
1 Introduction to Queuing Theory JAYPEE UNIVERSITY OF ENGINEERING AND TECHNOLOGY, GUNA (M.P) Presented by: 1. Roopam Pawar (112013) 2. Rohit Gurjar (112012) 3. Rahul Kr. Garg Presented to: Mr. H.K. Mishra Maths Deptt. JUET, Guna

Transcript of Final Queuing Theory

Page 1: Final Queuing Theory

1

Introduction to Queuing Theory

JAYPEE UNIVERSITY OF ENGINEERING AND TECHNOLOGY, GUNA (M.P)

Presented by:1. Roopam Pawar (112013)2. Rohit Gurjar (112012)3. Rahul Kr. Garg (112011)

Presented to:Mr. H.K. MishraMaths Deptt.JUET, Guna

Page 2: Final Queuing Theory

2

• What is Queuing Theory– Introduction– History– Applications– Need of Queuing Theory– Queuing Analysis– Cost vs. Service Graph

• What is queuing system– Block Diagram– Characteristics– Real world examples

Overview (I)

Page 3: Final Queuing Theory

3

cont`d…Overview (II)

• What is Queuing Process– Components– Multiple vs. Single Configuration– Structure– Elements– Kendall Notations– Operating Characteristics

• Queuing Models– Classification– Performance Measures– Flow Charts– Numerical Problems

Page 4: Final Queuing Theory

4

Introduction and History

• Also called ‘Waiting Line’ Theory.

• The theory of queuing systems was developed to provide

models for forecasting behaviors of systems subject to

random demand.

• Developed by Agner Krarup Erlang , a Danish engineer in

1909.

• David G. Kendall introduced an A/B/C queuing notation

in 1953.

• Objective behind its development was efforts to analyze

telephone traffic congestion with the aim of satisfying the

randomly arising demand for the services of Copenhagen

telephone system in 1909.

• Erlang observed that a telephone system can be modeled

by Poisson customer arrivals and exponentially distributed

service times.

Fig. A.K. Erlang (1878-1929)

Page 5: Final Queuing Theory

5

• Queue- A line of people or vehicles waiting for something.

• Queuing Theory– Mathematical study of waiting lines, using models to show results, and

show opportunities, within arrival, service, and departure processes

• Mathematical analysis of queues and waiting times in stochastic systems.– Used extensively to analyze production and service processes

exhibiting random variability in market demand (arrival times) and service times.

• Queues arise when the short term demand for service exceeds the capacity– Most often caused by random variation in service times and the times

between customer arrivals.– If long term demand for service > capacity the queue will explode!

What is Queuing Theory

Page 6: Final Queuing Theory

6

Applications of Queuing Theory

• Examples of such ‘arrival’/ ‘departure’ problems:

(a) Customers waiting to deposit electricity bills

(b) Machines waiting to be repaired

(c) Aircraft waiting to land at an airport

(d) Patients in a hospital who need treatment

• Service stations in these situations are:

(a) Cash counter

(b) Repairmen

(c) Runway

(d) Doctor

Page 7: Final Queuing Theory

7

Need of Queuing Theory

• Why do waiting lines develop? Because service is not rendered immediately on arrival

of customer at the service facility.

• Why?

- Lack of adequate service facility

- Inefficiency of the existing facility

• Therefore, to meet service demand

• Increase service capacity; and /or

• Raise capacity of existing capacity/facility, if possible.

• It is possible to build capacity to such high level that can always meet peak demand with

no queues.

• This would become uneconomical after a stage because capacity will remain idle to

varying degrees when there are no or very few customers.

Page 8: Final Queuing Theory

8

cont`d…

• Manager’s/ Management job is to balance.

• Inefficient/poor service excessive waiting cost in terms of:-

(a) Customer frustration

(b) Loss of goodwill in the long run

(c) Direct cost of idle employees (e.g. employees waiting at the store for

collection of tools).

• Conversely too high a service level high set-up cost idle time for service

stations.

• Goal of queuing modeling achievement of economic balance between

(a) Cost of providing service

(b) Cost associated with wait

Page 9: Final Queuing Theory

9

• Capacity problems are very common in industry and one of the main drivers of process redesign– Need to balance the cost of increased capacity against the gains of

increased productivity and service• Queuing and waiting time analysis is particularly important in service

systems– Large costs of waiting and of lost sales due to waiting

Prototype Example – ER at County Hospital• Patients arrive by ambulance or by their own accord• One doctor is always on duty• More and more patients seeks help longer waiting times

Why is Queuing Analysis Important ?

Page 10: Final Queuing Theory

10

Total Expected Cost of Operating the Facility

Increased Service

Tota

l exp

ecte

d c

ost

of

op

era

tin

g f

acil

ity

Total expected cost

S = Optimum service level

Cost of providing serviceWaiting time cost

Page 11: Final Queuing Theory

11

Customer arrivals

Departure of impatient customers

Departure of served customers

• A queuing system can be described as follows:"customers arrive for a given service, wait if the service cannot start immediately and leave after being served"

• The term "customer" can be men, products, machines, ...

What is Queuing System ?

Page 12: Final Queuing Theory

12

Queuing Systems can be characterized with several criteria:

• Customer arrival processes• Service time• Service discipline• Service capacity• Number of service stages

Characteristics of Queuing System

Page 13: Final Queuing Theory

13

• Commercial Queuing Systems– Commercial organizations serving external customers– Ex. Dentist, bank, ATM, gas stations, plumber, garage …

• Transportation service systems– Vehicles are customers or servers– Ex. Vehicles waiting at toll stations and traffic lights, trucks or ships

waiting to be loaded, taxi cabs, fire engines, elevators, buses …• Business-internal service systems

– Customers receiving service are internal to the organization providing the service

– Ex. Inspection stations, conveyor belts, computer support …• Social service systems

– Ex. Judicial process, waiting lists for organ transplants or student dorm rooms …

Real World Queuing System

Page 14: Final Queuing Theory

14

Calling Population

QueueService

Mechanism

Input Source The Queuing System

Jobs

Arrival Process

Queue Configuration

Queue Discipline

Served Jobs

Service Process

leave the system

Queuing Process

Page 15: Final Queuing Theory

15

• The calling population– The population from which customers/jobs originate– The size can be finite or infinite (the latter is most

common)– Can be homogeneous (only one type of customers/ jobs)

or heterogeneous (several different kinds of customers/jobs)

• The Arrival Process– Determines how, when and where customer/jobs arrive to

the system– Important characteristic is the customers’/jobs’ inter-

arrival times – To correctly specify the arrival process requires data

collection of interarrival times and statistical analysis.

Components of Queuing Process

Page 16: Final Queuing Theory

16

• The queue configuration– Specifies the number of queues

• Single or multiple lines to a number of service stations

– Their location– Their effect on customer behavior

• Balking and reneging– Their maximum size (of jobs the queue can hold)

• Distinction between infinite and finite capacity

cont`d…

Page 17: Final Queuing Theory

17

Servers

Multiple Queues

Servers

Single Queue

Example of Queuing Configuration

Page 18: Final Queuing Theory

18

1. The service provided can be differentiated– Ex. Supermarket express lanes

2. Labor specialization possible3. Customer has more flexibility4. Balking behavior may be

deterred– Several medium-length lines are

less intimidating than one very long line

1. Guarantees fairness– FIFO applied to all arrivals

2. No customer anxiety regarding choice of queue

3. Avoids “cutting in” problems4. The most efficient set up for

minimizing time in the queue5. Jockeying (line switching) is

avoided

Multiple Line Advantages Single Line Advantages

Multiple vs Single Queue configuration

Page 19: Final Queuing Theory

19

• The Service Mechanism– Can involve one or several service facilities with one or several

parallel service channels (servers) - Specification is required– The service provided by a server is characterized by its service time

• Specification is required and typically involves data gathering and statistical analysis.

• Most analytical queuing models are based on the assumption of exponentially distributed service times, with some generalizations.

• The queue discipline– Specifies the order by which jobs in the queue are being served.– Most commonly used principle is FIFO.– Other rules are, for example, LIFO, SPT, EDD…– Can entail prioritization based on customer type.

components of queuing process cont`d…

Page 20: Final Queuing Theory

20

General Structure of Queuing System

• Arrival Process• Arrival (Input) Distribution• Service (Output) Distribution• Service System• Maximum number of people allowed into the system• Calling source or population• Customer Behaviour

Population

Arrival Process

Queue Service System Customers leave

Elements of Queuing System

Page 21: Final Queuing Theory

21

1. Arrival Process.

(a) According to source

(i) Finite

(ii) Infinite

(b) According to numbers

(iii) Individual, as in a bank

(ii) In groups, as in a ship

(c) According to time

(iv) Deterministic, as in automated processes

(v) Stochastic (Probabilistic), at random

ELEMENTS OF QUEUING SYSTEM

Page 22: Final Queuing Theory

22

2. Arrival (or input) distribution.

• It represents the pattern in which customers arrive at a service facility.

• Arrivals can be characterized either by an average arrival rate or by an average arrival time.

• An average arrival rate denotes the average number of arrivals in a given interval of time – e.g. two customers per hour, four trucks per minute, two potholes per kilometer of road, five typing errors per printed page.

• In contrast, average arrival time denotes the average time between two successive arrivals – e.g. 30 minutes between customers, 0.25 minutes between trucks, 0.5 kilometers between potholes, 0.2 pages between typing errors.

• Important to remember that for queuing models, we typically use the average rate.

• Arrivals may be separated by equal intervals of time, unequal but definitely known intervals of time, or by unequal intervals of time whose probabilities are known; the last one is termed as random arrivals.

ELEMENTS OF QUEUING SYSTEM

Page 23: Final Queuing Theory

23

Notation of Kendall

The following is a standard notation system of queueing systems

T/X/C/K/P/Z with

– T: probability distribution of inter-arrival times– X: probability distribution of service times– C: Number of servers– K: Queue capacity– P: Size of the population– Z: service discipline

Page 24: Final Queuing Theory

24

Customer arrival processT/X/C/K/P/Z

• T can take the following values:– M : markovian (i.e. exponential)– G : general distribution– D : deterministic– Ek : Erlang distribution– …

• If the arrivals are grouped in lots, we use the notation T[X] where X is the random variable indicating the number of customers at each arrival epoch– P{X=k} = P{k customers arrive at the same time}

• Some arriving customers can leave if the queue is too long

Page 25: Final Queuing Theory

25

Service timesT/X/C/K/P/Z

• X can take the following values:– M : markovian (i.e. exponential)– G : general distribution– D : deterministic– Ek : Erlang distribution– …

Erlang distribution Ek with parameter m

k exponential servers with parameter m

Page 26: Final Queuing Theory

26

Number of serversT/X/C/K/P/Z

In simple queueing systems, servers are identical

Page 27: Final Queuing Theory

27

Queue capacityT/X/C/K/P/Z

Loss of customers if the queue is full

Capacity K

Page 28: Final Queuing Theory

28

Size of the populationT/X/C/K/P/Z

The size of the population can be either finite or infinite

For a finite population, the customer arrival rate is a function of the number of customers in the system: l(n).

Page 29: Final Queuing Theory

29

Service disciplineT/X/C/K/P/Z

Z can take the following values:

• FCFS or FIFO : First Come First Served

• LCFS or LIFO : Last Come First Served

• RANDOM : service in random order

• HL (Hold On Line) : when an important customer arrives, it takes the head of the queue

• PR ( Preemption) : when an important customer arrives, it is served immediately and the customer under service returns to the queue

• PS (Processor Sharing) : All customers are served simultaneously with service rate inversely proportional to the number of customers

• GD (General Discipline)

Page 30: Final Queuing Theory

30

2. Arrival (or input) distribution.

• It turns out that in many real-world queuing problems, even when the arrivals are random, the number of arrivals per interval can be estimated using the Poisson Probability Distribution.

• Poisson distribution is applicable whenever the following assumptions are made:-

(a) The average arrival rate over a given interval is known.

(b) This average rate is the same for all equal-sized intervals.

(c) The actual number of arrivals in one interval has no bearing on the actual number of arrivals in another interval.

(d) There cannot be more than one arrival in an interval as the size of the interval approaches zero.

• The mean value of the arrival rate, i.e. average arrival rate, is represented by λ (Lambda).

ELEMENTS OF QUEUING SYSTEM

Page 31: Final Queuing Theory

31

• For a given average arrival rate, a discrete Poisson distribution can be established by using the formula

P(x) = (λx. e-λ)/x! for x=0,1,2,….. where,

x = number of arrivals per interval

P(x) = Probability of exactly ‘x’ arrivals in an interval#.

λ = average arrival rate (i.e. average number of arrivals per unit interval)

e = 2.71828 or 2.7183

{# - The intervals could be time or space (length/ distance).}

• Properties of Poisson Probability distribution (which is a discrete probability distribution)

(a) Probability of an occurrence is the same for any two

intervals# of equal length.

(b) Occurrence or non-occurrence in any interval# is independent of the occurrence or non-occurrence in any

other interval#.

ELEMENTS OF QUEUING SYSTEM

Page 32: Final Queuing Theory

32

(3) Service (or output) distribution.

• Service patterns are like arrival patterns in that they can be either constant, variable but known, or random (variable with only known probability).

• If the service time is constant, it takes the same amount of time to take care of each customer – e.g. processes in a soft drinks industry.

• However, more often than not, service times are randomly distributed.

• It turns out that in real-world queuing problems, such situations are well represented by exponential distribution.

• Poisson and exponential probability distributions are directly related to each other. If the number of arrivals follows a Poisson distribution, it turns out that the time between successive arrivals follows an exponential distribution.

• Processes that follow these distributions are commonly referred to as Markovian processes.

• Mean value of service rate is represented by μ.

….Cont’d

ELEMENTS OF QUEUING SYSTEM

Page 33: Final Queuing Theory

33

Service Distribution

• Just as we did with arrivals, we need to distinguish here between service rate and service time – while the service rate denotes the number of units served in a given interval of time, the service time denotes the length of time taken to actually perform the service.

• Although the exponential distribution estimates the probability of service times, the parameter used in this computation is the average rate.

• Exponential distribution can be established using the formula:

P(t) = e- μt (t≥0) where,

t = Service time

P(t) = probability that service time will be greater than t

μ = average service rate (i.e. average number of customers served per unit time

e = 2.7183

Expected time (mean of the exponential distribution), E(t) = 1/λ

Note : Mean of exponential distribution is the inverse of the mean of the Poisson distribution.

ELEMENTS OF QUEUING SYSTEM

Page 34: Final Queuing Theory

35

(4) Service System(a) Service Channels (b) Speed of Service (c) Service Discipline

(a) Service Channels :(i) Single Service facility with single queue

ELEMENTS OF QUEUING SYSTEM

Arrivals

Queue

Service facility Customers leave

Single Server Single Queue E.g. Library counter

Page 35: Final Queuing Theory

36

Service System (a) Service Channels :

(ii) Multiple parallel facility with single queue

ELEMENTS OF QUEUING SYSTEM

Service facility

Queue Customers leave

Arrivals

Multiple Parallel Servers Single Queue E.g. Car Service Station

Page 36: Final Queuing Theory

37

Service System (a) Service Channels :

(iii) Multiple parallel facility with multiple queues

QueueService facility

Customers leave

Arrivals

Arrivals

Arrivals

Arrivals

Multiple Parallel Servers Multiple Queues E.g. Railway Reservation Counter

ELEMENTS OF QUEUING SYSTEM

Page 37: Final Queuing Theory

38

Service System (a) Service Channels :

(iv) Service Facilities in Series

Arrivals

Queue Service facility

Customers leave

Multiple Servers in Series E.g. Machining of an item consisting of cutting, turning, grinding drilling and packaging

Queue Service facility

ELEMENTS OF QUEUING SYSTEM

Page 38: Final Queuing Theory

39

Service System

(b) Speed of Service:

Speed with which service can be provided can be expressed in two ways :-

(i) Service Rate: No. of customers served during a unit of time.

(ii) Service Time: Amount of time needed to serve a customer.

For e.g., if a cashier can serve 10 customers in an hour, then Service Rate is 10 customers per hour and Service Time is 6 minutes per customer.

(c) Service Discipline:

(i) First come-first served (FCFS) or

(ii) Last come-first served (LCFS) or Last in-First out (LIFO) basis

(iii) Service in random order (SIRO)

(iv) Priority Service E.g. Customers called according to some identifiable characteristics (say length of job), treatment of VIPs in preference to other patients in a hospital

ELEMENTS OF QUEUING SYSTEM

Page 39: Final Queuing Theory

40

(5) Maximum number of people allowed into the system

• Maximum number can be ‘finite’ or ‘infinite’.

• In some facilities, only a limited number of customers or

units are allowed into the system and new arriving

customers/ units are not allowed to join the system unless

the number becomes lesser than the limiting value.

• For example, computerized system – up to limiting value you

get into the system and till you are connected to a server, a

pre-recorded message comes to you that you are in the

queue. However, in case you dial when there are more

customers than the limiting value already in the system, you

will not be allowed into the system and you get an engaged

tone.

ELEMENTS OF QUEUING SYSTEM

Page 40: Final Queuing Theory

41

(6) Calling source or population

- Arrival pattern depends on the source that generates them

- If only few potential customers – calling source or population is called ‘finite’

- If large number of potential customers – called ‘infinite’.

- Another rule for categorizing source as finite or infinite –

(i) A finite source exists when an arrival affects the probability of arrival of potential future customers.

For Example: say, ‘M’ machines are running – if one machine breaks down, it becomes a customer and cannot generate another ‘call’ till repaired or serviced, thus affecting the probability of breakdown of (M-1) machines, i.e. rate of arrival of the remaining machines. Hence, the calling source is termed as finite.

(ii) An infinite source exists when arrival of one customer does not affect the rate of arrival of potential future customers.

ELEMENTS OF QUEUING SYSTEM

Page 41: Final Queuing Theory

42

(7) Customer Behaviour or Queuing Behaviour

This element is only applicable where human customers are

involved.

(a) Jockeying – i.e. going/moving from one queue to another

in the hope of reducing waiting time.

(b) Balking – i.e. not joining the queue at all because of the

anticipated long delay.

(c) Reneging – Leaving the queue and going away because

they have been waiting too long

ELEMENTS OF QUEUING SYSTEM

Page 42: Final Queuing Theory

43

An analysis of a given queuing system involves a study of its

different operating characteristics. This is done using queuing

models. Commonly used operating characteristics are :-

(a) Queue Length (Lq) – Average number of customers in the

queue waiting to get service. Long queues may indicate poor

service performance or inadequate service facilities. Small

queues may imply too much server capacity.

(b) System Length (Ls) – Average number of customers in the

system, i.e. both those waiting to be served and those being

served.

….Cont’d

OPERATING CHARACTERISTICS OF QUEUING SYSTEM

Page 43: Final Queuing Theory

44

(c) Waiting Time in the Queue (Wq) – Average time that a

customer has to wait in the queue to get service. Long

waiting time is directly related to customer dissatisfaction

and potential loss of future revenues. Very less waiting time

may indicate too much service capacity and scope to reduce

service cost.

(d) Total Time in the System (Ws) – Average time that a

customer spends in the system, from entry in the system till

he leaves the system on completion of service (i.e. waiting

time + service time).

(e) Utilization factor (ρ) – It is the proportion of time that a

server actually spends with the customers, i.e. average

utilization. It is also called ‘traffic intensity’ or ‘clearing

ratio’ or ‘proportion of time that the server is busy’.

OPERATING CHARACTERISTICS OF QUEUING SYSTEM

Page 44: Final Queuing Theory

45

Queuing Models

Assumption:

• Various models that we would now be seeing are based on the

assumption that the system operates under ‘equilibrium or

steady state’ conditions and is not in the ‘transient’ stage.

• For example, opening of a departmental store during a

“normal” day or during a “big sale” day represent radically

different initial conditions (small or non-existent initial queue

versus long initial queue) which will affect the operating

characteristics during the early part of the operating period.

• However, as time goes by, the system will eventually settle

down to its long run or steady state tendencies.

Page 45: Final Queuing Theory

46

• Another example for settling down into the steady state

condition in the long run is the concept of “learning curves”.

• When an aircraft is newly purchased, initial servicing time of

the aircraft is very high.

• With practice, however, the time period will gradually reduce

and eventually settle down to an average steady state condition.

Transient Phase

Steady State Phase

Steady State Mean

Time

No o

f u

nit

s in

th

e q

ueu

e

Queuing Models

Page 46: Final Queuing Theory

47

Queuing Models - Deterministic

• Queuing models can be categorized as “Deterministic” or “Probabilistic”.

DETERMINISTIC QUEUING MODEL

1. If each customer or unit arrives at fixed or known intervals and the service time is known with certainty, the queuing model would be deterministic in nature.

2. Suppose customers come to a bank’s teller counter every 5 minutes. Interval between arrivals of any two successive customers is exactly 5 minutes.

(a) Suppose the teller takes exactly 5 minutes to serve a customer – here both arrival and service rates = 12 customers per hour. In such a situation, there will never be a queue and the teller will always be busy.

Page 47: Final Queuing Theory

48

Queuing Models - Deterministic

(b) Suppose that the teller can serve 15 customers per hour – consequence of this higher service rate would be that the teller would be busy 4/5th of the time and idle for 1/5th of the time i.e. he would take 4 minutes to serve a customer and wait for 1 minute for the next customer to arrive. Therefore, there would be no queue.

(c) If teller can serve 10 customers per hour – teller will always be busy and queue length will increase continuously without limit i.e. if service rate is lesser than the arrival rate, the service facility cannot cope with all the arrivals and eventually the system leads to an explosive situation. Such a problem can only be solved by providing additional service facility.

Page 48: Final Queuing Theory

49

Symbolically, if

λ = arrival rate of customers per unit time;

μ = service rate of customers per unit time; then,

if λ > μ a waiting line will be formed that will increase

indefinitely; the service facility will always be busy; and the

service system will eventually fail.

if λ < or = μ there will be no waiting line; the

proportion of time the service will be idle is (1- λ/μ).

λ/μ = ρ (pronounced ‘Rho’), is also called ‘average utilization’

or ‘traffic intensity’ or ‘clearing ratio’ or ‘proportion of time

that the server is busy’. ρ is the proportion of time that the

system will be busy.

Queuing Models - Deterministic

Page 49: Final Queuing Theory

50

So, in other words, if ρ < 1, the system will work and if ρ > 1, the

system will eventually fail.

Note:- It has been proved mathematically that in a probabilistic

model, even if λ = μ (i.e. ρ =1) the system will eventually fail.

Such deterministic models are only applicable for highly

automated plants – e.g. soft drinks industry, pharmaceutical

industry. Where humans are involved, variable arrival rates and

service times are the more realistic assumptions.

Queuing Models - Deterministic

Page 50: Final Queuing Theory

51

PROBABILISTIC QUEUING MODELS

Kendall’s Notation for representing queuing models is (a/b/c) :

(d/e/f), where

a = Arrival distribution (or inter-arrival time)

b = Service distribution (or service time)

c = number of parallel service channels in the system

d = Service discipline

e = maximum number of customers allowed into the system

f = calling source or population

Queuing Models - Probabilistic

Page 51: Final Queuing Theory

52

Symbols for ‘a’(Arrival distribution) and ‘b’(Departure distribution)

M = Markovian (Poisson) arrival or departure (or exponential inter-arrival or service time distribution)

Ek = Erlangian or Gamma inter-arrival or service time.

GI = General independent arrival distribution.

G = General departure distribution

D = Deterministic inter-arrival or service distribution.

Symbols for ‘c’(No. of service channels)

1 for single server and ‘c’ or ‘s’ or ‘k’ for multiple servers.

Symbols for ‘d’(Service discipline)

FCFS, LCFS, SIRO, etc.

Symbols for ‘e’(Max. no of customers allowed into the system)

N = finite number of customers allowed in the system

∞ = infinite number of customers allowed in the system

Symbols for ‘f’(Calling

source/population)

N = finite population

∞ = infinite population

Following conventional codes are generally used to replace the symbols:-

For example:- (M/M/1) : (FCFS/∞/∞) ; (M/M/1) : (SIRO/∞/∞) ; M/M/c) : (FCFS/N/∞)

Queuing Models - Probabilistic

Page 52: Final Queuing Theory

53

Queuing Models - Probabilistic• We shall concentrate on the (M/M/1) : (FCFS/∞/∞) model

• In this model, the customers’ arrivals follow Poisson distribution while the service times are exponentially distributed. To recapitulate, the Poisson probability function,

f(x) = e-μ . μx/ x! where,

f(x) = probability of ‘x’ occurrences in an interval

μ = expected value or mean number of occurrences in an interval.

• Using this formula for our purpose, with average arrival rate equal to λ per period of time, then according to Poisson probability distribution, the probability that ‘n’ customers will arrive in the system during a given time interval ‘t’ is given by

(a) P(‘n’ arrivals in time ‘t’) = {e-λt.(λ.t)n/n! } for n = 0, 1, 2, …..

(b) Probability density function (pdf) of inter-arrival time ( i.e. time interval between two consecutive arrivals) = λ.e-λt

• (Note: λ is assumed to be constant over time and is independent of the number of units already serviced or served, queue length or any other random property of the queue).

Page 53: Final Queuing Theory

54

Queuing Models - Probabilistic

Similarly for Service,

• Service time is the time required for completion of a service, i.e. it is the time interval between beginning of a service and its completion.

• The mean service rate, μ, is the number of customers served per unit of time (assuming the service to be continuous throughout the entire time unit), while the average service time, 1/μ, is the time required to serve one customer.

• Most common type of distribution used for service times is exponential distribution.

• It involves the probability of completion of a service.

Page 54: Final Queuing Theory

55

Queuing Models - Probabilistic

Note :

1. Poisson distribution cannot be applied to servicing because of the possibility of the service facility remaining idle for some time (Poisson distribution assumes fixed time intervals of continuous servicing which can never be assured in all services and at all times).

2. μ is also assumed to be constant over time and independent of the number of units already serviced, queue length or any other random property of the system.

3. If λ is the arrival rate, the inter-arrival time is 1/λ, and if μ is the service rate, then the service time is 1/μ.

Page 55: Final Queuing Theory

56

Queuing Models - Probabilistic

(a) P (‘n’ complete services in time ‘t’) = e-μt.(μ.t)n/n!

(b) Probability density function (pdf) of inter-service time (or time

between two consecutive services) = μ.e-μt

(c) Probability that customer shall be serviced in more than time

‘t’= e-μt

(d) P (no more than ‘t’ time period needed to service a customer) =

1 – e-μt

Page 56: Final Queuing Theory

57

Performance Measures of a Queuing System

3. Questions involving value of time for both customers and servers.

(a) What is the probability that an arriving customer has to wait before being served? It is also called ‘blocking probability’.

(b) What is the probability that a server is busy at any particular point in time (denoted by ρ)? It is the proportion of time that a server actually spends with the customer i.e. the fraction of time a server is busy.

(c) What is the probability of ‘n’ customers being in the queuing system when it is in steady state condition? It is denoted by Pn , n = 0,1,2,3….

(d) What is the probability of service denial when an arriving customer cannot enter the system because the queue is full?

4. Cost related questions.

(a) What is the average cost needed to operate the system per unit of time?

(b) How many servers are needed to achieve cost effectiveness?

Page 57: Final Queuing Theory

58

Arrival Event

Schedule the next arrival event

Isthe server

busy?

Set delay=0for this customer

and gather statistics

Add 1 to the number in queue

Add 1 to the number of

customers delayed

Make the server busy

Schedule a departure event for this customer

Isthe queue

full?

Write errormessage and stop

simulation

Store time of arrival of this

customer

Return

Yes

Yes

No

No

FIGURE 1.8Flowchart for arrival routine, queueing model

Page 58: Final Queuing Theory

59

DepartureEvent

Isthe queueempty?

Subtract 1 from the number

in queue

Compute delay of customer entering service

and gather statistics

Add 1 to the number of customers

delayed

Schedule a departure event for this customer

Return

Yes No

FIGURE 1.9Flowchart for departure routine, queueing model

Move each customer in queue (if any) up

one place

Make the server idle

Eliminate departure event from

consideration

Page 59: Final Queuing Theory

60

Performance measures of M/M/1 queue(online proof and figures)

Ls = Number of customers in the queue = /(1-r r) = l/( -m l)

Ws = Sojourn time in the system = 1/(1-r)m = 1/( -m l)

Lq = queue length = l2/( -m l) = m Ls - r

Wq = average waiting time in the queue = l/( -m l) = m Ws - 1/m

TH = departure rate = l

Server utilization ratio = r

Server idle ratio = P0 = 1 - r

P{n > k} = Probability of more than k customers = rk+1

Page 60: Final Queuing Theory

61

Example

• On a network router, measurements show – the packets arrive at a mean rate of 125 packets

per second (pps) – the router takes about 2 millisecs to forward a

packet • Assuming an M/M/1 model• What is the probability of buffer overflow if the

router had only 13 buffers• How many buffers are needed to keep packet loss

below one packet per million?

Page 61: Final Queuing Theory

62

Example

Arrival rate λ = 125 pps Service rate μ = 1/0.002 = 500 pps Router utilization ρ = λ/μ = 0.25 Prob. of n packets in router =

Mean number of packets in router =

nn )25.0(75.0ρ)ρ1(

33.057.0

25.0

ρ1

ρ

Page 62: Final Queuing Theory

63

Example

Probability of buffer overflow: = P(more than 13 packets in router) = ρ13 = 0.2513 = 1.49x10-8

= 15 packets per billion packets To limit the probability of loss to less

than 10-6:

= 9.96

610ρ n

25.0log/10log 6n

Page 63: Final Queuing Theory

64

Problem 1

• On an average, 6 customers reach a booth every hour to make calls. Determine the probability that exactly 4 customers will reach in 30-minute period, assuming that arrivals follow Poisson distribution.

• SolutionGiven λ = 6 customers per hour t = 30 minutes = 0.5 hour n = 4 λt = 6*0.5 = 3

 Probability of exactly 4 customers reaching in 30-minute period,

  = e-λt.(λt)n/n! = e-3.34/4! = 0.168

Simple Problems

Page 64: Final Queuing Theory

65

Simple Problems

Problem 2

• In a bank, 20 customers on the average are served by a cashier in an hour. If the service time has exponential distribution, what is the probability that –

(a) It will take more than 10 minutes to serve a customer?(b) A customer shall be free within 4 minutes?

 • Solution

Given μ = 20 customers per hour t = 10 minutes = 10/60 = 1/6 hour(a) Probability that it will take more than 10 minutes to serve a customer

= e-μt = e-20*1/6 = 0.0357(b) In this case, t = 4 minutes = 1/15 hour ; μ = 20 customers per hour

Probability that a customer shall be free within 4 minutes = 1 – e-μt = 1 – e-20*1/15 = 0.736

Page 65: Final Queuing Theory

66

Some performance measures/operating characteristics of general interest for evaluation of the performance of an existing queuing system and to design a new system in terms of the level of service a customer receives as well as the proper utilization of the service facilities are:-

1. Time-related questions for the customers.

(a) What is the average (or expected) time an arriving customer has to wait in the queue (denoted by Wq) before

being served?

(b) What is the average (or expected) time an arriving customer spends in the system (denoted by Ws) including

waiting and service? This data can be used to make economic comparison of alternative queuing systems.

Performance Measures of a Queuing System

Page 66: Final Queuing Theory

67

2. Quantitative questions related to the number of customers.

(a) Expected number of customers who are in the queue (Queue length) for service denoted by Lq.

(b) Expected number of customers who are in the system either waiting in the queue or being served (denoted by Ls). The data can be used for finding the mean customer time spent in the system.

Performance Measures of a Queuing System

Page 67: Final Queuing Theory

68

NOTATIONS

1. n = no. of customers in the system (waiting and in service).

2. Pn = Probability of ‘n’ customers in the system.

3. λ = Average (or expected) customer arrival rate or average arrivals per unit of time in the queuing system.

4. μ = Average (or expected) service rate or average number of customers served per unit time.

5. λ/μ = ρ = Average service completion time (1/μ)/Average inter arrival time (1/λ) = Traffic utilization or server utilization factor (the expected fraction of time for which the server is busy)

6. s or c = number of service channels (service facilities or servers).

7. N = finite number of customers allowed in the system or finite population.

8. Ls = Average (expected) no. of customers in the system (waiting and in service).

9. Lq = Average (expected) no. of customers in the queue (queue length).

10. Lb = Average (expected) length of non-empty queue.

11. Ws = Average (expected) waiting time in the system (waiting and in service).

12. Wq = Average (expected) waiting time in the queue.