Decidability and complexity issues for subclasses of counter systems - - PowerPoint PPT Presentation

decidability and complexity issues for subclasses of
SMART_READER_LITE
LIVE PREVIEW

Decidability and complexity issues for subclasses of counter systems - - PowerPoint PPT Presentation

Decidability and complexity issues for subclasses of counter systems Lecture 1 Vector Addition Systems with States St ephane Demri demri@lsv.ens-cachan.fr LSV, ENS Cachan, CNRS, INRIA Course 2.9 MPRI 2010/2011 Verification of


slide-1
SLIDE 1

Decidability and complexity issues for subclasses of counter systems Lecture 1 Vector Addition Systems with States

St´ ephane Demri demri@lsv.ens-cachan.fr

LSV, ENS Cachan, CNRS, INRIA

Course 2.9 – MPRI – 2010/2011 “Verification of parametrized and dynamic systems”

slide-2
SLIDE 2

Decidability and complexity issues for subclasses

  • f counter systems
  • Lecture 1 (10/12/2010): Vector Addition Systems with

States.

  • Lecture 2 (17/12/2010): Reversal-bounded counter

automata.

  • Lecture 3 (07/01/2011): Counter systems with finite

monoid and flatness.

  • Lecture 4 (14/01/2011): Linear-time temporal logics for

counter systems.

  • Lecture 5 (21/01/2011): Exercises on data logics and

counter systems,improving Rackoff’s proof and model-checking (if time permits).

2

slide-3
SLIDE 3

Organizational matters

  • Slides available on-line on the 2.9 course web page:

http://mpri.master.univ-paris7.fr/C-2-9.html

  • Structure of each lecture:
  • Course 1h15-1h30.
  • 10-min break.
  • 30-45 min course
  • 20 min exercises.

3

slide-4
SLIDE 4

Internship proposals at LSV, ENS Cachan

  • “Counter Systems with Presburger-definable Reachability

Sets: Decidability and Complexity” with Arnaud Sangnier (LIAFA, Paris VII).

  • “D´

ecidabilit´ e et complexit´ e de la reconnaissance de langages alg´ ebriques” with Alain Finkel (LSV, Cachan).

  • “Compl´

etude de la logique de s´ eparation” with Etienne Lozes (LSV, RWTH Aachen).

  • Other proposals can be found at the course web page.

4

slide-5
SLIDE 5

Plan of the lecture

  • Recall on vector addition systems with states.
  • Coverability graphs.
  • EXPSPACE upper bound for the covering problem.
  • Other properties that can be checked in EXPSPACE.
  • If time permits, we start developments about the

EXPSPACE-hardness of problems on VASS.

  • Exercise on VASS weakly computing multiplication.

5

slide-6
SLIDE 6

Recapitulation about VASS

6

slide-7
SLIDE 7

Recapitulation about VASS

q0 q1

B B @ −1 1 C C A B B @ 1 C C A B B @ 1 −1 1 1 C C A B B @ −1 1 1 C C A

  • VASS is a counter system with transitions of the form

q

  • b

− → q′ with b ∈ Zn, which is a shortcut for

  • i∈[1,n]

x′

i = xi +

b(i)

  • VAS = VASS with a unique control state.

7

slide-8
SLIDE 8

Presburger arithmetic

  • Terms: t ::= 0 | 1 | x | t + t.
  • Presburger formulae (k ≥ 2)

ϕ ::= t ≡k t | t < t | ¬ϕ | ϕ ∧ ϕ | ∃x ϕ | ∀x ϕ

  • Valuation v : VAR → N + extension to all terms with

v(0) = 0 v(1) = 1 v(t + t′) = v(t) + v(t′)

  • Formula ϕ(x1, . . . , xn) with n free variables:

REL(ϕ(x1, . . . , xn))

def

= {(v(x1), . . . , v(xn)) ∈ Nn : v | = ϕ}.

8

slide-9
SLIDE 9

Counter systems

q0 q1 q2 ϕ( x, x′) ϕ′( x, x′) x′

1 = x′ 2 = x′ 3 = 0

x′

1 = x1 + 1

x′

2 = x2 + 1

x′

3 = x3 + 1

  • Counter system S = (Q, n, δ) of dimension n ≥ 1:
  • Q is a nonempty finite set of control states.
  • δ: finite set of transitions of the form t = (q, ϕ, q′) where

q, q′ ∈ Q and ϕ is a Presburger formula with free variables x1, . . . , xn, x′

1, . . . , x′ n.

  • Configuration (q,

a) ∈ Q × Nn.

  • (q,

a) t − → (q′, a′)

def

⇔ v[ x ← a, x′ ← a′] | = ϕ.

  • Runs as nonempty (possibly infinite) sequences

ρ = (q0, a0) − → (q1, a1) · · · (qk, ak) · · ·

9

slide-10
SLIDE 10

Subclasses of counter systems

  • Standard counter automaton (Q, n, δ): transitions are of

the form either q

inc(i)

− − → q′ or q

dec(i)

− − → q′ or q

zero(i)

− − − → q′.

  • Succinct counter automaton (Q, n, δ): transitions of the

form either q

add( b)

− − − → q′ with b ∈ Zn or q

zero( b′)

− − − → q′ with

  • b′ ∈ {0, 1}n (simultaneous zero-tests).
  • Vector addition systems with states (VASS): succinct

counter automata without zero-tests. A transition t is an element in Q × Zn × Q.

  • VAS T ⊆ Zn (finite sets of tuples).

10

slide-11
SLIDE 11

Reachability problems

  • REACHABILITY PROBLEM:

Input: VASS V, (q, x) and (q′, x′). Question: is there a finite run with initial configuration (q, x) and final configuration (q′, x′)? (in symbols (q, x) ∗ − → (q′, x′)?)

  • CONTROL STATE REACHABILITY PROBLEM:

Input: VASS V, (q, x) and q′. Question: is there a finite run with initial configuration (q, x) and whose final configuration has control state q′? (∃ x′ (q, x) ∗ − → (q′, x′)?)

  • CONTROL STATE REPEATED REACHABILITY PROBLEM:

Input: VASS V, (q, x) and qf. Question: is there an infinite run with initial configuration (q, x) such that the control state qf is repeated infinitely often?

11

slide-12
SLIDE 12

Variant problems

  • COVERING PROBLEM:

Input: VASS V, (q, x) and (q′, x′). Question: is there a finite run with initial configuration (q, x) and whose final configuration is (q′, x′′) with x′ x′′? (control state reachability is an instance with x′ = 0)

  • BOUNDEDNESS PROBLEM:

Input: VASS V and (q, x). Question: is the set {(q′, x′) ∈ Q × Nn : (q, x) ∗ − → (q′, x′)} finite?

  • TERMINATION PROBLEM:

Input: VASS V and (q, x). Question: is there an infinite run with initial configuration (q, x)?

12

slide-13
SLIDE 13

Witness run characterization for termination problem

  • VAS T ⊆f Zn and initial configuration

x0 ∈ Nn.

  • Propositions below are equivalent:

1 There is an infinite run from

x0.

2 There is a finite run

x0

− → y

+

− → y′ such that y y′.

y y′

def

⇔ for i ∈ [1, n], we have y(i) ≤ y′(i).

− →: reflexive and transitive closure of − →.

  • +

− →: transitive closure of − →.

  • Use of Dickson’s Lemma: for any infinite sequence
  • z0,

z1, . . . of tuples in Nn, there are i < j such that zi zj.

13

slide-14
SLIDE 14

From VASS to VAS (other direction is obvious)

A B C

+1 −1

(x1, A, B, C) (1, −1, 1, 0) (0, 1, −1, 0) (−1, 0, −1, 1) (0, 0, 1, −1) (A, 4) ≈ (4, 1, 0, 0) and (C, 2) ≈ (2, 0, 0, 1) Reduction is correct from VASS without self-loops

14

slide-15
SLIDE 15

Reduction

  • W.l.o.g., V has no transition of the form q
  • b

− → q. Otherwise, replace q

  • b

− → q by q

→ qnew and qnew

  • b

− → q.

  • As an exercise, show that the reachability [resp. covering,

boundedness] problem for VASS can be reduced to the same problem for VASS without self-loops.

  • VAS T built from VASS V = (Q, n, δ) has dimension

n + card(Q). Control states are encoded in the card(Q) last components.

  • Alternative reduction from VASS of dimension n to VAS of

dimension n + 3 (instead of n + card(Q)). [Hopcroft & Pansiot, TCS 79]

15

slide-16
SLIDE 16

Bijection between configurations

  • VASS V = (Q, n, δ) without self-loop.
  • Bijection h : Q → {n + 1, . . . , n + card(Q)} dedicated to

relate each control state of V with a unique component in the VAS we shall build.

  • Bijection between configurations in V and elements from

the set X: X = { x ∈ Nn+card(Q) : x([n + 1, n + card(Q)]) = ei ∈ Ncard(Q) for some i ∈ [1, card(Q)]},

  • ei ∈ Ncard(Q): unit element with 1 for the ith component and

zero otherwise.

x([n + 1, n + card(Q)]) is the tuple in Ncard(Q) restricted to the card(Q) last components of x.

16

slide-17
SLIDE 17
  • X = N × {(1, 0, 0), (0, 1, 0), (0, 0, 1)} for the VASS below:

A B C

+1 −1

17

slide-18
SLIDE 18

Defining the VAS T

  • VAS T such that for t = q
  • b

− → q′ ∈ δ (q = q′), the transition t′ ∈ T is defined as follows:

  • (t′)([1, n]) =

b,

  • for q′′ ∈ Q \ {q, q′}, t′(h(q′′)) = 0,
  • t′(h(q)) = −1 and t′(h(q′)) = 1.
  • For each run (q0,

x0) . . . (qk, xk) of V, f((q0, x0)) . . . f((qk, xk)) is a run in T .

  • Each configuration f((qi,

xi)) belongs to X.

  • Similarly, for each run

x0 · · · xk in T with x0 ∈ X, f −1( x0) · · · f −1( xk) is a run of V.

18

slide-19
SLIDE 19

Reductions

  • (q′,

x′) is reachable from (q, x) in V iff f((q′, x′)) is reachable from f((q, x)) in T .

  • This can be easily shown by induction on the lenght of the

run.

  • Consequently, the reachability problem for VASS can be

reduced to the reachability problem for VAS.

  • Given configurations (q,

x) and (q′, x′), the propositions below are equivalent:

  • in V, there is a run of the form (q,

x)

− → (q′, x′′) with x′ x′′,

  • in T , there is a run of the form f((q,

x))

− → z with f((q′, x′)) z.

  • Consequently, the covering problem for VASS can be

reduced to the covering problem for VAS.

19

slide-20
SLIDE 20

Reduction for the boundedness problem

  • Given a configuration (q,

x) for V, the propositions below are equivalent (one direction is obvious):

  • (q,

x) is unbounded (in V),

  • f((q,

x)) is unbounded (in T ).

  • For any configuration reachable from f((q,

x)), its restriction to the card(Q) last components can take at most card(Q) distinct values.

  • If f((q,

x)) is unbounded, then there is q′ ∈ Q such that there is an infinite amount of configurations reachable from f((q, x)) of the form f((q′, y)).

  • Hence, f((q,

x)) is unbounded implies (q, x) unbounded.

  • The boundedness problem for VASS can be reduced to the

boundedness problem for VAS.

20

slide-21
SLIDE 21

Solving the covering problem for VAS

21

slide-22
SLIDE 22

About the covering problem for VAS

  • COVERING PROBLEM:

Input: a VAS T and two configurations x, x′ ∈ Nn, Question: is there some configuration x′′ reachable from

  • x such that

x′ x′′?

  • The covering problem for VAS is EXPSPACE-complete:
  • Decidability with nonprimitive recursive complexity.

[Karp & Miller, TCS 69]

  • EXPSPACE lower bound from [Lipton, TR 76].
  • EXPSPACE upper bound from [Rackoff, TCS 78].
  • The control state reachability problem for VASS can be

reduced to the covering problem for VAS: require that one specific component has at least value 1. (reaching the control state A in VASS is equivalent to cover (0, 1, 0, 0) in corresponding VAS)

22

slide-23
SLIDE 23

Coverability Graph

23

slide-24
SLIDE 24

Coverability graphs in a nutshell

  • Finite graph whose set of nodes is a finite subset of

(N ∪ {∞})n that can be effectively computed.

  • It approximates the set of reachable configurations.
  • Simple properties on it allow to solve various problems:

boundedness, covering, termination, etc.

  • . . . but in the worst-case, its size can be nonprimitive

recursive.

  • First, we need to define relations and operations on

(N ∪ {∞})n.

24

slide-25
SLIDE 25

A digression on a variant of Ackermann function

  • A0(m) = 2m + 1, An+1(0) = 1.
  • An+1(m + 1) = An(An+1(m)) ( =

m+1 times

  • An(· · · (An(m)) · · · ) ).
  • A(n) = An(2).
  • The function A(n) majorizes the primitive recursive

functions.

  • The size of the coverability graph can be in O(A(n)).

(n: size of T and x0), see e.g. [Jantzen, APN’97].

25

slide-26
SLIDE 26

How to calculate with ∞?

  • For k, k′ ∈ N ∪ {∞},

k ≤ k′

def

⇔ either k, k′ ∈ N and k ≤ k′ or k′ = ∞.

  • k < k′ whenever k ≤ k′ and k = k′.
  • (N ∪ {∞}, <) is isomorphic to the ordinal ω + 1.
  • ≤ and < are extended component-wise to (N ∪ {∞})n.
  • 2

3 1

  • <
  • 2

4 1

  • → acc(
  • 2

3 1

  • ,
  • 2

4 1

  • )

def

=

  • 2

∞ 1

  • .
  • For

