59
An Automata-Theoretical Characterization of Context-Free Trace Languages Benedek Nagy Friedrich Otto Department of Computer Science Fachbereich Elektrotechnik/Informatik Faculty of Informatics Universitat Kassel University of Debrecen, Hungary Kassel, Germany SOFSEM 2011. Novy Smokovec, Slovakia

An Automata-Theoretical Characterization of Context-Free Trace Languages

  • Upload
    tracey

  • View
    31

  • Download
    0

Embed Size (px)

DESCRIPTION

An Automata-Theoretical Characterization of Context-Free Trace Languages. Benedek Nagy Friedrich Otto Department of Computer Science Fachbereich Elektrotechnik / Informatik Faculty of Informatics Universitat Kassel - PowerPoint PPT Presentation

Citation preview

Page 1: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

An Automata-Theoretical Characterization of

Context-Free Trace Languages

Benedek Nagy Friedrich OttoDepartment of Computer Science Fachbereich Elektrotechnik/InformatikFaculty of Informatics Universitat KasselUniversity of Debrecen, Hungary Kassel, Germany

SOFSEM 2011. Novy Smokovec, Slovakia

Page 2: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

Outline• Introduction, concepts, definitions• Stateless R-automata with constant

window size – with window size 1• CD-systems (of stateless det. R-aut. with

window size 1) with external PushDown• The new model – (an alternative view)• Context-free trace languages• The title, i.e., the main result• Concluding remarks

Page 3: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

Stateless Restarting (R-)automata• Restarting automata – linguistic motivation

Principle of analysis by reduction• (,¢,$,k,), where

is a finite alphabet, ¢, $ markers left, right border of the workspace k ≥ 1 is the size of the read/write window, is the transition relation there are 3 types of transitions

• Deterministic machine – at most 1 transition

Page 4: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

Transitionsthere are 3 types of transitions:• move-right steps (MVR), which shift the

window one step to the right, • combined rewrite/restart steps, which

delete one or more symbols from the content u of the window, thereby shortening the tape, and place the window over the left end of the tape, and

• accept steps (Accept), which cause the automaton to halt and accept.

Page 5: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

Efficiency of Restart-autom.

is accepted by a stateless deterministic R(2)-automaton for each n.

These machines are monotone, therefore

With k=9: non CF language

Page 6: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

Det R-automata with k=1

• The alphabet can be partitioned:

Page 7: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

Accepted language• Without rewriting/restarting step

(tail computation)

• Allowing rewriting/restarting steps (cycles):

Page 8: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

CD systems

• Cooperating Distributed system• More than 1 device, work one after the other

several modes are known• For stateless deterministic R-automata we

use =1 mode (the simplest combination)• We need: initial component(s) and define the

successor(s) for each component• In PDCD systems an external pushdown

helps to choose the next component

Page 9: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

PushDown CD-Systems of Stateless Determ. R(1)-Automata• with• I is a finite set of indices• is a finite input alphabet• componentsstateless det. R(1)-automata • Possible sucessors • Initial indices are:

Page 10: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

PushDown CD-Systems of Stateless Determ. R(1)-Automata• with• is a finite pusdown alphabet• • Successor relation :

Page 11: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

Configurations of a PDCD-stl-dR(1) system

• A configuration of M is (i, ¢w$, α), where i I is the index of the active∈ component Mi,¢w$ (w Σ∈ ∗) is a restarting config. of Mi, andα ∈ ⊥· Γ∗ is the content of the PD store with the first symbol of α at the bottom and the last symbol of α at the top.

• For w Σ∈ ∗, an initial configuration of M on input w has the form (i0, cw$,⊥) for i0 I∈ 0, and

• an accepting configuration has the form (i, Accept,⊥).

Page 12: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

Work of PDCD-stl-dR(1) systems

• The single-step computation relation ⇒ is defined by the following three rules, where i I, w Σ∈ ∈ ∗, α · Γ∈ ⊥ ∗, A Γ, ∈are the subsets of Σ: (MVR and delete)

rewriting/restarting

Page 13: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

Work of PDCD-stl-dR(1) systems

• The single-step computation relation ⇒ is defined by the following three rules, where i I, w Σ∈ ∈ ∗, α · Γ∈ ⊥ ∗, A Γ, ∈are the subsets of Σ: (MVR and delete)

rewrite/restart for empty stack

Page 14: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

Work of PDCD-stl-dR(1) systems

