Presentation is loading. Please wait.

Presentation is loading. Please wait.

Chapter 6 Queuing Models.

Similar presentations


Presentation on theme: "Chapter 6 Queuing Models."— Presentation transcript:

1 Chapter 6 Queuing Models

2

3

4

5

6 Arrival Process

7 Arrival Process

8

9

10 Service Times and Service Mechanism
Example: consider a discount warehouse where customers may Serve themselves before paying at the cashier or wait for one of the 3 clerks.

11 Wait for one of the three clerks

12 Queueing Notation A notation system for parallel server queues: A/B/c/N/K 􀂅 A represents the interarrival-time distribution, 􀂅 B represents the service-time distribution, 􀂅 c represents the number of parallel servers, 􀂅 N represents the system capacity, 􀂅 K represents the size of the calling population.

13 Queueing Notation

14 6.3 Long-run measures of performance of queuing systems
Primary long-run measures of queuing systems are :- L: long-run time-average number of customers in system, LQ: long-run time-average number of customers in queue, w: long-run average time spent in system per customer, wQ: long-run average time spent in queue per customer. ρ: server utilization

15 This section defines the major performance measures for a general G/G/c/N/K queueing system.
There are two types of estimators :- 1. Ordinary sample average 2. Time-integrated (or time-weighted) sample average

16 6.3.1 Time-Average Number in System L
Consider a queuing system over a period T, L(t) denotes the no of customers in the system at time t Ti : total time during [0, T] in which the system contained exactly i customers. A Simulation is shown in the fig 6.6

17 Consider the total area under the function is L(t), then,
From fig 6.6, = [0(3) + 1(12) + 2(4) + 3(1)]/20 = 23/20 = 1.15 Let Ti denote the total time during [0,T] in which the system contained exactly i customers, the time- weighted-average number in a system is defined by: Consider the total area under the function is L(t), then, The above 2 equations are always equal for any queuing system, regardless of the number of servers queue discipline

18 The 2nd equation justifies the terminology "time- integrated average“
Many systems exhibit a long-run stability in terms of their avg performance. For such systems, as T gets large, the observed time- average number in the system approaches a limiting value, say L. L is called the long-run time-average number in system, with probability 1. This is given by eqn 3, The estimator is strongly consistent for L. If the simulation run length is sufficiently long, becomes close to L.

19 This can be applied to the queue alone as it is done to the whole system.
Let LQ(t) denote the number of customers waiting in line and denote the total time during [0,T] in which exactly i customers are waiting in line Where is the observed time average number of customers waiting in line from time 0 to time T and LQ is the long-run time average number waiting in line.

20 Fig 6.7 : Number in waiting line, LQ(t) at time t.

21 Example :- Fig 6.6 represents a single server queue – that is G/G/1/N/K queueing system (N >= 3, K >= 3). Then the number of customers in the waiting line is given by LQ(t) defined by :- L(t) – 1, because the 1st customer enters service when the server is free and does not enter the queue. This is shown in fig 6.7 Thus T0 = 5+10 = 15, T1 = 2+2 = 4, T2 = 1. Therefore

22 4.3.2 Average Time Spent in System per Customer (w)
Wi: Time that customer i spends in system : Average system time The average time spent in system per customer, called the average system time, is: where W1, W2, …, WN are the individual times that each of the N customers spend in the system during [0,T]. For stable system, when N →∞, → w, where w is called “ the long-run average system time”.

23 6.3.2 Average Time Spent in System Per Customer w
: The total time customer spends waiting in queue : The observed average time spent in queue (called delay) wQ : The long-run average delay per customer If the system under consideration is the queue alone:

24 Example 6. 4 : For Fig 6. 8, N=5 customers arrive
Example 6.4 : For Fig 6.8, N=5 customers arrive. The system has a single server and a FIFO queue discipline. Each jump upwards of L(t) represents arrival and jump downwards is a departure. The details about the system is given in fig 6.8 (next pg) The average system time is : Average queue time = = ( )/5 = 1.2 time units

25 Fig 6.8 : System times, Wi, for a single-server FIFO system.

26 6.3.3 The Conservation Equation L = λw
For the system in fig 6.6, = 1.15, = 4.6 There were N = 5 arrivals and T = 20 time units. Hence = N/T = 5/20 = ¼ We found that Let λ be the long-run average arrival rate when T →∞ and N → ∞ the relationship between L, λ and w holding for almost all queueing systems is L = λ w (proof in terms of integral eqn in pg 189) Avg no of customers in the system (L) (at any arbitrary point) Avg no of arrivals per time unit (λ) Avg time spent by each customer in the system (w) = *

27 Server Utilization Definition: The proportion of time that a server is busy. Observed server utilization, , is defined over a specified time interval [0,T]. Long-run server utilization is ρ. For systems with long-run stability: For Example 6.6, the server utilization is = = (Summation of all Ti )/ T = 17/20

28 Server utilization in G/G/1/∞/∞ queues :
For G/G/1/∞/∞ queues : single-server queueing system with average arrival rate λ customers per time unit, where average service time E(S) = 1/μ time units, (which means, the server is working at μ customers/time unit, on an avg). μ is called the service rate. infinite queue capacity and calling population. Conservation equation, L = λw, can be applied to the server, because the server alone is a subsystem that can be considered as a queuing system in itself.

29 Server utilization in G/G/1/∞/∞ queues :
For a stable system, the average arrival rate to the server, Λs, must be identical to λ(arr. rate to system). Λs cannot be > λ. (customers cannot be served faster than they arrive. Certainly, Λs <= λ. If Λs < λ, waiting line will tend to grow at an avg rate of (λ - λs ) customers/unit. So we would have an unstable system.

30 Server utilization in G/G/1/∞/∞ queues :
For the server subsystem, the average number of system time is: w = E(s) = 1/ μ = μ -1 The actual no of customers in the system is either 0 or 1, as shown in fig 6.9(NP) for the system represented in 6.6 The average number of customers in the server is: For the above pbm, = (20 – 3)/20 = 17/20 = In general, for a single server queue, the average number of customers being served at an arbitrary point is equal to server utilization. ( Because the server is idle during T0 = 3 time units )

31 Server utilization in G/G/1/∞/∞ queues :
Fig 6.9 : Number being served, L(t) – LQ(t) at time t.

32 Therefore, L = λ w (conservation law) ρ = λ / μ
We have Ls = ρ , w = E(s) = 1/ μ Therefore, L = λ w (conservation law) ρ = λ E(s) ρ = λ / μ That is, For a single server queue to be stable, the arrival rate λ, must be less that service rate μ, i.e. (λ < μ) or (λ / μ) < 1 If arrival rate(λ) > service rate(μ), the server will eventually get further behind. After sometime, the waiting line will tend to grow in length at an avg rate of λ – μ customers per unit time, because departures will occur at rate μ per unit time. the long-run server utilization in a single server queue Average arrival rate = Average service rate

33 For an unstable queue (λ > μ),
long-run server utilization is 1, and long-run average queue length is infinite. i.e., Hence L = w = WQ = ∞. Therefore these long-run measures of performance are meaningless for unstable queues. The quantity λ/μ is also called the offered load and is a measure of the workload imposed on the system. as

34 Server utilization in G/G/c/∞/∞ queues :
For G/G/c/∞/∞ queues: A system with c identical servers in parallel. If an arriving customer finds more than one server idle, the customer chooses a server at random without favoring any particular server. Arrivals occur at rate λ and each server works at the rate μ customers /time unit. For systems in statistical equilibrium, the average number of busy servers, Ls, is: Ls = λw = λE(s) = λ/μ. Where 0 <= Ls <= c The long-run average utilization of all the servers is :

35 The utilization ρ can be interpreted as the proportion of time an arbitrary server is busy in the long run. Maximum service rate of G/G/c/∞/∞ system is cμ which occurs when all the servers are busy. For the system to be stable, the average arrival rate λ must be less than the max service rate cμ. i.e., λ < cμ OR the offered load λ/μ is less than the no. of servers c. If λ > cμ, then, arrivals are occurring on the avg, faster than the system can handle them. So, all the servers will be continuously busy, and the waiting line will grow in length at an avg rate of (λ – cμ) customers/unit time. Such a system is unstable.

36 Server Utilization and System Performance
System performance can vary widely for a given value of utilization ρ. Consider a G/G/1/∞/∞ queue, i.e., single server, with arrival rate λ, service rate μ and utilization ρ = λ/μ < 1. Two cases :- Extreme case is with both λ & μ are deterministic(D/D/1) Then all inter-arrival times = A1, A2, … = E(A) = 1/λ All service times = S1, S2, …… = E(S) = 1/μ L = ρ = λ/μ, w = E(S) = μ and LQ = WQ = 0. By varying λ and μ, server utilization can assume any value between 0 and 1, yet there is no waiting line. It is shown in the fig 6.10

37 Fig 6.11 : Deterministic Queue, D/D/1

38 Example 6.7 A physician who schedules patients
every 10 minutes and spends Si minutes with the ith patient: Arrivals are deterministic, A1 = A2 = … = λ-1 = 10. Services are stochastic, with The mean of a discrete random variable X is a weighted average of the possible values that the random variable can take. mean given by : E(Si) = 9(0.9) + 12(0.1) = 9.3 min variance given by : V(S0) = E(Si) 2 – [E(Si)] 2 = 92(0.9) (0.1) – (9.3) 2 = 0.81 mins2. On average, the physician's utilization : ρ = λ/μ = E(S)/E(A) = 9.3/10 = 0.93 < 1. Hence the system is stable and the physician is busy 93% of the time in the long run. Note : E(S) = 1/ μ E(A) = 1/ λ

39 Consider the system is simulated with service times:
S1 = 9, S2 =12, S3 = 9, S4 = 9, S5 = 9, …. The system is shown in fig 6.11 S2 = 12, causes a waiting line to form temporarily.

40 6.4 Steady-State Behavior of Infinite-Population Markovian Models
Steady state solution of que models that can be solved mathematically For the inifinite population models, the arrivals are assumed to follow a Poisson process with λ arrivals/time unit Markovian models: Arrival process is exponentially distributed with mean arrival rate = λ. Service times may be exponentially distributed as well (M) or arbitrarily distributed (G). FIFO Queuing principle. Because of the exponential distribution of the arrival process, these are called Markovian Models. A queueing system is in statistical equilibrium, or in steady state, if, the probability that the system is in a given state is not time dependent: P( L(t) = n ) = Pn (t) = Pn.

41 2 properties of stochastic models are –
Approaching equilibrium from any starting state Remaining in statistical equilibrium when it is reached. Mathematical models in this chapter can be used to obtain approximate results even when the model assumptions do not strictly hold (considered as a rough guide). Mathematical analysis (when it is applicable) provides the true value of the model parameter (eg. L), where as, a simulation analysis delivers a statistical estimate (eg. L(cap)) of the parameter. For complex systems, simulation model is more faithful representation than a mathematical model.

42 For simple models studied here, the steady state parameter L, (the time-average number of customers in the system), can be computed as -> Where, Pn is the steady-state Probability of finding n customers in the system. Once L is given, the other steady state parameters can be computed from Little’s equation i.e., L = λw, which can be applied to the whole system and the queue alone. G/G/c/∞/∞ example: to have a statistical equilibrium, a necessary and sufficient condition is λ/(cμ) < 1 , where λ is the arrival rate, μ is the service rate of one server and c is the no of parallel servers.

43 M/G/1 Queues Single Server Queues, with Poisson arrivals and Unlimited Capacity. Suppose service times have mean 1/μ and variance σ2 with a single server. If ρ = λ/μ < 1, then M/G/1 queue has a steady-state probability distribution with steady-state characteristics, as given in table 6.3 (below).

44 M/M/1 Queues Suppose the service times in an M/G/1 queue are exponentially distributed with mean 1/μ, then the variance is σ2 = 1/μ2, it is an M/M/1 queue. Mean and standard deviation of an exponential distribution are equal, so, M/M/1 queue is a useful approximate model when service times have standard deviation approximately equal to their means. The steady-state parameters (given in table 6.4 below) can be computed by substituting σ2 = 1/μ2 for the formulae given in table 6.3

45 Network of Queues Many systems are naturally modeled as networks of single queues: customers departing from one queue may be routed to another Consider the network of queues as discussed earlier in fig 6.3

46 Network of Queues The following results assume a stable system with infinite calling population and system capacity. Provided that no customers are created or destroyed in the queue, then the departure rate out of a queue is the same as the arrival rate into the queue (over the long run). If customers arrive to queue i at rate λi, and a fraction 0 ≤ pij ≤ 1 of them are routed to queue j upon departure, then the arrival rate from queue i to queue j is λipij (over the long run) The overall arrival rate into queue j, λj , is the sum of the arrival rate from all sources. i.e., λipij

47 Network of Queues If customers arrive from outside the network at rate aj Then, If queue j has cj < ∞ parallel servers, each working at rate μj, then the long-run utilization of each server is ρj = λj/(cμj) (where ρj < 1 for stable queue). If arrivals from outside the network form a Poisson process with rate aj for each queue j, and if there are cj identical servers delivering exponentially distributed service times with mean 1/ μj, then, in steady state, queue j behaves like an M/M/cj queue with arrival rate λj, as given above.

48 Network of Queues : Example


Download ppt "Chapter 6 Queuing Models."

Similar presentations


Ads by Google