postproc: fix monitor code
Fixes #240. * spot/twaalgos/postproc.cc: Do not call do_simul on the output of minimize_monitor(), and do not skip complete() when PREF_==Any. * tests/core/monitor.test: Add a test case. * NEWS: Mention the bug. * doc/org/ltl2tgba.org: Document complete monitors.
This commit is contained in:
parent
cf5d2c2b32
commit
2b9accdf58
4 changed files with 61 additions and 44 deletions
|
|
@ -921,32 +921,6 @@ $txt
|
|||
ltl2tgba -MD '(Xa & Fb) | Gc' -d
|
||||
#+END_SRC
|
||||
|
||||
#+RESULTS: monitor2
|
||||
#+begin_example
|
||||
digraph G {
|
||||
rankdir=LR
|
||||
node [shape="circle"]
|
||||
fontname="Lato"
|
||||
node [fontname="Lato"]
|
||||
edge [fontname="Lato"]
|
||||
node[style=filled, fillcolor="#ffffa0"] edge[arrowhead=vee, arrowsize=.7]
|
||||
I [label="", style=invis, width=0]
|
||||
I -> 3
|
||||
0 [label=<0>]
|
||||
0 -> 0 [label=<1>]
|
||||
1 [label=<1>]
|
||||
1 -> 0 [label=<a>]
|
||||
2 [label=<2>]
|
||||
2 -> 2 [label=<c>]
|
||||
3 [label=<3>]
|
||||
3 -> 1 [label=<!c>]
|
||||
3 -> 4 [label=<c>]
|
||||
4 [label=<4>]
|
||||
4 -> 0 [label=<a>]
|
||||
4 -> 2 [label=<!a & c>]
|
||||
}
|
||||
#+end_example
|
||||
|
||||
#+BEGIN_SRC dot :file monitor2.png :cmdline -Tpng :var txt=monitor2 :exports results
|
||||
$txt
|
||||
#+END_SRC
|
||||
|
|
@ -959,6 +933,29 @@ match the formula, monitor cannot be used to check for eventualities
|
|||
such as =F(a)=: indeed, any finite execution can be extended to match
|
||||
=F(a)=.
|
||||
|
||||
|
||||
Because Monitors accept every recognized run (in other words, they
|
||||
only reject words that are not recognized), it makes little sense to
|
||||
use option =-C= to request /complete/ monitors. If uou combine =-C=
|
||||
with =-M=, the result will output as a Büchi automaton if (and only
|
||||
if) a sink state had to be added. For instance, here is the
|
||||
"complete" version of the previous monitor.
|
||||
|
||||
#+NAME: monitor3
|
||||
#+BEGIN_SRC sh :results verbatim :exports code
|
||||
ltl2tgba -C -M -D '(Xa & Fb) | Gc' -d
|
||||
#+END_SRC
|
||||
|
||||
#+BEGIN_SRC dot :file monitor3.png :cmdline -Tpng :var txt=monitor3 :exports results
|
||||
$txt
|
||||
#+END_SRC
|
||||
|
||||
#+RESULTS:
|
||||
[[file:monitor3.png]]
|
||||
|
||||
|
||||
|
||||
|
||||
# LocalWords: ltl tgba num toc PSL Büchi automata SRC GFb invis Acc
|
||||
# LocalWords: ltlfilt filenames GraphViz vectorial pdf Tpdf dotex
|
||||
# LocalWords: sed png cmdline Tpng txt iff GFa ba utf UTF lbtt Fb
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue