* wrap/python/cgi/ltl2tgba.in: Add "Formula Simplications" options.
* wrap/python/spot.i: Wrap src/ltlvisite/reduce.hh.
This commit is contained in:
parent
b42cdc0d8f
commit
bd69b16e46
3 changed files with 32 additions and 0 deletions
|
|
@ -1,5 +1,8 @@
|
||||||
2004-06-23 Alexandre Duret-Lutz <adl@gnu.org>
|
2004-06-23 Alexandre Duret-Lutz <adl@gnu.org>
|
||||||
|
|
||||||
|
* wrap/python/cgi/ltl2tgba.in: Add "Formula Simplications" options.
|
||||||
|
* wrap/python/spot.i: Wrap src/ltlvisite/reduce.hh.
|
||||||
|
|
||||||
* src/ltlvisit/simpfg.cc, src/ltlvisit/simpfg.hh: New files,
|
* src/ltlvisit/simpfg.cc, src/ltlvisit/simpfg.hh: New files,
|
||||||
extracted from ...
|
extracted from ...
|
||||||
* src/ltlvisit/lunabbrev.cc: ... this one, which now work as documented
|
* src/ltlvisit/lunabbrev.cc: ... this one, which now work as documented
|
||||||
|
|
|
||||||
|
|
@ -203,6 +203,11 @@ options_common = [
|
||||||
('show_never_claim', 'output Spin never claim', 0),
|
('show_never_claim', 'output Spin never claim', 0),
|
||||||
('show_lbtt', 'convert automaton for LBTT', 0),
|
('show_lbtt', 'convert automaton for LBTT', 0),
|
||||||
]
|
]
|
||||||
|
options_reduce = [
|
||||||
|
('reduce_basics', 'basic rewritings', 1),
|
||||||
|
('reduce_syntimpl', 'syntactic implication', 1),
|
||||||
|
('reduce_eventuniv', 'eventuality and universality', 1),
|
||||||
|
]
|
||||||
options_debug = [
|
options_debug = [
|
||||||
('show_parse', 'show traces during parsing', 0),
|
('show_parse', 'show traces during parsing', 0),
|
||||||
('show_dictionnary', 'print BDD dictionary', 0),
|
('show_dictionnary', 'print BDD dictionary', 0),
|
||||||
|
|
@ -339,6 +344,7 @@ for opt, desc, color in translators:
|
||||||
add_options('', 0, color, globals()['options_' + opt])
|
add_options('', 0, color, globals()['options_' + opt])
|
||||||
|
|
||||||
add_options("Common Options", 1, '', options_common)
|
add_options("Common Options", 1, '', options_common)
|
||||||
|
add_options("Formula Simplications", 1, '', options_reduce)
|
||||||
add_options("Debugging Options", 1, '', options_debug)
|
add_options("Debugging Options", 1, '', options_debug)
|
||||||
|
|
||||||
print '<TABLE>'
|
print '<TABLE>'
|
||||||
|
|
@ -351,6 +357,8 @@ for d in range(depth):
|
||||||
for i in width:
|
for i in width:
|
||||||
if d < len(column[i]):
|
if d < len(column[i]):
|
||||||
print column[i][d]
|
print column[i][d]
|
||||||
|
else:
|
||||||
|
print '<TD></TD>'
|
||||||
print '</TR>'
|
print '</TR>'
|
||||||
print '</TABLE>'
|
print '</TABLE>'
|
||||||
|
|
||||||
|
|
@ -394,6 +402,25 @@ if show_formula_png:
|
||||||
del outfile
|
del outfile
|
||||||
render_dot(imgprefix + '-f')
|
render_dot(imgprefix + '-f')
|
||||||
|
|
||||||
|
opt = spot.Reduce_None
|
||||||
|
if reduce_basics:
|
||||||
|
opt = opt + spot.Reduce_Basics
|
||||||
|
if reduce_syntimpl:
|
||||||
|
opt = opt + spot.Reduce_Syntactic_Implications
|
||||||
|
if reduce_eventuniv:
|
||||||
|
opt = opt + spot.Reduce_Eventuality_And_Universality
|
||||||
|
if opt != spot.Reduce_None:
|
||||||
|
f2 = spot.reduce(f, opt)
|
||||||
|
spot.destroy(f)
|
||||||
|
f = f2
|
||||||
|
print "<p>Reduced formula is<code>", f, "</code></p>"
|
||||||
|
|
||||||
|
if show_formula_png:
|
||||||
|
outfile = spot.ofstream(imgprefix + '-f2.txt')
|
||||||
|
spot.dotty(outfile, f)
|
||||||
|
del outfile
|
||||||
|
render_dot(imgprefix + '-f2')
|
||||||
|
|
||||||
print '<H2>Automaton</H2>'
|
print '<H2>Automaton</H2>'
|
||||||
|
|
||||||
dict = spot.bdd_dict()
|
dict = spot.bdd_dict()
|
||||||
|
|
|
||||||
|
|
@ -56,6 +56,7 @@
|
||||||
#include "ltlvisit/dump.hh"
|
#include "ltlvisit/dump.hh"
|
||||||
#include "ltlvisit/lunabbrev.hh"
|
#include "ltlvisit/lunabbrev.hh"
|
||||||
#include "ltlvisit/nenoform.hh"
|
#include "ltlvisit/nenoform.hh"
|
||||||
|
#include "ltlvisit/reduce.hh"
|
||||||
#include "ltlvisit/tostring.hh"
|
#include "ltlvisit/tostring.hh"
|
||||||
#include "ltlvisit/tunabbrev.hh"
|
#include "ltlvisit/tunabbrev.hh"
|
||||||
|
|
||||||
|
|
@ -110,6 +111,7 @@ using namespace spot;
|
||||||
%include "ltlvisit/dump.hh"
|
%include "ltlvisit/dump.hh"
|
||||||
%include "ltlvisit/lunabbrev.hh"
|
%include "ltlvisit/lunabbrev.hh"
|
||||||
%include "ltlvisit/nenoform.hh"
|
%include "ltlvisit/nenoform.hh"
|
||||||
|
%include "ltlvisit/reduce.hh"
|
||||||
%include "ltlvisit/tostring.hh"
|
%include "ltlvisit/tostring.hh"
|
||||||
%include "ltlvisit/tunabbrev.hh"
|
%include "ltlvisit/tunabbrev.hh"
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue