PNML Analyzer ReachabilityCoverability Analysis of Petri Nets from
PNML Analyzer Reachability/Coverability Analysis of Petri Nets from PNML files Roger Ruiz-Carrillo
Presentation Contents • • PNML Program structure Algorithm for reachability/coverability graph Tests and Comparison with PIPE[1]’s output [1] PIPE, Platform Independent Petri net Editor, software project from Department of Computing, Imperial College London. http: //pipe 2. sourceforge. net/ (valid in April 2012)
PNML • • Petri Net Markup Language XML based PNML. org No current XSD
Program Structure – Petri Net Petri. Net petrinetid places transitions arcs get. Markings() set. Markings(tuple) 0. . 1 Arc Transition transitionid incoming. Arcs outgoing. Arcs is. Enabled() fire() 1 arcid weight direction place source target 0. . 1 Place placeid 1 tokens incoming. Arcs outgoing. Arcs
Program Structure • PNMLLoader: Unmarshals the petri net from the XML into Petri. Net, Place, Arc and Transition objects • Reachability. Analyzer: Creates the reachability/coverability graph and produces the Graph. Viz output file and XML graph representation.
Algorithm (created from [TM 89]) build root. Node from initial marking Add root. Node to nodes. To. Process While there are nodes in nodes. To. Process: node = first node in nodes. To. Process; remove node from nodes. To. Process for each enabled transition in the net with node’s marking: fire the transition and assign the resulting marking to new. Marking for inspected. Node in node and all its parents: if(new. Marking dominates inspected. Node’s marking) update new. Marking with infinity in the proper places if no node with new. Marking already exists: create a new. Node with the new. Marking, assign node as its parent append new. Node to nodes. To. Process else new. Node = existing node append new. Node to node’s children along with the enabled transition [TM 89] Tadao Murata, “Petri Nets: Properties, Analysis and Applications”, in Proceedings of the IEEE, vol. 77, no. 4, April 1989
Tests – Simple Petri Net
Tests – Simple Petri Net: PIPE
Tests – Simple Petri Net: PNML Analyzer
Tests – Dining Philosophers (PIPE example)
Tests – Dining Philosophers (PIPE example) - PIPE
Tests – Dining Philosophers (PIPE example) – PNML Analyzer
Tests – Dining Philosophers (PNML. org example)
Tests – Dining Philosphers (PNML. org example) – PNML Analyzer
- Slides: 14