spot
1.0
|
Classes | |
class | spot::postprocessor |
Wrap TGBA/BA/Monitor post-processing algorithms in an easy interface. More... |
Enumerations | |
enum | spot::reduce_tgba_options { spot::Reduce_None = 0, spot::Reduce_quotient_Dir_Sim = 1, spot::Reduce_transition_Dir_Sim = 2, spot::Reduce_quotient_Del_Sim = 4, spot::Reduce_transition_Del_Sim = 8, spot::Reduce_Scc = 16, spot::Reduce_All = -1U } |
Options for reduce. More... |
Functions | |
sba_explicit_number * | spot::minimize_monitor (const tgba *a) |
Construct a minimal deterministic monitor. | |
sba_explicit_number * | spot::minimize_wdba (const tgba *a) |
Minimize a Büchi automaton in the WDBA class. | |
tgba * | spot::minimize_obligation (const tgba *aut_f, const ltl::formula *f=0, const tgba *aut_neg_f=0, bool reject_bigger=false) |
Minimize an automaton if it represents an obligation property. | |
const tgba * | spot::reduc_tgba_sim (const tgba *a, int opt=Reduce_All) |
Simplify the automaton using a simulation relation. | |
tgba * | spot::simulation (const tgba *automaton) |
Attempt to reduce the automaton by direct simulation. | |
tgba * | spot::cosimulation (const tgba *automaton) |
Attempt to reduce the automaton by reverse simulation. | |
tgba * | spot::iterated_simulations (const tgba *automaton) |
Iterate simulation() and cosimulation(). |
Options for reduce.
tgba* spot::cosimulation | ( | const tgba * | automaton | ) |
Attempt to reduce the automaton by reverse simulation.
When the prefixes (letter and acceptance conditions) leading to one state are included in the prefixes leading to one, the former state can be merged into the latter. Reverse simulation is discussed in the following paper, bu following paper, but generalized to handle TGBA directly. @verbatim
/// { somenzi.00.cav, /// author = {Fabio Somenzi and Roderick Bloem}, /// title = {Efficient {B"u}chi Automata for {LTL} Formul{}}, /// booktitle = {Proceedings of the 12th International Conference on /// Computer Aided Verification (CAV'00)}, /// pages = {247–263}, /// year = {2000}, /// volume = {1855}, /// series = {Lecture Notes in Computer Science}, /// address = {Chicago, Illinois, USA}, /// publisher = {Springer-Verlag} /// } ///
Our reconstruction of the quotient automaton based on this prefix-inclusion relation will also improve codeterminism. We recommend to call scc_filter() to first simplify the automaton that should be reduced by cosimulation. Reducing an automaton by reverse simulation (1) does not change the number of acceptance conditions so the resulting automaton may have superfluous acceptance conditions, and (2) can create SCCs that are terminal and non-accepting. For these reasons, you should call scc_filer() to prune useless SCCs and acceptance conditions afterwards. If you plan to run both simulation() and cosimulation() on the same automaton, you should start with simulation() so that the codeterminism improvements achieved by cosimulation() does not hinder the determinism improvements attempted by simulation(). (This of course assumes that you prefer determinism over codeterminism.) \param automaton the automaton to simulate. \return a new automaton which is at worst a copy of the received one
tgba* spot::iterated_simulations | ( | const tgba * | automaton | ) |
Iterate simulation() and cosimulation().
Runs simulation(), cosimulation(), and scc_filter() in a loop, until the automaton does not change size (states and transitions).
We recommend to call scc_filter() to first simplify the automaton that should be reduced by iterated simulations, since this algorithm will only call scc_filter() at the end of the loop.
automaton | the automaton to simulate. |
sba_explicit_number* spot::minimize_monitor | ( | const tgba * | a | ) |
Construct a minimal deterministic monitor.
The automaton will be converted into minimal deterministic monitor. All useless SCCs should have been previously removed (using scc_filter() for instance). Then the automaton will be determinized and minimized using the standard DFA construction as if all states were accepting states. For more detail about monitors, see the following paper: @verbatim
/// { tabakov.10.rv, /// author = {Deian Tabakov and Moshe Y. Vardi}, /// title = {Optimized Temporal Monitors for SystemC{$^*$}}, /// booktitle = {Proceedings of the 10th International Conferance /// on Runtime Verification}, /// pages = {436–451}, /// year = 2010, /// volume = {6418}, /// series = {Lecture Notes in Computer Science}, /// month = nov, /// publisher = {Spring-Verlag} /// } /// (Note: although the above paper uses Spot, this function did not exist in Spot at that time.)
a | the automaton to convert into a minimal deterministic monitor |
tgba* spot::minimize_obligation | ( | const tgba * | aut_f, |
const ltl::formula * | f = 0 , |
||
const tgba * | aut_neg_f = 0 , |
||
bool | reject_bigger = false |
||
) |
Minimize an automaton if it represents an obligation property.
This function attempts to minimize the automaton \a aut_f using the algorithm implemented in the minimize_wdba() function, and presented by the following paper: @verbatim
/// { dax.07.atva, /// author = {Christian Dax and Jochen Eisinger and Felix Klaedtke}, /// title = {Mechanizing the Powerset Construction for Restricted /// Classes of {$$}-Automata}, /// year = 2007, /// series = {Lecture Notes in Computer Science}, /// publisher = {Springer-Verlag}, /// volume = 4762, /// booktitle = {Proceedings of the 5th International Symposium on /// Automated Technology for Verification and Analysis /// (ATVA'07)}, /// editor = {Kedar S. Namjoshi and Tomohiro Yoneda and Teruo Higashino /// and Yoshio Okamura}, /// month = oct /// } ///
Because it is hard to determine if an automaton corresponds to an obligation property, you should supply either the formula \a f expressed by the automaton \a aut_f, or \a aut_neg_f the negation of the automaton \a aut_neg_f. \param aut_f the automaton to minimize \param f the LTL formula represented by the automaton \a aut_f \param aut_neg_f an automaton representing the negation of \a aut_f \return a new tgba if the automaton could be minimized, aut_f if the automaton cannot be minimized, 0 if we do not if if the minimization is correct because neither \a f nor \a aut_neg_f were supplied. The function proceeds as follows. If the formula \a f or the automaton \a aut can easily be proved to represent an obligation formula, then the result of <code>minimize(aut)</code> is returned. Otherwise, if \a aut_neg_f was not supplied but \a f was, \a aut_neg_f is built from the negation of \a f. Then we check that <code>product(aut,!minimize(aut_f))</code> and <code> product(aut_neg_f,minize(aut))</code> are both empty. If they are, the the minimization was sound. (See the paper for full details.) If \a reject_bigger is set, this function will return the input automaton \a aut_f when the minimized WDBA has more states than the input automaton. (More states are possible because of determinization step during minimize_wdba().) Note that checking the size of the minimized WDBA occurs before ensuring that the minimized WDBA is correct.
sba_explicit_number* spot::minimize_wdba | ( | const tgba * | a | ) |
Minimize a Büchi automaton in the WDBA class.
This takes a TGBA whose language is representable by a Weak Deterministic Büchi Automaton, and construct a minimal WDBA for this language. This essentially chains three algorithms: determinization, acceptance adjustment (Löding's coloring algorithm), and minimization (using a Moore-like approache). If the input automaton does not represent a WDBA language, the resulting automaton is still a WDBA, but it will not be equivalent to the original automaton. Use the minimize_obligation() function if you are not sure whether it is safe to call this function. Please see the following paper for a discussion of this technique. @verbatim
/// { dax.07.atva, /// author = {Christian Dax and Jochen Eisinger and Felix Klaedtke}, /// title = {Mechanizing the Powerset Construction for Restricted /// Classes of {$$}-Automata}, /// year = 2007, /// series = {Lecture Notes in Computer Science}, /// publisher = {Springer-Verlag}, /// volume = 4762, /// booktitle = {Proceedings of the 5th International Symposium on /// Automated Technology for Verification and Analysis /// (ATVA'07)}, /// editor = {Kedar S. Namjoshi and Tomohiro Yoneda and Teruo Higashino /// and Yoshio Okamura}, /// month = oct /// } ///
const tgba* spot::reduc_tgba_sim | ( | const tgba * | a, |
int | opt = Reduce_All |
||
) |
Simplify the automaton using a simulation relation.
Do not use this obsolete function.
a | the automata to reduce |
opt | a conjonction of spot::reduce_tgba_options specifying which optimizations to apply. Actually any simulation-related flag will cause direct simulation to be applied. |
tgba* spot::simulation | ( | const tgba * | automaton | ) |
Attempt to reduce the automaton by direct simulation.
When the suffixes (letter and acceptance conditions) reachable from one state are included in the suffixes seen by another one, the former state can be merged into the latter. The algorithm is based on the following paper, but generalized to handle TGBA directly. @verbatim
/// { etessami.00.concur, /// author = {Kousha Etessami and Gerard J. Holzmann}, /// title = {Optimizing {B"u}chi Automata}, /// booktitle = {Proceedings of the 11th International Conference on /// Concurrency Theory (Concur'00)}, /// pages = {153–167}, /// year = {2000}, /// editor = {C. Palamidessi}, /// volume = {1877}, /// series = {Lecture Notes in Computer Science}, /// address = {Pennsylvania, USA}, /// publisher = {Springer-Verlag} /// } ///
Our reconstruction of the quotient automaton based on this suffix-inclusion relation will also improve determinism. We recommend to call scc_filter() to first simplify the automaton that should be reduced by simulation. Reducing an automaton by simulation does not change the number of acceptance conditions. In some rare cases (1 out of more than 500 in our benchmark), the reduced automaton will use more acceptance conditions than necessary, and running scc_filter() again afterwards will remove these superfluous conditions. \param automaton the automaton to simulate. \return a new automaton which is at worst a copy of the received one