Transcript

Competing Resource Allocationin Two-Dimension

Tin Yau Pang and K.Y. Szeto+Physics DepartmentSchool of Science

Hong Kong University ofScience and Technology

Hong Kong+Email: [email protected]

Abstract-Strategies of resource allocation for companiescompeting in a metropolis can be investigated in the context ofstatistical physics using the technique of Monte Carlosimulation. In this paper we focus on several topologicalarrangements for two competing companies in a hexagonalworld. We have investigated six classes of patterns: randomgraph, random walk, clusters, straight lines, small rings, andbig rings. The aim of each company is to find the best strategyof initial distribution of resource to achieve market dominancein the shortest time. Two measures of the fitness of theconfiguration are introduced. The first one measures the speedof one company to achieve dominance with a given percentageof market share. The second one measures the market share bythe dominant company within a fixed period (in terms ofMonte Carlo steps) of evolution. Numerical simulationsindicate that initial patterns with certain topological propertiesdo evolve faster to market dominance.

I. INTRODUCTION

The problem of optimal strategies of resources allocationis an interesting topic in econophysics. Let's consider theproblem of two competing supermarket companies openingtheir branches in shopping malls in a metropolis. Thedecision makers must decide the locations of their branchesgiven the city map, here assumed to be a hexagonal lattice.If their objective is to dominate the opponent in marketshare as quickly as possible, how would they assign theirbranches? In this paper, we approach this problem usingknowledge in statistical mechanics [1]. We initialize thehexagonal lattice by various topological arrangements andsimulate the evolution of the two competing companies byMonte Carlo method. The aim of our investigation is tostudy how certain simple topological patterns would affectthe outcome of evolution. Since we consider only twocompanies, we can map this problem to the Ising model ofstatistical mechanics and observe the evolution of the spinconfigurations at various noise levels [2]. Here the shoppingmalls in a city are mapped to the sites of an Ising lattice. Thetwo spins in the Ising model represent the branches of thetwo competing companies. We assume that every shoppingmall must accommodate one and only one supermarket, and

so every site in the lattice will have one spin only.We focus on six types of patterns: Small Ring, Big Ring,

Straight Line, Cluster, Random Walk and Random Graph.The basic approach is as follow: (1) A fitness is designed toassess the quality of a configuration over 2000 numericalexperiments. (2) Two hundred configurations for eachpattern are generated for statistical analysis. Totally thereare twelve hundred configurations to be assessed for sixpatterns. (3) Monte Carlo Simulation [3] with metropolisalgorithm is performed to evolve these configurations.

II. DEFINITION OF THE MODEL

Agent-based interaction between two competingcompanies can be modelled by the ferromagnetic Isingmodel in statistical physics. This model has beenextensively studied in physics of magnetism [1,4] andrecently used in econophysics [2,5,6]. It considers two spinorientations (up or down) corresponding to two companies,black and white on the lattice, with site labelled by the x andy coordinates on this lattice. The city map is modelled by a20x20 hexagonal lattice with periodic boundary condition.Each site must be occupied by one and only one spin. Themodel describes the competition between the two companiesin the city via nearest neighbour interaction, described bythe interaction energy,

E=-EJiiXiXj<i,j>

(1)

where Jij =0 if i j

Here J4 represents the interaction between spins in twoneighbouring sites (i,j), and xi represents the spin state of thei site, with value I or -1. We can see that the interactionbetween two agents of the same company lowers the energyand vice verses. In order to have a fair comparison ofdifferent topologies for resource distribution, we assumethat the number of shops of the two companies is initiallyequal. This justification of this model for competing

0-7803-9422-4/05/$20.00 C2005 IEEE1670

companies has been reported earlier [2].

III. DEFINITION OF THE PATTERNS

After defining the model of interaction betweencompanies, we propose several classes of patterns, all withequal number of spin up and spin down, and compare theadvantages of each pattern in the context resource allocationfor two competing companies. A simple performanceevaluation for the patterns is to compare the speed toachieve dominance, defined by a fixed percentage of themarket share. This corresponds to the race of the twocompanies to first reaching the market share of a fixpercentage, for example, 75%. Another measure is to askhow each strategy of resource allocation can becomedominant, and what this percentage is, after defining the fixduration of the race. Both measures are meaningful.

Before we discuss the measures, we must first define theway we generate our patterns. We first assign sequentiallyan integer to each site on the lattice, starting with 0 assignedto the site at the top left corner. For example, in a 20 x 20lattice, the second site in the first row is numbered 1, and thethird site 2,.and so on., while the first site on the second rowis numbered 20. An integer therefore defines a site in thelattice uniquely in this scheme. The procedures forgenerating the patterns are described in the followingparagraphs and Fig. 1 shows some of the typical examples ofthese patterns. In Fig. 1, the winner is coloured white and theloser is coloured black.

