genaut: introduce --m-nba
* bin/genaut.cc: Implement the --m-nba option. * spot/gen/automata.hh, spot/gen/automata.cc: Add the generation code. * NEWS, bin/man/genaut.x: Document it. * doc/org/genaut.org: Update. * tests/core/genaut.test, tests/core/parity2.test: Add some tests.
This commit is contained in:
parent
435fec89b0
commit
cba012328e
8 changed files with 132 additions and 18 deletions
|
|
@ -1,6 +1,6 @@
|
|||
#!/bin/sh
|
||||
# -*- coding: utf-8 -*-
|
||||
# Copyright (C) 2017, 2018 Laboratoire de Recherche et Développement
|
||||
# Copyright (C) 2017, 2018, 2019 Laboratoire de Recherche et Développement
|
||||
# de l'Epita (LRDE).
|
||||
#
|
||||
# This file is part of Spot, a model checking library.
|
||||
|
|
@ -29,7 +29,8 @@ s/[=[].*/=1/p
|
|||
res=`genaut $opts --stats="--%F=%L"`
|
||||
test "$opts" = "$res"
|
||||
|
||||
genaut --ks-nca=..3 --l-nba=..3 --l-dsa=..3 --stats=%s,%e,%t,%c,%g >out
|
||||
genaut --ks-nca=..3 --l-nba=..3 --l-dsa=..3 --m-nba=..3 \
|
||||
--stats=%s,%e,%t,%c,%g >out
|
||||
cat >expected <<EOF
|
||||
3,7,16,1,Fin(0)
|
||||
5,14,32,1,Fin(0)
|
||||
|
|
@ -40,6 +41,9 @@ cat >expected <<EOF
|
|||
4,6,6,1,Fin(0) | Inf(1)
|
||||
8,12,12,1,(Fin(0) | Inf(1)) & (Fin(2) | Inf(3))
|
||||
12,18,18,1,(Fin(0) | Inf(1)) & (Fin(2) | Inf(3)) & (Fin(4) | Inf(5))
|
||||
2,3,4,1,Inf(0)
|
||||
3,6,10,1,Inf(0)
|
||||
4,9,18,1,Inf(0)
|
||||
EOF
|
||||
diff out expected
|
||||
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
#!/bin/sh
|
||||
# -*- coding: utf-8 -*-
|
||||
# Copyright (C) 2018 Laboratoire de Recherche et Développement de
|
||||
# Copyright (C) 2018, 2019 Laboratoire de Recherche et Développement de
|
||||
# l'Epita (LRDE).
|
||||
#
|
||||
# This file is part of Spot, a model checking library.
|
||||
|
|
@ -1526,3 +1526,17 @@ diff expected4 res4
|
|||
ltlcross 'ltl2tgba -P' 'ltl2tgba -P"odd max"' 'ltl2tgba -P"even min"' \
|
||||
'ltl2tgba -p' 'ltl2tgba -p"odd max"' 'ltl2tgba -p"even min"' \
|
||||
-f FGa -f 'GFa&GFb' -f 'GF(a <-> XXXb)' -f '(p0 W XXGp0) & GFp1 & FGp2'
|
||||
|
||||
|
||||
# Test the behavior of our determinization on Max Michel automata.
|
||||
# Any change to Spot that lowers the output.states is welcome :-)
|
||||
genaut --m-nba=1..4 | autcross --language-preserved 'autfilt -D' --csv=out.csv
|
||||
cut -d, -f4,17 out.csv > sizes.csv
|
||||
cat >expected <<EOF
|
||||
"input.states","output.states"
|
||||
2,3
|
||||
3,15
|
||||
4,129
|
||||
5,2057
|
||||
EOF
|
||||
diff sizes.csv expected
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue