Sunteți pe pagina 1din 19

Spectral Expansion Solutions for

Markov-Modulated Queues
Isi Mitrani, Newcastle University
Unbounded queue in a finite-state Markovian environment.
Wide range of applications: computer, communication, manufacturing
and transport models.

The solution is not difficult to implement and is computationally
efficient.

It also leads to very simple approximations.
State description
Two state variables:

I

= 0,1,,N

= state of the Markovian environment at time t ;

J

= 0,1,


= number of jobs present at time t


Joint steady-state probabilities:
) , (
,
j J i I P p
j i
= = =
Restrictions
1. There is a threshold, M, such that the instantaneous transition
rates out of state (i,j) do not depend on j when j>M


2. The jumps of the random variable J are bounded
Quasi-Birth-and-Death process (QBD): the jumps of J are of size 1
(i.e., jobs arrive and depart one at a time).
Metrics

=
N
i
j i j
p p
0
, ,

=
0
,
j
j
jp L

=
0
, ,
j
j i i
p p
(average number of jobs present)
(marginal distributions of queue size and environment state)
Examples
, , q
1. Multiserver queue with breakdowns and repairs
i

The environment state is the number of operative servers.


Instantaneous transitions out of state (i,j):
i,j
i,j+1
i,j-1
i-1,j i+1,j
i

i
q ) ( i N
) , min( j i
2. Manufacturing blocking

N-1
Node 1 is blocked when the buffer at node 2 is full
Environment state

i=0,1,, N-1 : number of jobs at node 2; node 1 not blocked;

i=N : node 1 blocked
Instantaneous transitions out of state (i,j) when i<N-1:
i,j
i,j+1


i-1,j i+1,j

i+1,j-1
i,j-1
N-1,j
N-1,j+1


N-2,j N,j


N-1,j-1
When i=N-1 :
N,j
N,j+1
N-1,j

When i=N :
N,j-1 N-1,j-1
Spectral Expansion Solution
QBD models
General balance equations:
)] , ( ) , ( ) , ( [ )] , ( ) , ( ) , ( [
1 1 , 1 1 , ,
0 0
,
i k c p i k b p i k a p k i c k i b k i a p
j j k j j k j j k
N
k
j j j
N
k
j i +
= =
+ + = + +

) , ( k i a
j
Instantaneous transition rates:
change the environment only: (i,j) -> (k,j)
) , ( k i b
j
change environment and increase queue by 1: (i,j) -> (k,j+1)
) , ( k i c
j
change environment and decrease queue by 1: (i,j) -> (k,j-1)
Balance equations in matrix-vector form:
) ,..., , (
, , 1 , 0 j N j j j
p p p = v
1 1 1 1
] [
+ +
+ + = + +
j j j j j j
C
j
B
j
A
j j
C A B D D D v v v v
Matrices independent of j when j>M:
C A B D D D
j j j
C B A
j 1 1
] [
+
+ + = + + v v v v
Vector difference equation of order 2, with constant coefficients:
0
2 2 1 1 0
= + +
+ +
Q Q Q
j j j
v v v
Spectral expansion solution:


1. Form the matrix polynomial
2
2 1 0
) ( x Q x Q Q x Q + + =
2. Find the generalised eigenvalues and left eigenvectors
0 )] ( det[ =
k
x Q 0 u = ) (
k k
x Q
M j
k
N
k
k k j
x

+
=

=
1
1
u v o
3. There should be exactly N+1 eigenvalues inside the unit disk.

Then the solution has the form
where
k
o are arbitrary constants.
Otherwise the system is unstable.
The unknown constants are determined from the boundary
balance equations (j<M), and the normalizing equation.
The solution generalises to cases where arrivals and/or
departures may occur in batches.
Simple approximation
General idea: use only one (the largest) eigenvalue-eigenvector pair
in the spectral expansion.

The eigenvalue with the largest modulus, x
N+1
= , is real and
positive, and so is the corresponding eigenvector, u
N+1
.
The solution becomes:
,... 1 , 0 ; ) 1 (
1
= =
+
j
j
N j
u v
(u is normalized so that its elements add up to 1)
Proposition: the approximate solution is asymptotically
exact in heavy traffic.
Implementation
function [e,V] = dom(A,B,C)
%Dominant eigenvalue and eigenvector
%QBD process defined by (N+1)x(N+1) matrices A,B,C
%The birth matrix B is assumed non-singular
n = size(A,1); %n = N+1
u = ones(n,1);
C1 = inv(C);
Q = A-diag(A*u)-diag(B*u)-diag(C*u);
Big = [zeros(n,n),-B*C1;eye(n),-Q*C1]; %size 2(N+1)x2(N+1)
[V0,e0] = eigs(Big',10,0.999999); % ten eigvals closest to 1
V0 = V0(1:n,:); % first half of each vector
[e0,ix] = sort(diag(e0)); %sort eigvals ascending
V0 = V0(:,ix); %sort eigvects
good = e0<0.999999; %select eigvals smaller than 1
e0 = e0(good); %discard the others
V0 = (V0(:,good))'; %corresponding row vects
V = V0(size(e0,1),:); %return largest row vector
e = e0(size(e0,1)); %return largest eigenvalue

References
[1] I. Mitrani and R. Chakka, Spectral Expansion Solution for a Class of
Markov Models: Application and Comparison with the Matrix-Geometric
Method, Performance Evaluation, 23, 241-260, 1995.

[2] I. Mitrani, Approximate Solutions for Heavily Loaded Markov Modulated
Queues, Performance Evaluation, 62, pp 117-131, 2005.

[3] L. Kumar, M. Misra and I. Mitrani, Analysis of a Transaction System with
Checkpointing, Failures and Rollback, in Computer Performance
Evaluation (Springer LNCS 2324, Eds. T. Field, P.G. Harrison, J. Bradley
and U. Harder), 2002 (TOOLS 2002 Conference, London).

S-ar putea să vă placă și