Commit graph

269 commits

Author SHA1 Message Date
Alexandre Duret-Lutz
948f99bc4e complement: add a complement() function
* spot/twaalgos/complement.cc,
spot/twaalgos/complement.hh (complement): New function.
* bin/autfilt.cc, spot/twa/twa.cc, spot/twaalgos/contains.cc,
spot/twaalgos/powerset.cc, spot/twaalgos/stutter.cc: Use it.
* tests/core/complement.test: Adjust.
* NEWS: Mention it.
2019-04-07 15:48:06 +02:00
Alexandre Duret-Lutz
628364909d dot: add option 'g'
* spot/twaalgos/dot.cc: Implement support for hidding labels.
* tests/core/readsave.test: Test it.
* bin/common_aoutput.cc: Add --help text.
* NEWS: Mention it.
2019-03-31 22:21:24 +02:00
Alexandre Duret-Lutz
55c50c65c8 autfilt: add support for --highlight-accepting-run
Fixes #381.

* bin/autfilt.cc: Here.
* tests/core/highlightstate.test: Test it.
* NEWS: Mention it.
2019-03-20 21:47:32 +01:00
Alexandre Duret-Lutz
7af47c7db5 bin: fix handling of \r\n with %>
Fix issue #380.

* bin/common_finput.cc: Erase a trailing \r.
* tests/core/ltl2tgba2.test: Test it.
* NEWS: Mention the fix.
2019-03-20 21:31:11 +01:00
Alexandre Duret-Lutz
bd0f959418 Bump copyright year
* bin/common_setup.cc, debian/copyright: Here.
2019-01-07 11:30:18 +01:00
Etienne Renault
c2c8d21538 noexcept: please gcc snapshot
* bin/common_finput.hh,
bin/common_trans.cc,
bin/common_trans.hh,
spot/misc/minato.hh,
spot/ta/ta.cc,
spot/ta/ta.hh,
spot/twa/acc.hh,
spot/twaalgos/cycles.hh,
spot/twaalgos/emptiness.hh,
spot/twaalgos/gtec/gtec.hh,
spot/twaalgos/ndfs_result.hxx,
spot/twaalgos/sccinfo.hh,
spot/twaalgos/word.cc,
spot/twaalgos/word.hh: Here.
2018-11-29 10:16:01 +00:00
Alexandre Duret-Lutz
29e08a1afb introduce count_univbranch_states() and count_univbranch_edges()
Fixes #368, suggested by František Blahoudek.

* spot/twaalgos/isdet.cc, spot/twaalgos/isdet.hh
(count_univbranch_states(), count_univbranch_edges()): New functions.
* bin/common_aoutput.cc, bin/common_aoutput.hh: Add %u and variants.
* NEWS: Mention these.
* tests/core/alternating.test: Test them.
2018-11-08 10:33:49 +01:00
Alexandre Duret-Lutz
d94efe9fe1 implement is_liveness() and is_liveness_automaton()
* spot/twaalgos/strength.cc, spot/twaalgos/strength.hh,
spot/tl/hierarchy.cc, spot/tl/hierarchy.hh: Here.
* bin/ltlfilt.cc (--liveness): New filter.
* NEWS: Mention those.
* tests/core/ltlfilt.test, tests/python/ltlsimple.py: Add test cases.
2018-10-15 21:37:31 +02:00
Alexandre Duret-Lutz
d2316b1428 fix ltlfilt --accept-word and --reject-word
* NEWS: Mention the issue.
* bin/ltlfilt.cc: Fix test.
* tests/core/acc_word.test: Test this.
2018-10-15 21:17:18 +02:00
Alexandre Duret-Lutz
23722c031f contains: fix the semantics
spot::contains(a, b) should test a⊇b.  It was testing a⊆b instead.

* NEWS: Mention the bug.
* spot/twaalgos/contains.cc, spot/twaalgos/contains.hh: Fix the
code and documentation.
* tests/python/contains.ipynb: Adjust description and expected
results.
* python/spot/__init__.py: Also swap the argument of
language_containment_checker.contains()
* bin/autfilt.cc: Adjust usage.
2018-08-01 17:17:25 +02:00
Maximilien Colange
8d5d453efa ltlsynt: new algorithm, based on LAR
* bin/ltlsynt.cc: here
* tests/core/ltlsynt.test: test it
* NEWS: document it
2018-07-27 15:34:39 +02:00
Maximilien Colange
bd75ab5b39 ltlsynt: rework synthesis algorithms
ltlsynt now offers two algorithms: one where splitting occurs before
determinization (the historical one) and one where determinization
occurs before splitting.

* bin/ltlsynt.cc: here
* tests/core/ltlsynt.test: test it and refactor test file
* NEWS: document it
* spot/misc/game.hh, spot/misc/game.cc: remove Calude's algorithm
2018-07-27 14:22:11 +02:00
Alexandre Duret-Lutz
4b8910d3f9 ltlfilt: introduce --suspendable
* bin/ltlfilt.cc: Add the option.
* tests/core/ltlfilt.test: Use it.
* NEWS: Mention it.
2018-07-25 11:18:26 +02:00
Alexandre Duret-Lutz
04d05104fa bin: conform to GNU Coding Standards for --version
* bin/common_setup.cc: Print the version number after the parentheses.
2018-06-29 21:55:21 +02:00
Alexandre Duret-Lutz
f5f5daec9a translate: enable a restricted form of ltl-split for TGBA/BA
Fixes #267

* spot/twaalgos/gfguarantee.cc: Fix a typo when comparing automata
sizes.
* spot/twaalgos/translate.cc, spot/twaalgos/translate.hh: Use
ltl-split even for BA/TGBA, but only of conjunctions with GF(..)
in those cases.
* tests/core/ltl2tgba2.test: Adjust and add the example of #267.
* tests/core/degenid.test, tests/core/parity2.test,
tests/core/stutter-tgba.test, tests/python/automata.ipynb,
tests/python/highlighting.ipynb, tests/python/stutter-inv.ipynb,
bin/spot-x.cc: Adjust.
2018-06-28 23:02:26 +02:00
Alexandre Duret-Lutz
4235b007f3 org: clarify that ltl2tgba does not only output TGBA
* doc/org/tools.org: Adjust the link to ltl2tgba.org.
* doc/org/ltl2tgba.org: Also point out that --generic and --parity can
be used without --deterministic.
* bin/ltl2tgba.cc, bin/spot.cc: Adjust help text.
2018-06-27 16:52:45 +02:00
Alexandre Duret-Lutz
4815a361de translate: add ltl-split option
* spot/twaalgos/translate.cc, spot/twaalgos/translate.hh: Build
automata with generic acceptance by doing product of automata for
smaller subformulas.
* bin/spot-x.cc: Mention ltl-split.
* NEWS: Mention the change, and show some results.
* tests/core/genltl.test, tests/python/_product_susp.ipynb,
tests/python/highlighting.ipynb: Adjust test cases.
* doc/org/ltl2tgba.org: Update.
* tests/core/gragsa.test: Add another formula to cover more
code.
2018-06-20 11:38:59 +02:00
Maximilien Colange
f2128360a7 update ltlsynt documentation
closes #355

* doc/org/citing.org, bin/man/ltlsynt.x: add SYNT2018 paper
* doc/org/ltlsynt.org: fix documentation
2018-06-13 15:57:34 +02:00
Alexandre Duret-Lutz
1341c656be genltl: add --gf-equiv-xn, --gf-implies-xn
* spot/gen/formulas.cc, spot/gen/formulas.hh: Here.
* bin/genltl.cc: Add options.
* tests/core/genltl.test: Test them.
* NEWS: Mention them.
2018-06-08 15:51:11 +02:00
Alexandre Duret-Lutz
c535871ffd genltl: --ms-example now has two arguments
* bin/genltl.cc, spot/gen/formulas.cc, tests/core/genltl.test: Adjust.
* NEWS: Mention it.
2018-06-05 08:48:40 +02:00
Alexandre Duret-Lutz
2e50f9e986 autfilt: implement --has-univ-branching and --has-exist-branching
Fixes #352.

