|
Go to the documentation of this file.
12 FD_DIO( "IsIoSystem("<< rIoSystem. Name() << ",...)");
17 rQErr. Name( "ErrorStates");
19 FD_DIO( "IsIoSystem("<< rIoSystem. Name() << ",...): testing completeness");
22 StateSet::Iterator sit=acc. Begin();
23 StateSet::Iterator sit_end=acc.End();
24 for(;sit!=sit_end;sit++){
28 if(tit==tit_end) rQErr. Insert(*sit);
33 FD_DIO( "IsIoSystem("<< rIoSystem. Name() << ",...): not complete");
41 EventSet::Iterator eit_end= rIoSystem. AlphabetEnd();
42 for(; eit != eit_end; ++eit) {
55 FD_DIO( "IsIoSystem("<< rIoSystem. Name() << ",...): not a u-y partition of events");
58 for(; tit!=tit_end; tit++)
63 FD_DIO( "IsIoSystem("<< rIoSystem. Name() << ",...): trivial partition");
67 FD_DIO( "IsIoSystem("<< rIoSystem. Name() << ",...): i/o alternation");
71 for(; sit != sit_end; ++sit) {
75 for(; tit!=tit_end; tit++) {
86 for(; sit != sit_end; ++sit) {
92 while(not todo.empty()) {
93 const Idx current = todo.top();
95 bool uok = rQU. Exists(current);
96 bool yok = rQY. Exists(current);
100 for(; tit!=tit_end; tit++) {
105 if(!uok) rQErr. Insert(current);
109 if(!yok) rQErr. Insert(current);
124 bool res= IsIoSystem(rIoSystem, QU, QY, QErr);
140 FD_DIO( "IsInputLocallyFree("<< rIoSystem. Name() << ",...)");
149 FD_DIO( "IsInputLocallyFree("<< rIoSystem. Name() << ",...)");
152 rQErr. Name( "ErrorStates");
157 StateSet::Iterator sit_end= rIoSystem. StatesEnd();
158 for(; sit != sit_end; ++sit) {
163 for(; tit!=tit_end; tit++)
167 if(lsigu. Empty()) continue;
169 if(lsigu == sigu) continue;
174 return rQErr. Empty();
180 FD_DIO( "IsInputOmegaFree("<< rIoSystem. Name() << ",...)");
189 FD_DIO( "IsInputOmegaFree("<< rIoSystem. Name() << ",...)");
194 FD_DIO( "IsInputOmegaFree("<< rIoSystem. Name() << ",...): failed for locally free");
202 rQErr. Name( "ErrorStates");
207 FD_DIO( "IsInputOmegaFree(...): iterate over good states");
209 StateSet::Iterator sit = rQErr. Begin();
210 while(sit!=rQErr. End()) {
212 StateSet::Iterator cit=sit++;
214 if(goodstates. Exists(*cit)) continue;
219 if(tit==tit_end) continue;
222 for(; tit!=tit_end; ++tit) {
223 if(goodstates. Exists(tit->X2)) { block= false; continue; }
224 if(yalph. Exists(tit->Ev)) continue;
228 if(tit==tit_end && !block) {
229 FD_DIO( "IsInputOmegaFree(): ins good state " << rIoSystem. SStr(*cit));
241 FD_DIO( "IsInputOmegaFree(): accessible <= good: passed");
246 FD_DIO( "IsInputOmegaFree(): accessible <= good: failed");
258 FD_DIO( "IoFreeInput("<< rGen. Name() << ",...)");
261 std::stringstream errstr;
262 errstr << "Input alphabet must be contained in generator alphabet";
263 throw Exception( "IoFreeInput(..)", errstr.str(), 100);
269 EventSet::Iterator eit;
270 EventSet::Iterator eit_end;
273 StateSet::Iterator sit_end= rGen. StatesEnd();
274 for(; sit != sit_end; ++sit) {
279 for(; tit!=tit_end; tit++)
282 if(lsigu. Empty()) continue;
284 if(lsigu == rUAlph) continue;
293 for(; eit!=eit_end; eit++) {
302 eit_end=rUAlph. End();
303 for(; eit!=eit_end; eit++)
312 FD_DIO( "RemoveIoDummyStates("<< rIoSystem. Name() << ",...)");
324 StateSet::Iterator sit_end= rIoSystem. StatesEnd();
325 for(; sit != sit_end; ++sit) {
332 for(; tit!=tit_end; tit++) {
333 if(qsuc==0) qsuc=tit->X2;
334 if(qsuc!=tit->X2) { qunique= false; break;}
338 if(!qunique || qsuc==0) continue;
340 if(!(lsig == sigy)) continue;
345 FD_DIO( "RemoveIoDummyStates(): Candidates type 1 " << qerr1. ToString());
346 FD_DIO( "RemoveIoDummyStates(): Candidates type 2 " << qerr2. ToString());
350 sit_end= qerr2. End();
351 for(; sit != sit_end; ++sit) {
358 for(; tit!=tit_end; tit++) {
359 if(qsuc==0) qsuc=tit->X2;
360 if(qsuc!=tit->X2) { qunique= false; break;}
364 if(!qunique) continue;
366 if(!qerr1. Exists(qsuc)) continue;
368 if(!(lsig == sigu)) continue;
372 FD_DIO( "RemoveIoDummyStates(): Candidates type 2 (approved) " << qerr2a. ToString());
377 sit_end= qerr1. End();
378 for(; sit != sit_end; ++sit) {
381 if(tit==tit_end) { qrm1. Insert(*sit); break;}
382 if(!qerr2a. Exists(tit->X2)) { qrm1. Insert(*sit); break;}
386 sit = qerr2a. Begin();
387 sit_end= qerr2a. End();
388 for(; sit != sit_end; ++sit) {
391 if(tit==tit_end) { qrm2. Insert(*sit); break;}
401 for(; sit != sit_end; ++sit)
403 FD_DIO( "RemoveIoDummyStates(): done");
libFAUDES 2.24g
--- 2014.09.15
--- c++ api documentaion by doxygen
|