• Tidak ada hasil yang ditemukan

M ICH A EL J.D IN N EEN and BA K H A DY R K H O U SSA IN OV, D epartm entofCom puterScience,U niversity ofAuckland,Auckland, New Zealand.

N/A
N/A
Protected

Academic year: 2023

Membagikan "M ICH A EL J.D IN N EEN and BA K H A DY R K H O U SSA IN OV, D epartm entofCom puterScience,U niversity ofAuckland,Auckland, New Zealand."

Copied!
14
0
0

Teks penuh

(1)

U pdate G am esand U pdate N etw orks

M ICH A EL J.D IN N EEN and BA K H A DY R K H O U SSA IN OV, D epartm entofCom puterScience,U niversity ofAuckland,Auckland, New Zealand.

E-m ail:

f

m jd,bm k

g

@ cs.auckland.ac.nz

ABSTRACT:In thispaperw em odelinfiniteprocessesw ith finiteconfigurationsasinfinitegam es overfinite graphs.W e investigate those gam es,called update gam es,in w hich each configura- tion occurs an infinite num beroftim esduring a tw o-person play. W e also presentan efficient polynom ial-tim e algorithm (and partialcharacterization) for deciding ifa graph is an update network.

Keywords:Infinite gam es,update netw orks.

1 Introduction

M any real-w orld system s can be view ed as infinite duration processes w ith finite states.Severalexam plescan be found in com puteroperating system s,airtraffic con- trolsystem s,banking system s,and the on-going m aintenance ofcom m unication net- w orks. A functioning system has to be robust(e.g.,an operating system should not crash regardlessofw hatthe userdoes).A term ination ofany ofthese system scan be thoughtofas a failure. Thusw e need an infinite duration m odelto study properties ofsuch system s.In practice these system shave only a finite num berofstates(e.g.,a banking system hasa finite num berofcustom ers,assets,etc.).

O vertim e,each system enters only a finite num berofstates and produces an in- finite sequence ofstates,called a run-tim e sequence. Since the num berofstates is finite,som e ofthe states,called persistentstates,appearinfinitely often in a run-tim e sequence. The success ofa run-tim e sequence is determ ined by w hetherornotthe collection ofpersistentstates satisfies certain specifications. Thus,w e can view the run-tim e sequencesas plays ofa tw o-playergam e w here one player,called the Sur- vivor,triesto ensure thatpersistentstatessatisfy som e property and the otherplayer, called the Adversary,doesthe opposite.

O urproposed m odelforan infinite duration system is based on a finite (directed) graph.The verticesofthe graph representthe states ofthe system and the edges(or arcs)correspondto thelegalstatechanges,called m oves(ortransitions),ofthesystem . DEFIN ITIO N 1.1

A n infinite duration gam eG is a finite (directed)graphG =(V;E),a fam ilyW of subsetsofV,and tw o players(the Survivorand the A dversary).W e requirethateach vertex ofGhas out-degree ofatleastone. A m em berofW is called a winning set.

A configuration ofa gam e is a pairofthe form (v;Survivor)or(v;A dversary)for

J.D iscrete Algorithm s,Vol.2 N o.1,pp.55–68,2002 cK ing’sCollege Publications

(2)

v2V.

Thegam erulesallow configurationm ovesfrom (w;X)to(w0;X0)such that(w;w0)

2 EandX 6=X0. Each play ofan infinite duration gam e is an infinite sequence of configurations(v0

;X

0 );(v

1

;X

1

);:::;(v

i

;X

i

);::: such thatthe gam e rules are fol- low ed. W e calla finite prefix sequence of a play a history. W e say thata vertex

v is visited in the play if configuration(v;X)occurs in som e history of the play.

N ote thateither the Survivor or the A dversary m ay begin the play. The Survivor w insa play ifthe setofpersistentverticesofthe play isa w inning set,otherw ise the A dversary w ins. A strategy fora playerXi ofa gam e is a function from play his- tories(v0

;X

0

);:::;(v

i

;X

i

)to configurations(vi+1

;X

i+1

)such thatthe m ove from

(v

i

;X

i

)to(vi+1

;X

i+1

)isa gam erule.

A given strategy fora playerX m ay eitherw in orloose a gam e w hen starting at an initialconfiguration(v0

;X

0

),w herev0

2 V andX0is eitherplayer. A player’s winning strategy foran initialconfiguration isone thatw insno m atterw hatthe other playerdoes.

EX A M PLE1.2

In Figure 1 w e presenta gam eG=(G;W).A san exam pleofa w inning strategy for theSurvivorconsiderthe initialconfiguration(4;A dversary).Ifthe A dversary m oves to vertex3then the Survivorsim ply m ovesto vertex1and the gam e repeatsbetw een those tw o vertices (w hich is a w inning set). O n the other hand,if the A dversary m ovesto vertex5,the Survivorm ovesto vertex6forcing the A dversary to m ove to

4,w hich isthen controlled by the Survivor.The Survivorattem ptsto force the vertex setf4;5;6ginto apersistentsetby m oving to vertex5.Ifthe A dversary triesto m ove to3from 5then the Survivoris allow ed to change its m ind and forcef1;3gas the persistentsetand w in.Thus,the A dversary loosesno m atterw hatchoice ism ade at vertex5.

W e end this section w ith a few related references. Previous w ork on tw o-player infinite duration gam es on finite bipartite graphs is presented in the paper by M c- N aughton [1]and extended by N erode etal. [2]. O urw ork focuseson a subclassof the gam esconsidered by these authors.N erode etal.providean algorithm fordecid- ing M cN aughton gam es. Theiralgorithm runs in exponentialtim e ofthe graph size forcertain inputs.Forourgam esw e provide tw o sim ple polynom ialtim e algorithm s fordeciding updatenetw orks,partially based on thestructuralpropertiesoftheunder- lying graphs. W e also note thatseveralearlierpapershave dealtw ith finite duration gam eson autom ataand graphs(e.g.,see [3,4]).

2 U pdate G am es

W e now m odela naturalcom m unication netw ork problem . Suppose w e have data stored on each node ofa netw ork and w e w antto continuously update allnodesw ith consistentdata. Forinstance,w e are interested in addressing redundancy issues in distributed databases.O ften one requirem entisto share key inform ation betw een all nodesofthe distributed database.W e can do thisby having a data packetofcurrent

(3)

2

3

4

5

6

W =ff1;3g;f2;3;4;5g;f4;5;6gg V =f1;2;3;4;5;6g

E =f(1;3);(2;3);(2;4);(3;1);(3;2);(4;3);(4;5);(5;3);(5;6);(6;4)g G=(V;E)

1

FIG.1.Exam pleofan infinite duration gam e.

inform ation continuously go through allnodesofthe netw ork.Thisisessentially an infiniteduration gam ew heretheSurvivor’sobjectiveisto achieveaw inning setequal to allthe nodesofthe netw ork.Thisgam eisform ally defined asfollow s:

DEFIN ITIO N 2.1

A n updategam e isan infinite duration gam eG=(G;W)w ith the singleton w inning setW =fVg.A n updatenetworkistheunderlying graphGofan updategam ew here the Survivorhasa w inning strategy foreach initialconfiguration.

Som etim esw e w illtalk abouta graphGbeing an updategam ew ithoutm entioning the w inning set,since itisunderstood thatW =fVg.

EX A M PLE2.2

Thegraph displayed below in Figure2 isan updatenetw ork.N oticethatallcyclesare ofodd length so thatthe Survivorand the A dversary alternately controlthe vertices w ith m ore than one possible m ove.The Survivorcan use itsopportunitiesto visitall verticesofthe graph.

3 Bipartite U pdate N etw orks

W e firststudy a specific class ofupdate gam es on bipartite graphs,called bipartite update gam es. Forthese gam esw e restrictthe dom ain ofgraphsto bipartite graphs w here the verticesV of each graph can be partitioned into tw o disjointsetsAand

S such thatevery edge is directed from AtoS orfrom S toA. W e also stipulate thateach vertex hasan out-going edge (i.e.,thisensuresthatevery play isofinfinite duration).By definition,w eassum ethattheSurvivorm ovesfrom Sand theA dversary

(4)

FIG.2.A sim ple exam pleofan updategam ew hich isan updatenetw ork.

