Commit graph

2348 commits

Author SHA1 Message Date
Alexandre Duret-Lutz
7615a57dab dstar2tgba: rewrite using common_aoutput
Fixes #8.

* src/bin/dstar2tgba.cc: Here.
2015-08-20 23:21:28 +02:00
Alexandre Duret-Lutz
f831f729e1 homogenize dstar_parse() and parse_aut() outputs
* src/dstarparse/dstarparse.yy, src/dstarparse/dstarscan.ll
src/dstarparse/parsedecl.hh, src/dstarparse/public.hh:
Adjust to return the same return types as parse_aut.
* src/dstarparse/fmterror.cc: Delete, we can use
the one of parse_aut.
* src/dstarparse/Makefile.am: Adjust.
* src/tests/ikwiad.cc, src/bin/dstar2tgba.cc,
src/bin/ltldo.cc: Adjust usage.
* src/bin/ltlcross.cc: The the result of dstar_parse() as-is, now that
it is a TωA like those produced by parse_aut().  As a consequence,
get rid of all the code storing statistics about the input
automaton.
* src/tests/ltlcross3.test, src/tests/ltl2dstar.test: Adjust expected
CSV output.
* doc/org/ltlcross.org, src/bin/man/ltlcross.x: Adjust to not
mention that %D performs a tranformation to Büchi.
2015-08-20 23:21:20 +02:00
Alexandre Duret-Lutz
62f5b9769b remove algorithms that where only used by dstar's dra2ba conversion
Since we just removed that conversion, those can go as well.  Yay!

* src/tests/kv.test, src/twa/twamask.cc,
src/twa/twamask.hh, src/twa/twaproxy.cc,
src/twa/twaproxy.hh, src/twaalgos/scc.cc,
src/twaalgos/scc.hh: Delete.
* src/twaalgos/Makefile.am, src/twa/Makefile.am,
src/tests/Makefile.am, src/tests/ikwiad.cc: adjust.
2015-08-20 21:35:39 +02:00
Alexandre Duret-Lutz
9b5340b90a dstarparse: get rid of the deticated data structures and conversions
* src/dstarparse/dstarparse.yy: Use the twa_graph_ptr to store the
acceptance condition.
* src/dstarparse/dra2ba.cc, src/dstarparse/dstar2tgba.cc,
src/dstarparse/nra2nba.cc, src/dstarparse/nsa2tgba.cc: Delete
all these conversion routines.
* src/dstarparse/public.hh, src/dstarparse/Makefile.am: Adjust.
* src/bin/dstar2tgba.cc: Adjust to call to_generalized_buchi()
instead.
* src/bin/ltlcross.cc: Adjust to call remove_fin() instead.
* src/bin/ltldo.cc: Use the parsed automaton as-is.
* src/tests/degenid.test, src/tests/dstar.test, src/tests/ikwiad.cc:
Adjust test cases.
2015-08-20 21:34:38 +02:00
Alexandre Duret-Lutz
5f0b6dc36c remfin: deal with almost-Rabin automata
I.e., automata that could be Rabin if we add some empty Fin(x) or full
Inf(y) sets.   This way it does not matter when remove_fin() is called
after cleanup_acceptance().

* src/twaalgos/remfin.cc: Implement that.
* src/tests/remfin.test: More tests.
2015-08-20 19:53:43 +02:00
Alexandre Duret-Lutz
ef1bbfc659 remfin: make sure Rabin automata are always converted to Büchi
Because using multiple acceptance condition is pointless in this case.

