|
Go to the documentation of this file.
9 using namespace faudes;
28 std::cout << "################################\n";
29 std::cout << "# modular language-diagnosability (system 1/2)\n";
30 std::cout << "# a) read data \n";
33 g1 = new System( "data/diag_system_3_modular1.gen");
34 g2 = new System( "data/diag_system_3_modular2.gen");
35 k1 = new System( "data/diag_specification_3_modular1.gen");
36 k2 = new System( "data/diag_specification_3_modular2.gen");
39 g1-> Write( "tmp_diag_system_3_modular1.gen");
40 g2-> Write( "tmp_diag_system_3_modular2.gen");
41 k1-> Write( "tmp_diag_specification_3_modular1.gen");
42 k2-> Write( "tmp_diag_specification_3_modular2.gen");
45 g1-> GraphWrite( "tmp_demo_system_3_modular1.png");
46 g2-> GraphWrite( "tmp_demo_system_3_modular2.png");
47 k1-> GraphWrite( "tmp_demo_specification_3_modular1.png");
48 k2-> GraphWrite( "tmp_demo_specification_3_modular2.png");
52 abstAlph. Read( "data/diag_abstrAlph_3_modular12.alph");
56 g1Abst. Write( "tmp_diag_system_3_modular1_hat.gen");
57 g2Abst. Write( "tmp_diag_system_3_modular2_hat.gen");
69 std::cout << "# b) run modular diagnosability test (expect result PASS)\n";
74 std::cout << "The overall system G is modularly diagnosable with respect to overall specification K." << std::endl;
75 std::cout << report << std::endl;
77 std::cout << "The overall system G is not modularly diagnosable with respect to overall specification K." << std::endl;
78 std::cout << report << std::endl;
91 std::cout << "# c) compute modular diagnoser\n";
97 diag. At(0).Write( "tmp_diag_diagnoser_3_modular1.gen");
98 diag. At(1).Write( "tmp_diag_diagnoser_3_modular2.gen");
101 diag. At(0).GraphWrite( "tmp_demo_diagnoser_3_modular1.png");
102 diag. At(1).GraphWrite( "tmp_demo_diagnoser_3_modular2.png");
108 std::cout << "# done \n";
109 std::cout << "################################\n";
124 std::cout << "################################\n";
125 std::cout << "# modular diagnosability (system 3/4)\n";
126 std::cout << "# a) read data \n";
129 g1 = new System( "data/diag_system_3_modular3.gen");
130 g2 = new System( "data/diag_system_3_modular4.gen");
131 k1 = new System( "data/diag_specification_3_modular3.gen");
132 k2 = new System( "data/diag_specification_3_modular4.gen");
135 g1-> Write( "tmp_diag_system_3_modular3.gen");
136 g2-> Write( "tmp_diag_system_3_modular4.gen");
137 k1-> Write( "tmp_diag_specification_3_modular3.gen");
138 k2-> Write( "tmp_diag_specification_3_modular4.gen");
141 g1-> GraphWrite( "tmp_demo_system_3_modular3.png");
142 g2-> GraphWrite( "tmp_demo_system_3_modular4.png");
143 k1-> GraphWrite( "tmp_demo_specification_3_modular3.png");
144 k2-> GraphWrite( "tmp_demo_specification_3_modular4.png");
156 std::cout << "# b) run modular diagnosability test (expect result FAIL)\n";
161 std::cout << "The overall system G is modularly diagnosable with respect to overall specification K." << std::endl;
162 std::cout << report << std::endl;
164 std::cout << "The overall system G is not modularly diagnosable with respect to overall specification K." << std::endl;
165 std::cout << report << std::endl;
172 std::cout << "# done \n";
173 std::cout << "################################\n";
187 std::cout << "################################\n";
188 std::cout << "# modular diagnosability (system sf/cb1a)\n";
189 std::cout << "# a) read data \n";
192 g1 = new System( "data/diag_system_3_modular_sf.gen");
193 g2 = new System( "data/diag_system_3_modular_c1.gen");
194 k1 = new System( "data/diag_specification_3_modular_sf.gen");
195 k2 = new System( "data/diag_specification_3_modular_c1.gen");
198 g1-> Write( "tmp_diag_system_3_modular_sf.gen");
199 g2-> Write( "tmp_diag_system_3_modular_c1.gen");
200 k1-> Write( "tmp_diag_specification_3_modular_sf.gen");
201 k2-> Write( "tmp_diag_specification_3_modular_c1.gen");
204 g1-> GraphWrite( "tmp_demo_system_3_modular_sf.png");
205 g2-> GraphWrite( "tmp_demo_system_3_modular_c1.png");
206 k1-> GraphWrite( "tmp_demo_specification_3_modular_sf.png");
207 k2-> GraphWrite( "tmp_demo_specification_3_modular_c1.png");
219 std::cout << "# b) run diagnosability test (expect result PASS)\n";
223 std::cout << "The overall system G is modularly diagnosable with respect to overall specification K." << std::endl;
224 std::cout << report << std::endl;
226 std::cout << "The overall system G is not modularly diagnosable with respect to overall specification K." << std::endl;
227 std::cout << report << std::endl;
236 std::cout << "# c) compute modular diagnoser\n";
242 diag. At(0).Write( "tmp_diag_diagnoser_3_modular_sf.gen");
243 diag. At(1).Write( "tmp_diag_diagnoser_3_modular_c1.gen");
246 diag. At(0).GraphWrite( "tmp_demo_diagnoser_3_modular_sf.png");
247 diag. At(1).GraphWrite( "tmp_demo_diagnoser_3_modular_c1.png");
253 std::cout << "# done \n";
254 std::cout << "################################\n";
262 std::cout << std::endl;
libFAUDES 2.26g
--- 2015.08.17
--- c++ api documentaion by doxygen
|