# CS457 - System Performance Evaluation - Winter 2008

1. Assignment 4
2. `Service centre'

# Analytic Queueing Theory - Queueing Networks

Text: Chapters 30--36

## Operational Analysis

### Closed Networks in Steady State

1. Can solve only for ratios of the \lambda_i
2. Cut the system (at an arbitrary location) to define the throughput, X.

#### B. Interactive System in Steady State

1. Call the set of terminals server 0

2. Throughput

Cut at entrance to terminals: X = \lambda_0

Define visit ratio: number of visits to service i per job

• V_i = \lambda_i / X = \lambda_i / \lambda_0

Why did we define the visit ratio?

• It can be calculated from the ratios!

3. Utilization

U_i = \lambda_i s_i = X V_i s_i = X D_i

• D_i = V_i s_i is the demand per job at server i

U_i / U_j = D_i / D_j

4. Upper bound on throughput

D = \sum D_i

X(n): throughput with N users

• X(1) = 1 / (D + Z)
• X(N) <= N/(Z + D) : equality when there is no contention

5. Bottleneck analysis

1. b - server with highest demand
2. D_b = max{D_i} = D_max
3. U_b = X D_b <= 1
4. X <= 1/D_max

Therefore, X(N) <= min( 1/D_max, N / (D+Z) )

6. Lower bound on mean response time

1. Treat entire system as one server. Then R(N) = N/X - Z
2. R(N) >= D = sum_i D_i because R(N) <= N / (D+Z)
3. X(N) <= 1 / D_max, so that R(N) <= ND_max - Z

## Markovian Analysis

#### Assumptions

1. All random variables Markovian (exponentially distributed)
• interarrival time
• service time
• think time
2. Solutions are product form
• This is called an ansatz
• State of a system is (n_1, n_2, ... , n_M)
• r_i = \lambda_i / \mu_i is the load at service centre i
• Definition of product form solution: p(n_1, n_2, ... , n_M) = (!/G) r_1^(n_1) r_2^(n_2) ... = (1/G) \PI_i r_i^(n_i)
• Intuition behind the product form solution p(n_1, n_2, ... ,n_i + 1, ..., n_M) = r_i * p(n_1, n_2, ... ,n_i, ..., n_M)

#### Solution Method (with M/M/1 example)

1. Draw state transition diagram
2. Develop balance equations
• Boundary case \lambda p(0) = \mu p(1)
• General case: (\lambda + \mu)p(n) = \lambda p(n-1) + \mu p(n+1)
3. Assume product form solution
• p(n) = (1/G) r^n
4. Verify that product form solution satisfies balance equations
• Boundary case: \lambda (1/G) ?= \mu (1/G) r^1: obviously true.
• General case:
• (\lambda + \mu) (1/G) r^n ?= \lambda (1/G) r^(n-1) + \mu (1/G) r^(n+1)
• (\lambda + \mu) r ?= \lambda + \mu r^2
• \lambda r + \lambda ?= \lambda + \lambda r
• Obviously true
5. Evaluate any constants
• \sum_n (1/G) r^n = 1
• G = 1 / (1 - r)
6. Determine performance metrics
• E[n] = ..., etc.

#### Challenging Example: General Open Network

State is (n_1, n_2, ... , n_M).

Connectivity (conservation) equations are

• \lambda_i = \gamma_i + \sum_j \lambda_j p_ji

1. State transition diagram

1. (n_1, ..., n_i - 1, ..., n_M) -> (n_1, ..., n_i, ..., n_M): \gamma_i
2. (n_1, ..., n_i + 1, ..., n_M) -> (n_1, ..., n_i, ..., n_M): \mu_(i+1) p_(i+1)(M+1)
3. (n_1, ..., n_i - 1, ..., n_j + 1, ..., n_M) -> (n_1, ..., n_i, ..., n_M): \mu_j p_ji
4. (n_1, ..., n_i, ..., n_M) -> (n_1, ..., n_i, ..., n_M): \mu_i p_ii
5. (n_1, ..., n_i, ..., n_M) -> (n_1, ..., n_i + 1, ..., n_M): \gamma_i
6. (n_1, ..., n_i, ..., n_M) -> (n_1, ..., n_i - 1, ..., n_M): \mu_i p_i(M+1)
7. (n_1, ..., n_i, ..., n_M) -> (n_1, ..., n_i - 1, ..., n_j + 1, ...,, n_M): \mu_i p_ij

2. Balance equations