* src/twaalgos/remfin.cc (ra_to_ba): Extract most of the RA->BA code
into this new function for clarity.
* src/tests/remfin.test: Adjust.
2015-08-20 13:40:10 +02:00
Alexandre Duret-Lutz
4bef219d8f remfin: implement the BA-type check
* src/twaalgos/remfin.cc: Here.
* src/tests/remfin.test: Add a single test.
* src/twa/acc.hh (mark_t::lowest): New function.
2015-08-19 18:23:31 +02:00
Alexandre Duret-Lutz
c5541a2189 * src/twaalgos/mask.hh: Cleanup comments. 2015-08-19 11:00:01 +02:00
Alexandre Duret-Lutz
818b58ec70 ltl: allow \" and \\ in double-quoted atomic propositions
* src/ltlparse/ltlscan.ll: Adjust parser.
* src/ltlvisit/print.cc: Adjust printer.
* src/tests/ltlfilt.test: Add some tests.
* NEWS: Mention it.
2015-08-18 15:47:16 +02:00
Alexandre Duret-Lutz
ce9b2369ed more final keywords
* src/ltlvisit/mutation.cc, src/ltlvisit/relabel.cc,
src/ltlvisit/remove_x.cc: Add final keyword to final classes.
2015-08-18 09:46:13 +02:00
Alexandre Duret-Lutz
0689aa165b silence diagnostics from gcc-snapshot
(Upcoming GCC 6.)

* src/misc/intvcmp2.cc: Here.
* NEWS: Mention it.
2015-08-17 18:56:36 +02:00
Alexandre Duret-Lutz
56cbc3c813 ltlfilt: add --unabbreviate
* src/bin/ltlfilt.cc: Add option --unabbreviate.
* src/tests/ltlfilt.test: Add a test case.
* NEWS: Mention it.
2015-08-17 17:38:47 +02:00
Alexandre Duret-Lutz
d1f915c748 merge tunnabrev/lunnabrev/wmunabbrev into a single function
* src/ltlvisit/lunabbrev.cc, src/ltlvisit/lunabbrev.hh,
src/ltlvisit/tunabbrev.cc, src/ltlvisit/tunabbrev.hh,
src/ltlvisit/wmunabbrev.cc, src/ltlvisit/wmunabbrev.hh: Delete.
* src/ltlvisit/unabbrev.cc, src/ltlvisit/unabbrev.hh: New files.
* src/ltlvisit/Makefile.am: Adjust.
* src/ltlvisit/print.cc, src/tests/equalsf.cc, src/tests/Makefile.am,
src/twaalgos/ltl2taa.cc, wrap/python/spot_impl.i, src/bin/ltlfilt.cc:
Adjust callers.
* src/ltlvisit/contain.cc, src/tests/syntimpl.cc: Remove useless
include.
* wrap/python/tests/formulas.ipynb: New test cases.
* doc/tl/tl.tex: Group all rules in a single section.
* NEWS: Mention it.
2015-08-17 17:38:47 +02:00
Alexandre Duret-Lutz
59202bd5de do not rewrite <-> and -> for Spin LTL output
Fixes #39, reported by Joachim Klein.

* src/ltlvisit/lunabbrev.hh, src/ltlvisit/lunabbrev.cc: Take an option
to specify which of xor/equiv/implies should be rewritten.
* src/ltlvisit/print.cc (print_spin): Rewrite only xor.
* src/tests/ltlfilt.test: Add a test case.
* NEWS: Mention this.
2015-08-14 20:33:56 +02:00
Alexandre Duret-Lutz
ac6b042e2c remove a GCC 4.6 workaround
* src/twa/twagraph.hh (namer): Use a template alias instead
of a trait.
* src/twa/twagraph.cc, src/parseaut/parseaut.yy,
src/twaalgos/ltl2tgba_fm.cc: Adjust.
2015-08-14 15:34:28 +02:00
Alexandre Duret-Lutz
304f2496ea bdddict: remove register_clone_acc
* src/twa/bdddict.cc, src/twa/bdddict.hh: Here.
2015-08-14 15:16:26 +02:00
Alexandre Duret-Lutz
c50d5a82ac fix a spurious assertion
* src/twaalgos/totgba.cc: Here.
* NEWS: Mention it.
2015-08-14 14:13:57 +02:00
Alexandre Duret-Lutz
0143f0d435 sccsimpl: Remove Fin sets between SCCs
We do not remove them in rejecting SCCs (as it might make the SCC
accepting), but we can remove them between SCCs.

Fixes #101.

* src/twaalgos/sccfilter.cc: Here.
* src/tests/sccsimpl.test: Add test case.
* NEWS: Mention this.
2015-08-14 11:42:28 +02:00
Alexandre Duret-Lutz
2eab0344b9 fix latex escaping
* src/ltlvisit/print.cc: Property output the double
quotes in latex mode, not only sclatex.
* src/misc/escape.cc: Fix LaTeX escape to work in math mode.
* src/tests/latex.test: Add a test.
* wrap/python/tests/formulas.ipynb: Adjust expected output
* NEWS: Mention the fix.
2015-08-13 17:25:00 +02:00
Alexandre Duret-Lutz
21ff2d0415 org: Add link to the Python notebooks.
Fixes #100.

* doc/org/tut.org: Link to the notebook.
* src/sanity/ipynb.test: New test, to make sure we do not forget
to document ipython notebook when we add some.
* src/sanity/Makefile.am: Add it and run it.
* NEWS: Mention it.
2015-08-13 16:50:15 +02:00
Alexandre Duret-Lutz
868cabe4f6 * src/bin/man/ltlcross.x: Document %N, %T, %H. 2015-08-13 16:50:15 +02:00
Alexandre Duret-Lutz
288a4ff33c * src/bin/man/ltl2tgba.x: Remove superfluous directory. 2015-08-13 15:13:44 +02:00
Alexandre Duret-Lutz
f7b65001e9 man: improve typesetting and prepare for html output
* src/bin/man/autfilt.x, src/bin/man/dstar2tgba.x,
src/bin/man/ltl2tgba.x, src/bin/man/ltlcross.x,
src/bin/man/ltlgrind.x, src/bin/man/randltl.x, src/bin/man/spot-x.x:
Improve typesetting and cross-references.
* tools/help2man: Adjust to better detect the optional arguments.
Detect options that are not separated from their description by two
spaces.  Argp output some of those.
* tools/man2html.pl: New file.
* Makefile.am: Distribute it.
* src/bin/ltlfilt.cc: Fix description of --define.
* src/bin/ltlgrind.cc: Fix duplicate description for --help and
--version.  Reorder --help output slightly.
* NEWS: Mention the few fixes.
2015-08-13 09:06:21 +02:00
Alexandre Duret-Lutz
3edd55fcd5 print_hoa: diagnose unknown options
* src/twaalgos/hoa.cc: Here.
* src/tests/readsave.test: Test it.
* NEWS: Mention it.
* src/twaalgos/dot.cc, src/twaalgos/neverclaim.cc: Fix the
error message.
2015-07-24 23:23:55 +02:00
Alexandre Duret-Lutz
5cd8c1b8cc * src/twa/twasafracomplement.cc: Remove two unused methods. 2015-07-23 18:05:46 +02:00
Alexandre Duret-Lutz
e76596e1bf acc: fix detection of generalized-Rabin
Fixes #99.

* src/tests/parseaut.test: New test case.
* src/twa/acc.cc (is_generalized_rabin): Fix detection
of Fin(0)|Fin(1)|Fin(2)&Inf(3).
* NEWS: Mention it.
2015-07-23 17:56:42 +02:00
Alexandre Duret-Lutz
750d352fb6 Fix many dead links.
Also change http:// to https:// for url that would automatically
redirect to the later.

* doc/mainpage.dox, doc/org/dstar2tgba.org, doc/org/ltl2tgba.org,
doc/org/ltlcross.org, doc/org/satmin.org, doc/org/tools.org,
src/ltlvisit/dot.hh, src/misc/hashfunc.hh, wrap/python/ajax/trans.html:
Here.
2015-07-17 17:55:15 +02:00
Alexandre Duret-Lutz
29052c4619 bin: better shell quoting for ltlcross and ltldo
* src/bin/common_trans.cc: Use double-quotes when single-quotes
cannot do.
* src/tests/ltlcross3.test: Add a test case.
* NEWS: Mention it.
2015-07-16 22:39:26 +02:00
Alexandre Duret-Lutz
31f5ea75b2 bin: document %% for ltldo and ltlcross
I had no idea this was working...
Reported by Joachim Klein.

* src/bin/common_trans.cc: Document it.
* src/tests/ltlcross3.test: Test it.
2015-07-16 20:01:24 +02:00
Alexandre Duret-Lutz
dafeda6fff bin: make it clear that -B produces state-based acceptance
* src/bin/autfilt.cc, src/bin/dstar2tgba.cc, src/bin/ltl2tgba.cc: Here.
2015-07-16 17:49:21 +02:00
Alexandre Duret-Lutz
e6a5a743f7 remfin: avoid some loops in SCC that do not intersect any Fin
* src/twaalgos/remfin.cc: Here.
2015-07-16 12:07:40 +02:00
Alexandre Duret-Lutz
d8a1dafad1 new conversion for Streett->GBA
* src/twaalgos/totgba.hh, src/twaalgos/totgba.cc: Implement
the new function.
* NEWS: Mention this new function.
* src/bin/man/spot-x.x: Document SPOT_STREETT_CONV_MIN.
* src/tests/ltl2dstar4.test: Add tests.
* src/tests/Makefile.am: Add it.
* src/bin/autfilt.cc: Do do call remove_fin explicitely
when --tgba is used, let the postprocessor do it.
* src/twa/acc.hh: Add shift operators for acceptance marks.
* src/twaalgos/remfin.cc: Use the new algorithm.
* src/twaalgos/sccinfo.cc, src/twaalgos/sccinfo.hh: Add
a new method to supply the acceptance sets visited by an SCC.
2015-07-10 19:43:34 +02:00
Alexandre Duret-Lutz
9af40bf14e sccinfo: remove useless fields from the root stack
* src/twaalgos/sccinfo.cc: Here.
2015-07-09 11:54:55 +02:00
Alexandre Duret-Lutz
344ac0f930 sccinfo: do not accumulate successors during merge
The command in #96 now takes 1min 16s.

* src/twaalgos/sccinfo.cc: Only gather successor SCCs when popping an
SCC.
* wrap/python/tests/automata.ipynb: Adjust.
2015-07-09 10:05:02 +02:00
Alexandre Duret-Lutz
b13b591f11 sccinfo: store live states in a separate stack
Suggested by Etienne.

The command in #96 now takes 9min 35s.

* src/twaalgos/sccinfo.cc, src/twaalgos/sccinfo.hh: Here.
2015-07-09 00:09:58 +02:00
Alexandre Duret-Lutz
c8cf86b081 sccinfo: stop keeping track of conditions between SCCs
They are unused.

* src/twaalgos/sccinfo.cc, src/twaalgos/sccinfo.hh: Do
not keep track of conditions between two SCCs.
* src/twaalgos/minimize.cc, src/twaalgos/ltl2tgba_fm.cc:
Adjust.
2015-07-09 00:09:32 +02:00
Alexandre Duret-Lutz
348e1ee22b * src/bin/ltlcross.cc: Fix 80 columns. 2015-07-01 10:04:09 +02:00
Alexandre Duret-Lutz
56188c7038 ltlcross: be more verbose about product size
This helps diagnosing #96.

* src/bin/ltlcross.cc (process_formula): Print product sizes if
--verbose.
2015-06-30 22:52:43 +02:00
Alexandre Duret-Lutz
5cb19a290b scc_filter: do not remove Fin sets from rejecting SCCs
* src/twaalgos/sccfilter.cc (acc_filter_some, acc_filter_all): Merge
into...
(acc_filter_mask): ... this single parametrized class, and only
remove sets that are only used as Inf.
* src/twa/acc.hh: Add missing operator~.
* src/tests/sccsimpl.test: Add test case.
* src/tests/sccdot.test: Adjust.
* NEWS: Mention the bug.
2015-06-30 17:18:27 +02:00
Alexandre Duret-Lutz
5d9e7d1f93 ltl: fix detection of some siPSL formulas
* src/ltlast/bunop.cc: Fix detection of f[:*2] as siPSL if f is siPSL
* src/tests/kind.test: Test it.
* NEWS: Mention it.
2015-06-23 19:27:30 +02:00
Alexandre Duret-Lutz
0c4eccd8c7 * src/twaalgos/ltl2tgba_fm.hh: Typo in comment. 2015-06-21 13:47:16 +02:00
Alexandre Duret-Lutz
b327565ca6 doxygen: fix membership to misc_tools module
* src/misc/bareword.hh, src/misc/bitvect.hh, src/misc/escape.hh,
src/misc/hashfunc.hh, src/misc/intvcmp2.hh, src/misc/intvcomp.hh,
src/misc/random.hh, src/misc/timer.hh, src/misc/tmpfile.hh: Use ingroup
rather than addtogroup.
2015-06-21 13:42:15 +02:00
Alexandre Duret-Lutz
813c3799c0 ltl: remove is_eltl_formula()
* doc/tl/tl.tex, src/ltlast/atomic_prop.cc, src/ltlast/binop.cc,
src/ltlast/bunop.cc, src/ltlast/constant.cc, src/ltlast/formula.cc,
src/ltlast/formula.hh, src/ltlast/multop.cc, src/ltlast/unop.cc:
Remove is_eltl_formula().
* src/tests/kind.test: Adjust.
2015-06-20 15:21:31 +02:00
Alexandre Duret-Lutz
b7fbf72461 bin: fix documentation of degeneralization option
Reported by Jan Strejček.