* bin/autfilt.cc: Add the options.
* tests/core/alternating.test: Test them.
* NEWS: Mention them.
2018-06-05 08:48:40 +02:00
Alexandre Duret-Lutz
939f63eec9 genltl: add support for --sejk-f=n,m
Together with the previous patch, this Fixes #353.

Implementing this required to extend our interface two support
two-parameter patterns.

* spot/gen/formulas.cc, spot/gen/formulas.hh: Implement it.
* bin/genltl.cc: Add --sejk-f.
* bin/common_output.cc, bin/common_output.hh: Adjust to handle
"line numbers" that are not integers (e.g., "3,2"), since those
are used to display pattern parameters.
* bin/ltlfilt.cc: Adjust.
* python/spot/gen.i: Add support for two-parameters patterns.
* tests/core/genltl.test, tests/python/gen.ipynb: Augment.
* NEWS: Mention it.
2018-06-05 08:48:40 +02:00
Alexandre Duret-Lutz
c76df95c69 genltl: three new families --sejk-{j,k,patterns}
These correspond to the first three blocks of table 1 in S. Sickert,
J. Esparza, S. Jaax, and J. Křetínský: Limit-Deterministic Büchi
Automata for Linear Temporal Logic.  CAV'16.  LNCS 9780.

For #353.

* spot/gen/formulas.cc, spot/gen/formulas.hh, bin/genltl.cc: Implement
the new families.
* tests/core/genltl.test: Test it.
* bin/man/genltl.x, NEWS: Document it.
2018-06-03 20:20:59 +02:00
Alexandre Duret-Lutz
b12eb0508f fix and check shifting issue
The exception raised by << and >> when shifting mark_t by too many
bits are only enabled in SPOT_DEBUG, as those operations are quite
low-level.  However we were always testing them, and although we
wanted them to be active in Python, it was not always the case.

* spot/twa/acc.hh: introduce max_accsets() as
a static constexpr method, so we can see it in Python.
* spot/misc/bitset.hh: Fix preprocessing directive
so the check is actually enabled when compiling the Python
bindings.
* bin/autcross.cc, bin/autfilt.cc, bin/ltlcross.cc: Use max_accsets().
* tests/core/acc.cc: Comment out the shifting exception when
SPOT_DEBUG is unset.
* tests/python/except.py: Make sure the exception is always raised in
Python.
2018-05-25 16:08:00 +02:00
Alexandre Duret-Lutz
2e165f188d rename SPOT_NB_ACC to SPOT_MAX_ACCSETS
* NEWS, bin/autcross.cc, bin/autfilt.cc, bin/ltlcross.cc,
configure.ac, spot/parseaut/parseaut.yy, spot/twa/acc.cc,
spot/twa/acc.hh, tests/core/acc.cc, .gitlab-ci.yml: Here.
2018-05-24 22:18:42 +02:00
Alexandre Duret-Lutz
c87c13db67 autfilt: better handling of chain of products with -B
Fixes #348, reported by Jeroen Meijer.

* bin/autfilt.cc: If -B is used with many --product,
degeneralize intermediate products as needed.
* NEWS: Mention the change.
* tests/core/prodchain.test: New file.
* tests/Makefile.am: Add it.
* spot/twa/acc.cc, spot/twa/acc.hh: Fix reporting of
overflow.
* tests/core/acc.cc: Adjust.
2018-05-24 19:23:48 +02:00
Maximilien Colange
1a4117a07f randltl: fix option --allow-dups
* bin/randltl.cc: here
* tests/core/rand.test: test it
* NEWS: document it
2018-05-23 12:01:43 +02:00
Maximilien Colange
cde0977ef8 hide implementation of spot::acc_cond::mark_t
* bin/autcross.cc, bin/autfilt.cc, bin/ltlcross.cc,
  spot/parseaut/parseaut.yy: use SPOT_NB_ACC