x < x′, let us define acc( x, x′) ∈ (N ∪ {∞})n:

  • acc(

x, x′)(i)

def

= x′(i) when x(i) = x′(i),

  • acc(

x, x′)(i)

def

= ∞ when x(i) < x′(i). “The ith component can be as large as we wish.”

26

slide-27
SLIDE 27

How to calculate with ∞? (II)

  • Given

x ∈ (N ∪ {∞})n and t ∈ Zn, let us define

  • x + t ∈ (Z ∪ {∞})n:
  • (

x + t)(i)

def

= x(i) + t(i) if x(i) ∈ N,

  • (

x + t)(i)

def

= ∞ otherwise.

(i ∈ [1, n])

  • 2

∞ 1

  • +
  • −3

−6 2

  • =
  • −1

∞ 3

  • .
  • The construction of the coverability graph CG(T ,

x0) uses these operations on N ∪ {∞}.

27

slide-28
SLIDE 28

Example

A B C (t1) +1

0 (t2)

(t3) −1

0 (t4)

0, 1, 0, 0 ≈ (A, 0) 1, 0, 1, 0 ≈ (B, 1) 0, 0, 0, 1 ∞, 1, 0, 0 0, 0, 1, 0 ∞, 0, 1, 0 ∞, 0, 0, 1 t1 t3 t2 t4 t1 t2 t2 t3 t4

28

slide-29
SLIDE 29

Properties of CG(T , x0)

  • Given T and

x0, coverability graph CG(T , x0) is a structure (V, E) with V ⊆ (N ∪ {∞})n and E ⊆ V × T × V. (a) CG(T , x0) is a finite structure with “root” x0. (K¨

  • nig’s Lemma and Dickson’s Lemma)

(b) Every configuration reachable from x0 can be covered in CG(T , x0), i.e.

  • for

y reachable from x0, there is y′ in CG(T , x0) such that

  • y

y′.

(c) For all y in CG(T , x0) and bounds B ∈ N, there is a configuration y′ reachable from x0 such that for i ∈ [1, n],

y(i) = ∞ implies y′(i) ≥ B,

y(i) = ∞ implies y′(i) = y(i).

29

slide-30
SLIDE 30

A quick presentation of the construction

E := ∅; V := ∅; ToBeTreated := { x0}; while ToBeTreated = ∅ do

  • Select an element

x from ToBeTreated;

  • ToBeTreated := ToBeTreated \ {

x};

  • for t ∈ T such that

x + t ∈ (N ∪ {∞})n do

x′ := x + t;

  • if there is

y ∈ V such that y

− → x in (V, E) and y < x′ then

  • Let

y0 be the extended configuration the closest to x in (V, E) such that y0 < x′;

x′ := acc( y0, x′);

  • if

x′ ∈ V then

  • V := V ∪ {

x′};

  • ToBeTreated := ToBeTreated ∪ {

x′};

  • E := E ∪ {

x

t

− → x′};

30

slide-31
SLIDE 31

Characterizations with coverability graph Just look at the finite graph CG(T , x0)!

  • There is

x′′ reachable from x0 such that x′ x′′ iff there is

  • y in CG(T ,

x0) such that x′ y.

  • The set of configurations reachable from

x0 is infinite iff ∞ appears in CG(T , x0).

  • Every run from

x0 terminates iff there is no cycle in CG(T , x0).

31

slide-32
SLIDE 32

Finiteness of CG(T , x0)

  • By K¨
  • nig’s Lemma, CG(T ,

x0) is infinite iff there is an infinite branch (finite-branching is due to the finite set of transitions).

  • In an infinite branch, after some node nd, no new ∞ is

inserted since the dimension n is finite.

  • So after that node nd by Dickson’s Lemma, there are

nodes nd1 and nd2 labelled by y and y′ respectively, such that y y′.

  • If

y ≺ y′, then this leads to a contradiction by construction

  • f nd.
  • If

y = y′, then this leads to a contradiction since the branch is infinite but in case y = y′, we are supposed to stop the construction.

32

slide-33
SLIDE 33

Covering

There is x′′ reachable from x0 such that x′ x′′ iff there is

  • y in CG(T ,

x0) s.t. x′ y.

  • Suppose that

x′′ reachable from x0 and x′ x′′.

  • By (b), there is

y in CG(T , x0) s.t. x′′ y.

  • Since is transitive on (N ∪ {∞})n,

x′ y.

( x′ x′′ and x′′ y imply x′ y)

  • Suppose that there is

y in CG(T , x0) such that x′ y.

  • B: maximal value occurring in

x′.

  • By (c), there is

y′ reachable from x0 such that for i ∈ [1, n], if y(i) = ∞ then y′(i) ≥ B otherwise y′(i) = y(i).

  • Hence,