* src/bin/spot-x.cc: Fix documentation.
* src/twaalgos/degen.cc, src/twaalgos/degen.hh: Fix comments.
2015-06-16 11:06:32 +02:00
Alexandre Duret-Lutz
b2e812b105 ltlcross: skip product that require too much acceptance sets
Reported by Fanda when he was testing ltl3dra 0.2.2.

* src/bin/ltlcross.cc: Here.
* src/tests/ltl3dra.test: New file.
* src/tests/Makefile.am: Add it.
2015-06-15 23:35:31 +02:00
Alexandre Duret-Lutz
7ea9ebe07a bin: typo in ltl3dra shorthand
Reported by Fanda.

* src/bin/common_trans.cc: Here.
2015-06-15 18:42:27 +02:00
Alexandre Duret-Lutz
17dc2f8654 Rename src/tests/ltl2tgba as src/tests/ikwiad.
Fixes #23.

* src/tests/ltl2tgba.cc: Rename as ...
* src/tests/ikwiad.cc: ... this.
* src/tests/Makefile.am, src/tests/babiak.test, src/tests/checkta.cc,
src/tests/complementation.test, src/tests/cycles.test,
src/tests/dbacomp.test, src/tests/degendet.test,
src/tests/degenid.test, src/tests/det.test, src/tests/dfs.test,
src/tests/dstar.test, src/tests/dupexp.test, src/tests/emptchke.test,
src/tests/kv.test, src/tests/ltl2neverclaim-lbtt.test,
src/tests/ltl2neverclaim.test, src/tests/ltl2tgba.test,
src/tests/ltlcounter.test, src/tests/ltlcross.test,
src/tests/neverclaimread.test, src/tests/obligation.test,
src/tests/parseaut.test, src/tests/randaut.test,
src/tests/randpsl.test, src/tests/renault.test,
src/tests/satmin2.test, src/tests/sccsimpl.test, src/tests/sim2.test,
src/tests/simdet.test, src/tests/spotlbtt.test, src/tests/wdba.test,
src/tests/wdba2.test, bench/emptchk/README, bench/emptchk/defs.in,
bench/ltlclasses/run, bench/ltlcounter/run, bench/wdba/run: Adjust.
2015-06-12 20:52:34 +02:00
Alexandre Duret-Lutz
af8634d8c4 graph: rename num_transitions() as num_edges()
And in fact, rename most "trans*" as "edges*", because that what they
really are.

