lbtt: improve the LBTT output
Provide a way to output automata with state-based acceptance. Also print the guards using to_lbt_string() for consistency: as a consequence, atomic proposition that do not match p[0-9]+ are now double-quoted. * src/tgbaalgos/lbtt.hh (lbtt_reachable): Add a sba option. * src/tgbaalgos/lbtt.cc: Implement it, and use to_lbt_string(). * src/ltlvisit/lbt.cc (is_pnum): Reject 'p' without number. * src/bin/ltl2tgba.cc: Activate the sba option of --ba was given. Add an option --lbtt=t to get the old behavior. * src/bin/man/ltl2tgba.x: Document the LBTT format we use with some links and examples. * src/tgbatest/lbttparse.test: More tests. * src/tgbatest/ltlcross2.test: Add a check with --lbtt --ba. * NEWS: Update.
This commit is contained in:
parent
e2378b4904
commit
eed7e2df8f
8 changed files with 225 additions and 60 deletions
|
|
@ -1,6 +1,6 @@
|
|||
#!/bin/sh
|
||||
# -*- coding: utf-8 -*-
|
||||
# Copyright (C) 2012 Laboratoire de Recherche et Développement
|
||||
# Copyright (C) 2012, 2013 Laboratoire de Recherche et Développement
|
||||
# de l'Epita (LRDE).
|
||||
#
|
||||
# This file is part of Spot, a model checking library.
|
||||
|
|
@ -38,8 +38,29 @@ do
|
|||
tr=`cat size | sed -n 's/transitions: //p'`
|
||||
l=`expr $st \* 2 + $tr + 1`
|
||||
test "$s" -eq "$l"
|
||||
done
|
||||
|
||||
# Do the same with bin/ltl2tgba
|
||||
run 0 ../../bin/ltl2tgba --low --any --lbtt "$f" >out3
|
||||
cmp out out3
|
||||
head -n 1 out3 | grep t
|
||||
# Make sure we output the state-based format
|
||||
# for BA...
|
||||
run 0 ../../bin/ltl2tgba --ba --lbtt --low --any "$f" >out4
|
||||
head -n 1 out4 | grep t && exit 1
|
||||
s4=`wc -l < out4`
|
||||
test "$s" -eq "$s4"
|
||||
run 0 ../ltl2tgba -t -XL out4 > out5
|
||||
s5=`wc -l < out5`
|
||||
test "$s" -eq "$s5"
|
||||
# ... unless --lbtt=t is used.
|
||||
run 0 ../../bin/ltl2tgba --ba --lbtt=t --low --any "$f" >out6
|
||||
head -n 1 out6 | grep t
|
||||
s6=`wc -l < out6`
|
||||
test "$s" -eq "$s6"
|
||||
run 0 ../ltl2tgba -t -XL out6 > out7
|
||||
s7=`wc -l < out7`
|
||||
test "$s" -eq "$s7"
|
||||
done
|
||||
|
||||
# This is the output of 'lbt' on the formula 'U p0 p1'.
|
||||
cat >Up0p1 <<EOF
|
||||
|
|
|
|||
|
|
@ -37,4 +37,5 @@ ltl2tgba=../../bin/ltl2tgba
|
|||
"$ltl2tgba --lbtt -x comp-susp,!skel-wdba --lbtt --small %f >%T" \
|
||||
"$ltl2tgba --lbtt -x comp-susp,early-susp --lbtt --small %f >%T" \
|
||||
"$ltl2tgba --lbtt -x comp-susp,!skel-wdba,!skel-simul --lbtt --small %f >%T" \
|
||||
"$ltl2tgba --lbtt --ba --high %f > %T" \
|
||||
--json=output.json --csv=output.csv
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue