Dynamic Membership for Regular Languages
Antoine Amarilli1, Louis Jachiet1, Charles Paperman2 June 18, 2021
1T ´el ´ecom Paris
2Universit ´e de Lille
1/18
Problem: dynamic membership for regular languages
• Fix aregular languageL
→ E.g.,L= (ab)∗
• Read aninput wordwwithn:=|w|
→ E.g.,w=abbbab
• Preprocessit inO(n)
→ E.g., we havew∈/L
• Maintainthe membership ofwtoLundersubstitution updates
→ E.g., replace character at position 3 witha: we now havew∈L
Problem: dynamic membership for regular languages
• Fix aregular languageL
→ E.g.,L= (ab)∗
• Read aninput wordwwithn:=|w|
→ E.g.,w=abbbab
• Preprocessit inO(n)
→ E.g., we havew∈/ L
• Maintainthe membership ofwtoLundersubstitution updates
→ E.g., replace character at position 3 witha: we now havew∈L
2/18
Problem: dynamic membership for regular languages
• Fix aregular languageL
→ E.g.,L= (ab)∗
• Read aninput wordwwithn:=|w|
→ E.g.,w=abbbab
• Preprocessit inO(n)
→ E.g., we havew∈/ L
• Maintainthe membership ofwtoLundersubstitution updates
→ E.g., replace character at position 3 witha: we now havew∈L
Design choices
• Model: RAM model
• Cell size inΘ(log(n))
• Unit-cost arithmetics
• Updates: only substitutions(sonnever changes)
• Otherwise, alreadytrickyto maintain the current state of the word
• Memory usage: alwayspolynomial innby definition of the model
• Our upper bounds onlyneedO(n)space
• The lower bounds applywithout this assumption
• Preprocessing:
• The upper bounds onlyneedO(n)preprocessing
• The lower bounds applywithout this assumption
3/18
A general-purpose algorithm inO(logn)
Fix the languageL= (ab)∗: start 0 1 a b
• Build abalanced binary treeon the input wordw=abaabb
• Label each nodenby thetransition monoidelement: all pairsq q0 such that we can go fromqtoq0 by reading the factor belown
a b b b a b
• Thetree rootdescribes ifw∈L
• We can update the tree for each substitutioninO(logn)
• Can be improved toO(logn/log logn)with alog-ary tree
A general-purpose algorithm inO(logn)
Fix the languageL= (ab)∗: start 0 1 a b
• Build abalanced binary treeon the input wordw=abaabb
• Label each nodenby thetransition monoidelement: all pairsq q0 such that we can go fromqtoq0 by reading the factor belown
a b b b a b
• Thetree rootdescribes ifw∈L
• We can update the tree for each substitutioninO(logn)
• Can be improved toO(logn/log logn)with alog-ary tree
4/18
A general-purpose algorithm inO(logn)
Fix the languageL= (ab)∗: start 0 1 a b
• Build abalanced binary treeon the input wordw=abaabb
• Label each nodenby thetransition monoidelement: all pairsq q0 such that we can go fromqtoq0 by reading the factor belown
a b b b a b
• Thetree rootdescribes ifw∈L
• We can update the tree for each substitutioninO(logn)
• Can be improved toO(logn/log logn)with alog-ary tree
A general-purpose algorithm inO(logn)
Fix the languageL= (ab)∗: start 0 1 a b
• Build abalanced binary treeon the input wordw=abaabb
• Label each nodenby thetransition monoidelement: all pairsq q0 such that we can go fromqtoq0 by reading the factor belown
a b b b a b
• Thetree rootdescribes ifw∈L
• We can update the tree for each substitutioninO(logn)
• Can be improved toO(logn/log logn)with alog-ary tree
4/18
A general-purpose algorithm inO(logn)
Fix the languageL= (ab)∗: start 0 1 a b
• Build abalanced binary treeon the input wordw=abaabb
• Label each nodenby thetransition monoidelement: all pairsq q0 such that we can go fromqtoq0 by reading the factor belown
a b b b a b
0 0 ∅ 0 0
∅ 0 0
∅
• Thetree rootdescribes ifw∈L
• We can update the tree for each substitutioninO(logn)
• Can be improved toO(logn/log logn)with alog-ary tree
A general-purpose algorithm inO(logn)
Fix the languageL= (ab)∗: start 0 1 a b
• Build abalanced binary treeon the input wordw=abaabb
• Label each nodenby thetransition monoidelement: all pairsq q0 such that we can go fromqtoq0 by reading the factor belown
a b b b a b
0 0 ∅ 0 0
∅ 0 0
∅
• Thetree rootdescribes ifw∈L
• We can update the tree for each substitutioninO(logn)
• Can be improved toO(logn/log logn)with alog-ary tree
4/18
Can we do better thanO(logn)?
For our languageL= (ab)∗ we can handle updates inO(1):
• Check thatniseven
• Countviolations: a’s ateven positionsandb’s at odd positions
• Maintain this counterin constant time
• We havew∈Liffthere are no violations
Question:what is the complexity of dynamic membership, depending on the fixed regular languageL?
Can we do better thanO(logn)?
For our languageL= (ab)∗ we can handle updates inO(1):
• Check thatniseven
• Countviolations: a’s ateven positionsandb’s at odd positions
• Maintain this counterin constant time
• We havew∈Liffthere are no violations
Question:what is the complexity of dynamic membership, depending on the fixed regular languageL?
5/18
Can we do better thanO(logn)?
For our languageL= (ab)∗ we can handle updates inO(1):
• Check thatniseven
• Countviolations: a’s ateven positionsandb’s at odd positions
• Maintain this counterin constant time
• We havew∈Liffthere are no violations
Question:what is the complexity of dynamic membership, depending on the fixed regular languageL?
Dynamic word problem for monoids
To answer the question, we study thedynamic word problem for monoids:
• Problem definition:
• Fix amonoidM(set with associative law and neutral element)
• Input:wordwof elements ofM
• Maintain theproductof the elements under substitution updates
• This is aspecial caseof dynamic membership for regular languages
• e.g., it assumes that there is aneutral element
• This problem was studied by [Skovbjerg Frandsen et al., 1997]:
→ inO(1)forcommutative monoids
→ inO(log logn)forgroup-free monoids
→ inΘ(logn/log logn)for a certain class of monoids
6/18
Dynamic word problem for monoids
To answer the question, we study thedynamic word problem for monoids:
• Problem definition:
• Fix amonoidM(set with associative law and neutral element)
• Input:wordwof elements ofM
• Maintain theproductof the elements under substitution updates
• This is aspecial caseof dynamic membership for regular languages
• e.g., it assumes that there is aneutral element
• This problem was studied by [Skovbjerg Frandsen et al., 1997]:
→ inO(1)forcommutative monoids
→ inO(log logn)forgroup-free monoids
→ inΘ(logn/log logn)for a certain class of monoids
Our results on the dynamic word problem for monoids
ZG: inO(1)
not inO(1)?
• We identify the classZGsatisfyingxω+1y=yxω+1:
• for any monoidinZG, the problem isinO(1)
• for any monoidnot inZG, we can reduce from a problem that weconjecture is not inO(1)
• We identify the classSGsatisfyingxω+1yxω =xωyxω+1
• for any monoidinSG, the problem isinO(log logn)
• for any monoidnot inSG, it isinΩ(logn/log logn) (lower bound of Skovbjerg Frandsen et al.)
• The problem is always inO(logn/log logn)
7/18
Our results on the dynamic word problem for monoids
ZG: inO(1)
SG: inO(log logn) not inO(1)?
All: inΘ(logn/log logn)
• We identify the classZGsatisfyingxω+1y=yxω+1:
• for any monoidinZG, the problem isinO(1)
• for any monoidnot inZG, we can reduce from a problem that weconjecture is not inO(1)
• We identify the classSGsatisfyingxω+1yxω =xωyxω+1
• for any monoidinSG, the problem isinO(log logn)
• for any monoidnot inSG, it isinΩ(logn/log logn) (lower bound of Skovbjerg Frandsen et al.)
• The problem is always inO(logn/log logn)
Our results on the dynamic word problem for monoids
ZG: inO(1)
SG: inO(log logn) not inO(1)?
All: inΘ(logn/log logn)
• We identify the classZGsatisfyingxω+1y=yxω+1:
• for any monoidinZG, the problem isinO(1)
• for any monoidnot inZG, we can reduce from a problem that weconjecture is not inO(1)
• We identify the classSGsatisfyingxω+1yxω =xωyxω+1
• for any monoidinSG, the problem isinO(log logn)
• for any monoidnot inSG, it isinΩ(logn/log logn) (lower bound of Skovbjerg Frandsen et al.)
• The problem is always inO(logn/log logn)
7/18
Results on the dynamic membership problem for regular languages
QLZG: inO(1)
QSG: inO(log logn) not inO(1)?
All: inΘ(logn/log logn)
Our results extend to regular language classes called QLZGandQSG
→ We define them in the sequel
Results on monoids
O(1)upper bound for monoids
Theorem
The dynamic word problem forcommutative monoidsis inO(1) Algorithm:
• Countthe numbernmof occurrences of each elementmofMinw
• Maintainthe countsnm under updates
• Evaluatethe product asQ
m∈MmnminO(1)
Lemma (Closure under monoid variety operations)
Thesubmonoids,direct products,quotientsof tractable monoids are also tractable
O(1)upper bound for monoids
Theorem
The dynamic word problem forcommutative monoidsis inO(1) Algorithm:
• Countthe numbernmof occurrences of each elementmofMinw
• Maintainthe countsnm under updates
• Evaluatethe product asQ
m∈MmnminO(1) Lemma (Closure under monoid variety operations)
Thesubmonoids,direct products,quotientsof tractable monoids are also tractable
9/18
O(1)upper bound for monoids (cont’d)
Theorem
The monoidsS1where we add an identity to anilpotent semigroupSare inO(1) Idea of the proof:considere∗ae∗be∗
• Preprocessing: prepare adoubly-linked listLof the positions containinga’s andb’s
• Maintainthe (unsorted) list whena’s andb’s are added/removed
• Evaluation:
• If there are not exactly two positions inL, answerno
• Otherwise, check that thesmallest positionof these two is anaand thelargest is ab
This technique applies to monoids where we intuitively need to tracka constant number of non-neutral elements
O(1)upper bound for monoids (cont’d)
Theorem
The monoidsS1where we add an identity to anilpotent semigroupSare inO(1) Idea of the proof:considere∗ae∗be∗
• Preprocessing: prepare adoubly-linked listLof the positions containinga’s andb’s
• Maintainthe (unsorted) list whena’s andb’s are added/removed
• Evaluation:
• If there are not exactly two positions inL, answerno
• Otherwise, check that thesmallest positionof these two is anaand thelargest is ab
This technique applies to monoids where we intuitively need to tracka constant number of non-neutral elements
10/18
O(1)upper bound for monoids (cont’d)
Theorem
The monoidsS1where we add an identity to anilpotent semigroupSare inO(1) Idea of the proof:considere∗ae∗be∗
• Preprocessing: prepare adoubly-linked listLof the positions containinga’s andb’s
• Maintainthe (unsorted) list whena’s andb’s are added/removed
• Evaluation:
• If there are not exactly two positions inL, answerno
• Otherwise, check that thesmallest positionof these two is anaand thelargest is ab
This technique applies to monoids where we intuitively need to tracka constant number of non-neutral elements
O(1)upper bound for monoids (end)
CallZGthe variety of monoids satisfyingxω+1y=yxω+1 for allx,y
→ Elements of the formxω+1are those belonging to asubgroupof the monoid
→ This includes in particular allidempotents(xx=x)
→ Thexω+1 arecentral: they commute with all other elements
Lemma
ZGis exactly the monoids obtainable fromcommutative monoidsandmonoids of the form S1 for a nilpotent semigroupSvia themonoid variety operators
Theorem
The dynamic word problem for monoids inZGisin O(1)
11/18
O(1)upper bound for monoids (end)
CallZGthe variety of monoids satisfyingxω+1y=yxω+1 for allx,y
→ Elements of the formxω+1are those belonging to asubgroupof the monoid
→ This includes in particular allidempotents(xx=x)
→ Thexω+1 arecentral: they commute with all other elements Lemma
ZGis exactly the monoids obtainable fromcommutative monoidsandmonoids of the form S1 for a nilpotent semigroupSvia themonoid variety operators
Theorem
The dynamic word problem for monoids inZGisin O(1)
O(log logn)upper bound for monoids
CallSGthe variety of monoids satisfyingxω+1yxω=xωyxω+1for allx,y
→ Intuition:we canswapthe elements of any given subgroup of the monoid Examples:
• AllZGmonoids(where elementsxω+1 commute with everything)
• Allgroup-free monoids(where subgroups are trivial)
• ProductsofZGmonoids and group-free monoids
Theorem
The dynamic word problem for monoids inSGis inO(log logn)
Tools:induction onJ-classes, Rees-Sushkevich theorem, Van Emde Boas trees
12/18
O(log logn)upper bound for monoids
CallSGthe variety of monoids satisfyingxω+1yxω=xωyxω+1for allx,y
→ Intuition:we canswapthe elements of any given subgroup of the monoid Examples:
• AllZGmonoids(where elementsxω+1 commute with everything)
• Allgroup-free monoids(where subgroups are trivial)
• ProductsofZGmonoids and group-free monoids Theorem
The dynamic word problem for monoids inSGis inO(log logn)
Tools:induction onJ-classes, Rees-Sushkevich theorem, Van Emde Boas trees
Lower bounds
All lower bounds reduce from theprefix problemfor some languageL:
• Maintain a word undersubstitution updates
• Answer queries asking if agiven prefixof the current word is inL
Specifically:
• Prefix-Zd: forΣ ={0, . . . ,d−1}, does the input prefixsum to 0 modulod?
→ Knownlower boundofΩ(logn/log logn)
• Prefix-U1:forΣ ={0,1}, does the queried prefixcontain a 0?
→ Weconjecturethat this cannot be done inO(1) Theorem (Lower bounds on a monoidM)
• IfMisnot inSG, then for somed∈NthePrefix-Zdproblem reduces to the dynamic word problem forM
• IfMisinSG\ZG, thenPrefix-U1reduces to the dynamic word problem forM
13/18
Lower bounds
All lower bounds reduce from theprefix problemfor some languageL:
• Maintain a word undersubstitution updates
• Answer queries asking if agiven prefixof the current word is inL Specifically:
• Prefix-Zd: forΣ ={0, . . . ,d−1}, does the input prefixsum to 0 modulod?
→ Knownlower boundofΩ(logn/log logn)
• Prefix-U1:forΣ ={0,1}, does the queried prefixcontain a 0?
→ Weconjecturethat this cannot be done inO(1)
Theorem (Lower bounds on a monoidM)
• IfMisnot inSG, then for somed∈NthePrefix-Zdproblem reduces to the dynamic word problem forM
• IfMisinSG\ZG, thenPrefix-U1reduces to the dynamic word problem forM
Lower bounds
All lower bounds reduce from theprefix problemfor some languageL:
• Maintain a word undersubstitution updates
• Answer queries asking if agiven prefixof the current word is inL Specifically:
• Prefix-Zd: forΣ ={0, . . . ,d−1}, does the input prefixsum to 0 modulod?
→ Knownlower boundofΩ(logn/log logn)
• Prefix-U1:forΣ ={0,1}, does the queried prefixcontain a 0?
→ Weconjecturethat this cannot be done inO(1) Theorem (Lower bounds on a monoidM)
• IfMisnot inSG, then for somed∈NthePrefix-Zdproblem reduces to the dynamic word problem forM
• IfMisinSG\ZG, thenPrefix-U1reduces to the dynamic word problem forM
13/18
Results on languages
(via semigroups)
From monoids to semigroups
• Semigroup: like a monoid but possibly without a neutral element
• Dynamic word problem for semigroups: defined like for monoids What is the difference?
• The languageΣ∗(ae∗a)Σ∗onΣ ={a,b,e}has aneutral lettere that we intuitively need to “jump over”
• The languageΣ∗aaΣ∗ onΣ ={a,b}withoute
can bemaintained inO(1)by counting the factorsaa
14/18
Local monoids in semigroups
• Alocal monoidof a semigroupSis a subset ofSthat has aneutral element
→ IfShas a local monoidMthen the dynamic word problem forMreducestoS
→ Lower boundsonMthus apply toS
• Hence, we define:
• LSG: all local monoids areinSG
→ We showLSG=SGand extend our bounds tosemigroups inSG
• LZG: all local monoids areinZG
→ We haveLZG6=ZGand show bounds forsemigroups inLZG
Local monoids in semigroups
• Alocal monoidof a semigroupSis a subset ofSthat has aneutral element
→ IfShas a local monoidMthen the dynamic word problem forMreducestoS
→ Lower boundsonMthus apply toS
• Hence, we define:
• LSG: all local monoids areinSG
→ We showLSG=SGand extend our bounds tosemigroups inSG
• LZG: all local monoids areinZG
→ We haveLZG6=ZGand show bounds forsemigroups inLZG
15/18
Local monoids in semigroups
• Alocal monoidof a semigroupSis a subset ofSthat has aneutral element
→ IfShas a local monoidMthen the dynamic word problem forMreducestoS
→ Lower boundsonMthus apply toS
• Hence, we define:
• LSG: all local monoids areinSG
→ We showLSG=SGand extend our bounds tosemigroups inSG
• LZG: all local monoids areinZG
→ We haveLZG6=ZGand show bounds forsemigroups inLZG
From semigroups to languages
We now move back todynamic membership for regular languages
• Dynamic membership for a regular languageLis like the dynamic word problem for itssyntactic semigroup
→ This is like the transition monoid but without theneutral element
• Difference: not all elements of the syntactic semigroup can be achieved as one letter
→ We use instead thestable semigroup, which intuitively groups letters together intoblocksof a constant size
16/18
From semigroups to languages (cont’d)
CallQLZGandQSGthe languages whosestable semigroupis inZGandSG Theorem
Our results onsemigroupsinSGandLZGextend toregular languagesinQSG andQLZG
For any regular languageL:
• IfLisinQLZGthen dynamic membership isin O(1)
• IfLis notinQSG\QLZGthen dynamic membership isin O(log logn)and has a reductionfrom prefix-U1
• IfLisnot inQSGthen dynamic membership isinΘ(logn/log logn)
From semigroups to languages (cont’d)
CallQLZGandQSGthe languages whosestable semigroupis inZGandSG Theorem
Our results onsemigroupsinSGandLZGextend toregular languagesinQSG andQLZG
For any regular languageL:
• IfLisinQLZGthen dynamic membership isin O(1)
• IfLis notinQSG\QLZGthen dynamic membership isin O(log logn)and has a reductionfrom prefix-U1
• IfLisnot inQSGthen dynamic membership isinΘ(logn/log logn)
17/18
Conclusion and future work
Summary
We have shown a (conditional)trichotomyon the dynamic word problem for monoids and semigroups, and on dynamic membership forregular languages
• Can one show asuperconstant lower boundonprefix-U1?
→ Help welcome!but new techniques probably needed
• What aboutintermediate casesbetweenO(1)andO(log logn)
• Yes withrandomization: one languageinΘ(log logn)and oneinO(√
log logn)
• Question:can the intermediate classes becharacterized?
• Meta-dichotomy: what is the complexity of finding which case occurs?
→ ProbablyPSPACE-complete(depends on the representation)
• What about a dichotomy for theprefix problemorinfix problem?
→ We have such a result butinelegant characterization
• What about languages that arenon-regular?
Thanks for your attention!
18/18
Summary
We have shown a (conditional)trichotomyon the dynamic word problem for monoids and semigroups, and on dynamic membership forregular languages
• Can one show asuperconstant lower boundonprefix-U1?
→ Help welcome!but new techniques probably needed
• What aboutintermediate casesbetweenO(1)andO(log logn)
• Yes withrandomization: one languageinΘ(log logn)and oneinO(√
log logn)
• Question:can the intermediate classes becharacterized?
• Meta-dichotomy: what is the complexity of finding which case occurs?
→ ProbablyPSPACE-complete(depends on the representation)
• What about a dichotomy for theprefix problemorinfix problem?
→ We have such a result butinelegant characterization
• What about languages that arenon-regular?
Thanks for your attention!
Summary
We have shown a (conditional)trichotomyon the dynamic word problem for monoids and semigroups, and on dynamic membership forregular languages
• Can one show asuperconstant lower boundonprefix-U1?
→ Help welcome!but new techniques probably needed
• What aboutintermediate casesbetweenO(1)andO(log logn)
• Yes withrandomization: one languageinΘ(log logn)and oneinO(√
log logn)
• Question:can the intermediate classes becharacterized?
• Meta-dichotomy: what is the complexity of finding which case occurs?
→ ProbablyPSPACE-complete(depends on the representation)
• What about a dichotomy for theprefix problemorinfix problem?
→ We have such a result butinelegant characterization
• What about languages that arenon-regular?
Thanks for your attention!
18/18
Summary
We have shown a (conditional)trichotomyon the dynamic word problem for monoids and semigroups, and on dynamic membership forregular languages
• Can one show asuperconstant lower boundonprefix-U1?
→ Help welcome!but new techniques probably needed
• What aboutintermediate casesbetweenO(1)andO(log logn)
• Yes withrandomization: one languageinΘ(log logn)and oneinO(√
log logn)
• Question:can the intermediate classes becharacterized?
• Meta-dichotomy: what is the complexity of finding which case occurs?
→ ProbablyPSPACE-complete(depends on the representation)
• What about a dichotomy for theprefix problemorinfix problem?
→ We have such a result butinelegant characterization
• What about languages that arenon-regular?
Thanks for your attention!
Summary
We have shown a (conditional)trichotomyon the dynamic word problem for monoids and semigroups, and on dynamic membership forregular languages
• Can one show asuperconstant lower boundonprefix-U1?
→ Help welcome!but new techniques probably needed
• What aboutintermediate casesbetweenO(1)andO(log logn)
• Yes withrandomization: one languageinΘ(log logn)and oneinO(√
log logn)
• Question:can the intermediate classes becharacterized?
• Meta-dichotomy: what is the complexity of finding which case occurs?
→ ProbablyPSPACE-complete(depends on the representation)
• What about a dichotomy for theprefix problemorinfix problem?
→ We have such a result butinelegant characterization
• What about languages that arenon-regular?
Thanks for your attention!
18/18
Summary
We have shown a (conditional)trichotomyon the dynamic word problem for monoids and semigroups, and on dynamic membership forregular languages
• Can one show asuperconstant lower boundonprefix-U1?
→ Help welcome!but new techniques probably needed
• What aboutintermediate casesbetweenO(1)andO(log logn)
• Yes withrandomization: one languageinΘ(log logn)and oneinO(√
log logn)
• Question:can the intermediate classes becharacterized?
• Meta-dichotomy: what is the complexity of finding which case occurs?
→ ProbablyPSPACE-complete(depends on the representation)
• What about a dichotomy for theprefix problemorinfix problem?
→ We have such a result butinelegant characterization
• What about languages that arenon-regular?
Thanks for your attention!
Summary
We have shown a (conditional)trichotomyon the dynamic word problem for monoids and semigroups, and on dynamic membership forregular languages
• Can one show asuperconstant lower boundonprefix-U1?
→ Help welcome!but new techniques probably needed
• What aboutintermediate casesbetweenO(1)andO(log logn)
• Yes withrandomization: one languageinΘ(log logn)and oneinO(√
log logn)
• Question:can the intermediate classes becharacterized?
• Meta-dichotomy: what is the complexity of finding which case occurs?
→ ProbablyPSPACE-complete(depends on the representation)
• What about a dichotomy for theprefix problemorinfix problem?
→ We have such a result butinelegant characterization
• What about languages that arenon-regular?
Thanks for your attention! 18/18
References i
Fredman, M. and Saks, M. (1989).
The cell probe complexity of dynamic data structures.
InSTOC, pages 345–354.
Patrascu, M. (2008).
Lower bound techniques for data structures.
PhD thesis, Massachusetts Institute of Technology.
Skovbjerg Frandsen, G., Miltersen, P. B., and Skyum, S. (1997).
Dynamic word problems.
JACM, 44(2):257–271.
O(log logn)upper bound for monoids (proof sketch)
Example :Σ∗(ae∗a)Σ∗onΣ ={a,b,e}
• Idea: maintain the count of factorsae∗a
• Problem:to do this, we need to “jump over” thee’s
→ Van Emde Boas treedata structure:
• maintaina subset of{1, . . . ,n}underinsertions/deletions
• jumpto theprev/next elementinO(log logn)
Full proof:induction onJ-classesandRees-Sushkevich theorem
ExtendingSGto semigroups
We can show that, for semigroups:
Lemma
A semigroup satisfies the equation ofSGiff it is inLSG
Hence, as the algorithm forSGworks forsemigroupsas well as monoids:
Theorem
For any semigroupS:
• IfSisinSG, then the dynamic word problem isin O(log logn)
• Otherwise, the dynamic word problem isinΘ(logn/log logn)
Case ofZG
We haveZG6=LZG, but we can still show:
Theorem
For any semigroupS:
• IfSisinLZG, then the dynamic word problem isin O(1)
• Otherwise, it has a reductionfrom Prefix-U1
Proof sketch:only need to show theupper bound:
• We show theO(1)upper bound on thesemidirect productZG∗D ofZGwithdefinite semigroups
• We show an independentlocality result: LZG=ZG∗D
→ Technical proof relying onfinite categoriesandStraubing’s delay theorem
Case ofZG
We haveZG6=LZG, but we can still show:
Theorem
For any semigroupS:
• IfSisinLZG, then the dynamic word problem isin O(1)
• Otherwise, it has a reductionfrom Prefix-U1
Proof sketch:only need to show theupper bound:
• We show theO(1)upper bound on thesemidirect productZG∗D ofZGwithdefinite semigroups
• We show an independentlocality result: LZG=ZG∗D
→ Technical proof relying onfinite categoriesandStraubing’s delay theorem
Difference between the stable semigroup and syntactic semigroup
• Dynamic membership for(aa)∗ba∗ isinO(1): count theb’s atevenandodd positions
• The dynamic word problem for its syntactic semigroup has areduction from Z2