* src/bin/autfilt.cc, src/bin/ltlcross.cc, src/bin/randaut.cc,
src/dstarparse/dra2ba.cc, src/dstarparse/dstarparse.yy,
src/dstarparse/nra2nba.cc, src/dstarparse/nsa2tgba.cc,
src/graph/graph.hh, src/graph/ngraph.hh, src/ltlvisit/exclusive.cc,
src/parseaut/parseaut.yy, src/tests/complementation.cc,
src/tests/graph.cc, src/tests/ltl2tgba.cc, src/tests/ngraph.cc,
src/tests/twagraph.cc, src/twa/twagraph.cc, src/twa/twagraph.hh,
src/twa/twamask.hh, src/twaalgos/are_isomorphic.cc,
src/twaalgos/are_isomorphic.hh, src/twaalgos/canonicalize.cc,
src/twaalgos/cleanacc.cc, src/twaalgos/complete.cc,
src/twaalgos/compsusp.cc, src/twaalgos/cycles.cc,
src/twaalgos/degen.cc, src/twaalgos/dot.cc, src/twaalgos/dtbasat.cc,
src/twaalgos/dtgbacomp.cc, src/twaalgos/dtgbasat.cc,
src/twaalgos/dupexp.cc, src/twaalgos/emptiness.cc,
src/twaalgos/isunamb.cc, src/twaalgos/isweakscc.cc,
src/twaalgos/ltl2tgba_fm.cc, src/twaalgos/mask.hh,
src/twaalgos/minimize.cc, src/twaalgos/postproc.cc,
src/twaalgos/powerset.cc, src/twaalgos/product.cc,
src/twaalgos/randomgraph.cc, src/twaalgos/randomize.cc,
src/twaalgos/randomize.hh, src/twaalgos/relabel.cc,
src/twaalgos/remfin.cc, src/twaalgos/safety.cc, src/twaalgos/sbacc.cc,
src/twaalgos/sccfilter.cc, src/twaalgos/sepsets.cc,
src/twaalgos/simulation.cc, src/twaalgos/stutter.cc,
src/twaalgos/totgba.cc: Rename these.
2015-06-11 23:52:02 +02:00
Alexandre Duret-Lutz
6f500f3f50 twa: forward num_sets() to acc_.
* src/twa/twa.hh (num_sets): New method.  Delegating to acc_.
* src/twa/twagraph.hh, src/twa/twaproduct.cc, src/twa/twaproxy.cc,
src/twaalgos/degen.cc, src/twaalgos/dot.cc, src/twaalgos/dtgbacomp.cc,
src/twaalgos/dtgbasat.cc, src/twaalgos/gv04.cc, src/twaalgos/hoa.cc,
src/twaalgos/lbtt.cc, src/twaalgos/magic.cc, src/twaalgos/mask.cc,
src/twaalgos/ndfs_result.hxx, src/twaalgos/postproc.cc,
src/twaalgos/powerset.cc, src/twaalgos/product.cc,
src/twaalgos/remfin.cc, src/twaalgos/se05.cc,
src/twaalgos/simulation.cc, src/twaalgos/stats.cc,
src/twaalgos/stutter.cc, src/twaalgos/tau03.cc,
src/twaalgos/tau03opt.cc, src/twaalgos/totgba.cc: Simplify
acc().num_sets() into num_sets().
2015-06-11 21:55:23 +02:00
Alexandre Duret-Lutz
a86391ab77 hoaparse: rename to parseaut
Because this parser is not specific to HOA anymore.

* src/hoaparse/Makefile.am, src/hoaparse/fmterror.cc,
src/hoaparse/hoaparse.yy, src/hoaparse/parsedecl.hh,
src/parseaut/public.hh, src/hoaparse/hoascan.ll,
src/tests/hoaparse.test: Rename to...
* src/parseaut/Makefile.am, src/parseaut/fmterror.cc,
src/parseaut/parseaut.yy, src/parseaut/parsedecl.hh,
src/hoaparse/public.hh, src/parseaut/scanaut.ll,
src/tests/parseaut.test: ... these, and also adjust the name internally.
For instance hoa_aut_ptr is now parsed_aut_ptr; hoa_stream_parser is now
automaton_stream_parser, and hoa_parse() has become parse_aut().
* NEWS, README, configure.ac, doc/org/tut20.org, src/Makefile.am,
src/bin/autfilt.cc, src/bin/common_aoutput.cc,
src/bin/common_aoutput.hh, src/bin/common_conv.cc,
src/bin/ltlcross.cc, src/bin/ltldo.cc, src/tests/Makefile.am,
src/tests/complementation.cc, src/tests/ltl2tgba.cc,
src/tests/readsave.test, wrap/python/ajax/spot.in,
wrap/python/spot.py, wrap/python/spot_impl.i,
wrap/python/tests/automata-io.ipynb, wrap/python/tests/parsetgba.py:
Adjust.
2015-06-11 13:31:13 +02:00