Efficient Monte-Carlo simulation of a product ... - ACM Digital Library

0 downloads 0 Views 1MB Size Report
Efficient Monte-Carlo Simulation of a. Product-Form Model for a Cellular System with Dynamic Resource Sharing. PHILIP J. FLEMING and DENNIS ...
Efficient Monte-Carlo Simulation of a Product-Form Model for a Cellular System with Dynamic Resource Sharing PHILIP J. FLEMING and DENNIS SCHAEFFER Motorola,

Inc.

and BURTON SIMON University

of Colorado

at Denver

There are many ways for users to share the radio spectrum allocated to a cell in a cellular phone system. We analyze a commonly proposed scheme where the cell is divided into s sectors. Each sector has exclusive access to a certain number of channels. The remaining channels reside in a “common pool” and are shared among the sectors. The smallest unit of bandwidth that can be borrowed from the common pool is a “carrier,” which consists of c channels. When viewed as a multidimensional birth-death process, the steady-state distribution of the number of active channels in each sector has a “product form)” but because the state space is large and has a nonlinear boundary, direct calculation of quantities of interest is usually impractical. Ross and Wang have developed a Monte-Carlo technique that applies to our problem. We significantly improve the efficiency of their technique when applied to our problem by including certain (nonlinear) control variates. The kinds of control variates we use can be applied to other loss systems as well. We also explore the effect of importance sampling for our system. In many cases the variance reduction achieved from the combination of importance sampling and control variates is far greater than from either method alone. For systems with blocking probabilities in the range 0.001 to 0.1, the variance of the system-blocking probability estimator can be reduced by several orders of magnitude. Categories and Subject Descriptors: 1.6.1 [Simulation and Modeling]: Applications ing; 1.6.3 [Simulation General Additional

Terms: Experimentation, Key Words

Modeling,

and Phrases:

Control

and

Modeling]:

Simulation

and Model-

Theory variates,

importance

sampling,

variance

reduction

1. INTRODUCTION The purpose of this paper is twofold. We provide the details of an efficient and easily implemented simulation of a model of a dynamic resource-sharing technique commonly proposed for digital cellular phone systems. In addition, Authors’ addresses: P. J. Fleming and D. Schaeffer, Motorola, Inc., Arlington Heights, IL; B. Simon, Department of Mathematics, University of Colorado, Denver, CO 80217-3364. Permission to make digital/hard copy of all or part of this material without fee is granted provided that the copies are not made or distributed for profit or commercial advantage, the ACM copyright/server notice, the title of the publication, and its date appear, and notice is given that copying is by permission of the Association for Computing Machinery, Inc. (ACM). To copy otherwise, to republish, to post on servers, or to redistribute to lists requires prior specific permission and/or a fee. @ 1995 ACM 1049-3301/95/0100-0003 $03.50 ACM Transactions

on Modeling and Computer Simulation,

Vol. 5, No 1, January

1995, Pages 3-21

P. J, Fleming et al.

4.

the results we obtain suggest that similarly designed simulations of other loss systems may also perform well. The analytic solution of our model has a product form, but it is numerically intractable due to the size (and shape) of the state space. Our simulation directly utilizes the product-form solution. Previous authors have also exploited product-form solutions of queueing systems to design efficient simulations [Everitt and Manfield 1989; Ross and Wang 1992; Ross, Tsang, and Wang 1993]. In fact, Everitt and Manfield [1989] analyze a system very similar to ours (but bigger) via a direct Monte-Carlo simulation of the product-form solution. (They “reject” samples outside the state space in their implementation.) Our basic simulation technique is essentially equivalent to the method proposed by Ross and Wang [1992], which is more sophisticated than that of Everitt and Manfield [ 1989]. Ross and Wang are able to analyze a large class of product-form loss systems with their method. Strictly speaking, our model does not fit their framework because the constraints on the state space are not linear, but the necessary adjustments are trivial. Our main contribution is variance reduction based on certain nonlinear control variates. The control variates typically speed up simulations for systems with blocking probabilities in the “normal” range (10-3 to 10-1) by factors of 2 to 100, and occasionally by much more. They are more effective for systems with low blocking probabilities. These kinds of control variates appear to be a new idea and may have applications in other simulations that use ratio estimates (e. g., Ross and Wang’s loss systems and certain regenerative simulations). Like Ross and Wang [1992], we use importance sampling to speed up simulations where the blocking probabilities are outside the normal range. For our model, importance sampling is very effective for systems with high blocking probabilities (the opposite of the control variates). However, for systems with low blocking probabilities, importance sampling can backfire (increase variance) if one is not careful. Surprisingly, though, in all our examples the combination of control variates and importance sampling performs much better than either one alone. The combination of control variates and importance sampling gives speedups of as much as 1,000 for “normal” systems, and of many orders of magnitude more for systems outside the normal range. The techniques of this paper can therefore be applied to large problems, such as those in Everitt and Manfield [1989]. The remainder of the paper is organized as follows. In the next section we describe the dynamic resource-sharing model and its product-form solution. We

provide

a crude

complexity

analysis

of the

numerical

solution.

In

Section

we describe the basic simulation that utilizes the product-form solution and provide a crude complexity analysis that shows its inherent superiority to the numerical solution. In Section 4 we describe the (nonlinear) control variates. We provide a heuristic argument that explains why they work and suggests that analogous control variates may work well in other contexts. In Section 5 we include importance sampling in our basic simulation with control variates. We demonstrate an unexpected synergy between importance sampling and our control variates that yields spectacular speedups in many cases. We 3

ACM

Transactions

on Modeling

and Computer

Simulation,

Vol. 5, No, 1, January

1995

Efhcient Monte-Carlo

Simulation

.

5

argue that this synergy may also appear in other problems. Finally, in Section 6 we illustrate the efficiency of the simulation and the effect of the variance reduction with some examples. The results displayed are chosen primarily so that the reader can judge the merits of our simulation technique. Readers interested in the pros and cons of various cellular phone-system designs are referred to other work (e.g., Everitt and Manfield [ 1989]). 2. MODEL

DESCRIPTION

We consider a single “cell” in a cellular phone system. The cell is divided into s sectors. The resources provided by the cell are communication channels used by “customers” passing through the cell to place or receive phone calls. Requests for channels in sector i occur as a Poisson process with rate A,. (These arrivals include new calls originating in that sector and “handovers” from other cells in the system.) The Poisson processes are mutually independent. The holding time (service time) of a call has mean l/~ for each sector and is independent of the arrival processes and other holding times. Calls are assumed to be lost if no channel is available. Let

be the total

arrival

rate, let AL pL=—

P

be the “load”

on sector i, and let

be the load on the cell. From the system’s point of view, the channels come in groups of c on a “carrier”. Each carrier is a segment of the radio spectrum, and the c channels usually correspond to a time division of the carrier (TDMA), although from a modeling perspective that is not important. Sector i is allocated a, carriers which are not shared with the other sectors. However, sector i requires b, channels for signaling or other overhead, so the number of channels available exclusively to sector i for customers is ml = a,c — bi.

There are also A carriers shared by all the sectors in a “common pool.” If a request for a channel occurs in sector i and all the carriers presently there are saturated, a carrier from the common pool will be allocated to sector i, provided the common pool has one to offer (and sector i is not at its limit, as described below). We assume that the sectors always pack the customers into the least number of carriers possible. (This is not an unrealistic assumption and can be achieved by intra-sector handovers. Discrete event simulation results show that the number and frequency of handovers due to packing is a ACM Transactions

on Modeling and Computer Simulation,

Vol. 5, No 1, January 1995.

P. J. Fleming et al,

6.

negligible

burden

on the control

infrastructure

of the cellular

system.)

Thus,

n, + b,

if there

are n, customers

in sector

z then

carriers

— [1 c

are needed,

n, + ti,

where

[.] is the “ceiling”

common

n, — ml

function.

001 are required,

If

i.e., if

H —

> a, then

c

n ~ > ml

then

carriers

sector

from

the

has to borrow

i

carriers. When a borrowed carrier becomes free it is returned to [T the c%mmon pool. Finally, sector i is not allowed to borrow more than d, carriers from the common pool (due to constraints imposed by the radio frequency plan), so the maximum number of customers it can support is rL=dlc+

Letnl, i=l,2,..., s be the number described above imposes the following O s, we see that the complexity of a numerical s solution of our model increases very rapidly in both the number of sectors and the number of carriers. Let N=

~

+ n~ +

P(ii)(nl

““”

(2.5)

+7?.),

iiER

be the expected number

of customers iv,

=

in the system and let ~

(2.6)

P(ii)nl,

ZER ACM

Transactions

on Modeling

and Computer

Simulation,

Vol. 5, No. 1, January

1995.

P. J. Flemmg et al,

8.

be the expected number

of customers

B, = probability

in sector i. Define of blocking

in sector i,

and let

be the system-blocking probability. Let ~R be the boundary of R. We can write B =

~

fi=

(2.7)

F’(iOB(fi), ,7R

where B( ii) is the probability an arrival is blocked when the system is in state ii. Unfortunately, due to the form of the constraint (2.2), ?R consists of “corners” and “faces” of various dimensions (0 to .s – 1), and B(Fi’) therefore depends on the precise location of ii. There does not appear to be an efficient scheme for evaluating (2.7) for typical values of s (e.g., s = 6). Ross and Wang [ 1992] use Kelly’s results [ 1986] to obtain B and B, from “normalizing Kelly’s results cannot be applied to our model since R is not constants.” bounded by linear constraints. from N and N, via the It is more efficient to obtain B and B, indirectly balance equations, A(l – B)

= Np

(2.8)

) =NL/.L.

(2.9)

and A,(I –B, 3. THE BASIC SIMUL ATION In our simulation, we will obtain estimates of B and B, from estimates of N and N,, via (2.8) and (2.9). Equations (2.3) and (2.4) suggest the following scheme for evaluating N and N,. Let X = (Xl, Xz, , . . . X.) be independent Poisson random variables where E(XL ) = p,. Define Z=l ~

and

=X,Z,

{X’e R}>

Y=

(Xl

+Xz

+ . . . +X, )Z.

Then from (2.3), (2.4), (2.5), and (2.6), we have E(Y) N=—

In fact, if R

c R

where

when

E(x)

and



N, = —

E(Z)

R is the rectangular

fi={Fi:

then (3. 1) is valid

E(Z)

OP2,... > p,) is far from the boundary either 1 or O, depending on whether ~ is inside or outside of R. These two cases correspond to very low and very high blocking probabilities, respectively. Clearly our method (equations (3. 1) or (4.2)) will have difficulty in these cases. The standard approach to overcoming this problem uses importance sampling, which for our problem is very simple. We consider only reparameterization of the truncated Poisson distribution. (Ross and Wang [1992] consider our basic simulation (Section 3) to be using importance sampling, since the Xi’s are not uniformly distributed. However, we feel that the natural way to simulate our system is with (3.2) and therefore consider importance sampling to be the use of any other sampling distribution.) Let ~ be any positive vector. It is easy to show (e.g., Ross and Wang [ 1992]) that

Ep, E,;(Y) N =

E,;(Z)

(5.1)

= E@

In fact, for any vector

~, we can write

Ef(YIl;[;]’Yi-k) E,j( Y ) ‘=

E;(Z)

(5.2)

= E,;[ZH;=l(~]Y1-kl]”

To help reduce roundoff error, it is probably a good idea to choose ~’= E(l) (to keep the expectations from being too big or too small), although k has no effect on the variance of estimates based on (5.2). This is especially important different from 1. if the p,’s are large and/or the ratios p, /p,* are significantly ACM

TransactIons

on Modeling

and Computer

Slmulat,on,

Vol. 5, No. 1, January

1995

Efficient Monte-Carlo Simulation

.

17

Choose ~ and define X,–k,

()

Yp= Yi:l ;

X,–kc

,

Zr=zfi

& 2=1 ()P:

and let Y;., Z~, Y;,, and Z;, be defined analogously.

,

(5.3)

Thus, for any ~ we have

If we were to use importance sampling alone (no control would try to choose & so as to minimize the variance of

variates),

then we

(5.4)

Of course one must choose ~ heuristically and hope for the best. Ross and Wang [1992] obtain some insight about the optimal importance sampling distribution for problems similar to ours. Their results do not yield an implementable sampling distribution, and their heuristic for choosing P does not apply to our problem since they do not use (5.4). We suggest HEURISTIC

is closest

1.

For

to ~ when

(5.4),

choose ~“ near

,B is large

and

choose

the point G* near

on the boundary $ when

of R that

$ is small.

When @is very large, we find that (5.4) with ~ based on the heuristic works very well. However, for “normal” systems (blocking probabilities between 10-3 and 10- 1), importance sampling alone is of little value and can, in fact, be counterproductive. (See the examples in Section 6.) Ross and Wang [ 19921 report modest speedups using importance sampling with ~ # ~ based on heuristics ‘for their test system. We could not achieve their level of success for our system. As Bratley, Fox, and Schrage [1987] point out, the tradeoffs when using importance sampling are complex and often unpredictable. Even with the best of intentions, importance sampling sometimes backfires, increasing the variance instead of reducing it. However, we have observed an unexpected side effect of combining importance sampling with the control variates described in the previous section, which yields astonishing variance reduction for our system in many cases. Apparently ~c+/.??~t

when

,~~./Z;.and

~“ > 6 (elementwise), are much larger ~;./~~

the correlations than the correlations

~/~, ~’/~’ and ~“/l?”. The importance sampling amplifies the power of the control variates. Even sampling alone increases the variance of the estimate variates are included, the resulting estimate

between between

therefore significantly when the importance of N, after the control

(5.5)

ACM TransactIons on Modeling and Computer Simulation,

Vol 5, No. 1, January 1995

18

.

P. J. Fleming et al

has far less variance than either (5.4) or (4.2). (See the numerical studies in the next section.) The optimal ,iP for (5.5) is not the same as for (5.4). We suggest

is closest closest

For

2.

HEURISTIC

to ~ when

to ~ when

(5.5), choose ~ is large,

$* near

and

the point

choose

;*

on the boundary

halfway

of R that

to the boundary

point

$ is small.

The optimal values of yl and Yz in (5.5) are estimated using the same sequence of calculations as the optimal fll and ~z in (4.2). Thus, to implej ment (5.5) instead of (4.2) one simply changes the sampling distribution for X and replaces (Y, Z, Y’, Z’, Y“, Z“ ) by (~;., ZP, Y;,, Z;., Y~., Z;.). The following heuristic explanation sheds some light on the synergy we observe between importance sampling and control variates when ~ < ~. Furthermore, it suggests that we may observe this synergy in other contexts. from (5.3) that the samples of < 1 we see pZ/p~ When (Y~, Zj, ~J., Z:., Y;, Z~J) are large when the Xl’s are small, and small when the Xl’s are large. But when the X,’s are s~all we (usually) have Z = Z’ = Z“ = 1 and Y = Y’ = Y = Z:. ~X,, since X falls into all three regions, R, R‘, and l?”. Thus, Zp., Z;, and Z;, and Y$, Y; and Y$ coincide when they are (relatively) large and disagree when they are (relatively) small. This is the opposite of the situation when no importance sampling is used or if ~ < ~. We therefore expect larger correlations when we use importance sampling with ~ > ~. Of course, if we make $* too large the harm done by using a bad sampling distribution may negate the benefit of the control variates. When we follow Heuristic 2 we observe huge speedups, especially for systems outside the “normal” range. The idea of using importance sampling to increase control variate correlations is worthy of further investigation. The numerical studies in the next section show that dramatic variance reduction is possible using this technique. 6. NUMERICAL

STUDIES

The interested reader can obtain a copy of our simulation code by contacting one of the authors. In this section we attempt to give a sense of the efficiency of the simulation based on (3.1), (4.2), (5.4), and (5.5) with some numerical studies. It is difficult to do a thorough job in this regard due to the large number of parameters in our system and in the various implementations of the variance reduction techniques. However, we feel that the following results support the major claims made in the previous sections. We will use four different systems as test cases. The systems are symmetric (to reduce the number of parameters), but the simulation code is not altered in any way to take advantage of the symmetry. Without loss of generality we take p = 1. The four systems are specified in Table 1. The only parameter missing is p, the system load (and total arrival rate), which is used as the independent variable in the experiments. ACM

Tr-ansactlons

on Modeling

and Computer

S,mulatlon,

Vol. 5, No

1, January

1995,

Efficient Monte-Carlo Table 1.

Simulation

.

19

System Descriptions

s System

Parameter

rIIrIIv

I s (number of sectors)

6

c (channels per carrier

3

A (common carriers)

12

m (fixed channelsper sector)

2

r (max. channelsper sector)

12 38 44 50

633

613

24

72

72

72

36

192

128

82

225

136

90

235

144

98

245

085

=1=1=

To give an idea of the effectiveness of the three methods of variance reduction, control variates only (CV), importance sampling only (IS), and importance sampling with control variates (I SCV), we plot the “speedup” over the basic simulation (BS) due to each method for each system as a function of p. “Speedup” is the ratio of the asymptotic variance parameters of the estimate of B from the basic simulation and the estimate of 1? employing the variance reduction technique of interest. Since the calculations necessary to implement the variance reduction take very little CPU time, the speedup is approximately the increase in efficiency of the simulation. We approximate the speedup by taking the ratios of the sample variances from simulations that simultaneously implement BS, CV, IS, and ISCV. In the case of IS and ISCV, three values of p“ are used based on the heuristic given in Section 5. These values are given in Table 1. The regions R‘ and R“ are chosen as suggested in Section 4, i.e., r: = r, and A = CA + ~~.lml. The numbers along the top of the plots in Figure 3 are the blocking probability and the variance times 10G of the basic simulation with no variance reduction techniques applied for the corresponding offered load. For is approximately example, in System I, at p = 40, the blocking probability 0.075 and the variance of this estimate is 0.00000018. The lower case letters labeling the curves refer to the values in Table 1 of the importance sampling p“. Note that the vertical axes are logarithmic and identically parameter, scaled so comparisons can be made across systems. The granularity of the mark on the horizontal axis. Each plots is two values of p per “tick” simulation is based on 100,000 replications. The results consistently show the following: (1) IS alone tends fairly large.

to increase

ACM Transactions

variance

on Modeling

unless

and Computer

the blocking Simulation,

probability

Vol. 5, No 1, January

is 1995.

20

P. J. Fleming et al.

.

Blocking Fmbdxl,ty

Blcckmg Pmbahhty (Vmmax

IOSw,tio”t Vimancc Rc4ucUO”) 03.33 033 013 037 .075 121 169 216 258 (042)(034)(020(021)(0.10 (O17NJ20J(13 31)(056) (Vmance x

(%

(0%)

lo6w,tio”t (00:)

vmmm

(::)

134 (015)

10000-

10000

. .. . . .

1000 ~

099 (008)

(0::)

100000-

100000

----

100

~

,()

% %

~

Rduction)

& ml

1oo-

Y

,0- ..’.!

>.: -

m=

1-

/“ a,

0.1-

0.1

/

‘\ \/

0.0001 24

28

32

38

40

44

48

52

56

0.0001