* spot/twa/acc.hh: make implementation private
2018-05-23 10:27:51 +02:00
Alexandre Duret-Lutz
75550112a7 bin: remove some dead code
* bin/common_trans.cc, bin/common_trans.hh: Here.
2018-05-22 16:14:18 +02:00
Maximilien Colange
d7ee23ed2f acc_cond::mark_t now relies on bitset
This allows to represent more than 32 acceptance marks.

* configure.ac: add an option to specify the number of marks
* spot/twa/acc.hh: implement it
* tests/python/acc_cond.ipynb, tests/core/acc.cc,
  tests/core/ltlcross3.test: update tests
* NEWS: document it
* bin/randltl.cc: fix an include
2018-05-22 09:54:19 +02:00
Alexandre Duret-Lutz
3334a6a679 bin: remove dead code from ltl2tgta
* bin/ltl2tgta.cc: There is no -B option.
2018-05-21 17:39:38 +02:00
Alexandre Duret-Lutz
c369f899a3 bin: teach conversion options to report about the options
* bin/common_conv.cc, bin/common_conv.hh: Here.
* bin/autfilt.cc, bin/common_trans.cc, bin/ltlcross.cc, bin/ltldo.cc,
bin/ltlfilt.cc, bin/ltlgrind.cc, bin/randaut.cc, bin/randltl.cc: Pass
the name of the argumennt to the conversion function.
* tests/core/ltlcross3.test, tests/core/ltldo.test,
tests/core/randaut.test: Add test cases.
2018-05-21 17:39:38 +02:00
Alexandre Duret-Lutz
1f9f3c77ea bin: abort autcross on input parse error
* bin/common_hoaread.hh (hoa_processor): Add a abort_on_error
option.
* bin/autcross.cc: Use it.
* tests/core/autcross4.test: Add many more error cases to improve
coverage.
2018-05-21 17:39:38 +02:00
Alexandre Duret-Lutz
7b580e006a bin: add --usage back
Because it appears in some error messages we cannot remove.  Make
--usage as a synonym for --help.

* bin/common_setup.cc: Here.
2018-05-20 17:36:24 +02:00
Alexandre Duret-Lutz
af3f62c1c8 ltlcross, ltldo, autcross: add support for Rabinizer 4 tools
* bin/common_trans.cc: Here.
* NEWS: Mention that.
2018-05-20 17:24:26 +02:00
Alexandre Duret-Lutz
47974cd004 autfilt: support --is-colored
This also improve the coverage of the is_colored() function, because
it was not used in negative cases so far.

* bin/autfilt.cc: Implement it.
* tests/core/satmin2.test: Test it.
* NEWS: Mention it.
2018-05-18 20:50:48 +02:00
Alexandre Duret-Lutz
2f8ae55f6b bin: diagnose failures to print --help
Fixes #349.

* bin/common_setup.cc (OPT_HELP, OPT_VERSION): Call close_stdout().
2018-05-18 20:50:48 +02:00
Alexandre Duret-Lutz
a80cd361c0 bin: finish removal of --usage
* bin/common_setup.cc: Here.
2018-05-18 20:50:48 +02:00
Alexandre Duret-Lutz
645bb55622 bin: factor exception-handling code
* bin/common_setup.cc, bin/common_setup.hh: Define a protected_main()
function that deal with exceptions.
* bin/autcross.cc, bin/autfilt.cc, bin/dstar2tgba.cc, bin/genaut.cc,
bin/genltl.cc, bin/ltl2tgba.cc, bin/ltl2tgta.cc, bin/ltlcross.cc,
bin/ltldo.cc, bin/ltlfilt.cc, bin/ltlgrind.cc, bin/ltlsynt.cc,
bin/randaut.cc, bin/randltl.cc: Use it for all tools.
2018-05-16 20:15:04 +02:00
Alexandre Duret-Lutz
fc0ed01a45 randomltl: avoid #define
As this pollutes the user's namespace.

