cfl_localgen.h
Go to the documentation of this file.
1 /** @file cfl_localgen.h Helper functions for projected generators */
2 
3 /* FAU Discrete Event Systems Library (libfaudes)
4 
5  Copyright (C) 2006 Bernd Opitz
6  Exclusive copyright is granted to Klaus Schmidt
7 
8  This library is free software; you can redistribute it and/or
9  modify it under the terms of the GNU Lesser General Public
10  License as published by the Free Software Foundation; either
11  version 2.1 of the License, or (at your option) any later version.
12 
13  This library is distributed in the hope that it will be useful,
14  but WITHOUT ANY WARRANTY; without even the implied warranty of
15  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16  Lesser General Public License for more details.
17 
18  You should have received a copy of the GNU Lesser General Public
19  License along with this library; if not, write to the Free Software
20  Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA */
21 
22 
23 #ifndef FAUDES_LOCALGEN_H
24 
25 #include "cfl_agenerator.h"
26 #include <map>
27 #include <stack>
28 
29 namespace faudes {
30 
31 /**
32  * LowExitStates return-copy function:
33  *
34  * Wrapper for the corresponding call-by-reference function.
35  * Creates new StateSet, calls function and returns StateSet containing low level
36  * exit states.
37  *
38  * @param rLowGen
39  * Low level generator (just needed for determining statetable)
40  * @param rHighAlph
41  * High level events
42  * @param rEntryStatesMap
43  * Entry states map (see CreateEntryStatesMap(resmap))
44  * @param rLowRevTransRel
45  * Reverse sorted low level transition relation
46  * @param highState
47  * Hi level state for which to compute low level exit states
48  *
49  * @exception Exception
50  * Hi level state not found in entry states map (with FAUDES_CHECKED) (id 502)
51  */
52 StateSet LowExitStates(const Generator& rLowGen, const EventSet& rHighAlph,
53  const std::map<Idx,StateSet>& rEntryStatesMap, const TransSetX2EvX1& rLowRevTransRel, Idx highState);
54 
55 /**
56  * LowExitStates call-by-reference function:
57  *
58  * Compute the low level exit states for a corresponding hi level state
59  *
60  * @param rHighAlph
61  * High level events
62  * @param rEntryStatesMap
63  * Entry states map (see CreateEntryStatesMap(resmap))
64  * @param rLowRevTransRel
65  * Reverse sorted low level transition relation
66  * @param highState
67  * Hi level state for which to compute low level exit states
68  * @param rLowExitStates
69  * Reference to StateSet for low level exit states (result)
70  *
71  * @exception Exception
72  * Hi level state not found in entry states map (with FAUDES_CHECKED)
73  */
74 void LowExitStates(const EventSet& rHighAlph, const std::map<Idx,StateSet>& rEntryStatesMap,
75  const TransSetX2EvX1& rLowRevTransRel, Idx highState, StateSet& rLowExitStates);
76 
77 /**
78  * ReachableEvents return-copy function:
79  *
80  * Wrapper for the corresponding call-by-reference function.
81  * Creates new EventSet, calls function and returns EventSet containing the
82  * reachable hi level events.
83  *
84  * @param rLowGen
85  * Low level generator
86  * @param rHighAlph
87  * High level alphabet
88  * @param lowState
89  * Low level state
90  */
91 EventSet ReachableEvents(const Generator& rLowGen, const EventSet& rHighAlph,
92  Idx lowState);
93 
94 /**
95  * ReachableEvents call-by-reference function:
96  *
97  * Compute the set of hi level events which can be reached from a low
98  * level state. Resulting set will be cleared first.
99  *
100  * @param rLowGen
101  * Low level generator
102  * @param rHighAlph
103  * High level alphabet
104  * @param lowState
105  * Low level state
106  * @param rReachableEvents
107  * Reference to EventSet which will contain the reachable high level events
108  * (result)
109  */
110 void ReachableEvents(const Generator& rLowGen, const EventSet& rHighAlph,
111  Idx lowState, EventSet& rReachableEvents);
112 
113 /**
114  * Compute the coaccessible reach for a local automaton.
115  *
116  * @param rRevTransRel
117  * Reverse sorted transition relation
118  * @param rHighAlph
119  * High level alphabet
120  * @param lowState
121  * Low level exit state
122  * @param rCoaccessibleReach
123  * Result
124  */
125 void LocalCoaccessibleReach(const TransSetX2EvX1& rRevTransRel,
126  const EventSet& rHighAlph, Idx lowState, StateSet& rCoaccessibleReach);
127 
128 /**
129  * Compute the accessible reach for a local automaton
130  *
131  * @param rLowGen
132  * Low level generator
133  * @param rHighAlph
134  * High level alphabet
135  * @param lowState
136  * Low level entry state
137  * @param rAccessibleReach
138  * Result
139  */
140 void LocalAccessibleReach(const Generator& rLowGen, const EventSet& rHighAlph,
141  Idx lowState, StateSet& rAccessibleReach);
142 
143 } // namespace faudes
144 
145 #define FAUDES_LOCALGEN_H
146 #endif
147 

libFAUDES 2.26g --- 2015.08.17 --- c++ api documentaion by doxygen