• The single-step computation relation ⇒ is defined by the following three rules, where i I, w Σ∈ ∈ ∗, α · Γ∈ ⊥ ∗, A Γ, ∈are the subsets of Σ: (MVR and delete)

accept

Page 15: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

Accepted language

• By ⇒ ∗ we denote the computation relation of M, which is simply the reflexive and transitive closure of the relation . The ⇒language L(M) accepted by M consists of all words for which M has an accepting computation, that is,

Page 16: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

OC-CD-R(1)

• A PD-CD-R(1)-system is called a one-counter CD-system of stateless deterministic R(1)-automata (OC-CD-R(1)-system for short), if |Γ | = 1, that is, if there is only a single pushdown symbol in addition to the bottom marker ⊥.

Page 17: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

The new model – other point of view• Let the tape is divided to | | slices• At a ‘state’ (i.e. component) the machine

can see the first desired letter, if only ‘translucent’ letters are before

• We have a PDA (or a one-counter machine) that use such input tape (with tranclucent letters)

Page 18: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

Example

L={ }4 components:

1. delete an ‘a’ and extend the stack 1.,2.2. delete a ‘b’ (c translucent) 3.3. delete a ‘c’ (b transl.), remove stack 2,0.0. accept the empty: on $, (no translucent)

Initial {0,1}

Page 19: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

Example

L={ }

Initial {0,1}1. delete an ‘a’ and extend the stack 1.,2.

Page 20: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

Example

L={ }

Initial 11. delete an ‘a’ and extend the stack 1.,2.

Page 21: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

Example

L={ }

1. delete an ‘a’ and extend the stack 1.

Page 22: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

Example

L={ }

1. delete an ‘a’ and extend the stack 1.

Page 23: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

Example

L={ }

1. delete an ‘a’ and extend the stack 1.

Page 24: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

Example

L={ }

1. delete an ‘a’ and extend the stack 1.

Page 25: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

Example

L={ }

1. delete an ‘a’ and extend the stack 2.

Page 26: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

Example

L={ }

2. delete a ‘b’ (c translucent) 3.

Page 27: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

Example

L={ }

2. delete a ‘b’ (c translucent) 3.

Page 28: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

Example

L={ }

2. delete a ‘b’ (c translucent) 3.

Page 29: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

Example

L={ }

3. delete a ‘c’ (b transl.), remove stack 2,0.

Page 30: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

Example

L={ }

3. delete a ‘c’ (b transl.), remove stack 2,0.

Page 31: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

Example

L={ }

3. delete a ‘c’ (b transl.), remove stack 2.

Page 32: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

Example

L={ }

2. delete a ‘b’ (c translucent) 3.

Page 33: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

Example

L={ }

2. delete a ‘b’ (c translucent) 3.

Page 34: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

Example

L={ }

2. delete a ‘b’ (c translucent) 3.

Page 35: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

Example

L={ }

3. delete a ‘c’ (b transl.), remove stack 2,0.

Page 36: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

Example

L={ }

3. delete a ‘c’ (b transl.), remove stack 2.

Page 37: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

Example

L={ }

2. delete a ‘b’ (c translucent) 3.

Page 38: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

Example

L={ }

2. delete a ‘b’ (c translucent) 3.

Page 39: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

Example

L={ }

3. delete a ‘c’ (b transl.), remove stack 0,2.

Page 40: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

Example

L={ }

3. delete a ‘c’ (b transl.), remove stack 0,2.

Page 41: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

Example

L={ }

3. delete a ‘c’ (b transl.), remove stack 0

Page 42: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

Example

L={ }

0. accept the empty: on $, (no translucent)aaaccbcbb has been ACCEPTED.

L is an OC-CD-R(1) language.

Page 43: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

PD-CD and OC-CD languages• With one counter the machine is more

powerful than without any additional data structure (example L)

• By simulation of a PDA (OC), every context-free/one-counter language is in our families (no need of translucency)

Page 44: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

PD-CD and OC-CD languages

• The proof goes by simulation of PDA based on quadratic Greibach normal form grammar (each rule has at most 2 nonterminals on its right-hand side)

Page 45: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

Normal from (NF) machine

• 1. can accept only empty string.

• 2. For every other components

can delete exactly 1 letter, no acceptance on

any letters (nor on $)

There is an equivalent machine for each in NF

One can construct equivalent NF machine..

Page 46: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

Semi-linearity

contains a letter equivalent context-free sublanguage. (also for OC-CD and OC)

Idea: words accepted in a way that the first letter is being deleted in every step form a language that is accepted by a PDA (OC).

