twa: add support for very-weak property
* spot/twa/twa.hh: Implement the property. * spot/parseaut/parseaut.yy, spot/twaalgos/hoa.cc: Add input and output for it. * spot/twaalgos/strength.cc, spot/twaalgos/strength.hh (is_very_weak_automaton): New function. * tests/core/alternating.test: Add a test for --check=strength on an alternating automaton. * tests/core/strength.test, tests/core/parseaut.test: Adjust expected output. * NEWS, doc/org/hoa.org, doc/org/concepts.org: Document it.
This commit is contained in:
parent
a4ce999402
commit
582d455c23
11 changed files with 146 additions and 33 deletions
|
|
@ -995,6 +995,7 @@ automaton, and that can be queried or set by algorithms:
|
|||
| =state_acc= | automaton should be considered has having state-based acceptance |
|
||||
| =inherently_weak= | accepting and rejecting cycles cannot be mixed in the same SCC |
|
||||
| =weak= | transitions of an SCC all belong to the same acceptance sets |
|
||||
| =very-weak= | weak automaton where all SCCs have size 1 |
|
||||
| =terminal= | automaton is weak, accepting SCCs are complete, accepting edges may not go to rejecting SCCs |
|
||||
| =deterministic= | there is at most one run *recognizing* a word, but not necessarily accepting it |
|
||||
| =unambiguous= | there is at most one run *accepting* a word (but it might be recognized several time) |
|
||||
|
|
|
|||
|
|
@ -603,10 +603,10 @@ body of the file, and then return and error if what has been declared
|
|||
does not correspond to the reality.
|
||||
|
||||
Some supported properties (like =weak=, =inherently-weak=,
|
||||
=unambiguous=, or =stutter-invariant=) are not double-checked, because
|
||||
that would require more operations. Command-line tools that
|
||||
read HOA files all take a =--trust-hoa=no= option to ignore properties
|
||||
that are not double-checked by the parser.
|
||||
=very-weak=, =terminal=, =unambiguous=, or =stutter-invariant=) are
|
||||
not double-checked, because that would require more operations.
|
||||
Command-line tools that read HOA files all take a =--trust-hoa=no=
|
||||
option to ignore properties that are not double-checked by the parser.
|
||||
|
||||
It should be noted that each property can take three values: true,
|
||||
false, or maybe. So actually two bits are used per property. For
|
||||
|
|
@ -652,24 +652,25 @@ particular:
|
|||
to detect deterministic automata that have been output by algorithms
|
||||
that do not try to output deterministic automata.
|
||||
|
||||
| property | parser | stored | printer | notes |
|
||||
|---------------------+---------+--------+---------------------------------------------+------------------------------------------------------------------|
|
||||
| =state-labels= | checked | no | checked if =-Hk= | state labels are converted to transition labels when reading TωA |
|
||||
| =trans-labels= | checked | no | always, unless =-Hi= or =-Hk= | |
|
||||
| =implicit-labels= | checked | no | if =-Hi= | =-Hi= only works for deterministic automata |
|
||||
| =explicit-labels= | checked | no | always, unless =-Hi= | |
|
||||
| =state-acc= | checked | yes | checked, unless =-Ht= or =-Hm= | |
|
||||
| =trans-acc= | checked | no | if not =state-acc= and not =-Hm= | |
|
||||
| =no-univ-branch= | ignored | no | only if =-Hv= | |
|
||||
| =deterministic= | checked | yes | checked | |
|
||||
| =complete= | checked | no | checked | |
|
||||
| =unambiguous= | trusted | yes | as stored if (=-Hv= or not =deterministic=) | can be checked with =--check=unambiguous= |
|
||||
| =stutter-invariant= | trusted | yes | as stored | can be checked with =--check=stuttering= |
|
||||
| =stutter-sensitive= | trusted | yes | as stored (opposite of =stutter-invariant=) | can be checked with =--check=stuttering= |
|
||||
| =terminal= | trusted | yes | as stored | can be checked with =--check=strength= |
|
||||
| =weak= | trusted | yes | as stored if (=-Hv= or not =terminal=) | can be checked with =--check=strength= |
|
||||
| =inherently-weak= | trusted | yes | as stored if (=-Hv= or not =weak=) | can be checked with =--check=strength= |
|
||||
| =colored= | ignored | no | checked | |
|
||||
| property | parser | stored | printer | notes |
|
||||
|---------------------+---------+--------+---------------------------------------------------------+------------------------------------------------------------------|
|
||||
| =state-labels= | checked | no | checked if =-Hk= | state labels are converted to transition labels when reading TωA |
|
||||
| =trans-labels= | checked | no | always, unless =-Hi= or =-Hk= | |
|
||||
| =implicit-labels= | checked | no | if =-Hi= | =-Hi= only works for deterministic automata |
|
||||
| =explicit-labels= | checked | no | always, unless =-Hi= | |
|
||||
| =state-acc= | checked | yes | checked, unless =-Ht= or =-Hm= | |
|
||||
| =trans-acc= | checked | no | if not =state-acc= and not =-Hm= | |
|
||||
| =no-univ-branch= | ignored | no | only if =-Hv= | |
|
||||
| =deterministic= | checked | yes | checked | |
|
||||
| =complete= | checked | no | checked | |
|
||||
| =unambiguous= | trusted | yes | as stored if (=-Hv= or not =deterministic=) | can be checked with =--check=unambiguous= |
|
||||
| =stutter-invariant= | trusted | yes | as stored | can be checked with =--check=stuttering= |
|
||||
| =stutter-sensitive= | trusted | yes | as stored (opposite of =stutter-invariant=) | can be checked with =--check=stuttering= |
|
||||
| =terminal= | trusted | yes | as stored | can be checked with =--check=strength= |
|
||||
| =very-weak= | trusted | yes | as stored if (=-Hv= or not =terminal=) | can be checked with =--check=strength= |
|
||||
| =weak= | trusted | yes | as stored if (=-Hv= or not (=terminal= or =very-weak=)) | can be checked with =--check=strength= |
|
||||
| =inherently-weak= | trusted | yes | as stored if (=-Hv= or not =weak=) | can be checked with =--check=strength= |
|
||||
| =colored= | ignored | no | checked | |
|
||||
|
||||
The above table is for version 1 of the format. When version 1.1 is
|
||||
selected (using =-H1.1=), some negated properties may be output. In
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue