1 Dal non-determinismo al determinismo ( nei linguaggi 2dim ): alcune riflessioni Marcella Anselmo, Dora Giammarresi, Maria Madonia, Antonio Restivo Riunione.

Slides:



Advertisements
Similar presentations
CS2303-THEORY OF COMPUTATION Closure Properties of Regular Languages
Advertisements

Regular operations Sipser 1.1 (pages 44 – 47). CS 311 Fall Building languages If L is a language, then its complement is L’ = {w | w ∉ L} Let A.
Two-dimensional Rational Automata: a bridge unifying 1d and 2d language theory Marcella Anselmo Dora Giammarresi Maria Madonia Univ. of Salerno Univ. Roma.
8/27/2009 Sofya Raskhodnikova Intro to Theory of Computation L ECTURE 2 Theory of Computation Finite Automata Operations on languages Nondeterminism L2.1.
Tiling Automata: a computational model for recognizable two-dimensional languages Marcella Anselmo Dora Giammarresi Maria Madonia Univ. of Salerno Univ.
1 1 CDT314 FABER Formal Languages, Automata and Models of Computation Lecture 3 School of Innovation, Design and Engineering Mälardalen University 2012.
Pushdown Automata Chapter 12. Recognizing Context-Free Languages Two notions of recognition: (1) Say yes or no, just like with FSMs (2) Say yes or no,
Pushdown Automata Chapter 12. Recognizing Context-Free Languages We need a device similar to an FSM except that it needs more power. The insight: Precisely.
Pushdown Automata Part II: PDAs and CFG Chapter 12.
Finite Automata Section 1.1 CSC 4170 Theory of Computation.
Introduction to Computability Theory
NFAs Sipser 1.2 (pages 47–54). CS 311 Fall Recall… Last time we showed that the class of regular languages is closed under: –Complement –Union.
Regular operations Sipser 1.1 (pages 44 – 47). CS 311 Mount Holyoke College 2 Building languages If L is a language, then its complement is L’ = {w |
1 Introduction to Computability Theory Lecture2: Non Deterministic Finite Automata Prof. Amos Israeli.
NFAs Sipser 1.2 (pages 47–54). CS 311 Mount Holyoke College 2 Recall… Last time we showed that the class of regular languages is closed under: –Complement.
Finite Automata and Non Determinism
1 Introduction to Computability Theory Lecture2: Non Deterministic Finite Automata (cont.) Prof. Amos Israeli.
Finite Automata Finite-state machine with no output. FA consists of States, Transitions between states FA is a 5-tuple Example! A string x is recognized.
1 Lecture 15 Distinguishability –Definition –Help in designing/debugging FSA’s NFA’s –nondeterministic transition functions computations are trees, not.
CS5371 Theory of Computation Lecture 4: Automata Theory II (DFA = NFA, Regular Language)
1 Regular Languages Finite Automata eg. Supermarket automatic door: exit or entrance.
Automating Construction of Lexers. Example in javacc TOKEN: { ( | | "_")* > | ( )* > | } SKIP: { " " | "\n" | "\t" } --> get automatically generated code.
Nondeterminism (Deterministic) FA required for every state q and every symbol  of the alphabet to have exactly one arrow out of q labeled . What happens.
Nathan Brunelle Department of Computer Science University of Virginia Theory of Computation CS3102 – Spring 2014 A tale.
Regular Languages A language is regular over  if it can be built from ;, {  }, and { a } for every a 2 , using operators union ( [ ), concatenation.
Formal Language Finite set of alphabets Σ: e.g., {0, 1}, {a, b, c}, { ‘{‘, ‘}’ } Language L is a subset of strings on Σ, e.g., {00, 110, 01} a finite language,
Regular Expressions (RE) Empty set Φ A RE denotes the empty set Empty string λ A RE denotes the set {λ} Symbol a A RE denotes the set {a} Alternation M.
Basics of automata theory
On the intersection of submonoids of the free monoid L. Giambruno A. Restivo.
TM Design Universal TM MA/CSSE 474 Theory of Computation.
Introduction to CS Theory Lecture 3 – Regular Languages Piotr Faliszewski
Automating Construction of Lexers. Example in javacc TOKEN: { ( | | "_")* > | ( )* > | } SKIP: { " " | "\n" | "\t" } --> get automatically generated code.
Athasit Surarerks THEORY OF COMPUTATION 07 NON-DETERMINISTIC FINITE AUTOMATA 1.
Framed vs Unframed Two-dimensional languages Marcella Anselmo Natasha Jonoska Maria Madonia Univ. of Salerno Univ. South Florida Univ. of Catania ITALY.
Computing languages by (bounded) local sets Dora Giammarresi Università di Roma “Tor Vergata” Italy.
Push-down Automata Section 3.3 Fri, Oct 21, 2005.
1 CD5560 FABER Formal Languages, Automata and Models of Computation Lecture 3 Mälardalen University 2010.
D E C I D A B I L I T Y 1. 2 Objectives To investigate the power of algorithms to solve problems. To explore the limits of algorithmic solvability. To.
INHERENT LIMITATIONS OF COMPUTER PROGAMS CSci 4011.
An Introduction to Rabin Automata Presented By: Tamar Aizikowitz Spring 2007 Automata Seminar.
1 Pushdown Automata There are context-free languages that are not regular. Finite automata cannot recognize all context-free languages.
The decidability of Presburger Arithmetic By Guillermo Guillen 04/13/05 Dr. Smith COT 6421 FIU Spring 2005.
1 CD5560 FABER Formal Languages, Automata and Models of Computation Lecture 3 Mälardalen University 2007.
CSCI 4325 / 6339 Theory of Computation Zhixiang Chen.
Regular Languages Chapter 1 Giorgi Japaridze Theory of Computability.
Complexity and Computability Theory I Lecture #5 Rina Zviel-Girshin Leah Epstein Winter
1 CD5560 FABER Formal Languages, Automata and Models of Computation Lecture 3 Mälardalen University 2006.
Finite Automata A simple model of computation. 2 Finite Automata2 Outline Deterministic finite automata (DFA) –How a DFA works.
Pushdown Automata Chapter 12. Recognizing Context-Free Languages Two notions of recognition: (1) Say yes or no, just like with FSMs (2) Say yes or no,
What do we know? DFA = NFA =  -NFA We have seen algorithms to transform DFA to NFA (trival) NFA to  NFA (trivial) NFA to DFA (subset construction)
1 Key to Homework #3 (Models of Computation, Spring, 2001) Finite state control with a 4-way read/write head Figure (a)Figure (b) (over)
Lecture #5 Advanced Computation Theory Finite Automata.
Lexical analysis Finite Automata
Non Deterministic Automata
Chapter 2 Finite Automata
Chapter 2 FINITE AUTOMATA.
CSC 4170 Theory of Computation Nondeterminism Section 1.2.
REGULAR LANGUAGES AND REGULAR GRAMMARS
Closure Properties for Regular Languages
Nondeterministic Finite Automata
Non Deterministic Automata
Finite Automata.
4b Lexical analysis Finite Automata
Finite-State Methods in Natural-Language Processing: Basic Mathematics
4b Lexical analysis Finite Automata
Instructor: Aaron Roth
CSC 4170 Theory of Computation Nondeterminism Section 1.2.
Chapter 1 Regular Language
CSC 4170 Theory of Computation Finite Automata Section 1.1.
Instructor: Aaron Roth
Presentation transcript:

1 Dal non-determinismo al determinismo ( nei linguaggi 2dim ): alcune riflessioni Marcella Anselmo, Dora Giammarresi, Maria Madonia, Antonio Restivo Riunione Prin. Varese, luglio 2006

2  finite alphabet  ** all 2dim rectangular words (pictures) over  L   ** 2dim language p  L has size (m,n) Column concatenation Row concatenation Column/Row star 2dim Languages pq p q =  p  q = p q

3 Local 2dim Languages L is local if there exists a finite set  of tiles that contains all allowed subpictures of size (2,2,), i.e. p  L if and only if any 2  2 sub-picture of is in  p  tile: a square picture of size (2,2) bordered picture p:         p = 

4 L d = the set of square pictures with symbol “1” in all main diagonal positions and symbol “0” in the other positions (Usual) Example of local language   1  1    1  0  0  0 00  01   0   00 0  0   0    1  = p = ##### #100# #010# #001# ##### 

5 L is recognizable by tiling system if L=  (L’) where L’ is a local language and  is a mapping from the alphabet  of L’ to the alphabet  of L Recognizable 2dim Languages REC is the family of two-dimensional languages recognizable by tiling system REC is closed almost under all operations but it is not closed under complement ( , , ,  ), where L’=L(  ), is called tiling system

6 (Usual) Example L Sq = all squares over  = {a}. L Sq is recognizable by tiling system. Set L’=L d and  (1)=  (0)= a  L d aaa aaa aaa 

7 #### (Usual) Example L Sq = squares over {a}. Use L’=L d  (1)=  (0)= a aaa aaa aaa   1  1    1  0  0  0 00  01   0   00 0  0   0    1  = ##### ## ## ## # p =  “Computing” by a tiling system (from a tiling system to an automaton) First, decide a scanning strategy!

8 “Computing” by a tiling system (from a tiling system to an automaton) Remark :Tiling system = “undirectional” transitions Definition: A 2dim finite automaton is Tiling system + scanning procedure Local picture is the run of the automaton. Remark : All 2dim finite automata “correspond” to family REC (i.e. scanning procedure does not matter!) Ex: 2OTA (2dim on-line tesselation automata)

9 Scanning strategies (I) ######## ## ## ## ## ## ## ######## Diagonal (“2OTA”) ######## ## ## ## ## ## ## ######## By column

10 Scanning strategies (II) ######## ## ## ## ## ## ## ######## Snake-like Free ######## ## ## ## ## ## ## ########

11 A remark about REC A tiling system (= local language + projection) “generalizes” to 2 dim a non-deterministic finite automaton. Family REC is not closed under complement Definition of REC is intrinsically non-deterministic and it is not possible to eliminate non-determinism without getting a smaller class!

12 From non-determinism to determinism.... Non-determinism Possible accepting computations: “several” Possible backtracking steps at each step of computation: linear in the size of input [if pictures: =O(m  n)] Determinism Possible accepting computations: 1 Possible backtracking steps at each step of computation: 0

13 Remark on 1DIM case : In string languages 2 definitions possible: -Determinism from left to right - Co-determinism from right to left Correspond to same class!....choose one definition… ?? Remark: Languages recognized by automata that are both deterministic and co-deterministic are smaller class!

14 A tiling system is Top-Left-deterministic if  a,b,c   and s    unique tile such that  (s)=d. ab cd (Analogously TR-,BL-,BR-deterministic tiling system) ?? There is an unique way to fill this position with a symbol of  L is deterministic if it has a TL- or TR- or BL- or BR- deterministic tiling system Deterministic Recognizable Languages (DREC) Classical definition (only a bit extended)

15 L col-1n  REC a baba babaa bb ababb aaaab ababbb p’= L col-1n = {p | first col = last col }  {a,b} ** New Example Local alphabet:  = {x y } Projection “erase” subscripts:  ( x y ) = x L col-1n  DREC L col-  1i = {p |  1<i  n, first col = col i}  DREC

16 From non-determinism to determinism: what can we define in beetween? Non-determinism Possible accepting computations: “several” Possible backtracking steps at each step of computation: linear in the size of p (m  n) Determinism Possible accepting computations: 1 Possible backtracking steps at each step of computation: 0 Unambiguity one

17 Unambiguous Recognizable Languages (UREC) Def [GR92] A tiling system ( , , ,  ) is unambiguous for L   ** if the projection π is injective on L(  ) (i.e. for any p  L there is a unique p’  L’ such that  (p’)=p). UREC: all unambiguous recognizable 2dim languages. L   ** is unambiguous if it admits an unambiguous tiling system. UREC  REC Generalization in 2dims of unambiguous automata for strings

18 UREC and REC L col-  ij  REC L col-  ij  UREC L col-  ij =  ** L col-1n  ** and REC is closed with respect to   UREC REC  L col-  ij = i j  i,j: col i = col j Necess. Cond. for UREC

19 Properties of UREC Proposition UREC is not closed under row/column concatenation/closure. Proposition UREC is closed under intersection and rotation operations.

20 From non-determinism to determinism: what can we define in beetween? (2) Non-determinism Possible accepting computations: “several” Possible backtracking steps at each step of computation: linear in the size of p (m  n) Determinism Possible accepting computations: 1 Possible backtracking steps at each step of computation: 0 one dimension of p (m or n) “line”-unambiguity one

21 A tiling system is Left-Right Column-Unambiguous if, after having computed the local symbols in an entire column, the local symbols on the next column are univocally determined. ?? L is Col-UREC if L has a tiling system that is LR- or RL- column unambiguous. Column-Unambiguos Languages (Col-UREC) Remark: Backtracking at each step of possibly O(m) steps.

22 A tiling system is Top-Down Row-Unambiguous if, after having computed the local symbols in an entire row of a picture, the local symbols on the next row are univocally determined. ?? L is Row-UREC if L has a tiling system that is TD- or DT- column unambiguous. Row-Unambiguos Languages (Row-UREC) Remark: Backtracking at each step of possibly O(n) steps.

23 (A new) Example  = {a, b} L Sq-cent-a = odd-side squares with a in center position abba bbab aaaa babb b b b b a a aa a a0a0 b0b0 b0b0 a2a2 b1b1 b0b0 a2a2 b0b0 a0a0 a1a1 a0a0 a0a0 b2b2 a0a0 b1b1 b0b0 b1b1 b0b0 b0b0 b1b1 a0a0 a0a0 a0a0 a2a2 a0a0 L Sq-cent-a  Col-UREC, Row-UREC L Sq-cent-a  DREC By an “old” proof by Inoue et al.

24 Col-UREC and UREC L col-  1ij n  UREC L col-  1ijn  Col-UREC L col-  1ijn = L col-  1j  L col-  in and UREC is closed with respect to  Col- UREC UREC   i,j: col 1 = col j col i = col n L col-  1ij n = 1ijn  Necess. Cond. for Col-UREC

25 A necessary condition for unambiguity Theorem Let L   **. There is a k such that, for all m, 1.If L  Col-UREC then Row(M L(m) )  k m 2.If L  UREC then Rank Q (M L(m) )  k m L(m)  L is the subset of all pictures with m rows. It can be viewed as a string language over the columns alphabet. S  *, regular string language. M S is the boolean matrix M S =|a  |   *,   * where a  = 1 iff   L. The number of different rows, Row(M S ), is finite. Idea of Proof Use Matz’s Theorem and Hromkovic et al. Theorem

26 From 2dim to 1dim Theorem [ Matz 97 ] Let L   **. If L  REC, then there is a k such that, for all m, there is a finite string automaton A m with k m states for L(m). Fact If L  UREC, then A m is an unambiguous automaton with k m states for L(m). If L  Col-UREC, then A m is a deterministic automaton with k m states for L(m).

27 Theorem of Hromkovic et al. Theorem (Hromkovic et al.) For every regular string language S  *, d(S) = Row(M S ) uns(S)  Rank Q (M S ). d(S) the size of the minimal deterministic automaton accepting S uns(S) the size of a minimal unambiguous non- deterministic automaton accepting S.

28 The following inclusions are all strict: DREC  Col-UREC  UREC  REC Collecting all classes… a   1ijn   i j  

29 A separation result Theorem Whatever we choose a definition of deterministic 2dim finite automaton, the family of corresponding languages is strictly included in UREC. Proof : By previous strict inclusions results (Col-UREC  UREC ) Det-REC is strictly included in UREC, for any definition of Det-REC we choose.

30 An undecidability result for UREC Theorem Given a tiling system ( , , ,  ) for L   **, it is undecidable whether it is unambiguous. Proof : By reduction from the undecidable 2dimensional Unique Decipherability Problem.

31 A decidability result for Col-UREC (Row-UREC) Theorem Given a tiling system T = ( , , ,  ) for L   **, it is decidable whether it is col-unambiguous. Proof : Let M=Card {( ,  ) : ,    }. T col-unambiguous No pair of pictures sp with p, s, t   n,1 s  t  (s) =  (t) Any 2  2 sub-picture of p s, p t in  n  M   tp

32 A tiling system is Top-Left Diagonal-Unambiguous if, after having computed the local symbols in an entire diagonal of a picture, the local symbols on the next diagonal are univocally determined. ?? L is Diag-UREC if L has a tiling system that is TL-, TD-, BL- or BR- diagonal unambiguous. REMARK: Diag-Unambiguos Languages Remark: NO backtracking at each step

33 Conjecture: If L  REC\UREC then  L  REC Is UREC largest subset in REC closed under complement? Is UREC (Col-UREC) closed under complement? Open Problems Is L(4NFA)  UREC?

34 Conclusioni alle riflessioni… Tiling systems are a “compact” way to represent classes of finite state automata on 2 dims. Unambiguos languages are a strict intermediate class between non-deterministic and deterministic families.

35 riflettere a mente fresca…