cfl_omega.hGo to the documentation of this file.00001 /** @file cfl_omega.h 00002 00003 Operations on omega languages. 00004 00005 */ 00006 00007 /* FAU Discrete Event Systems Library (libfaudes) 00008 00009 Copyright (C) 2010 Thomas Moor 00010 00011 This library is free software; you can redistribute it and/or 00012 modify it under the terms of the GNU Lesser General Public 00013 License as published by the Free Software Foundation; either 00014 version 2.1 of the License, or (at your option) any later version. 00015 00016 This library is distributed in the hope that it will be useful, 00017 but WITHOUT ANY WARRANTY; without even the implied warranty of 00018 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 00019 Lesser General Public License for more details. 00020 00021 You should have received a copy of the GNU Lesser General Public 00022 License along with this library; if not, write to the Free Software 00023 Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */ 00024 00025 00026 #ifndef FAUDES_OMEGA_H 00027 #define FAUDES_OMEGA_H 00028 00029 #include "cfl_definitions.h" 00030 #include "cfl_generator.h" 00031 00032 namespace faudes { 00033 00034 00035 /** 00036 * Product composition for Buechi automata 00037 * 00038 * Referring to the Buechi acceptance condition, the resulting genarator 00039 * accepts all those inifinite words that are accepted by both, G1 and G2. 00040 * This implementation extends the usual product state space by a flag to indentify 00041 * executions with alternating marking. 00042 * 00043 * @param rGen1 00044 * First generator 00045 * @param rGen2 00046 * Second generator 00047 * @param rResGen 00048 * Reference to resulting product composition generator 00049 * 00050 * 00051 * @ingroup GeneratorFunctions 00052 * 00053 */ 00054 void OmegaProduct(const Generator& rGen1, const Generator& rGen2, Generator& rResGen); 00055 00056 00057 /** 00058 * Product composition for Buechi automata 00059 * 00060 * See also OmegaProduct(const Generator&, const Generator&, Generator&). 00061 * This version tries to be transparent on event attributes: if 00062 * argument attributes match and if the result can take the respective 00063 * attributes, then they are copied; it is considered an error if 00064 * argument attributes do not match. 00065 * 00066 * @param rGen1 00067 * First generator 00068 * @param rGen2 00069 * Second generator 00070 * @param rResGen 00071 * Reference to resulting product composition generator 00072 * 00073 * @ingroup GeneratorFunctions 00074 */ 00075 void aOmegaProduct(const Generator& rGen1, const Generator& rGen2, Generator& rResGen); 00076 00077 00078 /** 00079 * Parallel composition with relaxed acceptance condition. 00080 * 00081 * This version of the parallel composition relaxes the synchronisation of the acceptance 00082 * condition (marking). It requires that the omega extension of the generated language 00083 * has infinitely many prefixes that comply to the marked languages of G1 and G2, referring 00084 * to the projection on the respective alphabet. 00085 * It does however not require the synchronous acceptance. 00086 * 00087 * @param rGen1 00088 * First generator 00089 * @param rGen2 00090 * Second generator 00091 * @param rResGen 00092 * Reference to resulting parallel composition generator 00093 * 00094 * 00095 * @ingroup GeneratorFunctions 00096 * 00097 */ 00098 void OmegaParallel(const Generator& rGen1, const Generator& rGen2, Generator& rResGen); 00099 00100 00101 /** 00102 * Parallel composition with relaxed acceptance condition. 00103 * 00104 * See also OmegaParallel(const Generator&, const Generator&, Generator&). 00105 * This version tries to be transparent on event attributes: if 00106 * argument attributes match and if the result can take the respective 00107 * attributes, then they are copied; it is considered an error if 00108 * argument attributes do not match. 00109 * 00110 * @param rGen1 00111 * First generator 00112 * @param rGen2 00113 * Second generator 00114 * @param rResGen 00115 * Reference to resulting composition generator 00116 * 00117 * @ingroup GeneratorFunctions 00118 */ 00119 void aOmegaParallel(const Generator& rGen1, const Generator& rGen2, Generator& rResGen); 00120 00121 00122 /** 00123 * Topological closure. 00124 * 00125 * This function computes the topological closure the omega language 00126 * Bm realized by rGen. 00127 * 00128 * Method: 00129 * First, OmegaTrim is called to erase all states of rGen that do not 00130 * contribute to Bm. Then, all remaining states are marked. 00131 * 00132 * No restrictions on parameter. 00133 * 00134 * 00135 * @param rGen 00136 * Generator that realizes Bm to which omega closure is applied 00137 * 00138 * <h4>Example:</h4> 00139 * <table> 00140 * <tr> <td> Generator G </td> <td> PrefixClosure(G) </td> </tr> 00141 * <tr> 00142 * <td> @image html tmp_omegaclosure_g.png </td> 00143 * <td> @image html tmp_omegaclosure_gRes.png </td> 00144 * </tr> 00145 * </table> 00146 * 00147 * @ingroup GeneratorFunctions 00148 */ 00149 void OmegaClosure(Generator& rGen); 00150 00151 00152 /** 00153 * Test for topologically closed omega language. 00154 * 00155 * This function tests whether the omega language Bm(G) realized by the specified generator G 00156 * is topologically closed. 00157 * 00158 * Method: 00159 * First, compute the omega-trim state set and restrict the discussion to that set. 00160 * Then, omega-closedness is equivalent to the non-existence on a non-trivial SCC 00161 * with no marked states. 00162 * 00163 * @param rGen 00164 * Generator that realizes Bm to which omega closure is applied 00165 * @return 00166 * True <> Bm(G) is omega closed 00167 * 00168 * @ingroup GeneratorFunctions 00169 */ 00170 bool IsOmegaClosed(const Generator& rGen); 00171 00172 00173 00174 00175 } // namespace faudes 00176 00177 #endif 00178 libFAUDES 2.23h --- 2014.04.03 --- c++ api documentaion by doxygen |