29 gen.
Read(
"data/syn_lfeed.gen");
31 gen.
Read(
"data/syn_lplace2.gen");
33 gen.
Read(
"data/syn_lplace3.gen");
35 gen.
Read(
"data/syn_lplace4.gen");
37 gen.
Read(
"data/syn_lplace5.gen");
39 gen.
Read(
"data/syn_lplace6.gen");
41 gen.
Read(
"data/syn_lplace7.gen");
43 gen.
Read(
"data/syn_lexit7.gen");
53 gen.
Read(
"data/syn_efeeda.gen");
55 gen.
Read(
"data/syn_eexit7.gen");
59 std::map<faudes::Idx,faudes::Idx> MapEventsToPlant;
70 MapEventsToPlant, DisGenVec, SupGenVec);
77 std::cout <<
"################################\n";
78 std::cout <<
"Hello, this is a test case for compositional synthesis \n";
79 std::cout <<
"################################\n";
83 std::map<faudes::Idx,faudes::Idx>::iterator mit = MapEventsToPlant.begin();
84 std::cout <<
"################\n";
85 std::cout <<
"this is map\n";
86 std::cout <<
"################\n";
87 for(; mit != MapEventsToPlant.end(); ++mit) {
88 std::cout <<
"map "<<pEvSymTab->
Symbol(mit->first) <<
" to ";
89 std::cout << pEvSymTab->
Symbol(mit->second) << std::endl;
94 for(; i < DisGenVec.
Size(); ++i) {
101 for(i=0; i < SupGenVec.
Size(); ++i) {
110 for(i=0; i < SupGenVec.
Size(); ++i) {
111 Size += SupGenVec.
At(i).
Size();
115 std::cout<<
" the number of supervisors is "<<SupGenVec.
Size()<<std::endl;
116 std::cout<<
" the total size is "<<Size<<std::endl;
117 std::cout<<
" the total number of TransRel is "<<TransRelSize<<std::endl;
118 std::cout <<
"################################\n";
171 std::cout <<
"the size of closed behavior is :\n";
172 std::cout <<
"the states : " << My_Closed.
Size() << std::endl;
173 std::cout <<
"the TransRel : " << My_Closed.
TransRelSize() << std::endl;
174 std::cout <<
"################################\n";
183 bool my_iscon =
false;
186 bool my_isNB =
false;
194 std::cout <<
"the supervisor is " << (my_iscon?
"":
" not ") <<
"controllable\n";
195 std::cout <<
"the supervisor is " << (my_isNB?
"":
" not ") <<
"nonblocking\n";
#define FAUDES_TEST_DIFF()
Test protocol diff macro.
#define FAUDES_TEST_DUMP(mes, dat)
Test protocol record macro ("mangle" filename for platform independance)
Set of indices with symbolic names.
bool Insert(const Idx &rIndex)
Add an element by index.
A SymbolTable associates sybolic names with indices.
std::string Symbol(Idx index) const
Symbolic name lookup.
std::vector< int >::size_type Position
convenience typedef for positions
virtual const T & At(const Position &pos) const
Access element.
void Read(const std::string &rFileName, const std::string &rLabel="", const Type *pContext=0)
Read configuration data from file with label specified.
void Write(const Type *pContext=0) const
Write configuration data to console.
virtual void PushBack(const Type &rElem)
Append specified entry.
Idx Size(void) const
Get size of vector.
Base class of all FAUDES generators.
SymbolTable * EventSymbolTablep(void) const
Get Pointer to EventSymbolTable currently used by this vGenerator.
Idx TransRelSize(void) const
Get number of transitions.
Idx Size(void) const
Get generator size (number of states)
void aParallel(const Generator &rGen1, const Generator &rGen2, Generator &rResGen)
Parallel composition.
bool IsControllable(const Generator &rPlantGen, const EventSet &rCAlph, const Generator &rSupCandGen)
Test controllability.
void CompositionalSynthesis(const GeneratorVector &rPlantGenVec, const EventSet &rConAlph, const GeneratorVector &rSpecGenVec, std::map< Idx, Idx > &rMapEventsToPlant, GeneratorVector &rDisGenVec, GeneratorVector &rSupGenVec)
Compositional synthesis.
Includes all libFAUDES headers, incl plugings
libFAUDES resides within the namespace faudes.
uint32_t Idx
Type definition for index type (allways 32bit)
bool IsNonblocking(const GeneratorVector &rGvec)