Main Page | Namespace List | Class Hierarchy | Class List | File List | Namespace Members | Class Members

spot::magic_search Struct Reference

Emptiness check on spot::tgba_tba_proxy automata using the Magic Search algorithm. More...

#include <magic.hh>

Collaboration diagram for spot::magic_search:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 magic_search (const tgba_tba_proxy *a)
 Initialize the Magic Search algorithm on the automaton a.

 ~magic_search ()
bool check ()
 Perform a Magic Search.

std::ostream & print_result (std::ostream &os, const tgba *restrict=0) const
 Print the last accepting path found.


Private Types

typedef std::pair< magic_state,
tgba_succ_iterator * > 
state_iter_pair
typedef std::list< state_iter_pairstack_type
typedef std::list< bdd > tstack_type
typedef Sgi::hash_map< const
state *, magic, state_ptr_hash,
state_ptr_equal
hash_type

Private Member Functions

void push (const state *s, bool m)
 Append a new state to the current path.

bool has (const state *s, bool m) const
 Check whether we already visited s with the Magic bit set to m.


Private Attributes

stack_type stack
 Stack of visited states on the path.

tstack_type tstack
 Stack of transitions.

hash_type h
 Map of visited states.

const tgba_tba_proxya
const statex
 The state for which we are currently seeking an SCC.


Detailed Description

Emptiness check on spot::tgba_tba_proxy automata using the Magic Search algorithm.

This algorithm comes from

      @InProceedings{   godefroid.93.pstv,
        author        = {Patrice Godefroid and Gerard .J. Holzmann},
        title         = {On the verification of temporal properties},
        booktitle     = {Proceedings of the 13th IFIP TC6/WG6.1 International
                        Symposium on Protocol Specification, Testing, and
                        Verification (PSTV'93)},
        month         = {May},
        editor        = {Andr{\'e} A. S. Danthine and Guy Leduc
                         and Pierre Wolper},
        address       = {Liege, Belgium},
        pages         = {109--124},
        publisher     = {North-Holland},
        year          = {1993},
        series        = {IFIP Transactions},
        volume        = {C-16},
        isbn          = {0-444-81648-8}
      }
      


Member Typedef Documentation

typedef Sgi::hash_map<const state*, magic, state_ptr_hash, state_ptr_equal> spot::magic_search::hash_type [private]
 

typedef std::list<state_iter_pair> spot::magic_search::stack_type [private]
 

typedef std::pair<magic_state, tgba_succ_iterator*> spot::magic_search::state_iter_pair [private]
 

typedef std::list<bdd> spot::magic_search::tstack_type [private]
 


Constructor & Destructor Documentation

spot::magic_search::magic_search const tgba_tba_proxy a  ) 
 

Initialize the Magic Search algorithm on the automaton a.

spot::magic_search::~magic_search  ) 
 


Member Function Documentation

bool spot::magic_search::check  ) 
 

Perform a Magic Search.

Returns:
true iff the algorithm has found a new accepting path.
check() can be called several times until it return false, to enumerate all accepting paths.

bool spot::magic_search::has const state s,
bool  m
const [private]
 

Check whether we already visited s with the Magic bit set to m.

std::ostream& spot::magic_search::print_result std::ostream &  os,
const tgba restrict = 0
const
 

Print the last accepting path found.

Restrict printed states to the state space of restrict if supplied.

void spot::magic_search::push const state s,
bool  m
[private]
 

Append a new state to the current path.


Member Data Documentation

const tgba_tba_proxy* spot::magic_search::a [private]
 

The automata to check.

hash_type spot::magic_search::h [private]
 

Map of visited states.

stack_type spot::magic_search::stack [private]
 

Stack of visited states on the path.

tstack_type spot::magic_search::tstack [private]
 

Stack of transitions.

This is an addition to the data from the paper.

const state* spot::magic_search::x [private]
 

The state for which we are currently seeking an SCC.


The documentation for this struct was generated from the following file:
Generated on Tue Jan 13 18:20:52 2004 for spot by doxygen 1.3.5