x′ y′.

33

slide-34
SLIDE 34

Boundedness

The set of configurations reachable from x0 is infinite iff ∞ appears in CG(T , x0).

  • Suppose the set of configurations reachable from

x0 is infinite.

  • Ad absurdum, assume that ∞ does not occur in CG(T ,

x0).

  • By (b), there is

y in CG(T , x0) s.t. for an infinite amount of configurations x reachable from x0, we have x y.

  • There are at most (1 + max(

y))n distinct configurations smaller than y ∈ Nn, contradiction.

  • Suppose ∞ occurs in CG(T ,

x0).

  • By (c) the set of configurations reachable from

x0 is infinite.

  • For instance, consider bounds B greater and greater when

applying (c).

34

slide-35
SLIDE 35

Exponential-space decision procedure

35

slide-36
SLIDE 36

Small covering property

  • VAS T with configurations

x, x′. Equivalence between

  • there is a run from

x leading to y such that x′ y,

  • there is a run from

x leading to y′ such that x′ y′ and its length is at most double-exponential in the size of the instance T , x and x′ (numbers in binary).

  • A run of double-exponential length requires

double-exponential space to be fully encoded.

  • In the worst-case, there is a triple-exponential amount of

such runs.

  • Solution: guess nondeterministically the small run and

invoke Savitch’s theorem.

36

slide-37
SLIDE 37

Example of small covering

A B C [t1]

„ 1 « „ « [t2]

[t3]

„ 1 −1 « „ « [t4]

How to cover (A, (1, K)) from (A, (0, 0))?

Long covering: (A, (0, 0))

(t1t2)2K t1

− − − − → (B, (0, 2K + 1))

t3t4t2

− − → (A, (1, 2K )) (A, (1, K)) Short covering: (A, (0, 0))

(t1t2)K t1

− − − − → (B, (0, K + 1))

t3t4t2

− − → (A, (1, K)) (A, (1, K))

(t1t2)K t1t3t4t2 subword of (t1t2)2K t1t3t4t2

37

slide-38
SLIDE 38

How to be clever enough to guarantee a “short” covering?

38

slide-39
SLIDE 39

A nondeterministic algorithm with lenght L

  • Algorithm for T ,

x, x′ and L:

1 i := 0;

xc := x (current configuration);

2 While

x′ xc and i < L do

1

Guess a transition t ∈ T ; (nondeterministic step !)

2

If xc + t ∈ Nn then abort;

3

i := i + 1; xc := xc + t.

3 If

x′ xc then accept else abort (i = L).

  • If the maximal absolute value in T ,

x, x′ is 2N and L = 22N3 , then the maximal absolute value appearing in the algorithm is 2N + 2N × 22N3 (can be encoded with exponential space in N).

  • Determinism can be regained with recursive calls to a

function F(T , x, x′, L) since the number of transitions is finite.

39

slide-40
SLIDE 40

When small covering property implies EXPSPACE

Design a decision procedure that nondeterministically guesses the small run and only requires exponential space:

  • A counter with an exponential amount of bits can count

until a double-exponential value.

  • Only two configurations need to be store thanks to

nondeterminism.

  • 22N3

× 2N is still of double-exponential magnitude.

  • Comparing or adding two natural numbers requires

logarithmic space only.

  • [Savitch, JCSS 70]: a nondeterministic procedure for a

given problem using space f(N) ≥ log(N) can be turned into a deterministic procedure using f(N) × f(N) space.

  • Exponential functions are closed under multiplication.

40

slide-41
SLIDE 41

Remarks before the EXPSPACE proof

  • The EXPSPACE proof for the covering problem is based on

an induction on the dimension.

  • The proof for EXPSPACE upper bound for boundedness is

a bit more complex [Rackoff, TCS 78].

  • EXPSPACE-hardness proof for covering, boundedness and

reachability problems is presented later. It is based on [Lipton, TR 76; Esparza, 98].

  • The proof for decidability of reachability problem is much

more complex:

  • The book [Reutenauer, 1990] presents the full proof.
  • Nice hints about the proof can be found in [Haddad, 01].
  • A simpler proof has been found by J. Leroux.

[Leroux, LICS’09; Leroux POPL ’11]

41

slide-42
SLIDE 42

Special PAVAS event January 20th, 2011, Cachan

  • MPRI students are welcome to attend the special PAVAS

event.

  • This special event focuses on two recent major

claims/results:

1 a new proof, by a P

. Janˇ car, for the decidability of equivalence for deterministic pushdown automata, first established by G. S´ enizergues, and

2 a new proof, by J. Leroux, for the decidability of accessibility

