Monotone Deterministic RL-Automata Don’t Need Auxiliary Symbols Supported by grants from DFG and the Grant Agency of the Czech Republic Tomasz Jurdziński University of Wrocław Poland Martin Plátek Charles University Prague Czech Republic Friedrich Otto František Mráz Universität Kassel Germany
DLT Palermo Overview zmotivation zrestarting automata ydefinition, subclasses yright-, left- monotonicity zprevious results about (nondeterministic and deterministic) restarting automata with left/right monotonicity zmonotone deterministic two-way restarting automata do not need auxiliary symbols ycharacterization by deterministic transducers and DCFL zconclusions
DLT Palermo Restarting automata - Motivation zmodel for the analysis by reduction ya stepwise simplification of an input sentence while preserving its (non)correctness until a simple sentence is got or an error is found yeach simplification (reduction) means a rewriting a limited part of the sentence by a shorter one zrich taxonomy of constrains for various models of analyzers and parsers zin particular constrains on word-order – applications for free word- order languages (many Slavonic languages)
DLT Palermo Motivation z(right) monotonicty yduring a computation, places of rewriting do not increase their distance from the right end of the word ycharacterizations of CFL (by nondeterministic) and DCFL (by deterministic) one- way restarting automata zleft monotonicty yduring a computation, places of rewriting do not increase their distance from the left end of the word ynondeterministic left-monotone restarting automata – similar power as right- monotone ones ydeterministic left-monotone restarting automata – different
DLT Palermo b a b b a a b a a b b a b Restarting automaton finite set of states c $ q control unit scanning window input word |
DLT Palermo Operations zMVR - move right zMVL - move left rewrite by v zRESTART zACCEPT v the initial state q0q0
DLT Palermo Instructions (1) ( p, u ) ( q,MVR ) (3) ( p, u ) RESTART (5) ( p, u ) ( q, v ) k input alphabet working alphabet Two alphabets c... | u $ p (2) ( p, u ) ( q,MVL ) (4) ( p, u ) ACCEPT !!! | v |<| u | !!!
ACCEPT Accepting configuration c | $ Initial configuration c | $ input word q0q0 the initial state input symbols only Restarting configuration $ current word q0q0 the initial state working symbols allowed c | If there is no applicable instruction, the automaton rejects
DLT Palermo cycle –part of a computation between two restarting configurations contains exactly one rewriting tail – part of a computation between a restarting configuration and a halting configuration Cycles W1W1 W2W2 W3W3 W n-1 c| c| c| c| $ $ $ $ WnWn c|$ cycles tail
DLT Palermo Subclasses of restarting automata RLWW RRWWRWW RLWRRWRWRW RLRRR no MVL restart immediately after each rewrite deleting only no working symbols back
DLT Palermo (right-)mon-RLWW -automaton – all its computations starting on an input word are (right) monotone monotonicity ( right -monotonicity ) zright monotone computation – the places of rewriting in cycles do not increase their distance to the right sentinel c | $ c | $ c | $ c | $ c | $ tail not considered initial configuration c | $
DLT Palermo left -monotonicity zleft-monotone computation – the places of rewriting in cycles do not increase their distance from the left sentinel left-mon-RLWW -automaton – all its computations starting on an input word are left-monotone c | $ c | $ c | $ c | $ c | $ tail not considered initial configuration c | $
DLT Palermo Known results for nondeterministic restarting automata RLWWRRWWRWW RLWRRWRW RLRRR CFL nondeterministic right-mon- RLWWRRWWRWW RLWRRWRW RLRRR nondeterministic left-mon CFL X Y equivalence L (X ) = L (Y ) X Y proper inclusion L (X ) L (Y )
DLT Palermo Known results for deterministic restarting automata L={ a n b n c, a n b 2n d | n 0 } L L ( det-mon-RL ) \ DCFL L L ( det-left-mon-RL ) \ L ( det-RRW ) deterministic (right-) mon- RLWWRRWWRWW RLWRRWRW RLRRR DCFL deterministic left-mon- RLWWRRWWRWW RLWRRWRW RLRRR DCFL R
DLT Palermo Mirror Symmetry Lemma: For each X {, W, WW }: L ( det-left-mon- RLX ) = [ L ( det-mon- RLX ) ] R deterministic right-mon- RLWWRRWWRWW RLWRRWRW RLRRR DCFL deterministic left-mon- RLWWRRWWRWW RLWRRWRW RLRRR DCFL R
DLT Palermo The main theorem a) L ( det-mon- RLWW ) = L ( det-mon- RLW ) = L ( det-mon- RL ) b) L ( det-left-mon- RLWW ) = L ( det-left-mon- RLW ) = L ( det-left-mon- RL ) L ( det-left-mon- RRWW ) =
DLT Palermo q0q0 ( q 0, caa ) ( q 1, MVR ) W.l.o.g. an RRWW-automaton M scans whole tape before it restarts / accepts / rejects Characterization of L ( det-left-mon-RRWW ) aabba$bc | aabb
DLT Palermo q1q1 ( q 1, aaa ) ( q 2, MVR ) W.l.o.g. an RRWW-automaton M scans whole tape before it restarts / accepts / rejects Characterization of L ( det-left-mon-RRWW ) aabba$bc | aabb q0q0
DLT Palermo q2q2 ( q 2, aaa ) ( q 3, MVR ) W.l.o.g. an RRWW-automaton M scans whole tape before it restarts / accepts / rejects Characterization of L ( det-left-mon-RRWW ) aabba$bc | aabb q0q0 q1q1
DLT Palermo q3q3 ( q 3, aaa ) ( q 4, MVR ) W.l.o.g. an RRWW-automaton M scans whole tape before it restarts / accepts / rejects Characterization of L ( det-left-mon-RRWW ) aabba$bc | aabb q0q0 q1q1 q2q2
DLT Palermo q4q4 ( q 4, aab ) ( q 5, MVR ) W.l.o.g. an RRWW-automaton M scans whole tape before it restarts / accepts / rejects Characterization of L ( det-left-mon-RRWW ) aabba$bc | aabb q0q0 q1q1 q2q2 q3q3
DLT Palermo q5q5 ( q 5, abb ) ( q 6, b ) W.l.o.g. an RRWW-automaton M scans whole tape before it restarts / accepts / rejects Characterization of L ( det-left-mon-RRWW ) aabba$bc | aabb q0q0 q1q1 q2q2 q3q3 q4q4
DLT Palermo c q6q6 ( q 6, bbb ) ( q 7, MVR ) W.l.o.g. an RRWW-automaton M scans whole tape before it restarts / accepts / rejects Characterization of L ( det-left-mon-RRWW ) aabba$b | ab q0q0 q1q1 q2q2 q3q3 q4q4 q5q5
DLT Palermo q7q7 ( q 7, bb$ ) ( q 8, MVR ) W.l.o.g. an RRWW-automaton M scans whole tape before it restarts / accepts / rejects Characterization of L ( det-left-mon-RRWW ) q0q0 q1q1 q2q2 q3q3 q4q4 q5q5 q6q6 caabba$b | ab
DLT Palermo q8q8 ( q 8, b$ ) ( q 9, MVR ) W.l.o.g. an RRWW-automaton M scans whole tape before it restarts / accepts / rejects Characterization of L ( det-left-mon-RRWW ) q0q0 q1q1 q2q2 q3q3 q4q4 q5q5 q6q6 caabba$b | ab q7q7
DLT Palermo q9q9 ( q 9, $ ) RESTART W.l.o.g. an RRWW-automaton M scans whole tape before it restarts / accepts / rejects Characterization of L ( det-left-mon-RRWW ) q0q0 q1q1 q2q2 q3q3 q4q4 q5q5 q6q6 caabba$b | ab q7q7 q8q8
DLT Palermo q9q9 ( q 9, $ ) RESTART W.l.o.g. an RRWW-automaton M scans whole tape before it restarts / accepts / rejects Trace q0q0 q1q1 q2q2 q3q3 q4q4 q5q5 q6q6 caabba$b | ab q7q7 q8q8 q5q5 q5q5 trace
DLT Palermo W.l.o.g. an RRWW-automaton M scans whole tape before it restarts / accepts / rejects Computing the trace q0q0 q1q1 q2q2 q3q3 q4q4 q5q5 q6q6 caabba$b | ab q5q5 q5q5 aabbabaabb
DLT Palermo Computing the trace q0q0 q1q1 q2q2 q3q3 q4q4 q5q5 q6q6 q5q5 q5q5 aabbabaabb aabba$bc | aabb q2q2 deterministic transducer G M w =w = GM (w) =GM (w) = G M (L) = { G M (w) | w L } Proposition: For each det-left-mon-RRWW -automaton M : G M (L(M)) DCFL R
DLT Palermo Characterization of L ( det-left-mon-RRWW ) zProposition: For each det-left-mon-RRWW -automaton M : G M (L(M)) DCFL R. Idea: knowing the trace, a deterministic RRWW-automaton could accept L(M) working from right to left c | $ c | $ c | $ c | $ c | $ c | $ $ $ $ $ $ | c | c | c | c || | c | c | c | c || | c | c | c | c || | c | c | c | c || | c | c | c | c || | c | c | c | c || $ $
DLT Palermo Known results for deterministic restarting automata deterministic right-mon- RLWWRRWWRWW RLWRRWRW RLRRR DCFL deterministic left-mon- RLWWRRWWRWW RLWRRWRW RLRRR DCFL R
DLT Palermo Proposition: Let G be a deterministic transducer with input alphabet , and let L +. If G (L) R DCFL, then there exists a det-left- mon-RL-automaton M that accepts the language L. Idea: replace G by a deterministic transducer G ’ G ’ outputs one symbol for each letter read, and G ’ (L) R DCFL it is possible to “compute” G ’ ( w ) from w “on-the-fly” by a two-way finite state automaton A ; let q i be the state of G ’ when it is scanning w [ i ] ; knowing q i the automaton A can compute q i+1 - obvious q i-1 - [Hopcroft, Ullman 1967] Characterization of L ( det-left-mon-RRWW )
DLT Palermo [ G ’ (L) ] R DCFL, i.e. [ G ’ (L) ] R can be accepted by a det-mon-R- automaton M 1 a det-left-mon-RL-automaton M 2 can accept G ’ (L) by simulating M 1 first scans x G ’ (L) from left to right and checks whether x could be output of G ’ then simulates M 1 moving from right to left a det-left-mon-RL-automaton M 3 can accept L by simulating M 2 using A to compute G ’ (L) Characterization of L ( det-left-mon-RRWW )
DLT Palermo Conclusions zfor deterministic two-way restarting automata which are right or left monotone we do not need auxiliary symbols, we do not need to rewrite symbols, deleting is enough deterministic right-mon- RLWWRRWWRWW RLWRRWRW RLRRR DCFL deterministic left-mon- RLWWRRWWRWW RLWRRWRW RLRRR DCFL R
DLT Palermo LFLF Conclusions zFor modelling the analysis by reduction in the case of left/right monotone rewritings only we need not auxiliary symbols - it is possible to reduce a given sentence to a ‘simple’ form within the same language zthe main result carries over to det-right-left-mononotone two-way restarting automata, but it was shown by a pumping techniques LFLF L ( R )L ( R ) L ( R )L ( R )