is not in our class.

Page 47: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

Trace languagesA dependency relation D is a binary relation on an

alphabet that is reflexive and symmetric.Then is the corresponding

independence relation. It is irreflexive and symmetric. It induces a bin. relation that is defined as the smallest congruence relation containing the For , the congruence class of w mod D is denoted by [w]D. These congruence classes are called traces, and the factor monoid is a trace monoid.

Page 48: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

• Alph(w) is the set of letters occur in w.• Extension to words: if and only if

Page 49: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

Rational trace monoids

• A subset S of a trace monoid M(D) is rational if it can be obtained from singleton sets by a finite number of unions, products, and star operations.

• It follows that S M(D) is rational if and only if there exists a regular language L over such that .

• By RAT(M(D)) we denote the set of rational subsets of M(D).

Page 50: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

OC trace languages

• A language L Σ⊆ ∗ is a one-counter trace language, if there exist - a dependency relation D on Σ and - a one-counter language R Σ⊆ ∗ such that

• denotes the set of one-counter trace languages obtained from (Σ,D).

Page 51: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

Context-free trace languages

• A language L Σ⊆ ∗ is a context-free trace language, if there exist - a dependency relation D on Σ and - a context-free language R Σ⊆ ∗ such that

• denotes the set of context-free trace languages obtained from (Σ,D).

Page 52: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

Main theorems (the title of the talk)

• If D is a dependency relation on a finite alphabet Σ, then

• The proof is constructive: there is a CFL:grammar (quadr.Greibach) PD-CD-R(1)if a component can erase ‘a’ then all ‘b’-s are translucent

Page 53: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

Main theorems (the title of the talk)• Let M be a PD-CD-R(1) in NF satisfying

(if two components erase the same letter, then their translucent letters are the same)

• With M we associate the binary relation

(a, b) in it iff there exists a component Mi such that δi(a) = MVR and δi(b) = ε.Further

Page 54: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

We have an ‘if and only if’ characterization of CF trace languages by our machines:

• Let M be a PD-CD-R(1) in NF satisfying

• If the relationis symmetric,then L(M) is a CF trace language.

• In fact from M a PDA B can be constructedsuch that

• Analogous result for OC…

Page 55: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

Hierarchy of language classes of various CD-R(1)-systems

• Each arrow: proper inclusion, • not connected classes are incomparable.

Page 56: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

Conclusions

• New automata model : new language familiessemi-lin. languages, all CF are included

• not closed under intersection with regular languages, intersection or complementation,

• closed under union and under the operation of taking the commutative closure

• OPEN: product, Kleene star …• Other applications of the new automata

model?

Page 57: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

Literature• Aalbersberg, I., Rozenberg, G.: Theory of traces. Theoretical Computer

Science 60, 1–82 (1988)• Diekert, V., Rozenberg, G.: The Book of Traces. World Scientific,

Singapore (1995)• Jancar, P., Moller, F., Sawa, Z.: Simulation problems for one-counter

machines. SOFSEM 1999. LNCS 1725, pp. 404–413.• Messerschmidt, H., Otto, F.: Cooperating distributed systems of restarting

automata. Intern. J. Found. Comput. Sci. 18, 1333–1342 (2007)• Nagy, B., Otto, F.: CD-systems of stateless deterministic R(1)-automata

accept all rational trace languages. LATA 2010. LNCS 6031, pp. 463–474. • Nagy, B., Otto, F.: On CD-systems of stateless deterministic R-automata

with window size one. Kasseler Informatikschriften, 2010, 2, Kassel Univ. https://kobra.bibliothek.uni-kassel.de/

• Nagy, B., Otto, F.: CD-Systems of Stateless Deterministic R(1)-Automata Governed by an External Pushdown Store, Kasseler Informatikschriften 2010, 4, Kassel University, Tech-rep: all proofs of this contribution

Page 58: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

SupportThe presented results are results of a bilateral cooperation between the two

author’s research groups. Supported bythe Balassi Intézet Magyar Ösztöndj Bizottsága (MÖB) and the Deutsche

Akademischer Austauschdienst (DAAD).It is also supported by the TÁMOP 4.2.1/B-

09/1/KONV-2010-0007 project, which is implemented through the New Hungary

Development Plan, co-financed by the European Social Fund and the European Regional

Development Fund.

Page 59: An  Automata-Theoretical Characterization  of Context-Free Trace Languages

T t t tha an n nkY yo o o ou uf

r re

i