Piecewise Testable Tree Languages Mikoaj Bojaczyk, Luc Segoufin, - - PowerPoint PPT Presentation

piecewise testable tree languages
SMART_READER_LITE
LIVE PREVIEW

Piecewise Testable Tree Languages Mikoaj Bojaczyk, Luc Segoufin, - - PowerPoint PPT Presentation

Piecewise Testable Tree Languages Mikoaj Bojaczyk, Luc Segoufin, Howard Straubing is talk is about understanding the expressive power of logics on words and trees. e logics involved can only define (some) regular languages. is talk


slide-1
SLIDE 1

Piecewise Testable Tree Languages

Mikołaj Bojańczyk, Luc Segoufin, Howard Straubing

slide-2
SLIDE 2

is talk is about understanding the expressive power of logics on words and trees. e logics involved can only define (some) regular languages.

slide-3
SLIDE 3

is talk is about understanding the expressive power of logics on words and trees. e logics involved can only define (some) regular languages.

all regular languages languages definable in logic X

Understand logic X = give na algorithm to decide if a language L is definable in X

slide-4
SLIDE 4

eorem. (I. Simon, ) A word language is piecewise testable iff its syntactic monoid is J-trivial. is talk is about understanding the expressive power of logics on words and trees. e logics involved can only define (some) regular languages.

all regular languages languages definable in logic X

Understand logic X = give na algorithm to decide if a language L is definable in X

slide-5
SLIDE 5

a c a c b

slide-6
SLIDE 6

a c b a c a b is a piece of

slide-7
SLIDE 7

a c b a c a b is a piece of Definition. A word language is called piecewise testable if it is a boolean combination of languages “words that contain w as a piece”

slide-8
SLIDE 8

a c b a c a b is a piece of Definition. A word language is called piecewise testable if it is a boolean combination of languages “words that contain w as a piece” { abc } = contains piece abc, but no piece of length 4 a*b* = no piece ba a*b*a* = no piece bab

slide-9
SLIDE 9

a c b a c a b is a piece of Definition. A word language is called piecewise testable if it is a boolean combination of languages “words that contain w as a piece” { abc } = contains piece abc, but no piece of length 4 a*b* = no piece ba a*b*a* = no piece bab

  • Fact. A language is piecewise testable iff it can be defined

by a boolean combination of formulas. Σ1(≤) ∃x∃y a(x) ∧ b(y) ∧ x ≤ y

slide-10
SLIDE 10

eorem. (I. Simon, ) A word language is piecewise testable iff its syntactic monoid is J-trivial.

slide-11
SLIDE 11

Syntactic monoid of L ⊆ Σ∗

slide-12
SLIDE 12

Syntactic monoid of L ⊆ Σ∗ Consider the two-sided Myhill-Nerode congruence w w’ ∼L holds if for every u,v ∈ Σ∗ uwv iff uw’v ∈ L ∈ L

slide-13
SLIDE 13

Syntactic monoid of L ⊆ Σ∗ Consider the two-sided Myhill-Nerode congruence w w’ ∼L holds if for every u,v ∈ Σ∗ uwv iff uw’v ∈ L ∈ L Elements of the syntactic monoid are equivalence classes of this congruence, the monoid operation is concatenation.

slide-14
SLIDE 14

Syntactic monoid of L ⊆ Σ∗ Consider the two-sided Myhill-Nerode congruence w w’ ∼L holds if for every u,v ∈ Σ∗ uwv iff uw’v ∈ L ∈ L Elements of the syntactic monoid are equivalence classes of this congruence, the monoid operation is concatenation. (aa)* a*ba* (aa)* a(aa)* a* a*ba* a*ba*b(a+b)* Language Its syntactic monoid

slide-15
SLIDE 15

eorem. (I. Simon, ) A word language is piecewise testable iff its syntactic monoid is J-trivial.

slide-16
SLIDE 16

Infix relation in a monoid For s,t,u , we say s is an infix of tsu ∈ M We say s,t are in the same J-class if they are mutual infixes ∈ M

  • Example. e syntactic monoid of (aa)* has two elements,

(aa)* and a(aa)*, which are in the same J-class. A monoid is J-trivial if each J-class has one element.

slide-17
SLIDE 17

eorem. (I. Simon, ) A word language is piecewise testable iff its syntactic monoid is J-trivial.

slide-18
SLIDE 18

eorem. (I. Simon, ) A word language is piecewise testable iff its syntactic monoid is J-trivial. (aa)* a*ba* (aa)* a(aa)* a* a*ba* a*ba*b(a+b)* Language Its syntactic monoid a(a+b)* ε a(a+b)* b(a+b)*

slide-19
SLIDE 19

eorem. (I. Simon, ) A word language is piecewise testable iff its syntactic monoid is J-trivial. (aa)* a*ba* (aa)* a(aa)* a* a*ba* a*ba*b(a+b)* Language Its syntactic monoid a(a+b)* ε a(a+b)* b(a+b)*

slide-20
SLIDE 20

eorem. (I. Simon, ) A word language is piecewise testable iff its syntactic monoid is J-trivial. (aa)* a*ba* (aa)* a(aa)* a* a*ba* a*ba*b(a+b)* Language Its syntactic monoid a(a+b)* ε a(a+b)* b(a+b)* ✗

slide-21
SLIDE 21

eorem. (I. Simon, ) A word language is piecewise testable iff its syntactic monoid is J-trivial. (aa)* a*ba* (aa)* a(aa)* a* a*ba* a*ba*b(a+b)* Language Its syntactic monoid a(a+b)* ε a(a+b)* b(a+b)* ✗

slide-22
SLIDE 22

eorem. (I. Simon, ) A word language is piecewise testable iff its syntactic monoid is J-trivial. (aa)* a*ba* (aa)* a(aa)* a* a*ba* a*ba*b(a+b)* Language Its syntactic monoid a(a+b)* ε a(a+b)* b(a+b)* ✓ ✗

slide-23
SLIDE 23

eorem. (I. Simon, ) A word language is piecewise testable iff its syntactic monoid is J-trivial. (aa)* a*ba* (aa)* a(aa)* a* a*ba* a*ba*b(a+b)* Language Its syntactic monoid a(a+b)* ε a(a+b)* b(a+b)* ✓ ✗

slide-24
SLIDE 24

eorem. (I. Simon, ) A word language is piecewise testable iff its syntactic monoid is J-trivial. (aa)* a*ba* (aa)* a(aa)* a* a*ba* a*ba*b(a+b)* Language Its syntactic monoid a(a+b)* ε a(a+b)* b(a+b)* ✓ ✗ ✗

slide-25
SLIDE 25

eorem. (I. Simon, ) A word language is piecewise testable iff its syntactic monoid is J-trivial. (aa)* a*ba* (aa)* a(aa)* a* a*ba* a*ba*b(a+b)* Language Its syntactic monoid a(a+b)* ε a(a+b)* b(a+b)* ✓ ✗ ✗

slide-26
SLIDE 26

eorem. (I. Simon, ) A word language is piecewise testable iff its syntactic monoid is J-trivial. (aa)* a*ba* (aa)* a(aa)* a* a*ba* a*ba*b(a+b)* Language Its syntactic monoid a(a+b)* ε a(a+b)* b(a+b)* ✓ ✗ ✗ If s and t are in the same J-class, then for any n one can find representatives of s and t with the same pieces of size n. w uwv u’uwvv’ uu’uwvv’v u’uu’uwvv’vv’v s t t s s ...

slide-27
SLIDE 27

eorem. (I. Simon, ) A word language is piecewise testable iff its syntactic monoid is J-trivial. (aa)* a*ba* (aa)* a(aa)* a* a*ba* a*ba*b(a+b)* Language Its syntactic monoid a(a+b)* ε a(a+b)* b(a+b)* ✓ ✗ ✗

slide-28
SLIDE 28

eorem. (I. Simon, ) A word language is piecewise testable iff its syntactic monoid is J-trivial. (aa)* a*ba* (aa)* a(aa)* a* a*ba* a*ba*b(a+b)* Language Its syntactic monoid a(a+b)* ε a(a+b)* b(a+b)* ✓ ✗ ✗

slide-29
SLIDE 29

eorem. (I. Simon, ) A word language is piecewise testable iff its syntactic monoid is J-trivial. (aa)* a*ba* (aa)* a(aa)* a* a*ba* a*ba*b(a+b)* Language Its syntactic monoid a(a+b)* ε a(a+b)* b(a+b)* ✓ ✗ ✗ Several arguments, all difficult.

slide-30
SLIDE 30

What’s the point of all this?

ere is a rich theory connecting logic, regular languages, and algebra.

slide-31
SLIDE 31

What’s the point of all this?

ere is a rich theory connecting logic, regular languages, and algebra.

eorem. (Schützenberger, McNaughton/Papert) e following are equivalent for a word language: – L is definable in first-order logic – L is star-free – the syntactic monoid of L is group-free

slide-32
SLIDE 32

What’s the point of all this?

ere is a rich theory connecting logic, regular languages, and algebra.

eorem. (Schützenberger, McNaughton/Papert) e following are equivalent for a word language: – L is definable in first-order logic – L is star-free – the syntactic monoid of L is group-free eorem. (Schützenberger, érien / Wilke) e following are equivalent for a word language: – L is definable in two-variable first-order logic – L can be defined by a type of unambiguous expression – the syntactic monoid of L is in DA

slide-33
SLIDE 33

What’s the point of all this?

ere is a rich theory connecting logic, regular languages, and algebra.

eorem. (Schützenberger, McNaughton/Papert) e following are equivalent for a word language: – L is definable in first-order logic – L is star-free – the syntactic monoid of L is group-free eorem. (Schützenberger, érien / Wilke) e following are equivalent for a word language: – L is definable in two-variable first-order logic – L can be defined by a type of unambiguous expression – the syntactic monoid of L is in DA ... more results, including modulo quantifiers, the quantifier alternation hierarchy, etc.

slide-34
SLIDE 34

What’s the point of all this?

ere is a rich theory connecting logic, regular languages, and algebra.

eorem. (Schützenberger, McNaughton/Papert) e following are equivalent for a word language: – L is definable in first-order logic – L is star-free – the syntactic monoid of L is group-free eorem. (Schützenberger, érien / Wilke) e following are equivalent for a word language: – L is definable in two-variable first-order logic – L can be defined by a type of unambiguous expression – the syntactic monoid of L is in DA ... more results, including modulo quantifiers, the quantifier alternation hierarchy, etc.

What about trees?

slide-35
SLIDE 35

What’s the point of all this?

ere is a rich theory connecting logic, regular languages, and algebra.

eorem. (Schützenberger, McNaughton/Papert) e following are equivalent for a word language: – L is definable in first-order logic – L is star-free – the syntactic monoid of L is group-free eorem. (Schützenberger, érien / Wilke) e following are equivalent for a word language: – L is definable in two-variable first-order logic – L can be defined by a type of unambiguous expression – the syntactic monoid of L is in DA ... more results, including modulo quantifiers, the quantifier alternation hierarchy, etc.

What about trees?

is paper is part of a program to extend the algebra-logic connection to trees

slide-36
SLIDE 36

a b a a a b a a b b a b

A tree is finite, unranked and labeled

slide-37
SLIDE 37

a b a a a b a a b b a b

A tree is finite, unranked and labeled A forest is a sequence of trees

a b a a a b a a b a b

slide-38
SLIDE 38

a b a a a b a a b b a b

A tree is finite, unranked and labeled A forest is a sequence of trees

a b a a a b a a b a b

A context is a forest with a hole in a leaf

a b a b a

slide-39
SLIDE 39

a b a a a b a a b b a b

A tree is finite, unranked and labeled A forest is a sequence of trees

a b a a a b a a b a b

A context is a forest with a hole in a leaf

a b a b a a a b b a b a a a b b a b

=

slide-40
SLIDE 40

Notion of piece for forests and contexts. is a piece of is a piece of

slide-41
SLIDE 41

Notion of piece for forests and contexts. is a piece of is a piece of Definition. A forest language is called piecewise testable if it is a boolean combination of languages “forests that contain t as a piece”

slide-42
SLIDE 42

Notion of piece for forests and contexts. is a piece of is a piece of Definition. A forest language is called piecewise testable if it is a boolean combination of languages “forests that contain t as a piece”

  • Fact. A forest language is piecewise testable iff it can be

