In all examples, reference is made to the net 6.2, which models the controlling of two traffic lights.
For the net 6.2, the transposed incidence matrix is as follows:
The entry -1 in the first column of the first row means that the
transition t1 subtracts a token from place
Input matrix (transposed incidence matrix):
1 2 3 4 5 6
~~~~~~~~~~~~~~~~~~~~~~~~~~~
1 | -1 0 1 1 0 0
2 | 0 1 -1 -1 1 -1
3 | 0 -1 1 1 0 0
4 | 1 0 -1 -1 -1 1
.
The entry 1 in the sixth column of the
fourth row means, on the other hand, that firing the transition t4
adds a token onto place
.
If entries in the matrix are written as 00 instead of 0,
these entries result from the impurity of the net (see page
in chapter 6.2.1).
As an example, you see P-invariants of the net 6.2.
The basis is written in the form of a table where the rows are the numbers of the invariants, and the columns are the numbers of the places or transitions.
Nr. 1 2 3 4 5 6 ~~~~~~~~~~~~~~~~~~~~~~~~~~~ 1 | 1 1 1 0 0 0 + 2 | 1 1 0 1 0 0 + 3 | 0 0 0 0 1 1 +Invariants which you have written into a separate file using this format can be tested later with the command <T> (see page
). They are therefore saved in a file with the extension .inv. All other formats do not allow such a test, and are therefore written into a file with the extension .res
The basis is likewise written in the form of a table; however, instead of zero's, blanks are printed.
Nr. 1 2 3 4 5 6 ~~~~~~~~~~~~~~~~~~~~~~~~~~~ 1 | 1 1 1 + 2 | 1 1 1 + 3 | 1 1 +
The basis vectors are displayed as a list of their non-zero components in the form <node number> : <value> .
1 | 1: 1, 2: 1, 3: 1 + 2 | 1: 1, 2: 1, 4: 1 + 3 | 5: 1, 6: 1 +
The basis vectors are likewise displayed as a list of their non-zero components, but with the names of the components included.
1 | 1.gruen_eins : 1, | 2.gruen_zwei : 1, | 3.gelb_eins : 1 + 2 | 1.gruen_eins : 1, | 2.gruen_zwei : 1, | 4.gelb_zwei : 1 + 3 | 5.rot_eins : 1, | 6.rot_zwei : 1 +
Please note: semipositive invariants are denoted by a
+ when displayed (see also page ).
The P-(or T-)invariants form a linear space, closed under (componentwise) addition, scalar multiplication by integers, and division by the greatest commom divisor of all components. This space is spanned by a finite number of basis vectors, yet in general contains an infinite number of invariants. With the command <I> , a basis is computed.
First, you can change the displayed options:With the option <P> , you choose between computing place or transition invariants. With <O> , you can determine whether the (transposed) incidence matrix should be displayed, and with <F> , you determine the form in which the invariants are to be displayed.computation of place-invariants..................................P output (transposed) incidence matrix.............................O output format = complete table...................................FAfterwards, this command computes a basis for the space of all invariants of the selected type. INA states whether invariants were found, and possibly derives further deductions from it. The program decides whether the net is covered by invariants of the selected type, i.e., whether an invariant exists which is positive in all components. If such an invariant was actually computed, it will be displayed as well.
If P-invariants were found, a fast non-reachability test is offered: Test a marking for non-reachability? A description of this test can be found on page
.
At the end, the following lines are displayed on the screen: You may display the results by typing 'F <cr> Y <esc> ' and results by other format (f), exit (e).
With <E> , you return to the analysis menu, and with <F> , the four possible display formats are shown again. If you would like to have the invariants displayed on the screen, simply press <cr> now. If you answer the question Open a separate output file with <Y> and then press <esc> , the computed invariants are displayed on the screen, as desired. If, however, you want to direct the results into a separate file, then enter a file name; the extension .inv or .res is automatically appended. If desired, the display format can also be changed beforehand, of course. The question about a non-reachability test appears again, as well as the lines described above. If you wrote the results in a separate file and then enter <F> again, INA first asks Close separate output file ?. If you answer <Y> , the file is closed and you can enter another output file. Otherwise, the results are appended to the file already open.
For the T-invariant basis, we obtain
,
i.e., when all four transitions have fired, the
initial marking is reset.
For the net 6.2, the properties CPI, CTI, SB, and B can be deduced from the invariant analysis.
If the computation of
P-invariants has led to a result, a fast non-reachability test is
offered. With the computed invariants, INA can easily check
this, because of the following equation:
For the initial marking m0, an invariant x, and a marking m
reachable from m0,
it always holds that
.
For a specified marking, this equation is tested with all
basis invariants computed, and, if existent, the numbers of the
P-invariants which do not satisfy the equation are displayed.
Within the context of net 6.2, such a non-reachability is shown in the following, based on the previously computed P-invariants:
Non-reachability test of the marking m:
p : 1 2 3 4 5 6
-----------------------
m(p): 1 1 . . . .
The marking is not reachable from m0.
invariant nr. 3
invariant nr. 2
invariant nr. 1
Non-reachability test of the marking m:
p : 1 2 3 4 5 6
-----------------------
m(p): 1 . . . 1 .
No conclusions possible.
Non-reachability test of the marking m:
p : 1 2 3 4 5 6
-----------------------
m(p): . . 1 1 . .
The marking is not reachable from m0.
invariant nr. 3
As you can see, the state ``both traffic lights are green'' is not reachable. It violates all three P-invariants computed. Furthermore, it can not be decided whether the marking ``traffic light 1 is simultaneously green and red'' is reachable. The marking ``both traffic lights are yellow'' violates the invariant number three, which states that exactly one traffic light must indicate red; that marking is therefore not reachable.
© 1996-99 Prof. Peter H. Starke (starke@informatik.hu-berlin.de) und Stephan Roch (roch@...)
INA Manual Version 2.2 (last changed 1999-04-19)