Merged Processes of Petri nets Victor Khomenko Joint work with Alex Kondratyev, Maciej Koutny and Walter Vogler.

Slides:



Advertisements
Similar presentations
Model Checking Base on Interoplation
Advertisements

Vasileios Germanos 1, Stefan Haar 2, Victor Khomenko 1, and Stefan Schwoon 2 1 School of Computing Science, Newcastle University, UK 2 INRIA & LSV (ENS.
Shortest Violation Traces in Model Checking Based on Petri Net Unfoldings and SAT Victor Khomenko University of Newcastle upon Tyne Supported by IST project.
A* Search. 2 Tree search algorithms Basic idea: Exploration of state space by generating successors of already-explored states (a.k.a.~expanding states).
Techniques to analyze workflows (design-time)
Representing Boolean Functions for Symbolic Model Checking Supratik Chakraborty IIT Bombay.
Hardware and Petri nets Symbolic methods for analysis and verification.
A university for the world real R © 2009, Chapter 3 Advanced Synchronization Moe Wynn Wil van der Aalst Arthur ter Hofstede.
Automatic Verification Book: Chapter 6. What is verification? Traditionally, verification means proof of correctness automatic: model checking deductive:
Based on: Petri Nets and Industrial Applications: A Tutorial
Artificial Intelligence Constraint satisfaction problems Fall 2008 professor: Luigi Ceccaroni.
PROTOCOL VERIFICATION & PROTOCOL VALIDATION. Protocol Verification Communication Protocols should be checked for correctness, robustness and performance,
Applying Petri Net Unfoldings for Verification of Mobile Systems Apostolos Niaouris Joint work with V. Khomenko, M. Koutny MOCA ‘06.
Counting the bits Analysis of Algorithms Will it run on a larger problem? When will it fail?
26 September 2003U. Buy -- SEES 2003 Sidestepping verification complexity with supervisory control Ugo Buy Department of Computer Science Houshang Darabi.
A Novel Method For Fast Model Checking Project Report.
The Theory of NP-Completeness
IE 469 Manufacturing Systems
The number of edge-disjoint transitive triples in a tournament.
Kurt Jensen Lars M. Kristensen 1 Coloured Petri Nets Department of Computer Science Coloured Petri Nets Modelling and Validation of Concurrent Systems.
Complexity 12-1 Complexity Andrei Bulatov Non-Deterministic Space.
Logic Synthesis for Asynchronous Circuits Based on Petri Net Unfoldings and Incremental SAT Victor Khomenko, Maciej Koutny, and Alex Yakovlev University.
A Schedulability-Preserving Transformation of BDF to Petri Nets Cong Liu EECS 290n Class Project December 10, 2004.
Hardware and Petri nets Partial order methods for analysis and verification of asynchronous circuits.
The Theory of NP-Completeness
Validating Streaming XML Documents Luc Segoufin & Victor Vianu Presented by Harel Paz.
Resolution of Encoding Conflicts by Signal Insertion and Concurrency Reduction based on STG Unfoldings V. Khomenko, A. Madalinski and A. Yakovlev University.
Behaviour-Preserving Transition Insertions in Unfolding Prefixes
1 Petri Nets Marco Sgroi EE249 - Fall 2001 Most slides borrowed from Luciano Lavagno’s lecture ee249 (1998)
2-Layer Crossing Minimisation Johan van Rooij. Overview Problem definitions NP-Hardness proof Heuristics & Performance Practical Computation One layer:
Branching Processes of High-Level Petri Nets Victor Khomenko and Maciej Koutny University of Newcastle upon Tyne.
Parallel LTL-X Model Checking of High- Level Petri Nets Based on Unfoldings Claus Schröter* and Victor Khomenko** *University of Stuttgart, Germany **University.
Circuits CSE 373 Data Structures Lecture 22. 3/12/03Circuits - Lecture 222 Readings Reading ›Sections and 9.7.
Chapter 11: Limitations of Algorithmic Power
Branching Processes of High-Level Petri Nets and Model Checking of Mobile Systems Maciej Koutny School of Computing Science Newcastle University with:
Canonical Prefixes of Petri Net Unfoldings Walter Vogler Universität Augsburg in cooperation with V. Khomenko, M. Koutny (CAV 2002, Acta Informatica 2003)
A New Type of Behaviour- Preserving Transition Insertions in Unfolding Prefixes Victor Khomenko.
Detecting State Coding Conflicts in STGs Using SAT Victor Khomenko, Maciej Koutny, and Alex Yakovlev University of Newcastle upon Tyne.
*Department of Computing Science University of Newcastle upon Tyne **Institut für Informatik, Universität Augsburg Canonical Prefixes of Petri Net Unfoldings.
Merged processes – a new condensed representation of Petri net behaviour V.Khomenko 1, A.Kondratyev 2, M.Koutny 1 and W.Vogler 3 1 University of Newcastle.
CPSC 411, Fall 2008: Set 4 1 CPSC 411 Design and Analysis of Algorithms Set 4: Greedy Algorithms Prof. Jennifer Welch Fall 2008.
HELSINKI UNIVERSITY OF TECHNOLOGY *Laboratory for Theoretical Computer Science Helsinki University of Technology **Department of Computing Science University.
Regular Model Checking Ahmed Bouajjani,Benget Jonsson, Marcus Nillson and Tayssir Touili Moran Ben Tulila
Linear and Branching Time Safety, Liveness, and Fairness
The Theory of NP-Completeness 1. Nondeterministic algorithms A nondeterminstic algorithm consists of phase 1: guessing phase 2: checking If the checking.
Fixed Parameter Complexity Algorithms and Networks.
1 The Theory of NP-Completeness 2012/11/6 P: the class of problems which can be solved by a deterministic polynomial algorithm. NP : the class of decision.
Theory of Computing Lecture 17 MAS 714 Hartmut Klauck.
1 The Theory of NP-Completeness 2 Cook ’ s Theorem (1971) Prof. Cook Toronto U. Receiving Turing Award (1982) Discussing difficult problems: worst case.
Unit 9: Coping with NP-Completeness
NP-Complete Problems. Running Time v.s. Input Size Concern with problems whose complexity may be described by exponential functions. Tractable problems.
NP-COMPLETE PROBLEMS. Admin  Two more assignments…  No office hours on tomorrow.
Modelling by Petri nets
NP-Complete problems.
Behavioral Comparison of Process Models Based on Canonically Reduced Event Structures Paolo Baldan Marlon Dumas Luciano García Abel Armas.
Bounded Model Checking A. Biere, A. Cimatti, E. Clarke, Y. Zhu, Symbolic Model Checking without BDDs, TACAS’99 Presented by Daniel Choi Provable Software.
Instructor: Dr. GautamDas February 24, 2009 Class notes by Ranganath M R.
1 The Theory of NP-Completeness 2 Review: Finding lower bound by problem transformation Problem X reduces to problem Y (X  Y ) iff X can be solved by.
Complexity of Compositional Model Checking of Computation Tree Logic on Simple Structures Krishnendu Chatterjee Pallab Dasgupta P.P. Chakrabarti IWDC 2004,
Structural methods for synthesis of large specifications
Symbolic model checking with SAT/SMT
Inference and search for the propositional satisfiability problem
Coloured Petri Nets Modelling and Validation of Concurrent Systems
Concurrent Systems Modeling using Petri Nets – Part II
Approximation and Kernelization for Chordal Vertex Deletion
Introduction to Petri Nets (PNs)
Victor Khomenko and Andrey Mokhov
Petri Net :Abstract formal model of information flow Major use:
Chapter 14 Graphs © 2011 Pearson Addison-Wesley. All rights reserved.
Switching Lemmas and Proof Complexity
Presentation transcript:

Merged Processes of Petri nets Victor Khomenko Joint work with Alex Kondratyev, Maciej Koutny and Walter Vogler

2 Petri net unfoldings An acyclic net obtained through unfolding the PN by successive firings of transitions:  for each new firing a fresh transition (called an event) is generated  for each newly produced token a fresh place (called a condition) is generated The full unfolding can be infinite If the PN has finitely many reachable states then the unfolding eventually starts to repeat itself and can be truncated (by identifying a set of cut-off events) without loss of essential information, yielding a finite prefix

3 T1T1 P1P1 T2T2 T3T3 P2P2 P3P3 P4P4 P5P5 T4T4 P6P6 T5T5 P1P1 P7P7 P8P8 P7P7 P8P8 P9P9 T6T6 T7T7 P 10 P 11 T8T8 P 13 P 12 T9T9 P 14 T 10 P9P9 P7P7 P8P8 T1T1 P3P3 T3T3 P5P5 P2P2 T2T2 P1P1 T5T5 P6P6 T4T4 P4P4 P7P7 P8P8 P9P9 P 11 P 10 P 13 P 14 P 12 T9T9 T7T7 T 10 T6T6 T8T8 Example: Dining Philosophers

4 Alleviate the state space explosion problem for highly concurrent systems  e.g. for Dining Philosophers the prefix size is linear in the number of philosophers even though the number of states is exponential Efficient model checking algorithms  e.g. deadlock checking is PSPACE- complete for safe PNs but only NP- complete for prefixes  Do not cope well with other than concurrency sources of state space explosion, e.g. with sequence of choices  Do not cope well with non-safe PNs Characteristics of unfoldings

5 Example: sequence of choices No event is cut-off, the prefix is exponential

6 mm Example: non-safe PN Tokens in the same place are distinguished in the unfolding, the prefix is exponential

7 Wanted A data structure coping not only with concurrency but also with other sources of state space explosion

8 Occurrence-depth Merged Process: Fuse conditions with the same label and occurrence-depth Delete duplicate events

Example: a Petri net

10 Example: unfolding Step 1: Fuse conditions of the nodes with the same label and occurrence-depth

11 Example: (cont’d) Step 2: Delete event replicas

12 Examples MPs of these nets coincide with the original nets, even though unfoldings are exponential! mm

13 Properties of MPs Canonicity Finiteness Completeness Theoretical upper bounds on size Experimental results: size

14 Canonicity Easily follows from the canonicity of unfolding prefixes: Canonical MP = Merge(Canonical prefix)

15 Finiteness Proposition: Merge(Pref) is finite iff Pref is finite  trivial, as Merge(Pref) is no larger than the prefix  more difficult, as the Merge operation can collapse infinitely many nodes into one: …

16 Finiteness (cont’d)  follows from the analog of Köning’s lemma for branching processes:  an infinite branching process contains an infinite causal chain  hence there are infinitely many instances of some place p along it  hence the occurrence-depth of instances of p is unbounded  hence there are infinitely many instances of p in the merged process

17 Completeness Preservation of firings is tricky – it’s hard to define cut-offs since an event can have multiple local configurations Hence consider only marking- completeness (good enough for model checking as the firings can be retrieved from the original PN) Proposition: if Pref is marking-complete then Merge(Pref) is marking-complete

18 Theoretical upper bounds on size Trivial bound: Merge(Pref) is never larger than Pref, hence never larger than the reachability graph  too pessimistic in practice MPs of acyclic PN coincide with the original PNs with the dead nodes removed  unfoldings can be exponential MPs of live and safe free-choice PNs [with minor restrictions] are polynomial in the size of the original PNs  unfoldings can be exponential

19 Experimental results: size

20 Experimental results: PN/MP size

21 Experimental results: summary Corbett’s benchmarks were used MPs are often by orders of magnitude smaller than unfolding prefixes In many cases MPs are just slightly larger than the original PNs In some cases MPs are smaller than the original PNs due to removal of dead nodes

22 Model checking MPs are small, but are they of any use in practice? Can model checking algorithms developed for unfoldings be lifted to MPs? In what follows, we consider safe PNs only

23 Problem: cycles A Petri net

24 Problem: cycles Unfolding Criss-cross fusion results in a cycle!

25 MP with a cycle Problem: cycles Still worse, the marking equation (ME) used for unfolding-based verification can have spurious solutions

26 Problem: cycles Borrow a token Fire The borrowed token is returned The current marking is unreachable

27 Solution Add to the marking equation another constraint, ACYCLIC, requiring the run to be acyclic: ME & ACYCLIC

28 Example: an acyclic run

29 Example: a run with a cycle

30 SAT encoding Associate a Boolean variable v to each node v of MP indicating whether it belongs to the run View the run as a digraph induced in the MP by the variables whose value is true Sort the nodes of the merged process so that the number of feedback vertices is (heuristically) minimised

31 SAT encoding (cont’d) For each feedback vertex:  ignore the vertices on its left  generate the formula conveying that the sources of the feedback arcs are not reachable from this feedback vertex: Formula size: O(|V f |·|E|); can we do better? v

32 Another problem: spurious runs 1 2 Can visit this condition without first visiting the other one! not possible in the unfolding

33 Solution Add another constraint, NG (no-gap), conveying that  if a condition with occurrence-depth k>1 is visited then the condition with the same label and occurrence-depth k-1 is also visited  the conditions with the same label are visited in the order of increase of the occurrence depth (can be enforced by ACYCLIC by adding a few arcs)

34 Solution (cont’d)

35 Model checking ME & ACYCLIC & NG & VIOL This is enough to lift unfolding-based model checking algorithms to merged processes! Deadlock checking (and many other reachability-like problems) is NP-complete in the size of the MP – no worse than for unfoldings

36 Experimental results: MC time 

37 Experimental results Corbett’s benchmarks were used Model checking is practical – running times are comparable with those of an unfolding-based algorithm Still deteriorates on a couple of benchmarks – but it’s early days of this approach and we keep improving it

38 Open problems / future work Direct characterization of MPs (cf. the characterization of unfoldings by occurrence nets)  currently much is done via unfoldings Improve the efficiency of model checking  the SAT encoding of ACYCLIC is the main problem A direct algorithm for building MPs  currently built by fusing nodes in the unfolding prefix

39 Algorithm for building MPs Idea: reduce the problem of finding a possible extension to the following problem: Find a configuration C in the built part of the MP such that:  C can be extended by a new event and  C contains no cut-offs, i.e. for each event e in C there is no configuration C’ in the built part of MP such that Mark([e] C )=Mark(C’) and C’  [e] C Reducible to QBF with 1(?) alternation Reducible to SAT if the adequate order is 