spot: Implement dt*a_sat_minimize_assume(...) methods

* python/spot/__init__.py: Add 'assume' option.
* spot/misc/satsolver.cc: Add function to handle assumptions.
* spot/misc/satsolver.hh: Declare assumption function.
* spot/twaalgos/dtbasat.cc: Implement dtba_sat_minimize_assume.
* spot/twaalgos/dtbasat.hh: Declare it.
* spot/twaalgos/dtwasat.cc: Implement dtwa_sat_minimize_assume and
handle options.
* spot/twaalgos/dtwasat.hh: Declare it.
* spot/twaalgos/postproc.cc: Handle options.
* spot/twaalgos/postproc.hh: Use param_ var for incr and assume.
* tests/core/satmin.test: Add tests for the new function.
* tests/core/satmin2.test: Add tests for the new function.
* tests/python/satmin.py: Add tests for the new function.
This commit is contained in:
Alexandre GBAGUIDI AISSE 2016-10-11 16:08:46 +02:00
parent ee17c2dee4
commit 9a204b770f
12 changed files with 1021 additions and 69 deletions

View file

@ -81,4 +81,23 @@ namespace spot
bool state_based = false,
int max_states = -1,
int param = 2);
/// \brief Attempt to minimize a deterministic TBA incrementally with a SAT
/// solver.
///
/// This acts like dtba_sat_synthetize() and obtains a first minimized
/// automaton. Then, it adds <param> assumptions, such that each assumption
/// removes a new state and implies the previous assumptions. A first
/// resolution is attempted assuming the last assumption (thus involving all
/// the previous ones). If the problem is SAT several stages have just been
/// won and all this process is restarted. Otherwise, we know that the
/// minimal automaton can be obtained with fewer assumption. This
/// automaton is found dichotomously.
///
/// If no smaller TBA exist, this returns a null pointer.
SPOT_API twa_graph_ptr
dtba_sat_minimize_assume(const const_twa_graph_ptr& a,
bool state_based = false,
int max_states = -1,
int param = 6);
}