in vector addition systems, or equivalently in Petri nets, first established by E. Mayr (and S. R. Kosaraju).

  • Registration on

http://www.lsv.ens-cachan.fr/Events/Pavas/ See also Course 2.9 web page.

42

slide-43
SLIDE 43

Definitions about sizes

  • For

x ∈ Zn,

  • maxneg(

x)

def

= max({max(0, − x(i)) : i ∈ [1, n]}): maximal absolute negative value.

  • For example, maxneg(
  • −1

−2 −8 7

  • ) = max(0, −(−8)) = 8.
  • max(

x)

def

= max({ x(i) : i ∈ [1, n]}): maximal value.

  • For instance, max(
  • −1

−2 −8 7

  • ) = 7.
  • scale(T )

def

= max({|t(i)| : t ∈ T , i ∈ [1, n]}): maximal absolute value.

  • For instance, scale(
  • −1

−2 −8 7

  • ) = | − 8| = 8.
  • Note that maxneg(T ) ≤ scale(T ).

43

slide-44
SLIDE 44

Definitions about sizes (II) (or reasonably succinct encodings)

  • 2 + ⌈log2(1 + K)⌉ is a sufficient number of bits to encode

integers in [−K, K] for K > 0.

  • Size |T |

def

= n × card(T ) × (2 + ⌈log2(1 + scale(T ))⌉).

  • If N = |T | + |{

x}| + |{ x′}|, then maxneg(T ), card(T ), max( x′), max( x) ≤ 2N

44

slide-45
SLIDE 45

Paths and pseudo-runs

  • Path π: finite sequence of transitions (below in blue).

B B @ 1 1 C C A

B B B @

−1 1 1

1 C C C A

− − − − − − → B B @ 1 1 1 C C A

B B B @

1 −1

1 C C C A

− − − − − − → B B @ 1 1 1 C C A

B B B @

−1 1 1

1 C C C A

− − − − − − → B B @ 1 2 1 C C A

B B B @

1 −1

1 C C C A

− − − − − − → B B @ 1 2 1 C C A

  • π′ is a subpath of π = t1 . . . tk

def

⇔ there are 1 ≤ j1 < j2 · · · < jk′ ≤ k s.t. π′ = tj1 . . . tjk′.

  • Pseudo-configuration

x ∈ Zn (a configuration is in Nn).

  • Given π = t1 . . . tk and

x ∈ Zn, pseudo-run (π, x) = x0 · · · xk s.t. x0 = x and for i ∈ [1, k], xi = xi−1 + ti.

  • The length of (π,

x) [resp. π] is k + 1 [resp. k].

  • A pseudo-run

x0 · · · xk is a covering of x′ when x′ xk.

45

slide-46
SLIDE 46

Defining length of shortest coverings

  • Assume that (π,

x) is a run covering x′, m(T , x, x′, π)

def

= the length of the shortest subpath π′ of π such that (π′, x) is a run covering x′.

  • m(T ,

x, x′, π) ≤ length of π.

  • MB(n) (B, n ≥ 1): be the supremum of the set below
  • m(T ,

y, y′, π) : (π, y) is a run covering y′ T is a VAS of dimension n and maxneg(T ) + max( y′) ≤ B

  • 46
slide-47
SLIDE 47

Upper bound for MB(n)

  • Let us show that MB(n) ≤ gB(n) for all n, B ≥ 1 with

gB(n) =

  • B

if n = 1,

  • B · gB(n − 1)

n + gB(n − 1) if n ≥ 2.

  • For n ≥ 1 and B ≥ 2, gB(n) ≤ B3n! (gB(1) = B):

gB(n) ≤

  • B·gB(n−1)

n+gB(n−1) ≤

  • B·gB(n−1)

n+1 ≤ . . . . . . ≤

  • B1+(3(n−1))!n+1 ≤ B(3n)!

47

slide-48
SLIDE 48

Towards the rough bound 22N3

  • Existence of a covering of

x′ from x in T is equivalent to the existence of a covering of length at most α = (maxneg(T ) + max( x′) + 2)(3n)!

  • With N = |T | + |{

x}| + |{ x′}|, α ≤ (2N + 2N + 2)2N log2(N) ≤ (2N+2)2N2 ≤ 22N3 .

  • The covering problem for VAS, VASS (and Petri nets) can

be solved in exponential space.

48

slide-49
SLIDE 49

Back to inequalities (main proof)

  • We show for n, B ≥ 1:

MB(n) ≤

  • B = gB(1)

if n = 1,

  • B · gB(n − 1)

n + gB(n − 1) if n ≥ 2.

  • Base case n = 1.
  • T of dim. 1,

x, x′ ∈ N and maxneg(T ) + max( x′) ≤ B.

