Capítulo III – “Elementos genéricos para la formulación de un modelo cubano de negocios basado en el
3.6 Propuesta de elementos clave para el diseño de un modelo cubano de negocios basados en SLCA
repeated reachability games and of eventual safety games, and a simple divide-and-conquer algorithm for solving them that runs in time O(nm).
78 Marcin Jurdzi´nski
While the algorithm is simple and efficient, its design provides a blueprint for a divide-and-conquer algorithm for solving parity games discussed in Section 3.3.
Before we present the algorithm for solving repeated reachability games we establish positional determinacy of reachability and safety games, and we describe the structure of the winning sets in reachability and safety games.
For a set T ⊆ V of target vertices, we define the 1-reachability set by reach1(T ) =∞
i=0reachi1(T ), where:
reach01(T ) = T
reachi+11 (T ) = reachi1(T )
∪ {v ∈ V1 : there is (v, w)∈ E, such that w ∈ reachi1(T )}
∪ {v ∈ V0 : for all (v, w)∈ E, we have w ∈ reachi1(T )}.
A positional strategy for player 1 that maps each of his vertices in a set reachi+11 (T )\reachi1(T ) to its successor in reachi1(T ) will be referred to as a T -reachability strategy. The 0-reachability set reach0(T ), and positional T -reachability strategies for player 0, are defined in an analogous way.
Exercise 3.1 Argue that if player 1 follows a T -reachability strategy from a vertex in reachi1(T ) then a vertex in T is reached in at most i rounds.
Conclude that if G is a reachability game with a target set T ⊆ V , then reach1(T )⊆ win1(G).
A set U ⊆ V is said to be a 1-closed set if for every vertex u ∈ U, if u belongs to player 0 then it has a successor in U , and if u belongs to player 1 then all its successors are in U . A positional strategy for player 0 that maps each of her vertices in a 1-closed set U to a successor in U is called a U -trapping strategy . Sets that are 0-closed , and positional trapping strategies for player 1, are defined analogously.
Exercise 3.2 Argue that the set S = V \ reach1(T ) is 1-closed, and that if player 0 follows an S-trapping strategy from a vertex in S then no vertex in T is ever reached. Conclude that if G is a reachability game with a target set T ⊆ V , then V \ reach1(T )⊆ win0(G), and that reachability and safety games are positionally determined.
In the following exercise the reader is asked to provide vital implementation details of an efficient algorithm for solving reachability and safety games.
Exercise 3.3 Give a detailed description of an algorithm for computing the set reach1(T ) that runs in time O(m), where m =|E| is the number of edges in the game graph. Devise an appropriate data structure for directed
Algorithms for Solving Parity Games 79 graphs, that for every vertex maintains the number of outgoing edges, to achieve this running time bound.
Theorem 3.2 Reachability and safety games are positionally determined.
The winning sets and positional winning strategies of both players can be computed in time O(m).
In Figure 3.1 we present a divide-and-conquer algorithm for solving re-peated reachability, and hence also for eventual safety, games. The algorithm takes a repeated reachability game G with the target set T as input, and it returns the pair (win0(G), win1(G)) of the winning sets of both players. The main insight behind the design of this algorithm is that the solution of a repeated reachability game can be obtained from the solution of a subgame that is also a repeated reachability game, and that has fewer vertices.
algorithm B¨uchi-win(G) if reach1(T ) = V then (W0, W1)← (∅, V ) else
W0 ← V \ reach1(T ) G← G \ reach0(W0) (W0, W1)← B¨uchi-win(G) (W0, W1)← (V \ W1, W1) endif
return (W0, W1)
Figure 3.1 A divide-and-conquer algorithm for repeated reachability and eventual safety games
In a series of exercises we provide the detailed structure of an inductive correctness proof for the algorithm, and we invite the reader to fill in the details.
Exercise 3.4 Assume that reach1(T ) = V . Argue that if player 1 follows a positional T -reachability strategy from an arbitrary starting vertex v∈ V , then a vertex in T occurs infinitely many times. Conclude that in this case win1(G) = V .
We say that a set D ⊆ V is a 0-dominion if it is 1-closed and player 0 has a D-trapping strategy that is winning for her from every starting vertex in D; the latter is called a 0-dominion strategy on D. The definitions of a 1-dominion and a 1-dominion strategy are analogous.
80 Marcin Jurdzi´nski
Exercise 3.5 Assume that reach1(T )= V , i.e., that W0 = ∅. Observe that the set W0 is 1-closed and that if player 0 follows a positional W0-trapping strategy μ from a vertex in W0 then no vertex in T is ever reached.
Argue that the set reach0(W0) is 1-closed, and that a positional strategy μ that is the union of strategy μ (on W0) and a W0-reachability strategy (on reach0(W0)\W0) is a reach0(W0)-trapping strategy. Prove that if player 0 follows strategy μ from a starting vertex in reach0(W0) then vertices in T occur only finitely many times.
Conclude that reach0(W0)⊆ win0(G), that sets W0 and reach0(W0) are 0-dominions, and that μ and μ are 0-dominion strategies.
Let G= G\ reach0(W0) be a repeated reachability game that is obtained from game G by removing vertices in the set reach0(W0) and edges adjacent to them. Assume that the game G is positionally determined, and that there are positional 0-dominion and 1-dominion strategies μ and χ on the winning sets W0= win0(G) and W1= win1(G) respectively, in game G. Exercise 3.6 Observe that positional determinacy of game Gimplies that reach0(W0)∪ W0 = V \ W1. Prove that the positional strategy that is the union of μ and μ is a 0-dominion strategy on V \ W1 in game G. Conclude that V \ W1⊆ win0(G).
Prove that χ is a 1-dominion strategy on W1 in game G. Conclude that W1 ⊆ win1(G), that repeated reachability and eventual safety games are positionally determined, and that the algorithm B¨uchi-win(G) is correct.
Theorem 3.3 Repeated reachability and eventual safety games are posi-tionally determined.
Note that the algorithm B¨uchi-win(G) solves two reachability games, and it makes one recursive call on a repeated reachability game G= G\reach0(W0) whose number of vertices is strictly smaller than that of G. It follows that its worst-case running time can be characterised by the recurrence:
T (n) ≤ T (n − 1) + O(m), T (1) = O(1),
where n =|V | and m = |E| are the numbers of vertices and edges, respectively, of the game graph, and hence T (n) = O(nm).
Theorem 3.4 The winning sets and positional winning strategies of both players in repeated reachability and eventual safety games can be computed in time O(nm).
Algorithms for Solving Parity Games 81