pd_alg_nb_sub_b.h
Go to the documentation of this file.
1 /** @file pd_alg_nb_sub_b.h Nonblock subfunctions, part B*/
2 
3 
4 /* Pushdown plugin for FAU Discrete Event Systems Library (libfaudes)
5 
6  Copyright (C) 2013 Stefan Jacobi, Sven Schneider, Anne-Kathrin Hess
7 
8 */
9 
10 
11 #ifndef FAUDES_PD_ALG_NB_SUB_B_H
12 #define FAUDES_PD_ALG_NB_SUB_B_H
13 
14 #include "corefaudes.h"
15 #include "pd_pdgenerator.h"
16 
17 
18 namespace faudes {
19 
20  /**
21  * Associates each state of the generator with an annotation. Each state's
22  * merge attribute will be set to a MergeStateAnnotation. The MergeStateAnnotation
23  * will contain the annotation.
24  *
25  * @param word
26  * word with which the states will be annotated
27  * @param pd
28  * pushdown automaton to be annotated
29  * @return
30  * copy of the parameter automaton with annotated states
31  */
32  PushdownGenerator RenQ(const std::string word, const PushdownGenerator& pd);
33 
34  /**
35  * Adds an annotation to each stack symbol of the generator. Each stack symbol will
36  * be copied and added to to generator with the annotation preceding the original
37  * name.
38  *
39  * @param word
40  * word with which the stack symbols will be annotated
41  * @param pd
42  * pushdown automaton to be annotated
43  * @return
44  * copy of the parameter automaton with annotated states
45  */
46  PushdownGenerator RenG(const std::string word, const PushdownGenerator& pd);
47 
48  /**
49  * Removes all edges popping lambda.
50  *
51  * @param pd
52  * pushdown automaton
53  * @return
54  * pushdown automaton without lambda popping edges
55  */
57 
58  /**
59  * Restricts a pushdown generator to a pushdown generator with transitions that
60  * are either read (p,a,lambda,lambda,q), pop (p,lambda,x,lambda,q) or
61  * push (p,lambda,x,yx,q)
62  *
63  * @param pd
64  * the generator, which must not have transitions that pop more than one stack
65  * symbol
66  * @return
67  * generator
68  */
70 
71  /**
72  * Removes transitions popping more than one stack symbol. Inserts new transitions
73  * instead that only pop one stack symbol.
74  *
75  * @param pd
76  * the generator, which must NOT contain lambda pops
77  * @return
78  * generator with altered transitions
79  */
81 
82  /**
83  * For debugging, prints a transitions with their pop and push attributes
84  *
85  * @param transitions
86  * multimap containing the transitions
87  */
88  void PrintTransitions(const std::multimap<Transition, std::pair<std::vector<StackSymbol>, std::vector<StackSymbol> > >& transitions);
89 
90  /**
91  * Input must have passed Rpp!
92  * remodells the generator to prevent double (or multiple) acceptance of the same
93  * input string.
94  *
95  * @param pd
96  * the generator
97  * @return
98  * remodelled generator without double acceptance
99  */
101 
102 
103 } // namespace faudes
104 
105 #endif

libFAUDES 2.24g --- 2014.09.15 --- c++ api documentaion by doxygen