x′ x implies empty path produces a run covering x′.

  • Otherwise, no need to use negative values from T and

m(T , x, x′, π) is bounded by max( x′).

  • MB(1) ≤ B since max(

x′) ≤ B.

49

slide-50
SLIDE 50

Induction step

  • Suppose the property holds true for n − 1 ≥ 1.
  • It is sufficient to show:

m(T , x, x′, π) ≤

= gB(n−1)

  • B · gB(n − 1)

n + gB(n − 1) whenever maxneg(T ) + max( x′) ≤ B and T of dimension n.

  • After gB(n − 1) steps, a component greater than

gB(n − 1) maxneg(T ) + max( x′), has value at least max( x′). (useful when using induction hypothesis)

  • B′ = gB(n − 1)maxneg(T ) + max(

x′) ≤ B gB(n − 1).

  • Pseudo-run

x0 · · · xk is r-bounded (r > 0)

def

⇔ for i ∈ [0, k], we have xi ∈ [0, r − 1]n.

50

slide-51
SLIDE 51

Two cases are distinguished

  • (π,

x): run covering x′ for the VAS T .

  • π = t1 · · · tK , (π,

x) = x0 · · · xK and x′ xK .

  • We distinguish the case when (π,

x) is B′-bounded or not.

  • If (π,

x) is B′-bounded, then subpaths between identical configurations can be removed (pigeonhole principle).

  • Otherwise, the path is divided in two:
  • the first part is B′-bounded and can be shortened,
  • shortening the second part can be done by using induction

hypothesis. 51

slide-52
SLIDE 52

Case 1: (π, x) is B′-bounded

  • In the run

x0 · · · xK , each xl ∈ [0, B′ − 1]n.

  • Subruns between two identical configurations can be

eliminated: if xi = xj with 0 ≤ i < j ≤ K then

  • (π′,

x) is also a run covering of x′,

  • π′ = t1 · · · titj+1 · · · tK ,
  • π′ is a strict subpath of π.
  • This situation occurs as soon as K ≥ (B′)n.
  • This transformation can be repeated until K < (B′)n.

(pigeonhole principle)

  • Conclusion: there is a subpath π′ s.t. (π′,

x) is also a run covering x′ of length bounded by (B′)n ≤ (B gB(n − 1))n.

52

slide-53
SLIDE 53

Case 2: (π, x) is not B′-bounded

  • Unique decomposition π = π1π2 s.t.
  • π1 is of length k1,
  • all values in

x0 · · · xk1−1 are < B′.

  • (π1,

x) is not B′-bounded (“faulty” configuration xk1).

  • x0

t1

− → · · ·

tk1−1

− − →

  • xk1−1
  • B′−bounded

tk1

− → xk1 ∈ [0, B′ − 1]n tk1+1 − − →

  • xk1+1 · · ·

tK

− → xK π1 = t1 · · · tk1 π2 = tk1+1 · · · tK

  • There is π′

1, subpath of π1, such that

  • its length is bounded by (B gB(n − 1))n + 1,

(again pigeonhole principle!)

  • (π1,

x) and (π′

1,

x) have the same final configuration xk1.

  • (π′

1π2,

x) and (π2, xk1) are both runs covering x′.

53

slide-54
SLIDE 54

Case 2: (π, x) is not B′-bounded (II)

  • Let i ∈ [1, n] such that

xk1(i) ≥ B′.

  • xk1 =

    . . . · ≥ B′ . . .    

tk1+1

− − → · · ·

tK

− → xK =     . . . · . . .     x′

  • T −, π−

2 ,

xk1

−,

x′−: restrictions of T , π2, xk1, x′ to the components in [1, n] \ {i}.

  • xk1

− =

  . . . . . .  

t−

k1+1

− − → · · ·

t−

K

− → xK =   . . . . . .   x′−

  • (t−

k1+1 · · · t− K ,

xk1

−) is a run covering

x′− in T −.

  • maxneg(T −)+max(

x′−) ≤ B and T − is of dimension n −1.

  • m(T −,

xk1

−,

x′−, t−

k1+1 · · · t− K ) ≤ MB(n − 1).

54

slide-55
SLIDE 55

Case 2: (π, x) is not B′-bounded (III)

  • By induction hypothesis, there is π′

2, subpath of

t−

k1+1 · · · t− K such that

  • (π′

2,

xk1

−) is a run covering

x′−,

  • its length is bounded by MB(n − 1) ≤ gB(n − 1).
  • xk1

− =

  . . . . . .   t′

1

− → · · ·

t′

K′

− →

  • x′

k1+K ′ =

  . . . . . .   x′−

  • K ′≤gB(n−1)
  • Path π′′