m ovesfrom A.In essencethevertices(in thesebipartitegam es)areowned by thetw o playersofthe gam e. Thus,forthese gam es,there are onlyjVjgam e configurations w here each vertexvdeterm inesa unique configuration depending on w hethervisin

SorA.In the nextsection w e return to the updategam esdefined in D efinition 2.1.

DEFIN ITIO N 3.1

A bipartite update network isa bipartite graph(V =A[S;E)ofa bipartite update gam ein w hich theSurvivorhasaw inning strategy to visitevery vertex ofV infinitely often from every initialconfiguration.(Thatis,the Survivorcan force the persistent setofverticesto beV.)

W e can easily characterize those bipartite update netw orksw ith only one Survivor vertex.These are the bipartite graphsw here out-degree(s)=jAjforthe single Sur- vivorvertexs.W e now deriveseveralpropertiesforallbipartiteupdatenetw orks.

LEM M A3.2

If(V = A[S;E)is a bipartite update netw ork then forevery vertexs 2 S there existsatleastonea2Asuch that(a;s)2Eand out-degree(a)=1.

PRO O F.The idea is to show thatif there exists a vertexs thatdoes notsatisfy the statem entofthelem m athen theA dversary can alw aysavoid visitings.LetAs

=faj

(a;s)2 Egand assum e out-degree(a) > 1foralla 2As. The A dversary has the follow ing w inning strategy.Iftheplay history endsin configurationa2Asthen since out-degree(a)>1,the A dversary m ovestos0(ofS),w heres0 6=sand(a;s0)2E. Thiscontradictsthe assum ption oflem m a.

For the follow ing results let(A[S;E)be a bipartite update gam eB. For any Survivorvertexsdefine

Forced(s)=fajout-degree(a)=1and(a;s)2Eg;

w hich denotesthe setofA dversary verticesthatare ‘forced’to m ove tos. N ote,by the previouslem m a,thissetw illbe non-em pty forgam esplayed on bipartite update netw orks.

(5)

LEM M A3.3

IfBisa bipartite update netw ork such thatjSj>1then foreverys2Sthere exists ans06=sand ana2Forced(s),such that(s0;a;s)isa directed path.

PRO O F.Take anys 2 S and considerF = Forced(s). By the Lem m a 3.2F is not em pty. Ifthere is ans0 6= s adjacentto a vertex (i.e.,an in-neighbor)inF w e are done.O therw ise,alls0 6=sare notadjacentto any vertex inF.Thusthere existsan

a

0notinFfrom w hich theA dversary hasaw inning strategy by notm oving tos.This contradictsBbeing a bipartite updatenetw ork.

DEFIN ITIO N 3.4

G ivenabipartitegraph(S[ A;E)aforced cycleisa(sim ple)cycle(ak

;s

k

;:::;a

2

;s

2

;

a

1

;s

1 )forai

2Forced(si)andsi

2S.(N otethatforced cycleshaveeven length since the graph isbipartite.)

W enow presentourpenultim ateingredientthatw illbeused to characterizebipartite updatenetw orks.

LEM M A3.5

IfBisa bipartiteupdatenetw ork such thatjSj>1then there existsa forced cycle of length atleast4.

PRO O F.Takes1

2S.From Lem m a 3.3 there existsa path(s2

;a

1

;s

1

)inBsuch that

s

2 6=s

1 anda1

2 Forced(s1). N ow fors2 w e apply the lem m a again to geta path

(s

3

;a

2

;s

2

)inB such thats3 6= s

2anda2

2 Forced(s2). Ifs3

= s

1w e are done.

O therw ise repeatLem m a 3.3 forvertexs3.Ifs4 2fs

1

;s

2

gw e are done.O therw ise repeatthe lem m a fors4.Eventuallysi

2fs

1

;s

2

;:::;s

i 2

gsinceBisfinite.

Thus,ifBdoesnothavea forced cycleoflength atleast4 then eitherjSj=1orB isnota bipartite update netw ork.W e now presenta contraction m ethod thathelpsus decideifa bipartite gam eisa bipartite updatenetw ork.

LetB=(S[ A;E)beabipartiteupdategam ew ith aforcedcycleC=(ak

;s

k

;:::;

a

2

;s

2

;a

1

;s

1

)oflength atleast4.W e can define a contracted bipartite update gam e

B 0

=(S 0

[A 0

;E 0

)asfollow s.Fornew verticesaandslet

S 0

=(Snfs

1

;s

2

;:::;s

k

g)[fsg and A0 =(Anfa1

;a

2

;:::;a

k

g)[fag:

W ithE00being the induced edgesofthe subgraphBnfs1

;a

1

;:::;s

k

;a

k glet

E 0

=f(s;a 0

)ja 0

2A 0and(si

;a 0

)2E; forsom eikg[

f(a 0

;s)ja 0

2A

0and(a0;si

)2E; forsom eikg[

f(s 0

;a)js 0

2S

0and(s0;ai

)2E; forsom eikg[f(a;s);(s;a)g[E00: Thenextlem m ashow sthe relationship betw een gam eBand thereduced gam eB0. LEM M A3.6

IfB =(S[A;E)isa bipartite update gam e w ith a forced cycleCoflength atleast 4 then the contracted bipartite update gam eB0 =(S0[A0;E0)is a bipartite update netw ork ifand only ifBisone.

(6)

PRO O F.W e show thatifB0 is an update netw ork thenB is also an update netw ork.

W e firstdefine the naturalm appingpfrom verticesofBonto verticesofB0by

p(v)=v ifv62C

p(v)=s ifv2C\S

p(v)=a ifv2C\A:

Then any play history ofBism apped,via the functionp(v)=v0,onto a play history ofB0.Considera play historyv0

;v

1

;:::;v

nofBthatstartsatvertexv0andvn 2S. Letf0 be a w inning strategy in gam eB0 forthe Survivorw hen the gam e begins at vertexv0

0

.W e use the m appingpto constructthe Survivor’sstrategyf in gam eBby considering the follow ing tw o cases.

Casev0

n

=s. The strategy is to extend the play (inB)by visiting allthe verticesof the cycleC atleastonce. Iff0(v0

0

;:::;v 0

n ) = a

0 w herea0 6= aw e find asi 2 C

such that(si

;a 0

) 2 E then extend the play again w itha0 as the lastm ove. O ther- w isef0(v0

0

;:::;v 0

n

) = aand the play is extended by picking anak

2 C such that

(v

n

;a

k )2E. Casev0

n

6= s. Iff0(v0

0

;:::;v 0

n ) = a

0

6= athenf w illalso m ove toa0. O therw ise

a 0

2Cand the play isextended by picking anak

2Csuch that(vn

;a

k )2E. Itisnothard to seethatf isaw inning strategy fortheSurvivorin gam eBw henever

f

0isa w inning strategy inB0.

W e now show thatifB is an update netw ork thenB0 is also an update netw ork.

Takeany vertexv0

0

from B0.W e show thatthereisaw inning strategy fortheSurvivor starting atv0

0

.Fix any vertexv0such thatp(v0 )=v

0

0

.W e w illkeep a correspondence betw een positionsvi of a play onB w ith positionsv0

i

of a play onB0. W e now sim ulate the w inning strategyf onB starting atv0. The strategy forthe initialplay historyv0

0 2S

0isf0(v0

0

)=p(f(v

0

))exceptforthe casev0

0

=s.In thisexceptional casetheSurvivor’sinitialstrategy isto m ovedirectly to anya0 6=aand replacefw ith thestrategy starting ata0.N ow letv00

;v 0

1

;:::;v 0

nbeany play history ofB0thatoccurs afterthe initialplay asdictated above.W e definea strategy forf0w henv0

n

isinS0by studying tw o cases.

Casev0

n

= s. Considerthe previousvertexv0

k

=a 0

6=aofthe play history thatis inA0andv0

k +1

=s. Thusin the gam e onB,the A dversary from a0 elects to m ove to som esi inC. Since in gam eB0 the A dversary m ay have few erchoices,w e can pick,w ithoutloss ofgenerality,thatitm oved tosiw hereiisthe sm allestallow able index. The choice ofany indexiis validated because the cycleC is a forced cycle.

Thestrategyf0now sim ulatesw hatfw ould do from si.Tw o cases:(1)iff m ovesto avertexajonCthenf0m ovestoa,or(2)iff m ovesto avertexa0notonCthen also

f

0m ovestoa0.In thefirstinstancethestrategyf0forcesaplay thattogglesbetw eena andsinB0untilcase (2)holds.(A nd thism usthappen sincef isan updatestrategy.) Casev0

n

6=s.H ere the strategy issim plyf0(v0

0

;:::;v 0

n

)=p(f(v

0

;:::;v

n

)).Thatis, the play follow sthe strategyfon the sim ulated gam ehistory ofB.

The strategyf0forthe Survivorisan update strategy sincepisa m apping from B ontoB0(i.e.,ifallverticesofBareinfinitely repeated viafthen allverticesofB0are infinitely repeated viaf0).

(7)

s

1

s

2

s

3

s

4

a

1

a

2

a

3

a

4

a

5 B

B 0

s

a

a

5

a

4 a

3

s

4 s

3

FIG.3.Show ing the bipartiteupdategam ereduction ofLem m a3.6.

W ith respectto the contraction m ethod above,Figure 3 show show a forced cycle ofBisreduced to a sm allerforced cycle (oflength 2)inB0.

Forthenextresultletndenotetheorder(num berofvertices)andmdenotethesize (num berofedges)ofa graph.

TH EO R EM 3.7

Thereexistsan algorithm thatdecidesw hetherabipartiteupdategam eBisabipartite updatenetw ork in tim eO(nm).

PRO O F.W e show thatfinding a cycle thatisguaranteed to existby Lem m a 3.5 takes tim e atm ostO(m)and thatproducingB0from B in Lem m a 3.6 takes tim e atm ost

O(n+m).W e can also detectin tim e atm ostO(m)w hen a forced cycleoflength at least4doesnotexist.Since w e need to recursively do thisatm ostntim esthe overall running tim e isshow n to beO(nm).

The algorithm term inates w henever a forced cycle of length atleastfour is not found. Itdecides w hetherthe currentbipartite graph is a update netw ork by sim ply checkingthatS=fsgand out-degree(s)=jAj.Thatis,thesingleton Survivorvertex isconnected to allA dversary vertices.

Letusanalyze the running tim e forfinding a forced cycleC.Recallthe algorithm im plied by Lem m a 3.5 beginsatany vertexs1and findsan in-neighbora1(ofs1)of out-degree 1 w ith(s2

;a

1

)2 E w heres2 6= s

1. This takes tim e proportionalto the num berofedgesincidenttos1to find such a vertexa1.Repeating w iths2w e find an

a

2in tim e proportionalto the num berofedgesintos2,etc.W e keep a boolean array to indicate w hichsiare in the partially constructed forced path (i.e.,the look-up tim e w illbe constanttim e to detecta forced cycle oflength atleast4). The totalnum ber

(8)

ofstepsto find the cycle isatm osta constantfactortim esthe num berofedgesin the graph.

Finally,w e can observe thatbuilding the contracted bipartite gam eB0from Band

Crunsin lineartim e by the definition ofS0,A0andE0.N otethatifthe data structure forgraphsistaken to be adjacency liststhenE0isconstructed by copying the listsof

Eand replacing oneorm ore verticessi’soraj’sw ith onesora,respectively.

The above resultindicates the structure of bipartite update netw orks. These are basically connected forced cycles,w ith possibly otherlegalm oves forsom e of the Survivorand the A dversary vertices. Figure 4 show s a constructed exam ple ofone such bipartite update netw ork.The Survivor’sstrategy isto system atically repeatthe forced cyclesand ‘detour’to coverthe rem aining non-forced A dversary verticeson a periodicbasis.

FIG.4: Illustrating the structure ofbipartite update netw orks w ith Survivorvertices (black)and A dversary vertices(w hite).

W e listallthe non-isom orphic bipartite netw orks oforderatm ost5 in Figure 5.

N ote that18 of the 19 netw orks of order 5 w ere generated from three of the net- w orks of order4 (see those displayed on the top row ). This w as done by system - atically adding a new adversary node w ith allpossible com binationsin-degreesand out-degrees of 1 and 2. N ote thatthe firstfour graphs in the firstcolum n and the firstand fourth graphsin the lastcolum n are m inim alin the sense thatalledges are essentialforthese graphsto be bipartiteupdatenetw orks.

4 R ecognizing U pdate N etw orks

W e now w antto presentan algorithm to decide w hethera given update gam e isalso an update netw ork.O uridea isto take an update gam eGand im plicitly transform it into a bipartite gam eBG.(N oteBGw illnotbe a bipartite update gam e,asdescribed in Section 3.)W e then show how to decideifthe graphG(ofG)isan updatenetw ork by checking ifthe Survivorhas a w inning strategy forevery initialconfiguration of

B

G. Recallthatin a bipartite gam e the A dversary and the Survivoronly m ove from

(9)

FIG.5:A llsm allbipartiteupdatenetw orksw ith Survivorvertices(black)and A dver- sary vertices(w hite).

(10)

oneofthe vertex partitionsofthe graph.

W e define the gam eBG

= (B;W) from an update gam eG = (G;fV(G)g)as follow s:

V(B) = fv

S

jv2V(G)g[fv

A

jv2V(G)g

E(B) = f(v

S

;u

A

)j(v;u)2E(G)g[f(v

A

;u

S

)j(v;u)2E(G)g

W = fY j8v2V(G);9w2Y(w=v

Sorw=vA )g

N ote thatthe graphB is only tw ice the size ofGbutthe explicitstorage forthe w inning setsW is exponentialin the size ofG’s w inning setsfV(G)g. Figure 6 show sa sm allexam pleofthe construction ofBfrom G.

0

1 2

3

1

A

2

A

3

A 0

A 0

S

1

S

2

S

3

S

FIG.6.M apping an updategam e (graphG)to a bipartitegam e(graphB).

The vertices ofB w illcorrespond to a vertex/playercom bination ofthe gam eG. W e have the follow ing equivalence.

LEM M A4.1

The gam eGis an update netw ork ifand only ifthe Survivorhas a w inning strategy forevery initialconfiguration ofBG.

PRO O F.Firstassum eGisan update netw ork.Forany initialconfiguration(v;X)of the gam eGthe Survivorhasa w inning strategyf.The Survivorcan use thisstrategy

f forthe initialconfigurationvX in the gam eBG. (Recallthatin the bipartite gam e

B

G the Survivorcan only startfrom a vertexvS).Sincef forcesallverticesofGto be visited infinitely often,atleastone ofthevAorvS isvisited infinitely often inB forallv2G.

N ow assum e thatthe Survivorhas a w inning strategyf0forBG starting atvertex

v

X.Every persistentsetofverticesY thatoccurw hen the Survivorusesf0 isinW. TheSurvivorcan sim ulatef0(onBG)forthegam eGw ith initialconfiguration(v;X) and w in the gam e.

W e now define for any subsetof verticesV0 of a bipartite gam eG the closure Forced(V0).Thisisthe setofvertices(containingV0)thatthe Survivorhasa strat- egy to force the A dversary to visitatleastone vertex ofV0. W e have the follow ing algorithm to com puteForced(V0).

(11)

algorithm FindForced(V0V(G))forbipartitegraphG=(S[A;E) 1 Q ueueN ew Verts=V0

SetF =V0

2 w hile Vertexvin N ew Verts.head()do N ew Verts.rem ove(v)

3 ifv2Athen

SetF0= inN eighbors(v) N ew Verts.append(F0nF)

F =F[F 0

endif 4 ifv2Sthen

SetF0=;

5 forVertexuin inN eighbors(v)do

ifoutN eighbors(u)F then F0=F0[fug endfor

N ew Verts.append(F0nF)

F =F[F 0

endif endw hile returnF end

W e provethe correctnessofthisalgorithm below.

LEM M A4.2

A lgorithm FindForced com putesForced(V0)fora bipartitegraphG=(S[A;E). PRO O F.W e show thatforevery vertexv,vis in Forced(V0)ifand only ifvis re- turned inF by the algorithm FindForced.To do thisw e assign a num ber,called the rank,to each vertex of the graph. The rank indicates the num berofforced m oves needed to reachV0 from a vertex. Therankfunction is inductively defined as fol- low s:

1.Ifv2V0thenrank(v)=0.

2.Casev 2 S andrank(v)is notdefined. A ssum e allout-neighborsofv ofrank of atm ostihave been defined. Thenrank(v) = i+1if there exists anu 2 outN eighbors(v)w ithrank(u)=i.

3.Casev 2 A andrank(v) is notdefined. A ssum e allout-neighbors ofv have defined rank.Thenrank(v)=i+1ifeachu2outN eighbors(v)hasrank(u)

i.

Ifv 2Gdoesnotgetranked in the above processthen w e setrank(v)=1.W e now show thatv 2 Forced(V0)ifand only ifrank(v) <1. Supposerank(v) =

n < 1. Ifn = 0thenv 2 V0. O therw ise considertw o cases. Ifv 2 S thenv is in the closure since atleastone neighboruofv has sm allerrank (i.e.,the Survivor can m ove touandrank(u) < rank(v)). Ifv 2 Athenv is in the closure since allneighbors ofv have rank less thann(i.e.,any m ove ofthe A dversary m oves to

(12)

a vertexuofrank less thann). Supposerank(v) = 1. W e w antto show thatthe A dversary has a strategy thatdoes notallow the Survivorto reachV0. W e note that follow ing tw o observations. Ifv 2 Sthen allneighborsofv have rank equalto1 by definition ofthe rank function (i.e.,the Survivorcan notreachV0 from v). A lso by definition,ifv 2 Athen there is atleastone neighboruofvw ith rank equalto

1(i.e.,the A dversary can m ovetouthatisnotin the closure).N ow the A dversary’s strategy to avoidV0 is the follow ing.Foranyv 2Aw ithrank(v)=1m ove to a neighborvertexusuch thatrank(u) =1. Clearly this strategy causes allplays to stay on a subsetofthe setV00=fwjrank(w)=1gandV00\V0=;.

O necan see thatthe algorithm FindForced addsa vertexvtoFifand only ifithas finite rank.The algorithm im plicitly labelsa vertexvofS[Aby the iteration count ofthew hileloop atline2 w henvisadded toF(theverticesV0arelabeled w ith count 0). H ence ifa vertex is labeled then ithas finite rank. Statem ent3 ofthe algorithm correspondsto the casev2Sandv 62V0ofthe definition ofrank w hile Statem ents 4–5 correspond to the casev 2A andv 62 V0. This m eans thatifvhas finite rank then itw illbe labeled by the algorithm .

LEM M A4.3

Forbipartite gam es,there existsan algorithm thatrunsin tim eO(m),w heremisthe size ofthe graph,thatcom putesForced(V0).

PRO O F.W e show how to m odify the algorithm FindForced to run inO(m)tim e.The algorithm as listed needsto processeach vertex in the queue N ew Vertsatm ostonce and foreach ofthese vertices access its in-neighbors. So excluding the loop atline 5 the algorithm runs inO(m)steps. The process tim e,as listed,to check w hether outN eighbors(u) F takes atm ostO(n)tim e. H ence,FindForced runs in tim e

O(nm).

W e now explain how to reduce the running tim e ofthe loop atline 5 ofalgorithm FindForcedto constanttim e.Instead ofcheckingthesetm em bershipoutN eighbors(u)

F w e do the follow ing.W e keep an array ofintegersDegthatindicatesforeach vertex how m any neighborsare notcurrently inF.The entry forvertexxisinitially defined as the out-degree ofx. W henevera vertexy is added toF w e decrem ent the entry for each in-neighborz ofy by one. W e can now replace the condition outN eighbors(u)Fby testing w hetherDeg[u]=0,w hich can be donein constant tim e.

RecallLem m a 4.1 states thata gam eG is an update netw ork if and only if the Survivorhasa w inning strategy forevery initialconfiguration ofBG.The nexttheo- rem also characterizesupdatenetw orks(notnecessarily bipartite gam es)by using the closureoperator.

TH EO R EM 4.4

A gam eG = (G;fV(G)g )is an update netw ork if and only if for allv 2 V(G) Forced(fvS

;v

A

g)=V(B)in the corresponding bipartite gam eBG

=(B;W). PRO O F.Supposethereisan updatenetw ork,w ith graphG,such thatForced(fvS

;v

A g)

6= V(B)forsom ev 2 V(G). Take any vertexxofBthatdoes notbelong to this

(13)

closure.U sing theproofofLem m a4.2 w eseethattheSurvivorcan notforcetheplay to visitvSorvAfrom vertexx2V(B).ThustheA dversary w insgam eBGbeginning from x.By Lem m a 4.1 the graphG(ofthe gam eG)can notbe an updatenetw ork.

W e now prove the otherim plication ofthe theorem . By Lem m a 4.1,itsuffices to show thattheSurvivorcan w in thegam eBGfrom any starting vertex.W e use thefact thatForced(fvS

;v

A

g)=V(B),forallv2V(G),to build aw inning strategy forthe SurvivorinBG.O rderthe verticesofGasv1;v2;:::;vn.Letxbe a starting vertex ofB. The Survivorcan use algorithm FindForced to visiteitherv1

S

orv1

A

. N extthe Survivorcan force the play to visitto eitherv2

S

orv2

A

,then eitherv3

S

orv3

A

,etc.The Survivorthen repeatsthe forced playsbetw een the pairs(vi

S

orvi

A

)and (vi+1m odn

S

or

v

i+1m odn

A

)w hich yieldsa w inning setofW.

U sing the previous lem m a and theorem w e can efficiently recognize update net- w orks.

TH EO R EM 4.5

Thereexistsan algorithm thatdecidesw hetheran updategam eGisan updatenetw ork in tim eO(nm),w herenandmare the orderand size ofthe underlying graph.

PRO O F.W ecan constructthebipartitegraphBfrom thegam eBG,w hich corresponds toG = (G;fV(G)g),in lineartim e w ith respectto the size ofG. W e then invoke Lem m a 4.3 foreach pairofverticesfvA

;v

S

gforv 2V(G).By using Theorem 4.4, w e acceptthe inputif Forced(fvS

;v

A

g) = V(B) for allv 2 V(G). The total running tim e isn=jV(G)jm ultiplied by the tim e needed to com putethe closure(of tw o verticesvAandvS)inB.ThisproductisO(nm).

5 C onclusion

In thispaperw ehavepresented agam e-theoreticm odelofinfiniteduration processes.

A particularem phasis is given to a class ofnetw orks w hose objective is to continu- ously update allthe nodesw ith consistentdata.W e have show n thatitisalgorithm i- cally feasible to recognize update netw orks.Thatis,w e have provided an algorithm w hich solvestheupdategam eproblem inO(nm)tim e.M oreover,ouralgorithm for the case ofbipartite update gam escan be used to give a characterization ofbipartite updatenetw orks.

There are m any open questions thatstillneed to be investigated in this area. For exam ple,onecan try to characterizethoseupdategam esforw hich theupdatenetw ork problem isdecidablein lineartim e.O necan also study thequestion offinding feasible algorithm s forgam es w hose w inning conditions are m ore com plex than the one for updategam es.Forthe lattercase,w e w antto efficiently extractw inning strategies(if they existforthe Survivor)foreach setofverticesin the w inning setofa gam e.

The gam esconsidered in this paperoccuroverfinite graphs. These gam escan be generalized to gam es overdifferentfinite m odels (such as hypergraphs). W e w ould like to know w hich ofthese generalized gam eproblem sare tractable.

(14)

A cknow ledgm ent

W ethank thetw o anonym ousrefereesw ho provided detailed and usefulcom m entson an earlierversion ofthispaper.

R eferences

[1] R.M cN aughton.Infinite gam esplayed on finite graphs.AnnalsofPure and Applied Logic,65,149–

184,1993.

[2] A .N erode,J.Rem m eland A .Yakhnis.M cN aughton gam es and extracting strategies forconcurrent program s.AnnalsofPureand Applied Logic,78,203–242,1996.

[3] R.J.B ¨uchiand L.H Landw eber.Solving sequentialconditions by finite-state strategies.Trans.Am er.

M ath.Soc.,138,295–311,1969.

[4] T.J.Sch¨afer.Com plexity ofsom e tw o-person perfect-inform ation gam es.J.Com puter & System Sci- ences,16,185–225,1978.

Received 1 N ovem ber1999.

Referensi

Dokumen terkait

High-level Categories of Index Types • B-Trees covered next • Very good for range queries, sorted data • Some old databases only implemented B-Trees • We will look at a variant