Decision Properties of RLs & Automaton Minimization Martin Fränzle formatics and Mathematical Modelling The Technical University of Denmark Languages and Parsing MF Fall p./ What you ll learn. Decidable properties of DFA NFA -NFA RE: Language emptiness universality inclusion. Automaton minimization: An algorithm for reducing the state set of DFA Applicability to NFA Languages and Parsing MF Fall p./
Converting between descriptions Translation RE (ijk) construction Determinization Determ. DFA Embedding eps NFA Embedding NFA Languages and Parsing MF Fall p./ Worst-case cost of conversion -NFA to NFA: NFA to DFA: where is the number of states DFA to NFA: DFA to RE: since there are REs to be constructed and each of the rounds can quadruple the size RE to -NFA: where is the length of the RE Languages and Parsing MF Fall p./
Decision procedures: Language emptiness Languages and Parsing MF Fall p./ Emptiness check ~enter ~enter ~enter enter enter ~enter leave leave Appr. Appr. Appr. Appr. Languages and Parsing MF Fall p./
! " The coloring algorithm The set of reachable states of a (D/N/ smallest set satisfying Base case: Recursion: if N)FA and there is ( (or respectively) then is the respectively) s.t.. Adding some bookkeeping to avoid reexamination of already visited states above rules yield an algorithm for computing the reachable states. Complexity: where is the number of state pairs connected via transitions in the automaton; when is the number of states. Languages and Parsing MF Fall p.7/ Direct emptiness test on REs Base case: For atomic REs we have true false a false Recursion: For compound REs: false Languages and Parsing MF Fall p.8/
" ' ' ' ( & " # ) Membership test Whether a string is in the language can be tested by running the automaton on of some automaton #. Languages and Parsing MF Fall p.9/ Other decidable properties Due to the closure properties of regular languages the emptiness test can be used to decide universality is "? Kleene-closedness is inclusion is disjointness is image is??? for some given homomorphism )? Furthermore (in-)finiteness of is decidable e.g. by analysing the RE does it contain a Kleene star over a language different from and? Languages and Parsing MF Fall p./
. # * # * & +. # / - + / Automaton Minimization Languages and Parsing MF Fall p./ State equivalence Def: Two states and of a DFA are called equivalent iff iff holds for all ". Deciding equivalence: The set of distinguishable state pairs is the smallest set satisfying Base case: If and or vice versa then +. Recursion: If then - and there is +. s.t and Theorem: and are equivalent iff +. Languages and Parsing MF Fall p./
Automaton minimization Obviously equivalent states can be merged into a single one as no string distinguishes the two. We will now see that the resulting automaton is minimal in the following sense:. There is no DFA with fewer states accepting the same language.. It is isomorphic (in the sense that the automata differ only in their state names) to all other DFAs with the same number of states that accept the same language. Languages and Parsing MF Fall p./ The minimal automaton Let be a DFA its set of reachable states and let + be the set of its equivalent state pairs. induces equivalence classes on :. The automaton defined by ( is called the minimization of. is well-defined as implies. Languages and Parsing MF Fall p./
' ; 9 9 8 8 : 7 Minimality is a DFA and the DFA constructed from minimization algorithm then... Lemma: If by the is a DFA and the DFA constructed from minimization algorithm then. for each DFA 'with. Theorem: If by the Languages and Parsing MF Fall p./ The NFA A B C has no equivalent states. Yet it is non-minimal: state is redundant. Minimization algorithm based on state equiv. applies to DFA only! Languages and Parsing MF Fall p./