Early Math Counting & Skip Counting. Early Math “0” – see the number Counting & Skip Counting.
Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2...
Transcript of Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2...
![Page 1: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/1.jpg)
Regular Expressions with Counting:Weak versus Strong Determinism
Wouter Geladea Marc Gyssensa Wim Martensb
a Hasselt University, Belgiumb TU Dortmund, Germany
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 1 / 29
![Page 2: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/2.jpg)
Introduction
Regular Expressions
Regular Expressions are used in a wide array of applications(Bioinformatics, Programming Languages, Model Checking, XML SchemaLanguages, etc.)
Standard Regular Expressions (REG(Σ))
/0, ε, and every a ∈ Σ are in REG(Σ)
for standard regular expressions r and s,rs, r + s, r?, and r∗ are in REG(Σ)
To keep users happy. . .many applications add operators (counting, negation, intersection,. . . )
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 2 / 29
![Page 3: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/3.jpg)
Introduction
Regular Expressions
Regular Expressions are used in a wide array of applications(Bioinformatics, Programming Languages, Model Checking, XML SchemaLanguages, etc.)
Standard Regular Expressions (REG(Σ))
/0, ε, and every a ∈ Σ are in REG(Σ)
for standard regular expressions r and s,rs, r + s, r?, and r∗ are in REG(Σ)
To keep users happy. . .many applications add operators (counting, negation, intersection,. . . )
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 2 / 29
![Page 4: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/4.jpg)
Introduction
Regular Expressions
Regular Expressions are used in a wide array of applications(Bioinformatics, Programming Languages, Model Checking, XML SchemaLanguages, etc.)
Standard Regular Expressions (REG(Σ))
/0, ε, and every a ∈ Σ are in REG(Σ)
for standard regular expressions r and s,rs, r + s, r?, and r∗ are in REG(Σ)
To keep users happy. . .many applications add operators (counting, negation, intersection,. . . )
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 2 / 29
![Page 5: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/5.jpg)
Introduction
To keep users happy. . .many applications add operators (counting, negation, intersection,. . . )
Regular Expressions with Counting (REG#(Σ))
All REG(Σ) are REG#(Σ)
If r is a REG#(Σ), then rk,` for k ≤ ` ∈ N is also a REG#(Σ)
Example: (ab)3,5
(matches ababab, abababab, and ababababab)
Counting is used in, e.g.,. . .
XML Schema
egrep
Perl patterns
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 3 / 29
![Page 6: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/6.jpg)
Introduction
To keep users happy. . .many applications add operators (counting, negation, intersection,. . . )
Regular Expressions with Counting (REG#(Σ))
All REG(Σ) are REG#(Σ)
If r is a REG#(Σ), then rk,` for k ≤ ` ∈ N is also a REG#(Σ)
Example: (ab)3,5
(matches ababab, abababab, and ababababab)
Counting is used in, e.g.,. . .
XML Schema
egrep
Perl patterns
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 3 / 29
![Page 7: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/7.jpg)
Introduction
To keep users happy. . .many applications add operators (counting, negation, intersection,. . . )
Regular Expressions with Counting (REG#(Σ))
All REG(Σ) are REG#(Σ)
If r is a REG#(Σ), then rk,` for k ≤ ` ∈ N is also a REG#(Σ)
Example: (ab)3,5
(matches ababab, abababab, and ababababab)
Counting is used in, e.g.,. . .
XML Schema
egrep
Perl patterns
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 3 / 29
![Page 8: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/8.jpg)
Outline
1 Determinism in Regular Expressions
2 The Situation Without Counting
3 ResultsExpressive PowerSuccinctnessExpressions versus AutomataComplexity Results
4 Concluding Remarks
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 4 / 29
![Page 9: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/9.jpg)
Deterministic Regular Expressions
Deterministic regular expressions exist to facilitate matching(also called one-unambiguous regular expressions)
“When matching a string from left to right,it’s always clear which position in the expression to match next”
Example
c(a +b)∗a is not deterministic
cb∗a(b∗a)∗ is deterministic and equivalent
Deterministic expressions are used in, e.g., . . .
Document Type Definitions (DTD)
SGML
XML Schema
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 5 / 29
![Page 10: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/10.jpg)
Deterministic Regular Expressions
Deterministic regular expressions exist to facilitate matching(also called one-unambiguous regular expressions)
“When matching a string from left to right,it’s always clear which position in the expression to match next”
Example
c(a +b)∗a is not deterministic
cb∗a(b∗a)∗ is deterministic and equivalent
Deterministic expressions are used in, e.g., . . .
Document Type Definitions (DTD)
SGML
XML Schema
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 5 / 29
![Page 11: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/11.jpg)
Deterministic Regular Expressions
Deterministic regular expressions exist to facilitate matching(also called one-unambiguous regular expressions)
“When matching a string from left to right,it’s always clear which position in the expression to match next”
Example
c(a +b)∗a is not deterministic
cb∗a(b∗a)∗ is deterministic and equivalent
Deterministic expressions are used in, e.g., . . .
Document Type Definitions (DTD)
SGML
XML Schema
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 5 / 29
![Page 12: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/12.jpg)
Deterministic Regular Expressions
Deterministic regular expressions exist to facilitate matching(also called one-unambiguous regular expressions)
“When matching a string from left to right,it’s always clear which position in the expression to match next”
Example
c(a +b)∗a is not deterministic
cb∗a(b∗a)∗ is deterministic and equivalent
Deterministic expressions are used in, e.g., . . .
Document Type Definitions (DTD)
SGML
XML Schema
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 5 / 29
![Page 13: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/13.jpg)
Strong and Weak Determinism
Weak determinism: what we just saw
Strong determinism: weak determinism, plus“It should also be clear which operator to use next”
Example
(a∗)∗ is not strongly deterministic
a∗ is strongly deterministic and equivalent
Notation
DETS(Σ): strongly deterministic REG(Σ)
DETW (Σ): weakly deterministic REG(Σ)
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 6 / 29
![Page 14: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/14.jpg)
Strong and Weak Determinism
Weak determinism: what we just saw
Strong determinism: weak determinism, plus“It should also be clear which operator to use next”
Example
(a∗)∗ is not strongly deterministic
a∗ is strongly deterministic and equivalent
Notation
DETS(Σ): strongly deterministic REG(Σ)
DETW (Σ): weakly deterministic REG(Σ)
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 6 / 29
![Page 15: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/15.jpg)
Strong and Weak Determinism
Weak determinism: what we just saw
Strong determinism: weak determinism, plus“It should also be clear which operator to use next”
Example
(a∗)∗ is not strongly deterministic
a∗ is strongly deterministic and equivalent
Notation
DETS(Σ): strongly deterministic REG(Σ)
DETW (Σ): weakly deterministic REG(Σ)
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 6 / 29
![Page 16: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/16.jpg)
Strong and Weak Determinism
Weak determinism: what we just saw
Strong determinism: weak determinism, plus“It should also be clear which operator to use next”
Example
(a∗)∗ is not strongly deterministic
a∗ is strongly deterministic and equivalent
Notation
DETS(Σ): strongly deterministic REG(Σ)
DETW (Σ): weakly deterministic REG(Σ)
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 6 / 29
![Page 17: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/17.jpg)
Weak / Strong Determinism with Counting
Weak: “When matching a string from left to right,it’s always clear which position in the expression to match next”
Example
(b?a2,3)3,3b is not weakly deterministic (witness: aaaaaab . . .)
(b?a2,3)2,2b is weakly deterministic
Strong: “It should also be clear which operator to use next”
Example
(a1,2)3,4 is weakly deterministic, but not strongly deterministic
(a2,2)3,4 is weakly and strongly deterministic
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 7 / 29
![Page 18: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/18.jpg)
Weak / Strong Determinism with Counting
Weak: “When matching a string from left to right,it’s always clear which position in the expression to match next”
Example
(b?a2,3)3,3b is not weakly deterministic (witness: aaaaaab . . .)
(b?a2,3)2,2b is weakly deterministic
Strong: “It should also be clear which operator to use next”
Example
(a1,2)3,4 is weakly deterministic, but not strongly deterministic
(a2,2)3,4 is weakly and strongly deterministic
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 7 / 29
![Page 19: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/19.jpg)
Weak / Strong Determinism with Counting
Weak: “When matching a string from left to right,it’s always clear which position in the expression to match next”
Example
(b?a2,3)3,3b is not weakly deterministic (witness: aaaaaab . . .)
(b?a2,3)2,2b is weakly deterministic
Strong: “It should also be clear which operator to use next”
Example
(a1,2)3,4 is weakly deterministic, but not strongly deterministic
(a2,2)3,4 is weakly and strongly deterministic
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 7 / 29
![Page 20: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/20.jpg)
Where are we going?
XML Schema uses weakly deterministic expressions with counting
What do we know about these?
Does this class have a nice “deterministic” automata model?Is it decidable whether a regular language can be defined with a weaklydeterministic expression with counting?What’s the complexity for, e.g., membership, inclusion testing?
We’ll see that weak and strong determinism are very differentin expressions with counting
Do we want weak or strong determinism?
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 8 / 29
![Page 21: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/21.jpg)
Where are we going?
XML Schema uses weakly deterministic expressions with counting
What do we know about these?
Does this class have a nice “deterministic” automata model?Is it decidable whether a regular language can be defined with a weaklydeterministic expression with counting?What’s the complexity for, e.g., membership, inclusion testing?
We’ll see that weak and strong determinism are very differentin expressions with counting
Do we want weak or strong determinism?
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 8 / 29
![Page 22: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/22.jpg)
Where are we going?
XML Schema uses weakly deterministic expressions with counting
What do we know about these?
Does this class have a nice “deterministic” automata model?
Is it decidable whether a regular language can be defined with a weaklydeterministic expression with counting?What’s the complexity for, e.g., membership, inclusion testing?
We’ll see that weak and strong determinism are very differentin expressions with counting
Do we want weak or strong determinism?
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 8 / 29
![Page 23: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/23.jpg)
Where are we going?
XML Schema uses weakly deterministic expressions with counting
What do we know about these?
Does this class have a nice “deterministic” automata model?Is it decidable whether a regular language can be defined with a weaklydeterministic expression with counting?
What’s the complexity for, e.g., membership, inclusion testing?
We’ll see that weak and strong determinism are very differentin expressions with counting
Do we want weak or strong determinism?
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 8 / 29
![Page 24: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/24.jpg)
Where are we going?
XML Schema uses weakly deterministic expressions with counting
What do we know about these?
Does this class have a nice “deterministic” automata model?Is it decidable whether a regular language can be defined with a weaklydeterministic expression with counting?What’s the complexity for, e.g., membership, inclusion testing?
We’ll see that weak and strong determinism are very differentin expressions with counting
Do we want weak or strong determinism?
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 8 / 29
![Page 25: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/25.jpg)
Where are we going?
XML Schema uses weakly deterministic expressions with counting
What do we know about these?
Does this class have a nice “deterministic” automata model?Is it decidable whether a regular language can be defined with a weaklydeterministic expression with counting?What’s the complexity for, e.g., membership, inclusion testing?
We’ll see that weak and strong determinism are very differentin expressions with counting
Do we want weak or strong determinism?
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 8 / 29
![Page 26: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/26.jpg)
Where are we going?
XML Schema uses weakly deterministic expressions with counting
What do we know about these?
Does this class have a nice “deterministic” automata model?Is it decidable whether a regular language can be defined with a weaklydeterministic expression with counting?What’s the complexity for, e.g., membership, inclusion testing?
We’ll see that weak and strong determinism are very differentin expressions with counting
Do we want weak or strong determinism?
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 8 / 29
![Page 27: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/27.jpg)
Outline
1 Determinism in Regular Expressions
2 The Situation Without Counting
3 ResultsExpressive PowerSuccinctnessExpressions versus AutomataComplexity Results
4 Concluding Remarks
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 9 / 29
![Page 28: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/28.jpg)
What you need to know about REG(Σ)
Theorem (Implicit in Bruggmann-Klein, 1993; Brugg.-Klein,Wood, 1998)
Expressive power in a picture:
DETS(Σ) = DETW (Σ) ( REG(Σ)
Theorem (Bruggemann-Klein and Wood, 1998)
Given expression r , deciding whether there exists a deterministic expressionfor L(r) is in EXPTIME
Theorem (Implicit in Bruggmann-Klein, 1993)
Every weakly deterministic expression can be made strongly deterministicin linear time
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 10 / 29
![Page 29: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/29.jpg)
What you need to know about REG(Σ)
Theorem (Implicit in Bruggmann-Klein, 1993; Brugg.-Klein,Wood, 1998)
Expressive power in a picture:
DETS(Σ) = DETW (Σ) ( REG(Σ)
Theorem (Bruggemann-Klein and Wood, 1998)
Given expression r , deciding whether there exists a deterministic expressionfor L(r) is in EXPTIME
Theorem (Implicit in Bruggmann-Klein, 1993)
Every weakly deterministic expression can be made strongly deterministicin linear time
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 10 / 29
![Page 30: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/30.jpg)
What you need to know about REG(Σ)
Theorem (Implicit in Bruggmann-Klein, 1993; Brugg.-Klein,Wood, 1998)
Expressive power in a picture:
DETS(Σ) = DETW (Σ) ( REG(Σ)
Theorem (Bruggemann-Klein and Wood, 1998)
Given expression r , deciding whether there exists a deterministic expressionfor L(r) is in EXPTIME
Theorem (Implicit in Bruggmann-Klein, 1993)
Every weakly deterministic expression can be made strongly deterministicin linear time
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 10 / 29
![Page 31: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/31.jpg)
What you need to know
Bruggemann-Klein and Wood, 1998
Testing weak determinism of an expression is easy (O(n2))
Core operation: Glushkov(r)
Consider r = c(a +b)∗a
c1(a2 +b3)∗a4
start c1
b3
a2
a4c
b
a
a
a
b
b
a
a
a
Expression r is deterministic iff Glushkov(r) is a DFA
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 11 / 29
![Page 32: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/32.jpg)
What you need to know
Bruggemann-Klein and Wood, 1998
Testing weak determinism of an expression is easy (O(n2))
Core operation: Glushkov(r)
Consider r = c(a +b)∗a c1(a2 +b3)∗a4
start c1
b3
a2
a4c
b
a
a
a
b
b
a
a
a
Expression r is deterministic iff Glushkov(r) is a DFA
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 11 / 29
![Page 33: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/33.jpg)
What you need to know
Bruggemann-Klein and Wood, 1998
Testing weak determinism of an expression is easy (O(n2))
Core operation: Glushkov(r)
Consider r = c(a +b)∗a c1(a2 +b3)∗a4
start c1
b3
a2
a4c
b
a
a
a
b
b
a
a
a
Expression r is deterministic iff Glushkov(r) is a DFA
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 11 / 29
![Page 34: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/34.jpg)
Complexity of (Weakly) Deterministic Expressions
MEMBERSHIP: Given string w and expression r , is w ∈ L(r)?
INCLUSION: Given expressions r1, r2, is L(r1)⊆ L(r2)?
INTERSECTION: Given expressions r1, . . . , rn, is⋂i
L(ri ) 6= /0?
Theorem
For (weakly) deterministic expressions:
MEMBERSHIP is in O(n2)
INCLUSION: in PTIME [Stearns, Hunt 1981]
INTERSECTION: PSPACE-complete[Mar., Neven, Schwentick 2004]
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 12 / 29
![Page 35: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/35.jpg)
Complexity of (Weakly) Deterministic Expressions
MEMBERSHIP: Given string w and expression r , is w ∈ L(r)?
INCLUSION: Given expressions r1, r2, is L(r1)⊆ L(r2)?
INTERSECTION: Given expressions r1, . . . , rn, is⋂i
L(ri ) 6= /0?
Theorem
For (weakly) deterministic expressions:
MEMBERSHIP is in O(n2)
INCLUSION: in PTIME [Stearns, Hunt 1981]
INTERSECTION: PSPACE-complete[Mar., Neven, Schwentick 2004]
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 12 / 29
![Page 36: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/36.jpg)
Questions
The Situation for deterministic expressions. . .
Without counting
With counting
Expressiveness DETS(Σ) = DETW (Σ) ( REG(Σ)
???
Succinctness DETS(Σ)≈ DETW (Σ)
???
Det-Test easy (Glushkov)
??
∃-Det-Test EXPTIME
???
Membership O(n2)
??
Complexity PTIME/ PSPACE
??
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 13 / 29
![Page 37: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/37.jpg)
Questions
The Situation for deterministic expressions. . .
Without counting With counting
Expressiveness DETS(Σ) = DETW (Σ) ( REG(Σ)
???
Succinctness DETS(Σ)≈ DETW (Σ)
???
Det-Test easy (Glushkov)
??
∃-Det-Test EXPTIME
???
Membership O(n2)
??
Complexity PTIME/ PSPACE
??
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 13 / 29
![Page 38: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/38.jpg)
Questions
The Situation for deterministic expressions. . .
Without counting With counting
Expressiveness DETS(Σ) = DETW (Σ) ( REG(Σ) ???Succinctness DETS(Σ)≈ DETW (Σ) ???
Det-Test easy (Glushkov) ??∃-Det-Test EXPTIME ???
Membership O(n2) ??Complexity PTIME/ PSPACE ??
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 13 / 29
![Page 39: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/39.jpg)
Outline
1 Determinism in Regular Expressions
2 The Situation Without Counting
3 ResultsExpressive PowerSuccinctnessExpressions versus AutomataComplexity Results
4 Concluding Remarks
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 14 / 29
![Page 40: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/40.jpg)
Outline
1 Determinism in Regular Expressions
2 The Situation Without Counting
3 ResultsExpressive PowerSuccinctnessExpressions versus AutomataComplexity Results
4 Concluding Remarks
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 15 / 29
![Page 41: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/41.jpg)
Expressive Power
Theorem
In terms of expressive power,DETS(Σ) = DETW (Σ) = DET#
S (Σ) ( DET#W (Σ) ( REG(Σ) (if |Σ|> 1)
DETS(Σ) = DETW (Σ) = DET#S (Σ)=DET#
W (Σ) ( REG(Σ) (if |Σ|= 1)
The equalities. . .
DETW (Σ) = DET#S (Σ) (|Σ|> 1)
DETW (Σ) = DET#W (Σ) (|Σ|= 1)
are non-trivial!
Witness separating languages:
(a2,3b?)∗ is in DET#W (Σ), but not in DETW (Σ)
(aaa)∗(a +aa) is in REG(Σ), but not in DETW (Σ)
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 16 / 29
![Page 42: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/42.jpg)
Expressive Power
Theorem
In terms of expressive power,DETS(Σ) = DETW (Σ) = DET#
S (Σ) ( DET#W (Σ) ( REG(Σ) (if |Σ|> 1)
DETS(Σ) = DETW (Σ) = DET#S (Σ)=DET#
W (Σ) ( REG(Σ) (if |Σ|= 1)
The equalities. . .
DETW (Σ) = DET#S (Σ) (|Σ|> 1)
DETW (Σ) = DET#W (Σ) (|Σ|= 1)
are non-trivial!
Witness separating languages:
(a2,3b?)∗ is in DET#W (Σ), but not in DETW (Σ)
(aaa)∗(a +aa) is in REG(Σ), but not in DETW (Σ)
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 16 / 29
![Page 43: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/43.jpg)
Expressive Power
Theorem
In terms of expressive power,DETS(Σ) = DETW (Σ) = DET#
S (Σ) ( DET#W (Σ) ( REG(Σ) (if |Σ|> 1)
DETS(Σ) = DETW (Σ) = DET#S (Σ)=DET#
W (Σ) ( REG(Σ) (if |Σ|= 1)
The equalities. . .
DETW (Σ) = DET#S (Σ) (|Σ|> 1)
DETW (Σ) = DET#W (Σ) (|Σ|= 1)
are non-trivial!
Witness separating languages:
(a2,3b?)∗ is in DET#W (Σ), but not in DETW (Σ)
(aaa)∗(a +aa) is in REG(Σ), but not in DETW (Σ)
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 16 / 29
![Page 44: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/44.jpg)
Outline
1 Determinism in Regular Expressions
2 The Situation Without Counting
3 ResultsExpressive PowerSuccinctnessExpressions versus AutomataComplexity Results
4 Concluding Remarks
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 17 / 29
![Page 45: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/45.jpg)
Succinctness
Theorem
In terms of succinctness,DET#
W (Σ) is exponentially smaller than DET#S (Σ)
More precisely,for every n ∈ N, there’s a DET#
W (Σ) r of size O(n) such that every
DET#S (Σ) for L(r) is of size at least 2n
r = (a2n+1,2n+1)1,2
“all strings of as of length 2n + 1 until 2n+2, but not of length 2n+1 + 1”
Corollary
The above theorem holds for unary languages
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 18 / 29
![Page 46: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/46.jpg)
Succinctness
Theorem
In terms of succinctness,DET#
W (Σ) is exponentially smaller than DET#S (Σ)
More precisely,for every n ∈ N, there’s a DET#
W (Σ) r of size O(n) such that every
DET#S (Σ) for L(r) is of size at least 2n
r = (a2n+1,2n+1)1,2
“all strings of as of length 2n + 1 until 2n+2, but not of length 2n+1 + 1”
Corollary
The above theorem holds for unary languages
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 18 / 29
![Page 47: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/47.jpg)
Succinctness
Theorem
In terms of succinctness,DET#
W (Σ) is exponentially smaller than DET#S (Σ)
More precisely,for every n ∈ N, there’s a DET#
W (Σ) r of size O(n) such that every
DET#S (Σ) for L(r) is of size at least 2n
r = (a2n+1,2n+1)1,2
“all strings of as of length 2n + 1 until 2n+2, but not of length 2n+1 + 1”
Corollary
The above theorem holds for unary languages
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 18 / 29
![Page 48: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/48.jpg)
Succinctness
Theorem
In terms of succinctness,DET#
W (Σ) is exponentially smaller than DET#S (Σ)
More precisely,for every n ∈ N, there’s a DET#
W (Σ) r of size O(n) such that every
DET#S (Σ) for L(r) is of size at least 2n
r = (a2n+1,2n+1)1,2
“all strings of as of length 2n + 1 until 2n+2, but not of length 2n+1 + 1”
Corollary
The above theorem holds for unary languages
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 18 / 29
![Page 49: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/49.jpg)
Outline
1 Determinism in Regular Expressions
2 The Situation Without Counting
3 ResultsExpressive PowerSuccinctnessExpressions versus AutomataComplexity Results
4 Concluding Remarks
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 19 / 29
![Page 50: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/50.jpg)
Counter Automata
Counter Automaton: (Q,q0,C ,δ ,F ,τ)
Ingredients:
Q: states, q0: initial state
C : counter variables
α : C → N assigns values to counters
Transitions are guarded: δ ⊂ Q×Σ×Guard(C )×Update(C )×Q
F : Q→ Guard(C ) acceptance function
τ : C → N assigns maximum values to counters
Guard(C ): Boolean combination of true, false, c = k, c < kUpdate(C ): set of statements c + +, reset(c)
Remark
These are very similar to [McQueen]
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 20 / 29
![Page 51: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/51.jpg)
Counter Automata
Counter Automaton: (Q,q0,C ,δ ,F ,τ)
Ingredients:
Q: states, q0: initial state
C : counter variables
α : C → N assigns values to counters
Transitions are guarded: δ ⊂ Q×Σ×Guard(C )×Update(C )×Q
F : Q→ Guard(C ) acceptance function
τ : C → N assigns maximum values to counters
Guard(C ): Boolean combination of true, false, c = k, c < kUpdate(C ): set of statements c + +, reset(c)
Remark
These are very similar to [McQueen]
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 20 / 29
![Page 52: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/52.jpg)
Counter Automata
Counter Automaton: (Q,q0,C ,δ ,F ,τ)
Ingredients:
Q: states, q0: initial state
C : counter variables
α : C → N assigns values to counters
Transitions are guarded: δ ⊂ Q×Σ×Guard(C )×Update(C )×Q
F : Q→ Guard(C ) acceptance function
τ : C → N assigns maximum values to counters
Guard(C ): Boolean combination of true, false, c = k, c < kUpdate(C ): set of statements c + +, reset(c)
Remark
These are very similar to [McQueen]
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 20 / 29
![Page 53: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/53.jpg)
Counter Automata
Counter Automaton: (Q,q0,C ,δ ,F ,τ)
Ingredients:
Q: states, q0: initial state
C : counter variables
α : C → N assigns values to counters
Transitions are guarded: δ ⊂ Q×Σ×Guard(C )×Update(C )×Q
F : Q→ Guard(C ) acceptance function
τ : C → N assigns maximum values to counters
Guard(C ): Boolean combination of true, false, c = k, c < kUpdate(C ): set of statements c + +, reset(c)
Remark
These are very similar to [McQueen]
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 20 / 29
![Page 54: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/54.jpg)
Counter Automata
Counter Automaton: (Q,q0,C ,δ ,F ,τ)
Ingredients:
Q: states, q0: initial state
C : counter variables
α : C → N assigns values to counters
Transitions are guarded: δ ⊂ Q×Σ×Guard(C )×Update(C )×Q
F : Q→ Guard(C ) acceptance function
τ : C → N assigns maximum values to counters
Guard(C ): Boolean combination of true, false, c = k, c < kUpdate(C ): set of statements c + +, reset(c)
Remark
These are very similar to [McQueen]
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 20 / 29
![Page 55: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/55.jpg)
Counter Automata
Counter Automaton: (Q,q0,C ,δ ,F ,τ)
Ingredients:
Q: states, q0: initial state
C : counter variables
α : C → N assigns values to counters
Transitions are guarded: δ ⊂ Q×Σ×Guard(C )×Update(C )×Q
F : Q→ Guard(C ) acceptance function
τ : C → N assigns maximum values to counters
Guard(C ): Boolean combination of true, false, c = k, c < kUpdate(C ): set of statements c + +, reset(c)
Remark
These are very similar to [McQueen]
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 20 / 29
![Page 56: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/56.jpg)
Counter Automata
Counter Automaton: (Q,q0,C ,δ ,F ,τ)
Ingredients:
Q: states, q0: initial state
C : counter variables
α : C → N assigns values to counters
Transitions are guarded: δ ⊂ Q×Σ×Guard(C )×Update(C )×Q
F : Q→ Guard(C ) acceptance function
τ : C → N assigns maximum values to counters
Guard(C ): Boolean combination of true, false, c = k, c < kUpdate(C ): set of statements c + +, reset(c)
Remark
These are very similar to [McQueen]
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 20 / 29
![Page 57: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/57.jpg)
Counter Automata: Determinism
Configuration
(q,α), where q is a state, and α : C → N
Determinism
For every reachable configuration (q,α),
for every a ∈ Σ,
there’s at most one transition (q,a,φ ,π,q′) with α |= φ
Note
Testing determinism is PSPACE-complete
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 21 / 29
![Page 58: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/58.jpg)
Counter Automata: Determinism
Configuration
(q,α), where q is a state, and α : C → N
Determinism
For every reachable configuration (q,α),
for every a ∈ Σ,
there’s at most one transition (q,a,φ ,π,q′) with α |= φ
Note
Testing determinism is PSPACE-complete
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 21 / 29
![Page 59: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/59.jpg)
Counter Automata: Determinism
Configuration
(q,α), where q is a state, and α : C → N
Determinism
For every reachable configuration (q,α),
for every a ∈ Σ,
there’s at most one transition (q,a,φ ,π,q′) with α |= φ
Note
Testing determinism is PSPACE-complete
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 21 / 29
![Page 60: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/60.jpg)
Counter Automata: Determinism
Configuration
(q,α), where q is a state, and α : C → N
Determinism
For every reachable configuration (q,α),
for every a ∈ Σ,
there’s at most one transition (q,a,φ ,π,q′) with α |= φ
Note
Testing determinism is PSPACE-complete
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 21 / 29
![Page 61: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/61.jpg)
Counter Automata: Determinism
Configuration
(q,α), where q is a state, and α : C → N
Determinism
For every reachable configuration (q,α),
for every a ∈ Σ,
there’s at most one transition (q,a,φ ,π,q′) with α |= φ
Note
Testing determinism is PSPACE-complete
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 21 / 29
![Page 62: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/62.jpg)
From Expressions to Automata
We extend the Glushkov construction to REG#(Σ)Denote the construction by Glushkov#
Theorem
For every expression r ∈ REG#(Σ),
L(r) = L(Glushkov#(r)), and
r is strongly deterministic ⇔ Glushkov#(r) is deterministic
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 22 / 29
![Page 63: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/63.jpg)
From Expressions to Automata
We extend the Glushkov construction to REG#(Σ)Denote the construction by Glushkov#
Theorem
For every expression r ∈ REG#(Σ),
L(r) = L(Glushkov#(r)), and
r is strongly deterministic ⇔ Glushkov#(r) is deterministic
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 22 / 29
![Page 64: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/64.jpg)
Outline
1 Determinism in Regular Expressions
2 The Situation Without Counting
3 ResultsExpressive PowerSuccinctnessExpressions versus AutomataComplexity Results
4 Concluding Remarks
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 23 / 29
![Page 65: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/65.jpg)
Testing Determinism
Theorem
Testing weak determinism for REG#(Σ) is in time O(n3)(Kilpelainen and Tuhkanen 2007)
Theorem
Testing strong determinism for REG#(Σ) is in time O(n3)
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 24 / 29
![Page 66: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/66.jpg)
Testing Determinism
Theorem
Testing weak determinism for REG#(Σ) is in time O(n3)(Kilpelainen and Tuhkanen 2007)
Theorem
Testing strong determinism for REG#(Σ) is in time O(n3)
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 24 / 29
![Page 67: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/67.jpg)
Inclusion, Intersection
What should we expect? To put you in the right mood
Theorem (Gelade, Mar., Neven 2007)
INCLUSION for REG#(Σ) is EXPSPACE-complete
INTERSECTION for REG#(Σ) is PSPACE-complete
Theorem
INCLUSION for DET#S (Σ) is in PSPACE (from automata)
INTERSECTION for DET#S (Σ) and DET#
W (Σ) isPSPACE-complete
MEMBERSHIP for DET#S (Σ) is in O(n3) (from automata)
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 25 / 29
![Page 68: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/68.jpg)
Inclusion, Intersection
What should we expect? To put you in the right mood
Theorem (Gelade, Mar., Neven 2007)
INCLUSION for REG#(Σ) is EXPSPACE-complete
INTERSECTION for REG#(Σ) is PSPACE-complete
Theorem
INCLUSION for DET#S (Σ) is in PSPACE (from automata)
INTERSECTION for DET#S (Σ) and DET#
W (Σ) isPSPACE-complete
MEMBERSHIP for DET#S (Σ) is in O(n3) (from automata)
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 25 / 29
![Page 69: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/69.jpg)
Outline
1 Determinism in Regular Expressions
2 The Situation Without Counting
3 ResultsExpressive PowerSuccinctnessExpressions versus AutomataComplexity Results
4 Concluding Remarks
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 26 / 29
![Page 70: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/70.jpg)
Concluding Remarks
The Situation for deterministic expressions. . .
Without counting
With counting
Expressiveness DETS(Σ) = DETW (Σ)
DET#S (Σ) ( DET#
W (Σ)
Succinctness DETS(Σ)≈ DETW (Σ)
strong >exp weak
Det-Test easy (Glushkov)
easy (+ Glushkov#)
∃-Det-Test EXPTIME
2EXPTIME (strong)
Membership O(n2)
O(n3)
Complexity PTIME/ PSPACE
PSPACE (strong)
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 27 / 29
![Page 71: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/71.jpg)
Concluding Remarks
The Situation for deterministic expressions. . .
Without counting With counting
Expressiveness DETS(Σ) = DETW (Σ) DET#S (Σ) ( DET#
W (Σ)Succinctness DETS(Σ)≈ DETW (Σ) strong >exp weak
Det-Test easy (Glushkov) easy (+ Glushkov#)∃-Det-Test EXPTIME 2EXPTIME (strong)
Membership O(n2) O(n3)Complexity PTIME/ PSPACE PSPACE (strong)
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 27 / 29
![Page 72: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/72.jpg)
Where are we going?
XML Schema uses weakly deterministic expressions with counting
What do we know about these?
Does this class have a nice “deterministic” automata model?Is it decidable whether a regular language can be defined with a weaklydeterministic expression with counting?What’s the complexity for, e.g., membership, inclusion testing?
Weak and strong determinism are very differentin expressions with counting
Do we want weak or strong determinism?
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 28 / 29
![Page 73: Regular Expressions with Counting: Weak versus Strong ... file1 Determinism in Regular Expressions 2 The Situation Without Counting 3 Results Expressive Power Succinctness Expressions](https://reader031.fdocuments.in/reader031/viewer/2022041409/5e18ce3728f09929da414eb9/html5/thumbnails/73.jpg)
Thank you for listening
Gelade/Gyssens/Martens (MFCS 2009) Counting: Weak vs Strong Determinism August 24, 2009 29 / 29