2 obtained from π′ 2 by adding component i.

  • (π′′

2,

xk1) is a pseudo-run with final pseudo-configuration z such that for j ∈ ([1, n] \ {i}), z(j) ≥ x′(j).

  • Since

xk1(i) ≥ B′ = gB(n − 1)maxneg(T ) + max( x′), after gB(n − 1) steps, the ith component is greater or equal to max( x′) and the ith component is never negative.

55

slide-56
SLIDE 56

Conclusion

  • (π′′

2,

xk1) is a run covering x′.

  • Length of π′

1π′′ 2 is at most (B × gB(n − 1))n + gB(n − 1).

  • π′

1π′′ 2 is a subpath of π.

56

slide-57
SLIDE 57

Other properties in EXPSPACE

  • Termination problem.
  • Boundedness problem.
  • LTL model-checking problem for VASS is

EXPSPACE-complete [Habermehl, ICATPN 97].

  • Given (T ,

x) and i ∈ [1, n], checking whether { y(i) : x

− → y} is finite.

  • Generalization:

∃ x1, . . . , xn, π1, . . . , πn x0

π1

− → x1

π2

− → x2 · · · πn − → xn ∧C( x1, . . . , xn)∧ x1 xn

  • Satisfiability problem is in EXPSPACE.

[Atig & Habermehl, RP’09]

57

slide-58
SLIDE 58

Concluding remarks

  • Today’s lecture:
  • Coverability graphs.
  • Covering problem for VAS in EXPSPACE by induction on the

dimension (Rackoff’s proof).

  • Other properties in EXPSPACE.
  • Next lecture: EXPSPACE-hardness of covering problem for

VAS and basic definitions on reversal-bounded counter automata.

58

slide-59
SLIDE 59

Exercises

59

slide-60
SLIDE 60
  • Exo. 1
  • By the characterization of unboundedness from CG(T ,

x0), (T , x0) is unbounded iff there is x0

− → y

− → y′ with y ≺ y′.

  • Assuming that T has dimension n, (T ,

x0) is i-unbounded

def

⇔ { y(i) : x0

− → y} is infinite.

  • (T ,

x0) is unbounded iff there is i ∈ [1, n] such that (T , x0) is i-unbounded.

  • Are the propositions below equivalent?

1 (T ,

x0) is i-unbounded.

2 There is a run of the form

x0

− → y

− → y′ with y ≺ y′ and

  • y(i) <

y′(i).

60

slide-61
SLIDE 61

Exos 2–4

  • 2. Show that the covering problem restricted to VAS of

dimension 1 can be solved in linear time.

  • 3. Show that the reachability [resp. covering, boundedness]

problem for VASS can be reduced to the same problem for VASS without self-loops.

  • 4. Show that the covering problem for VAS augmented the

multiplication by 2 can be solved in exponential space.

61

slide-62
SLIDE 62

VASS weakly computing multiplication

A B

B B @ −1 1 C C A B B @ 1 C C A B B @ 1 −1 1 1 C C A B B @ −1 1 1 C C A

  • 1. Compute

{

  • a

b c d

  • ∈ N4 : (A,
  • 2

1

  • ) ∗

− → (A,

  • a

b c d

  • )}
  • 2. Show that

{ @ a b d 1 A ∈ N3 : d ≤ a × b} = { @ a b d 1 A ∈ N3 : ∃ @ a′ b′ c′ 1 A ∈ N3, (A, B B @ a b 1 C C A) ∗ − → (A, B B @ a′ b′ c′ d 1 C C A)}

62

slide-63
SLIDE 63

A B

B B @ −1 1 C C A B B @ 1 C C A B B @ 1 −1 1 1 C C A B B @ −1 1 1 C C A

  • 3. Is there
  • a

b c d

  • ∈ N4 such that

{

  • a′

b′ c′ d′

  • ∈ N4 : (A,
  • a

b c d

  • ) ∗

− → (A,

  • a′

b′ c′ d′

  • )}

is infinite?

63

slide-64
SLIDE 64

C A B Compute the map f such that

{ @ a b e 1 A ∈ N3 : e ≤ f(a, b)} = { @ a b e 1 A ∈ N3 : ∃ B B @ a′ b′ c′ d′ 1 C C A ∈ N4, (C, B B B @ a b 1 C C C A) ∗ − → (A, B B B B @ a′ b′ c′ d′ e 1 C C C C A )}

[t5]

B B B @ −1 1 1 1 C C C A B B B @ 1 C C C A [t6] B B B @ −1 1 C C C A [t2]

[t3]

B B B @ 1 C C C A B B B @ 1 −1 1 1 C C C A [t4]

[t1]

B B B @ −1 1 1 C C C A

64