20 #ifndef SPOT_TGBAALGOS_SCC_HH
21 # define SPOT_TGBAALGOS_SCC_HH
26 #include "tgba/tgba.hh"
28 #include "misc/hash.hh"
29 #include "misc/bddlt.hh"
66 std::ostream&
dump(std::ostream& out)
const;
73 typedef std::map<unsigned, bdd> succ_type;
74 typedef std::set<bdd, bdd_less_than> cond_set;
88 const tgba* get_aut()
const;
95 unsigned scc_count()
const;
100 unsigned initial()
const;
105 const succ_type& succ(
unsigned n)
const;
112 bool trivial(
unsigned n)
const;
117 bool accepting(
unsigned n)
const;
122 const cond_set& cond_set_of(
unsigned n)
const;
134 bdd ap_set_of(
unsigned n)
const;
142 bdd aprec_set_of(
unsigned n)
const;
147 bdd acc_set_of(
unsigned n)
const;
153 bdd useful_acc_of(
unsigned n)
const;
161 const std::list<const state*>& states_of(
unsigned n)
const;
169 const state* one_state_of(
unsigned n)
const;
174 unsigned scc_of_state(
const state* s)
const;
177 unsigned self_loops()
const;
180 bool has_strong_scc()
const;
183 bool has_weak_scc()
const;
186 bool has_terminal_scc()
const;
188 bool weak_subautomaton(
unsigned n)
const;
189 bool terminal_subautomaton(
unsigned n)
const;
190 bool strong_hard(
unsigned n)
const;
191 bool weak_hard(
unsigned n)
const;
192 bool weak(
unsigned n)
const;
193 bool terminal(
unsigned n)
const;
196 bdd update_supp_rec(
unsigned state);
197 int relabel_component();
198 void update_strength();
199 bool intern_is_terminal(
unsigned n);
200 bool intern_is_weak(
unsigned n);
204 scc(
int index) : index(index), acc(bddfalse),
205 supp(bddtrue), supp_rec(bddfalse),
206 trivial(
true), useful_acc(bddfalse),
207 is_terminal(
false), is_weak(
false),
244 bool is_terminal_subautomaton;
245 bool is_weak_subautomaton;
247 bool is_strong_subautomaton;
252 typedef std::list<scc> stack_type;
254 std::stack<bdd> arc_acc_;
256 std::stack<bdd> arc_cond_;
258 typedef Sgi::hash_map<
const state*, int,
265 typedef std::pair<const spot::state*, tgba_succ_iterator*> pair_state_iter;
266 std::stack<pair_state_iter> todo_;
275 typedef std::vector<scc> scc_map_type;
276 scc_map_type scc_map_;
279 unsigned self_loops_;
283 build_scc_stats(
const tgba* a);
285 build_scc_stats(
const scc_map& m);
287 SPOT_API std::ostream&
288 dump_scc_dot(
const tgba* a, std::ostream& out,
bool verbose =
false);
289 SPOT_API std::ostream&
290 dump_scc_dot(
const scc_map& m, std::ostream& out,
bool verbose =
false);
293 #endif // SPOT_TGBAALGOS_SCC_HH
this class acts like a wrapper to the C code of the open_set.
Definition: public.hh:32
bdd acc
Definition: scc.hh:213
An Equivalence Relation for state*.
Definition: state.hh:139
std::vector< bool > useless_scc_map
A map of the useless SCCs.
Definition: scc.hh:59
succ_type succ
Successor SCC.
Definition: scc.hh:223
Abstract class for states.
Definition: state.hh:40
unsigned acc_paths
Definition: scc.hh:51
bdd useful_acc
Set of acceptance combinations used in the SCC.
Definition: scc.hh:236
cond_set conds
Set of conditions used in the SCC.
Definition: scc.hh:217
bdd useful_acc
Definition: scc.hh:64
Hash Function for state*.
Definition: state.hh:164
A Transition-based Generalized Büchi Automaton.
Definition: tgba.hh:67
SPOT_API std::ostream & dump(std::ostream &os, const formula *f)
Dump a formula tree.
unsigned dead_paths
Definition: scc.hh:55
unsigned scc_total
Total number of SCCs.
Definition: scc.hh:37
bdd supp_rec
Conjunction of atomic propositions used in the SCC.
Definition: scc.hh:221
unsigned dead_scc
Definition: scc.hh:44
bool trivial
Trivial SCC have one state and no self-loops.
Definition: scc.hh:225
unsigned acc_scc
Total number of accepting SCC.
Definition: scc.hh:39
std::list< const state * > states
States of the component.
Definition: scc.hh:215
bdd supp
Conjunction of atomic propositions used in the SCC.
Definition: scc.hh:219
Build a map of Strongly Connected components in in a TGBA.
Definition: scc.hh:70