* spot/tl/randomltl.hh: Use class-level enum and constexpr instead
of #define.
* spot/tl/randomltl.cc, python/spot/__init__.py, bin/randltl.cc,
tests/python/dualize.py, tests/python/sum.py: Adjust usage.
2018-05-16 18:35:36 +02:00
Alexandre Duret-Lutz
565e25502c bin: stop supporting the hidden --usage
It's not used anywhere, not documented, and its output is slightly
broken with options that are too long.

* bin/common_setup.cc: Remove --usage support.
2018-05-16 17:18:48 +02:00
Alexandre Duret-Lutz
70b4aa7b7e bin: remove some dead code
* bin/common_output.cc, bin/common_output.hh: Here.
2018-05-16 17:05:21 +02:00
Alexandre Duret-Lutz
4d82758726 autfilt: --complement accepts non-deterministic input
* bin/autfilt.cc: Fix the --help string for --complement, and also
merge edges in the resulting automaton, as suggested by František
Blahoudek.
* tests/core/complement.test: Adjust output and add František's
example.
2018-05-16 14:23:31 +02:00
Alexandre Duret-Lutz
5c1d9c492c dot: add option K
* spot/twaalgos/dot.cc: Here.
* NEWS, bin/common_aoutput.cc: Mention it.
* tests/python/ltsmin-pml.ipynb: Use it.
* tests/python/ipnbdoctest.py: Work around some graphviz
version differences.
2018-05-14 18:07:58 +02:00
Alexandre Duret-Lutz
60898b6d22 dot: support 'u'
* spot/twaalgos/dot.cc: Implement it.
* bin/common_aoutput.cc, NEWS: Mention it.
* tests/python/alternation.ipynb: Test it.
2018-05-12 09:23:05 +02:00
Alexandre Duret-Lutz
d6f9618172 introduce containement checks functions
* spot/twaalgos/contains.hh, spot/twaalgos/contains.cc: New files.
* spot/twaalgos/Makefile.am, python/spot/impl.i: Add them.
* python/spot/__init__.py: Also attach these functions as methods,
and support string arguments.
* tests/python/contains.ipynb: New file.
* tests/Makefile.am, doc/org/tut.org: Add it.
* bin/autfilt.cc, tests/python/streett_totgba.py, tests/python/sum.py,
tests/python/toweak.py: Use the new function.
2018-05-04 17:18:49 +02:00
Maximilien Colange
1fdc32f9bb ltlsynt: improve construction of turn-based games
Improve the way transitions are duplicated when preparing the turn-based
game for synthesis. The resulting arena should now be deterministic on
nodes owned by the environment. Also move the code to another file, so
that it is easier to test (e.g. in Python).

* bin/ltlsynt.cc: move the code
* spot/twaalgos/split.cc, spot/twaalgos/split.hh: move the code and
  implement the improvements
* tests/Makefile.am, tests/python/split.py: test it
* tests/core/ltlsynt.test: update existing tests to reflect the changes
2018-04-30 14:41:52 +02:00
Maximilien Colange
9698363ef5 parity game: various improvements
Zielonka algorithm has been fixed and optimized.
It also now computes the strategy for both players.

* bin/ltlsynt.cc: Update calls to parity_game::solve()
* spot/misc/game.cc, spot/misc/game.hh: Implement the changes
2018-04-23 11:51:12 +02:00
Maximilien Colange
0e29d30d1b ltlsynt: fix the construction of the arena
* bin/ltlsynt.cc: implement it
* tests/core/ltlsynt.test: update tests
2018-04-23 11:51:12 +02:00
Maximilien Colange
5d80cc556c Add a verbose option to ltlsynt
* bin/ltlsynt.cc: implement it
2018-04-23 11:51:02 +02:00