A. Big Ring / Small RingLet's first choose a site randomly and define it as the set

S(O). Now, given S(k), we generate S(k+l) by consideringthe neighbours of the sites in S(k) by starting with the sitehaving the smallest number, which we call io. All theneighbours of io are considered in a clockwise direction,beginning from the one to the right of io. If the followingtwo conditions are met for the neighbour Xof io, (1) Xis notan element of the set S(k), and (2) k < j for some integer j,which we define later, then that site will be added to T(k)with a probability P. In fact, for large j, we have small ring,and for small j, we have big ring. When we have gonethrough all six neighbours of io, the site in S(k) with thesecond smallest number is to be considered in the samemanner as io. We continue this process till we finish theentire set S(k). When all neighbours of sites in S(k) arevisited, S(k+l) is defined as the union of S(k) and T(k). Herewe have to make sure that the number of elements in S(k)with k <j will not exceed half of the number of sites (L2) onthe lattice. This is because ifj is too large then S(k)/S(k-j),which will be used to produce the ring structure, maycontain more than L2/2 members for all k >j. When k >j,condition (2) is changed to (3) which states that thedifference of the number of elements between the set (S(k)U T(k)) and S(k-j+l) is no greater than L2/2. This ensures

that the number of sites inside this ring structure is no morethan L2/2. In this way we can be sure that there exists aninteger m > j such that the set S = S(m)/S(m-j) will contain200 elements, which consists of sites having spin opposite tothe rest of the lattice's. In our simulation we set P=0.6 andj=7 to generate Small Ring, and P=0.6 with j=5 for BigRing. Despite the similarity in the procedures generating theconfigurations of Big Ring and Small Ring, the two patternshave significant difference. For Big Ring, some of the partsof the ring are very close together, sometimes in contact dueto periodic boundary condition. In contrast, a distance isalways maintained for the sites of the ring in Small Ringpattern. Note that the losers (winners) are in the ring of theSmall (Big) Ring pattern. Thus, the ring in Small Ringtopology is coloured black, while the ring in Big Ringtopology is coloured white.

B. StraightLineFirst we randomly select a site as the starting point of a

straight line, with a direction randomly chosen out of the sixdirections. All sites along the chosen direction will bevisited one by one starting from the starting site, until itreturn to the starting site due to periodic boundary condition.All sites being visited will be coloured white and areincluded in the set S. If the number of members in S isbelow L2/2, another starting site is randomly selected andthe above procedure is repeated. When the number of whitesites reaches L2/2 we stop and the remaining sites arecoloured black.

C. ClusterA set S(O) of random sites is selected. Here the number of

members of the set S(O) is less than L2/2. Given the set S(k),we find the site in S(k) with the smallest number andlabelled it by io. Six neighbours of io are considered in aclockwise manner, starting from the one to the right of io. Aneighbour of io is included in a set T(k) if (1) this neighbouris not in the set S(k), and (2) the number of sites in the unionof S(k) and T(k) is less than L2/2. After considering allneighbours of io, we proceed to the site with the secondsmallest number in S(k) and repeat the process ofexamination of its six neighbours, until all the sites in S(k)have been considered. Finally, S(k+J) is defined as theunion of S(k) and T(k). The same procedure is continueduntil a certain m is attained, where S(m) contains L2/2elements, which we coloured black. The remaining sites areall coloured white. In our simulation, the number ofmembers in S(O) is set to 40.

D. Random WalkFirst randomly choose a site to form the first element ofS.

This site is coloured white and the remaining sites are black.We then perform random walk by visiting one of theneighbours of the chosen element of S, which initially

1671

Cluster

Kr) C00C*AQ

1D

Random Walk

