- Text
- Reachability,
- Nets,
- Transitions,
- Markings,
- Petri,
- Marking,
- Hierarchical,
- Analysis,
- Regions,
- Transition,
- Graph

Hierarchical Reachability Graph Generation for Petri Nets

286 BUCHHOLZ AND KEMPERDefinition 2. A vector x ∈ Z n x ≠ 0 is a P-invariant, if xC = 0. APN is covered bypositive P-invariants, if **for** each place p ∈ P, aP-invariant x ≥ 0 with x(p) > 0 exists.A vector y ∈ Z m y ≠ 0 is a T -invariant, if Cy T = 0. APN is covered by positive T -invariants, if **for** each transition t ∈ T a T -invariant y ≥ 0 with y(t) > 0 exists.An algorithm **for** computation of invariants is given in [35]. Although its time complexityis exponential **for** a worst case, invariant computation is usually much easier than generationof RS and RG. Invariants ensure certain properties, but they do not completely characterizeRS. The following theorem summarizes some classical results.Theorem 1. For a PN with a set of P-invariants X and a set of T-invariants Y, thefollowing results hold.• If marking M ′ is reachable from marking M, then an integer vector z exists such thatM ′ = M + Cz T . This implies that **for** every M ∈ RS(PN) an integer vector z M withM = M 0 + C(z M ) T exists.• If x, x ′ ∈ X and c, c ′ ∈ Z then c · x + c ′ · x ′ ∈ X. Analogously **for** Y.• For each reachable marking M the relation Mx T = M 0 x T has to hold **for** all x ∈ X.• If PN is covered by positive P-invariants, then it is bounded.• If PN is bounded and live, then it is covered by positive T-invariants.Proof:Proofs can be found in standard books on PNs.Although invariants offer some insight on the dynamic behavior of the modeled system,they are not usually able to provide the required results. Thus, RS and RG have to begenerated **for** a detailed analysis. Usually RS is generated first, and the arcs of RG arecomputed in a second step. The following algorithm computes RS **for** a PN. It terminatesif RS contains a finite number of markings. 1generate RS (PN)RS = U ={M 0 };while (U ≠ ∅)doremove M from U;**for** all t ∈ M[> dogenerate M ′ with M[t> M ′ ;if (M ′ ∉ RS) thenU = U ∪ M ′ ;RS = RS ∪ M ′ ;fiododendSet U contains markings **for** which successors have not been generated, whereas RScontains all generated markings. For U a simple data structure like a queue or stack issufficient, since elements only need to be added and removed. For RS a data structure

HIERARCHICAL REACHABILITY GRAPH GENERATION FOR PETRI NETS 287allowing an efficient membership test is necessary. Consequently, RS can be realized usingan appropriate hash function or a tree-like structure that allows a membership test with anef**for**t logarithmic in the number of elements. The problem with hashing is the possibilityof collisions. Hence, many software tools use binary trees **for** the generation of RS.We briefly analyze the ef**for**t required **for** the generation of RG when a binary tree is usedto store RS. Let n be the number of markings in RS and let n · d be the number of arcsin RG. Hence, the mean number of successors per marking is d. The time required **for** thegeneration of RS is on the order of d ∑ ni=1 log 2 (i) = d · log 2 (n!), which is approximatelyd · n · log 2 (n). Additionally, memory limitations have to be taken into account. Even if moresophisticated data structures are used **for** RS, the number of markings that can be generatedon a standard workstation lies between 500, 000 and 1, 500, 000. For PNs that include alarge number of places, the value can be much smaller. 2 After RS has been generated, thearcs in RG are generated in a second step. RG can be represented by an n × n adjacencymatrix Q. If transition identities are relevant, Q has to contain the required in**for**mation;however, **for** reachability analysis, a Boolean entry whose truth value indicates existence ornon-existence of a transition is sufficient.3. How to obtain a hierarchical net—outline of argumentationBe**for**e we go into the details of generating a hierarchical net description, our goals shouldbe clarified. We consider a problem of exponential complexity (state-space explosion).For this kind of problem, a divide and conquer strategy has been successfully employed,and our approach follows this tradition. The goal is to find a hierarchical structure, i.e., ahigh-level net HN and a set of low-level nets LN 1 ,...,LN J that correspond to the originalunstructured PN but divide the complexity among several parts. The construction shouldobserve the following side conditions:1. Each part of the construction should have an interpretation in terms of a PN. This meansthat HN alone should be a PN. Furthermore, HN should provide an environment **for**a single LN j such that HN together with LN j yields a PN. Finally HN together withLN 1 ,...,LN J is a PN that is equivalent to the original PN.2. Language and RS of the hierarchical net and the original PN must be equivalent.3. The hierarchical net should have a corresponding hierarchical matrix representation ofits RG that must be space-efficient.The first condition **for**ces us to use net trans**for**mations and projections such that theresulting partition in HN and LN 1 ,...,LN J (**for** an arbitrary but fixed J that is modeldependent)indeed describes a set of PNs. The key idea is to define certain subnets as regionsand add implicit places to the regions of the original PN, such that a low-level net LN j is aregion j plus its implicit places. The high-level net HN is built upon implicit places P aggand their pre- and postsets •P agg ∪ P agg •. This construction simplifies an argumentation infavor of condition 2, since the HN together with all LN 1 ,...,LN J is the original PN plussome additional implicit places, and implicit places by nature do not change the languageor RS.

- Page 1 and 2: Formal Methods in System Design, 21
- Page 3 and 4: HIERARCHICAL REACHABILITY GRAPH GEN
- Page 5: HIERARCHICAL REACHABILITY GRAPH GEN
- Page 9 and 10: HIERARCHICAL REACHABILITY GRAPH GEN
- Page 11 and 12: HIERARCHICAL REACHABILITY GRAPH GEN
- Page 13 and 14: HIERARCHICAL REACHABILITY GRAPH GEN
- Page 15 and 16: HIERARCHICAL REACHABILITY GRAPH GEN
- Page 17 and 18: HIERARCHICAL REACHABILITY GRAPH GEN
- Page 19 and 20: HIERARCHICAL REACHABILITY GRAPH GEN
- Page 21 and 22: HIERARCHICAL REACHABILITY GRAPH GEN
- Page 23 and 24: HIERARCHICAL REACHABILITY GRAPH GEN
- Page 25 and 26: HIERARCHICAL REACHABILITY GRAPH GEN
- Page 27 and 28: HIERARCHICAL REACHABILITY GRAPH GEN
- Page 29 and 30: HIERARCHICAL REACHABILITY GRAPH GEN
- Page 31 and 32: HIERARCHICAL REACHABILITY GRAPH GEN
- Page 33 and 34: HIERARCHICAL REACHABILITY GRAPH GEN
- Page 35: HIERARCHICAL REACHABILITY GRAPH GEN