Merge lp:~verifypn-stub/verifypn/inhibitor-por-error into lp:verifypn

Proposed by Peter Gjøl Jensen
Status: Merged
Approved by: Jiri Srba
Approved revision: 207
Merged at revision: 206
Proposed branch: lp:~verifypn-stub/verifypn/inhibitor-por-error
Merge into: lp:verifypn
Diff against target: 28 lines (+5/-2)
2 files modified
PetriEngine/PetriNet.cpp (+4/-1)
PetriEngine/ReducingSuccessorGenerator.cpp (+1/-1)
To merge this branch: bzr merge lp:~verifypn-stub/verifypn/inhibitor-por-error
Reviewer Review Type Date Requested Status
Jiri Srba Approve
Review via email: mp+346919@code.launchpad.net

Commit message

Fixes issue with POR and inhibitor arcs.
Also adds inhibitor arcs to the reduced-net-writing option.

To post a comment you must log in.
Revision history for this message
Jiri Srba (srba) wrote :

Tested and it fixes the issue with wrong answers for inhibitor arcs.

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'PetriEngine/PetriNet.cpp'
2--- PetriEngine/PetriNet.cpp 2018-05-11 10:16:07 +0000
3+++ PetriEngine/PetriNet.cpp 2018-05-27 17:43:24 +0000
4@@ -211,7 +211,10 @@
5 {
6 out << "<arc id=\"" << (id++) << "\" source=\""
7 << _placenames[pre.first->place] << "\" target=\""
8- << _transitionnames[t] << "\">\n";
9+ << _transitionnames[t]
10+ << "\" type=\""
11+ << (pre.first->inhibitor ? "inhibitor" : "normal")
12+ << "\">\n";
13
14 if(pre.first->tokens > 1)
15 {
16
17=== modified file 'PetriEngine/ReducingSuccessorGenerator.cpp'
18--- PetriEngine/ReducingSuccessorGenerator.cpp 2018-03-16 12:18:36 +0000
19+++ PetriEngine/ReducingSuccessorGenerator.cpp 2018-05-27 17:43:24 +0000
20@@ -242,7 +242,7 @@
21 for (; linv < next_finv; linv++)
22 {
23 if(_net._invariants[linv].direction > 0)
24- inhibitorPostsetOf(_net._invariants[finv].place);
25+ inhibitorPostsetOf(_net._invariants[linv].place);
26 }
27 }
28 } else {

Subscribers

People subscribed via source and target branches