defined by a boolean combination of formulas. Σ1(≤, ≤lex)

slide-43
SLIDE 43
slide-44
SLIDE 44

{ } contains piece contains no piece with 5 nodes

slide-45
SLIDE 45

{ } contains piece contains no piece with 5 nodes all leaves are contains no piece

slide-46
SLIDE 46

{ } contains piece contains no piece with 5 nodes all leaves are contains no piece forest is a word (vertically) contains no piece

slide-47
SLIDE 47

{ } contains piece contains no piece with 5 nodes all leaves are contains no piece forest is a word (vertically) contains no piece forest is a word (horizontally) contains no piece

slide-48
SLIDE 48

eorem. (I. Simon, ) A word language is piecewise testable iff its syntactic monoid is J-trivial. We want the forest extension of:

slide-49
SLIDE 49

eorem. (I. Simon, ) A word language is piecewise testable iff its syntactic monoid is J-trivial. What is a syntactic monoid for forest languages? Although a definition exists (forest algebra), here we will only talk about Myhill-Nerode equivalence. We want the forest extension of:

slide-50
SLIDE 50

Myhill-Nerode congruence for a forest language L.

slide-51
SLIDE 51

Myhill-Nerode congruence for a forest language L. Two contexts and are called L-equivalent if

slide-52
SLIDE 52

Myhill-Nerode congruence for a forest language L. Two contexts and are called L-equivalent if for every context and every forest

slide-53
SLIDE 53

Myhill-Nerode congruence for a forest language L. Two contexts and are called L-equivalent if for every context and every forest ∈ L iff ∈ L

slide-54
SLIDE 54

Main eorem. A forest language is piecewise testable iff the following holds for all sufficiently large n

slide-55
SLIDE 55

Main eorem. A forest language is piecewise testable iff the following holds for all sufficiently large n is a piece of if , then

slide-56
SLIDE 56

Main eorem. A forest language is piecewise testable iff the following holds for all sufficiently large n is equivalent to is a piece of if , then

n times{ n times{ n times

}

n times

}

slide-57
SLIDE 57

Main eorem. A forest language is piecewise testable iff the following holds for all sufficiently large n is equivalent to is a piece of if , then

n times{ n times{ n times

}

n times

}

is criterion is decidable. We also have variants of the theorem for – tree languages – commutative pieces – pieces with closest common ancestor

slide-58
SLIDE 58

e language is confused with * has a J-trivial syntactic monoid, but is not piecewise testable

slide-59
SLIDE 59

Big project: understand the expressive power of first-order logic on trees.

slide-60
SLIDE 60

FO(≤) Big project: understand the expressive power of first-order logic on trees. regular languages

slide-61
SLIDE 61

FO(≤) Σ1(≤) Π1(≤) Big project: understand the expressive power of first-order logic on trees. regular languages

slide-62
SLIDE 62

FO(≤) Σ1(≤) Π1(≤) Big project: understand the expressive power of first-order logic on trees. regular languages Easy excercise

slide-63
SLIDE 63

FO(≤) Σ1(≤) Π1(≤) Bool(Σ1(≤)) Big project: understand the expressive power of first-order logic on trees. regular languages Easy excercise

slide-64
SLIDE 64

FO(≤) Σ1(≤) Π1(≤) Bool(Σ1(≤)) Big project: understand the expressive power of first-order logic on trees. regular languages is paper Easy excercise

slide-65
SLIDE 65

FO(≤) Σ1(≤) Π1(≤) Bool(Σ1(≤)) Σ2(≤) Π2(≤) ∆2(≤) Big project: understand the expressive power of first-order logic on trees. regular languages is paper Easy excercise

slide-66
SLIDE 66

FO(≤) Σ1(≤) Π1(≤) Bool(Σ1(≤)) Σ2(≤) Π2(≤) ∆2(≤) Big project: understand the expressive power of first-order logic on trees. regular languages is paper BS, ICALP  Easy excercise

slide-67
SLIDE 67

FO(≤) Σ1(≤) Π1(≤) Bool(Σ1(≤)) Σ2(≤) Π2(≤) ∆2(≤) Big project: understand the expressive power of first-order logic on trees. regular languages =? =? =? is paper BS, ICALP  Easy excercise