I O D0*0* 0****0(1DI""Oooo*oowooo*oooeo*'"0(C"PNo

O*,

W*T"I'"IJSWI4Do-Oe o'

"a'*0

~~~oooooo~~'CJ."oo"ooooc

Random Graph* Oc"O***0II0*Q "p"1"O*a'**C)INI000QQ**00000*OQ**QO*0**010C)0**0Q*01 O**O0O*0Q**o*o* *oec*o*w*6is, .Q.OO..Q00.

Fig. 1. Typical examples of six different topologies. All figures have equal number ofwhite and black hexagons. By convention, company with whitehexagons are more likely to be the winner, (the dominant colour after some time). The graph of Small Ring and Big Ring are respectively made up of

4 identical configurations in order to restore the shape of the rings.

contains only one element which is denoted by io. This siteis coloured white and the remaining sites are coloured black.Given ik, we denote the next site to be visited as ik+j. Thissite ikj is a site randomly chosen out of the six neighboursof ik. When ik+1 is visited, its colour will be changed. Whenthe colour of ik+ has been changed, we will randomly visit

one of its six neighbours, which we calledi1k+2. Note that i,and i4, may refer to the same site for some m, n, and so thecolour of that site may be changed more than once. Thisprocess continues till the number of sites coloured whiteequals the number of sites coloured black. We denote the setof white sites by S.

1672

Small Ring

x "xxxxx

Big Ring

L]LILXILX1: IL IL 11

f,(O.75)

Small RingBig Ring

--- -- Straight Line-- Cluster-- Random Walk

~~ Random Graph

..00

0.0002Fitness

f2 (5°°°)

0*c)

.0

,>0.5

U)

CU

E0

0 oo

0.0

a 1.0-a)ci)LLc0

.-O 0.5-

.0

CU

E oo0

f2(3000)

0.5Fitness

0.5 0.0 0.5Fitness Fitness

Fig 2. The cumulative distribution frequency off,(O. 7S),f2(3000),f2(SOOO) andf2(7000).

TABLE I

PROBABILITY FOR ONE SPIN TO DOMINATESmall Big Straight Clut Random RandomRin Ring Line uster Walk Gah

f(O. 75) Average 1.00 0.84 0.94 0.60 0.52 0.50

S.D. 0.00 0.26 0.13 0.33 0.10 0.08

f2(3000) Average 0.89 0.89 0.84 0.59 0.52 0.50

S.D. 0.07 0.15 0.17 0.24 0.07 0.05

f2(SOOO) Average 0.99 0.91 0.88 0.56 0.53 0.51

S.D. 0.06 0.13 0.17 0.23 0.08 0.05

t2(7OOO) Average 1.00 0.89 0.90 0.59 0.52 0.51S.D. 0.02 0.18 0.15 0.23 0.07 0.05

S.D.: Standard Deviation

E. Random GraphL2/2 sites are randomly chosen among L2 sites to be white

and the remaining sites are coloured black.

By convention, we associate spin up (+1) for white sitesand spin down (-1) for black sites in our model Hamiltonianthat describes the interaction between two companies.

IV. MONTE CARLO SIMULATION

Monte Carlo simulation is employed to simulate theswitching process of association of companies at each site.In each Monte Carlo step (the metropolis algorithm), a site iis randomly chosen. We then consider the change of energy(AE ) due to switching the spin in site i (from white to blackif site i is white originally, or from black to white if site i is

1673

c 1.0ci)03

LLC03

. 0.5-0

0)

CU

E: 0.0-

C,

c 1.0-a)0 .a,LL

._n0

.0-

CU

E0

0.0000

0.0 1.0

black originally). If AE.O, the spin in site i will beswitched. IfAE>o, then the spin will be switched accordingto the probability:

p1 -Xg (2)

Here 8=JIkT is the inverse temperature, with k being theBoltmann constant (set to one in our discussion). In oursimulation we set T equals 0.2. (Note that this temperature iswell below the critical temperature of the Ising model inhexagonal lattice so that we are certainly not in the hightemperature phase where neither company can win due tothe high thermal noise [2]). At T=0.2, one company (colour)will be able to dominate the lattice. Simulation is carried outby repeating the Monte Carlo step until certain stoppingcriteria are reached. The stopping criteria define the basis ofour evaluation of the six different topologies in terms ofresource allocation.

V. ASSIGNING FITNESS TO THE CONFIGURRTIONS

Given six topologically different classes of patterns, allwith equal number of spin up and down, we like to comparethe advantages of each pattern in the context resourceallocation for two competing companies using the switchingdynamics in our Monte Carlo simulation.The first measure is to compare the speed to achieve

dominance, defined by a fixed percentage b of the marketshare. At the beginning, we generate 200 configurations foreach of the six pattems. Each configuration is repeated Ntimes for MCS. Out of these N times, some of thesimulations may enter a deadlock, in which neither colourcan defeat the other within 50000 MC steps. In this situationwe reject these trials. AfterN simulations with clear winners,there will n, times having white dominance and n, havingblack dominance, (N = n, + n,). For each configuration wethen define:

F (x,b)=nx( where x{1,-1} (3)

Here x can be 1 or -1 and t is the number of MCS forconfiguration i to evolve to a state with a winner. Thestopping criterion is defined by the time step t<S0000, whenone colour has reached b percent of the sample in aparticular trial. Here <J/t>x is the average of lit over nxtrials where spin x dominates the lattice. After evaluating200 configurations of the same topology, we observe thatone colour (which we choose to be white) has a higherprobability to dominate, except for the case of RandomGraph. We denote this winner by xo and the fitness of eachtopology by:

f1(b)=F1(xo0b) (4)Alternatively, we can fix the duration of the race (for

example, in s MCS) oftwo competing companies to achieve

dominance, and measure the percentage of the dominantcompany at the end of the race. Again we perform N trialsignoring those trials without clear winners in s steps. Then,for each topology inN trials with clear winner, we define:

F2(x,s)= nx x(D(x,s)), where xe{1,-l} (5)

Here D(x, s) is the fraction of sites with spin x after s MCSand <D(x, s)>x is the average of D(x, s) over the nx trialswith spin x dominance. After evaluating 200 configurationsof the same topology, we observe that one colour (againdefined to be white) has a higher probability to dominate thelattice. Denote it by xo and the fitness of a given topology isdefined as:

f2(s)= F2(x0,s) (6)For Random graph, there is statistically no clear winner andby convention the winners are white too. (xo is spin up).

In our simulations we set N equals 2000, which is chosenso that the error of <I/t>x and <D(x, s)>x are less than 10%.For the first fitness, we have chosen b = 0.75 and for thesecond fitness, we have used s = 3000, 5000 and 7000.(These values for s are chosen since most configurationsrequire s > 8000 to attain 100% dominance.)

VI. RESULTS

We have measuredff(0. 75),f2(3000),2(5000) andf2(7000)in 200 sample configurations of each of the six topologies.The cumulative distribution of fitness and the probability forwhite dominance are shown in Fig.2. Each curve in Fig.2 isaveraged over the results on 200 configurations of the sametopology. It is found that the winning company for the BigRing, Straight Line and Random Walk are those initiallylocated in sites that are in S. The expected winning spin forthe pattern Small Ring and Cluster are those initially in siteswhich are not in S. Again, as shown in Fig. 1, white colourdepicts the strategic locations of the company with higherwinning probability.

In terms of both measures, Small Ring, Big Ring andStraight Lines are winning strategies for resource allocation.The other patterns all have smaller fitness on average. Asexpected, the random graph produces winning probability of0.5.

VII. CONCLUSION

Through simulation we discover that certain topologicalarrangement of the resource in two-dimensions have higherprobability of dominance. In particular, small ring, big ringand straight line patterns are good topologies while randomwalk, clusters are of lower probability of winning. Ournumerical studies provide some guidance for resourceallocation with quick market dominance. Although our

1674

numerical works are performed on the hexagonal lattice, weexpect our findings to be generally applicable to theVoronoi diagrams constructed from random point patternsin two-dimension. This expectation is based on our recentwork on damage spreading in various kinds oftwo-dimensional cellular structures [7].

ACKNOWLEDGEMENT

K.Y. Szeto acknowledges the support by CERG GrantHKUST 6157-OIP and HKUST 6071-02P.

REFERENCE

[1] K.Huang, Statistical Mechanics, Wiley, 1987.[2] Kwok Yip Szeto and Chiwah Kong: Different Phases in a Supermarket

Chain Network: An Application of an Ising Model on Soap Froth,Computational Economics, 22(2): 163-17, 2003

[3] M. E. J. Newman, G. T. Barkema (1999), Monte Carlo Methods inStatistical Physics, Clarendon Press Oxford, 1999, p. 45-59

[4] Xiujun Fu, Kwok Yip Szeto, and Wing Keung Cheung, Phase transitionof Ising Model on two-dimensional random point patterns. PhysicalReview E70, 056123(2004)

[5] Chiwah Kong, MPhil. Thesis, Hong Kong University of Science andTechnology. 2002

[6] Wing Keung Cheung and K. Y. Szeto, Strategies for ResourceAllocation of Two Competing Companies using Genetic Algorithm,Proceedings ofthe Fifth International Conference on Recent Advancesin Soft Computing, Nottingham, United Kingdom, 16-18 December2004, P.416-421

[7] Z.Z.Guo, K.Y. Szeto, and Xiujun Fu, Damage spreading ontwo-dimensional trivalent structures with Glauber dynamics:Hierarchical and random lattices, Phys. Rev. E70, 016105(2004)

1675


Recommended