spot  0.8.3
Classes | Public Types | Public Member Functions | Protected Types | Protected Member Functions | Protected Attributes
spot::scc_map Class Reference

Build a map of Strongly Connected components in in a TGBA. More...

#include <tgbaalgos/scc.hh>

Collaboration diagram for spot::scc_map:
Collaboration graph
[legend]

List of all members.

Classes

struct  scc

Public Types

typedef std::map< unsigned, bdd > succ_type
typedef std::set< bdd,
bdd_less_than
cond_set

Public Member Functions

 scc_map (const tgba *aut)
 Constructor.
 ~scc_map ()
void build_map ()
 Actually compute the graph of strongly connected components.
const tgbaget_aut () const
 Get the automaton for which the map has been constructed.
unsigned scc_count () const
 Get the number of SCC in the automaton.
unsigned initial () const
 Get number of the SCC containing the initial state.
const succ_typesucc (unsigned n) const
 Successor SCCs of a SCC.
bool trivial (unsigned n) const
 Return whether an SCC is trivial.
bool accepting (unsigned n) const
 Return whether an SCC is accepting.
const cond_setcond_set_of (unsigned n) const
 Return the set of conditions occurring in an SCC.
bdd ap_set_of (unsigned n) const
 Return the set of atomic properties occurring in an SCC.
bdd aprec_set_of (unsigned n) const
 Return the set of atomic properties reachable from this SCC.
bdd acc_set_of (unsigned n) const
 Return the set of acceptance conditions occurring in an SCC.
bdd useful_acc_of (unsigned n) const
 Return the set of useful acceptance conditions of SCC n.
const std::list< const state * > & states_of (unsigned n) const
 Return the set of states of an SCC.
const stateone_state_of (unsigned n) const
 Return one state of an SCC.
unsigned scc_of_state (const state *s) const
 Return the number of the SCC a state belongs too.
unsigned self_loops () const
 Return the number of self loops in the automaton.

Protected Types

typedef std::list< sccstack_type
typedef Sgi::hash_map< const
state *, int, state_ptr_hash,
state_ptr_equal
hash_type
typedef std::pair< const
spot::state
*, tgba_succ_iterator * > 
pair_state_iter
typedef std::vector< sccscc_map_type

Protected Member Functions

bdd update_supp_rec (unsigned state)
int relabel_component ()

Protected Attributes

const tgbaaut_
stack_type root_
std::stack< bdd > arc_acc_
std::stack< bdd > arc_cond_
hash_type h_
int num_
std::stack< pair_state_itertodo_
scc_map_type scc_map_
unsigned self_loops_

Detailed Description

Build a map of Strongly Connected components in in a TGBA.


Member Typedef Documentation

typedef std::set<bdd, bdd_less_than> spot::scc_map::cond_set
typedef std::pair<const spot::state*, tgba_succ_iterator*> spot::scc_map::pair_state_iter [protected]
typedef std::vector<scc> spot::scc_map::scc_map_type [protected]
typedef std::list<scc> spot::scc_map::stack_type [protected]
typedef std::map<unsigned, bdd> spot::scc_map::succ_type

Constructor & Destructor Documentation

spot::scc_map::scc_map ( const tgba aut)

Constructor.

This will note compute the map initially. You should call build_map() to do so.


Member Function Documentation

bdd spot::scc_map::acc_set_of ( unsigned  n) const

Return the set of acceptance conditions occurring in an SCC.

Precondition:
This should only be called once build_map() has run.
bool spot::scc_map::accepting ( unsigned  n) const

Return whether an SCC is accepting.

Precondition:
This should only be called once build_map() has run.
bdd spot::scc_map::ap_set_of ( unsigned  n) const

Return the set of atomic properties occurring in an SCC.

Returns:
a BDD that is a conjuction of all atomic properties occurring on the transitions in the SCC n.
Precondition:
This should only be called once build_map() has run.
bdd spot::scc_map::aprec_set_of ( unsigned  n) const

Return the set of atomic properties reachable from this SCC.

Returns:
a BDD that is a conjuction of all atomic properties occurring on the transitions reachable from this SCC n.
Precondition:
This should only be called once build_map() has run.

Actually compute the graph of strongly connected components.

const cond_set& spot::scc_map::cond_set_of ( unsigned  n) const

Return the set of conditions occurring in an SCC.

Precondition:
This should only be called once build_map() has run.
const tgba* spot::scc_map::get_aut ( ) const

Get the automaton for which the map has been constructed.

unsigned spot::scc_map::initial ( ) const

Get number of the SCC containing the initial state.

Precondition:
This should only be called once build_map() has run.
const state* spot::scc_map::one_state_of ( unsigned  n) const

Return one state of an SCC.

The state in the returned list is still owned by the scc_map instance. It should NOT be destroyed by the client code.

Precondition:
This should only be called once build_map() has run.
int spot::scc_map::relabel_component ( ) [protected]
unsigned spot::scc_map::scc_count ( ) const

Get the number of SCC in the automaton.

SCCs are labelled from 0 to scc_count()-1.

Precondition:
This should only be called once build_map() has run.
unsigned spot::scc_map::scc_of_state ( const state s) const

Return the number of the SCC a state belongs too.

Precondition:
This should only be called once build_map() has run.
unsigned spot::scc_map::self_loops ( ) const

Return the number of self loops in the automaton.

const std::list<const state*>& spot::scc_map::states_of ( unsigned  n) const

Return the set of states of an SCC.

The states in the returned list are still owned by the scc_map instance. They should NOT be destroyed by the client code.

Precondition:
This should only be called once build_map() has run.
const succ_type& spot::scc_map::succ ( unsigned  n) const

Successor SCCs of a SCC.

Precondition:
This should only be called once build_map() has run.
bool spot::scc_map::trivial ( unsigned  n) const

Return whether an SCC is trivial.

Trivial SCCs have one state and no self-loop.

Precondition:
This should only be called once build_map() has run.
bdd spot::scc_map::update_supp_rec ( unsigned  state) [protected]
bdd spot::scc_map::useful_acc_of ( unsigned  n) const

Return the set of useful acceptance conditions of SCC n.

Useless acceptances conditions are always implied by other acceptances conditions. This returns all the other acceptance conditions.


Member Data Documentation

std::stack<bdd> spot::scc_map::arc_acc_ [protected]
std::stack<bdd> spot::scc_map::arc_cond_ [protected]
const tgba* spot::scc_map::aut_ [protected]
int spot::scc_map::num_ [protected]
unsigned spot::scc_map::self_loops_ [protected]
std::stack<pair_state_iter> spot::scc_map::todo_ [protected]

The documentation for this class was generated from the following file:

Please comment this page and report errors about it on the RefDocComments page.
Generated on Fri Mar 9 2012 13:52:11 for spot by doxygen 1.7.6.1