Professional Documents
Culture Documents
Andrea Bobbio
Anno Accademico 1999-2000
Queueing Systems 2
W Waiting time ( = R − S)
U0 Utilization factor
Birth-Death Processes
#$#$#
%&('
E i-1
birth
no events
Ei Ei
death
E i+1
The figure shows the way in which the event Ei(t + ∆ t) can be
generated.
Queueing Systems 4
Birth-Death Processes
Where:
O(∆ t)
lim = 0
∆ t→0 ∆t
Birth-Death Processes
P0 (t + ∆ t) − P0 (t)
= − λ0 P0 (t) + µ1 P1 (t) i=0
∆t
Pi (t + ∆ t) − Pi (t)
= −(λi + µi )Pi (t) + λi−1 Pi−1 (t) + µi+1 Pi+1 (t) i>0
∆t
P0(0) = 1 i=0
Pi(0) = 0 i>0
Queueing Systems 6
d Pi(t)
variation of flow =
dt
#$#$#
%&('
0 1 2 3 ··· i − 1 i i + 1 ···
0 −λ0 λ0
1 µ1 −(λ1 + µ1 ) λ1
2 0 µ2 −(λ2 + µ2 ) λ2
.. .. .. .. .. .. .. .. .. ..
Q = . . . . . . . . . .
i−1
i µi −(λi + µi ) λi
i+1
..
.
p(t) = {p0 p1 p2 . . . pi . . .}
d p(t)
= pQ
dt
Queueing Systems 8
d Pi(t)
lim = 0 (i = 0, 1, 2, . . .)
t→∞ dt
Hence:
1
P0 =
X i−1
Y λj
1+
i≥1 j=0 µj+1
A/B/c/d/e
where:
A Is the distribution of the interarrival times;
B Is the distribution of the service times;
c Is the number of servers;
d Is the storage capacity of the system (number of servers plus
the storage capacity of the buffer);
e Is the number of sources that provide clients.
The usual assumption for the interarrival and service time distri-
butions A and B is:
M/M/1
λi = λ for i ≥ 0 ; µi = µ for i ≥ 1
P0 = 1 − ρ
P1 = (1 − ρ) ρ
... ...
Pi = (1 − ρ) ρi
... ...
M/M/1: Probability vs ρ
Pi = (1 − ρ) ρi
1.
Pi
.8
.6
.4
.2
0
0 1 2 3 4 5 6
i
Queueing Systems 14
∞
X
E[N ] = i · Pi
i=0
= 0 · P0 + 1 · ρ · P0 + 2 · ρ2 · P0 + 3 · ρ3 · P0 + . . .
∞
X ∞
X ρ
= P0 i · ρi = (1 − ρ) i · ρi =
i=0 i=0 1−ρ
∞
X i ∂ ∞
X ∂ 1
i·ρ = ρ ρi = ρ
i=0 ∂ρ i=0 ∂ρ 1−ρ
ρ
=
(1 − ρ)2
Queueing Systems 15
E[N]
{ E[R]
E[N ] = λ · E[R]
1 ρ 1/µ
E[R] = λ−1 E[N ] = =
λ 1−ρ 1−ρ
From the above formula, the expected response time E[R] can be
interpreted as the ratio between the mean service time (1/µ) and
the probability of the sever to be idle (1 − ρ).
Queueing Systems 16
E[NQ]
{
E[W]
ρ2
E[NQ] = λ · E[W ] =
1−ρ
Number of customers in service
The expected number of customers in service is:
E[NS ] = E[N ] − E[NQ] = ρ
From the Little’s rule applied to the server, only:
λ
E[NS ] = λ · E[S] = = ρ
µ
Queueing Systems 17
λ arrival rate
µ service rate
ρ
E[N ] = Expected number of customers in the queue
1−ρ
(including those in service)
1/µ
E[R] = Expected response time
1−ρ
1
E[S] = Expected service time
µ
E[NQ] = λ · E[W ]
ρ2
= Expected number of waiting customers
1−ρ
K
The storage capacity of the system is K (one customer in ser-
vice and K − 1 customers in the waiting line) and the exceeding
customers are refused.
The general B/D process can be particularized as follows:
λ i<K
λi =
; µi = µ
0 i≥K
The M/M/1/K queue is stable for any positive value of the traffic
intensity ρ.
(1 − ρ) ρi
lim Pi = lim
ρ→1 ρ→1 1 − ρK+1
−ρi + i (1 − ρ) ρi−1 1
= lim =
ρ→1 −(K + 1) ρK K +1
K
X K
X (1 − ρ) ρi
E[N ] = i · Pi = i·
i=0 i=0 1 − ρK+1
1−ρ K
X
= i · ρi (4)
1 − ρK+1 i=0
ρ 1 − (K + 1) ρK + K ρK+1
=
1 − ρK+1 (1 − ρ)
The above formula (4) is based on the following finite series sum:
K
X i ∂ K
X i ∂ ρ (1 − ρK )
i·ρ = ρ ρ = ρ
i=0 ∂ρ i=1 ∂ρ 1−ρ
1 − (K + 1) ρK + K ρK+1
= ρ
(1 − ρ)2
The queue does not have a waiting line and the arriving customer
enters service only if the server is idle.
The queue has one arrival line and m identical servers with ser-
vice rate µ. The structure of the queue and its state space are
represented in the figures:
% . /
&(' 0(1 2(3
λ
Let us define the traffic intensity as ρ = .
mµ
The stability condition requires ρ < 1.
By rewriting the state probabilities in terms of the traffic intensity,
we obtain:
(m ρ)i
P0 i<m
i!
Pi =
ρi mm
P0 i≥m
m!
−1
i i m
m−1
X (m ρ) ∞
X ρ m
P0 = + (5)
i=0 i! i=m m!
∞
X ρi mm ρm mm ∞
X k (m ρ)m 1
= ρ =
i=m m! m! k=0 m! 1 − ρ
−1
m−1
X (m ρ)i (m ρ)m 1
P0 = +
i=0 i! m ! 1 − ρ
Queueing Systems 24
∞
X (m ρ)m P0
E[N ] = i Pi = m ρ + ρ
i=0 m ! (1 − ρ)2
m−1
X ∞
X λ
E[M ] = i Pi + m Pi = m ρ =
i=0 i=m µ
∞
X Pm (m ρ)m P0
P[queue] = Pi = =
i=m 1−ρ m! 1 − ρ
Queueing Systems 25
&(' 01325467
Hence, the state probabilities assume the following form and are
Poisson distributed:
−λ/µ (λ/µ)i
Pi = e
i!
E[N ] 1
E[N ] = λ/µ ; E[R] = =
λ µ