Controlling a Population Nathalie Bertrand INRIA Rennes Miheer
Controlling a Population Nathalie Bertrand (INRIA Rennes), Miheer Dewaskar (Univ. North Carolina@Chapel Hill), Blaise Genest (CNRS – IRISA Rennes), Hugo Gimbert (CNRS – La. BRI Bordeaux) Concur 2017 + Adwait Godbole (IIT Bombay) LMCS 2019 (+convergence speed)
Experimental Setting Yeasts Idealized Setting: Many yeasts, same simple finite-state model for all yeasts. Control: Same action for all yeasts at a given time (more or less sugar) Simplified question: ? Controller to surely bring all yeasts to a given state? (vs bring 60 -80% of yeasts in a given state)
Idealized Setting: Question: ? Controller to surely bring all yeasts to state 1 at the same time? sorbitol off/on 2 Control at each step: same action for every yeast. 1 e. g. : sorbitol off for all yeasts, sorbitol on for all yeasts 3 2 player game on NFA: Controller player + Agents resolving non det.
Exact Model: sorbitol off/on 2 2 2 …X… 1 sorbitol off/on 3 …X… 1 ~ 100. 000 3 1 3 times Untractable => Use symbolic Infinite system
Symbolic Population Model: sorbitol off/on 2 Configuration (X, Y, Z) with X+Y+Z=N 1 3 N times. Can we control a population of N yeasts, for all N? If not, for which N can we? Then compare with number of yeasts Parametric control question. Note: up to now, mostly parametric model-checking question (no synthesis of a controller)
Basic Properties: sorbitol off/on Prop: If there exist a controller s. N for N yeasts, then there exists a controller s. N-1 for N-1 yeasts 2 1 3 Hence, either exists a strategy for all N, or there exist a N 0 with controller for N< N 0, and no controller for N > N 0 is the cut-off.
Usual Solution to Param. Question: Let A an NFA with |Q| states. Prop: For all N, there is a strategy to control a population of N models A iff there is a controller for a population of size f(|Q|) (the cut off). Problem: There are NFA A such that f(|Q|) = 0(22|Q|). Untractable
Solving control problem symbolically c c c Natural idea: Use support NFA?
Solving control problem symbolically Prop: If winning strategy in the support game, then winning strategy for all N. Converse not necessarily true: agents counter strategy in support may not correspond to agent strategy for population of any size N.
Solving control problem symbolically c c c No Strategy for support c ,
Solving control problem symbolically c c c play ab: q 4 leak Strategy for all N. q 2 q 1 accumulate Playing (ab)* long enough till no token in q 2. And then we can play c and reach . Hence for all N, there is a strategy s. N leading to N. q 3
Solving control problem symbolically Prop: If winning strategy in the support game, then winning strategy for all N. Converse not necessarily true: agents strategy in support may not correspond to agent strategy for population of any size N. Idea: Keep support game but change the winning condition. Infinite play is R-winning for controller in support game if path reach { } OR no N such that play corresponds to a play with population of size N.
Defining Leaks Paths with « unbounded leak » does not correspond to paths of population of size N, for no N. leak q 4 q 2 q 1 accumulation q 3 Path has unbounded leak if for all K, exists a time point and state q with K or more entries in the future of q 1 2 3 states 0 K=4 4 5 … Time points
Solving control problem symbolically An infinite play is U-winning for controller in support game if reach { } or it has « unbounded leak » . Prop: for all N, controller has a winning strat for N tokens iff Controller has a U-winning strat in the support game. But Unbounded condition hard to check
Defining Leaks Unbounded leak if for all K, exists a time point and state q with K or more entries in the future of q Infinite leak if exists a time point and state q with Infinite number of entries in the future of q 1 2 3 4 5 … time Unbounded leak not equivalent with infinite leak state 0 K=infinity
Solving control problem symbolically Þ replace unbounded leak by infinite leak (Buchi condition, easier). An infinite play is I-winning for controller in support game if reach { } or there is an « infinite leak » . For finite memory strategies of Agents, if there is no infinite leak, there is no unbounded leak
Reach-or-Leak Question: How to solve I-winning games? Infinite Leaking accepted by a exp. non-determinsitic Buchi automata: Guess (q, i) and check that (q, i) has an infinite number of entries. Can determinize it as a doubly exp det. Parity automaton (exp. parities) Can run this det. parity automaton to tell if the play is I-winning. Þ 2 EXPTIME complexity. Finite memory M enough (doubly exp. ) Þ Hence solve U-winning games as well.
Theorem 1: We can check whether population can be controlled for all N In 2 -EXPTIME. Easy standard lower-bound: PSPACE-hard (using standard techniques with expon. many supports) We can do better than 2 EXPTIME! Theorem (CONCUR 2017): Population control is EXPTIME-complete Ad-hoc construction of exponential size parity game (with polynomial number of parities).
Example symbolic run … symbolic memory state ( support, parity + list ≤|Q|² graphs ) Parity (lowest in 1… 2|Q|²+1 ), 1: goal reached 4 G 1 Tracks: [0 -1] 4 graph extended Not leaking not leaking G 1 G 2 [0 -2] G 3 … [2 -3] … 1 3 2 graph extended graph restarted goal leaking reached
Number of steps before synchronization Theorem (LMCS 2019): if population controllable for all N, then O(1) |Q| need at most time N to reach Goal. There are systems requiring time polynomial in N and exponential in |Q|.
Number of steps before synchro? When the system is controllable for all number n of agents, how many control steps s(n) before all agents are in the target state f? s: n-> number of steps is it constant, log, linear, polynomial, exponential?
Number of steps before synchro? Assume system is controllable for all number n of agents. Consider a real run under our strategy … It plays action played by symbolic strategy symbolic run symbolic memory state (support + list ≤|Q|² graphs) … () ( G 1 G 2 ) ( G 3 ) …
Number of steps before synchro? Take any long enough real run following wininng strat: Many times the same symbolic memory state M M M M Between any 2 instances of M M , there must be a leak, else strategy not winning. More precisely, we can partition set of states as: M M L L A A L={qtop} e. g. : A={qbot, k}
Number of steps before synchro? Take any long enough real run following winning strat with n agents. M L A Partition (L, A) between first and last M. L, A are 2 disjoint sets M L A 1 ≤ entries of accumulator A ≤ n R 1 R 2 R 3 R 4 R 5 From R 1 to Rk, with k < n => take R 4 with most nbr of repeated M. Partition between first and last M of R 4: partition (L’, A’) ≠ partition (L, A) M 1 ≤ entries of accumulator A’ ≤ n L’ A’ M L’ A’ R 4 In R 4, no arrow between L and A. But one arrow at least between L’ and A’: must be within L or within A. Let say L: L’ ∩ L, A’ ∩ L are non empty, and at least one of A’ ∩ A or L’ ∩ A is non empty. 3 non-empty disjoint sets. By induction, |Q|+1 disjoint sets of |Q| states: contradiction
Number of steps before synchro? Assume system is controllable for all number n of agents. Theorem: If system has |Q| states and n agents, at most n|Q| 2|Q|4 steps before synchronization of all agents in target state f. There are systems requiring number of steps polynomial in number of agents and exp. in number of states, whatever the strategy.
Sum-up Deciding whether for all N, there exists controller s. N is EXPTIME-complete. If yes, we have a symbolic controller with finite exponential memory and which needs polynomial nbr or steps before synchro. |A|² 2|A|+1 If not, there exists N 0 ≤ 22 2 such that: controller up to N 0 and no controller after N 0 And there are cases where we have N 0 = 22 |A|/2 -10
Future work Sure rechability: Agents is too powerful, Allowed to perform always very unlikely behavior. 0. 6 0. 8 2 0. 1 1 0. 2 0. 8 If sorbitol on 0. 4 0. 1 3 2 0. 5 1 0. 7 3 0. 5 If sorbitol off What about almost-sure reachability? Controlling random population Fo. SSa. CS 2020 [Colcombet, Fijalkow, Ohlmann]
Controlling random population Fo. SSa. CS 2020 [Colcombet, Fijalkow, Ohlmann] Not even elementary complexity + But win in exponential average time in number of agents: not realistic. => controller is too powerful. Consider average logarithmic time to win? Work in progress
30
Average logarithmic time: Work in Prog. Build the support game. Compute # (accelerations) of words till saturation of the monoid of actions over support. (see Markov algo for PFAs) a, b q 0 d q 1, q 2 a, b q 0, f (d a)# (d b)# q 1, q 2, f d f
Average logarithmic time: Work in Prog. Computing w# from subset S: Consider the graph (S, E) with (s, t) ϵ E iff s S q 0 da f da w# w U BSCC (S, E) q 0, f (d a)# f t
What we expect: Deciding whether for all N, there exists almost sure controller s. N which needs a polylog number of steps in average is PSPACE-complete.
Exponential size Parity Automaton Build ad-hoc deterministic automaton: Compute deterministic parity automaton: exp. size, poly parities Þ EXPTIME, exponential memory, cut-off doubly exponential N= 2 M 2 1 2 3 4 5 … state 0 G 2 G 3 G 4 …. |A| G[2, 4]=G 2◦G 3 leaks at G 4
Exponential size Parity Automaton Build ad-hoc deterministic automaton: Compute deterministic parity automaton: exp. size, poly parities Þ EXPTIME, exponential memory, cut-off doubly exponential N= 2 M 2 |A| Main issue: Determinise the choice of start « i » for infinite leak 1 2 3 4 5 … i=2 state 0 G 2 G 3 G 4 …. Consider G[2, k] and accepting state everytime leaks at a graph Gk
Separation Determinise the choice of starting leak « i » x Def: We say that G[i, j]=Gi. . Gj-1 separates (x, y) if for some q, (q, y) G[i, j] and (q, x) G[i, j] q If G[i, j] leaks at Gj then G[i, j] separates some (x, y) Lemma: Take the minimal i s. t. run starts inifinte leak at i: Then exist (xj, yj)j ≥i such that : G[i, j] separates all (xj, yj) j ≥i and G[i-1, k] separates a finite number of (xj, yj) j ≥i y
Number of steps before synchro? What about synchronization in log time? in constant time wrt n? There is a winning strategy s. t. for all the runs under this strategy agents synchronize in constant time iff winning for support game More complex for logarithmic time: Supports are not enough. logarithmic time strategy: Repeat till synchro: Play d. If nb(q 1)>nb(q 2) play a, else play b. Not a support based strategy. Another solution: randomization.
Exponential size Parity Automaton Determinise the choice of starting leak « i » Keep in memory G[i 1, j], G[i 2, j]… G[in, j] such that G[ik, j] separates some (x, y) not separated by G[ik’, j] for k’<k. Only |A|² graphs to keep in memory. => Exp. number of states One parity for each graph, to detect infinite leak from this graph. EXPTIME, exponential memory, Cut off doubly exponential N= 2 M 2 2|A|+1
Number of steps before synchro? When the system is controllable for all number n of agents, how many control steps s(n) before all agents are in the target state f? s: n-> number of steps is it constant, log, linear, polynomial, exponential? Winning strategy: Play try (keep try)* till qtop or qbot empty, then play top or bot then restart. Repeat till agents in f. Number of steps till synchro is at most quadratic in number n of agents.
- Slides: 38