Automatic structures of bounded degree revisited
The first-order theory of a string automatic structure is known to be decidable, but there are examples of string automatic structures with nonelementary first-order theories. We prove that the first-order theory of a string automatic structure of bo…
Authors: Dietrich Kuske, Markus Lohrey
Automatic structures of b ounded degree revisited Dietric h Kuske and M arkus Lohrey ⋆ Universit¨ at Leipzig, Institu t f¨ ur I nformatik, German y { kuske,lo hrey } @inf ormatik.un i -leipzig.de Abstract. The first-order theory of a string automatic structure is know n to be decidable, but there are examples of string automatic structures with nonelementary first-order theories. W e prov e th at the first-order theory of a string automatic structure of b ounded degree is decidable in doub ly exp onen tial space (for injective automatic p resen tations, this h olds even u niformly). This result is shown to b e optimal since we also p resen t a string automatic structure of b ounded degree whose first-order theory is h ard for 2EXPSP A CE . W e prov e similar results also for tree automatic structures. These findings clo se the gaps left open in [24] b y improving both, the lo wer and th e upp er boun ds. 1 In tr o duction The idea of an automatic structure go es back to B ¨ uc hi and Elgot who used finite automata to decide, e.g., Presburger arithmetic [11]. Automaton decidable theories [14] and auto- matic groups [12] are similar concepts. A systematic study w as initiated by Khoussaino v and Nero de [16] wh o also coined the name “ automatic structur e ” (w e pr efer the term “ string automatic structur es ” in this paper). In essence, a s tructure is string automatic if the ele- men ts of the universe can b e represent ed as strings from a regular language (an elemen t can b e represente d by several strings) and ev ery relation of th e structure can b e recognized by a finite state automaton with sev eral heads that p r oceed synchronously . String automatic structures receiv ed in creasing in terest o v er th e last y ears [5,17,15,3,18,20,1,23,21,27,2]. On e of the main motiv atio n s for inv estigating s tring automatic stru ctures is that th eir first-order theories can b e decided uniform ly (i.e., the inpu t is a string automatic p resen tation and a first-order sentence) . But eve n the non-un iform first-order theory is far from efficien t sin ce there exist string automatic structures with a n onelemen tary first-order theory . Th is moti- v ates the searc h for su b classes of string automatic structures whose first-order theories are elemen tary . Th e first such class was identified by the second author in [24] who show ed that the first-order theory of every str in g automatic structure of b ounde d de gr e e can b e d ecided in triply exp onen tial alternating time with linearly many alternations. A structure has b ounded degree, if in its Gaifman graph, the num b er of neighb ors of a no de is b ounded by some fixed constan t. The pap er [24] also pr esents a sp ecific example of a string automat ic structure of b ounded degree, wh ere the first-order theory is hard for d ou b ly exp onenti al alternating time with linearly man y alternations. Hence, an exp onen tial gap b etw een the upp er and lo w er b ound r emained. An upp er b ound of 4-fold exp onen tial alternating time with linearly many alternations w as sho wn for tr e e automatic structur es (whic h are defined analogously to au- tomatic structures u sing tree automata) of b ounded degree. Our pap er [22] p r o v es a triply exp onen tial space b ound for the first-order theory of an injectiv e ω -automatic structure (that is defin ed via B ¨ uc hi-automata) of b ound ed degree. Here, injectivit y means that ev ery elemen t of the structure is repr esen ted by a u ni q ue ω -word from the underlyin g regular language. In this pap er, we ac hieve three goals: ⋆ The second author ac kn o wledges supp ort from the DFG-pro ject GELO. – W e close the complexit y gaps from [24] for string/tree automatic stru ctur es of b ounded degree. – W e inv estigate, for the first time, the complexit y of th e uniform fi rst-order theory (wh ere the automatic p r esen tation is p art of the inpu t) of string/tree automatic structures of b ounded degree. – W e r efine our complexit y an alysis using the gro w th fun ction of a stru cture. This function measures the size of a sphere in the Gaifman graph dep ending on the radius of the sphere. The gro wth function of a structur e of b ounded degree can b e at most exp onentia l. Our main results are the follo wing: – The uniform first-order theory for injectiv e string automatic presentat ions is 2EXPSP A CE - complete. The lo wer b ound already holds in the non-uniform setting, i.e. there exists a string automatic stru cture of b ounded d egree with a 2EXPSP AC E -complete fir st-order theory . – F or eve ry s tr ing automatic structure of b ound ed degree, wh ere th e growth f unction is p olynomially b ounded, the first-order theory is in EXPSP ACE , and there exists an example with an EXPSP ACE -co mp lete fir st-order th eory . – The uniform first-order th eory for injectiv e tree automatic presentat ions b elongs to 4EX- PTIME ; the non-unif orm one to 3EXPTIME for arbitrary tr ee automatic structures, and to 2EXPTIME if the gro wth function is p olynomial. Our b ounds f or th e non-uniform prob- lem are sh arp, i.e., there are tree automatic structur es of b ounded degree (and p olynomial gro wth) with a 3EXPTIME -complete ( 2EXPTIME -complete, resp.) first-order theory . W e conclude this pap er with some resu lts on the complexit y of first-order fr agmen ts with fixed q u an tifier alternation depth one or t wo on string/tree automatic structur es of b ounded degree. 2 Preliminaries Let Γ b e a fi nite alphab et and w ∈ Γ ∗ b e a finite word o v er Γ . The length of w is denoted b y | w | . W e also wr ite Γ n = { w ∈ Γ ∗ | n = | w |} . Let us define exp(0 , x ) = x and exp( n + 1 , x ) = 2 exp( n,x ) for x ∈ N . W e assume that the reader has s ome basic kno wledge in complexit y theory , see e.g. [26]. By Sa vitc h’s theorem, NSP ACE ( s ( n )) ⊆ DSP ACE ( s ( n ) 2 ) if s ( n ) ≥ log( n ). Hence, we can j ust write SP ACE ( s ( n ) O (1) ) for either NSP A CE ( s ( n ) O (1) ) or DSP A CE ( s ( n ) O (1) ). F or k ≥ 1, we d enote w ith k EXPS P A CE (resp. k EXPTIME ) the class of all problems that can b e accepted in space (resp. time) exp( k , n O (1) ) on a deterministic T ur ing mac hine. F or 1EXPSP ACE we write just EXPS P A CE . A compu tational problem is called elementary if it b elongs to k EXPTIME for some k ∈ N . 2.1 T ree and string automata F or our pur p ose it suffices to consider only tree automata on binary trees. Let Γ b e a fin ite alphab et. A finite binary tr e e ov er Γ is a mapping t : d om( t ) → Γ , where dom( t ) ⊆ { 0 , 1 } ∗ is finite, nonemp t y , and satisfies the follo wing closure condition for all w ∈ { 0 , 1 } ∗ : if { w 0 , w 1 } ∩ dom( t ) 6 = ∅ , then also w, w 0 ∈ dom( t ). With T Γ w e denote the set of all fi nite binary trees o v er Γ . A (top-do wn ) tr e e automaton over Γ is a tuple A = ( Q, ∆, q 0 ), wh ere Q is the fin ite set of states, q 0 ∈ Q is the initial state, and ∆ ⊆ ( Q × Γ × Q × Q ) ∪ ( Q × Γ × Q ) ∪ ( Q × Γ ) (1) 2 is the non-empt y transition relation. A suc c essful run of A on a tree t is a mappin g ρ : dom( t ) → Q suc h that (i) ρ ( ε ) = q 0 and (ii) for ev ery w ∈ dom( t ) with c hildr en w 0 , . . . , wi (th us − 1 ≤ i ≤ 1) w e h a v e ( ρ ( w ) , t ( w ) , ρ ( w 0) , . . . , ρ ( wi )) ∈ ∆ . With L ( A ) we d enote the set of all finite b inary trees t such that there exists a successful r un of A on t . A s et L ⊆ T Γ is called r e gular if th er e exists a fin ite tree automaton A with L = L ( A ). A tr ee t w ith dom( t ) ⊆ 0 ∗ can b e considered as a nonempty string t ( ε ) t (0 ) t (00) . . . t (0 n − 1 ) with n = | dom( t ) | . In th e same spirit, a finite string automaton can b e defin ed as a tree automaton, where the transition r elatio n ∆ in (1) s atisfies ∆ ⊆ ( Q × Γ × Q ) ∪ ( Q × Γ ). W e will need th e follo wing well kn o wn facts on string/tree automata: Emptiness (resp. inclusion) of the languages of string automata can b e d ecided in n ondeterministic logarithmic space (r esp. p olynomial s p ace), whereas emptiness (resp. in clusion) of the languages of tree automata can b e decided in p olynomial time (resp. exp onen tial time), s ee e.g. [8]. In all four cases completeness holds. 2.2 Structures and first -order logic A signatur e is a finite set S of relational sym b ols, w here ev ery sym b ol r ∈ S has some fixed arit y m r . The n otion of an S -structure (or mo del) is d efined as u sual in logic. Note that w e only consider relational structures. Sometimes, we will also us e constan ts, b ut in our cont ext, a constan t c can b e alw a y s replaced b y th e unary relation { c } . Let us fix an S -stru cture A = ( A, ( r A ) r ∈S ), w h ere r A ⊆ A m r . T o simplify notation, we will wr ite a ∈ A for a ∈ A . F or B ⊆ A w e define the restriction A ↾ B = ( B , ( r A ∩ B m r ) r ∈S ). Giv en further constan ts a 1 , . . . , a n ∈ A , w e write ( A , a 1 , . . . , a k ) for the str u cture ( A, ( r A ) r ∈S , a 1 , . . . , a k ). In the r est of the pap er, we will alw ays identi fy a symb ol r ∈ S with its interpretati on r A . A c ongruenc e on th e structure A = ( A, ( r ) r ∈S ) is an equiv alence relation ≡ on A su c h that for ev er y r ∈ S and all a 1 , b 1 , . . . , a m r , b m r ∈ A w e ha v e: If ( a 1 , . . . , a m r ) ∈ r and a 1 ≡ b 1 , . . . , a m r ≡ b m r , then also ( b 1 , . . . , b m r ) ∈ r . As u s ual, th e equiv alence class of a ∈ A w.r.t. ≡ is denoted b y [ a ] ≡ or just [ a ] and A/ ≡ denotes the set of all equiv alence classes. W e define th e quotient structur e A / ≡ = ( A/ ≡ , ( r / ≡ ) r ∈S ), wh ere r / ≡ = { ([ a 1 ] , . . . , [ a m r ]) | ( a 1 , . . . , a m r ) ∈ r } . The Gaifman-gr aph G ( A ) of the S -structure A is th e follo w ing symmetric graph: G ( A ) = ( A, { ( a, b ) ∈ A × A | _ r ∈S ∃ ( a 1 , . . . , a m r ) ∈ r ∃ j, k : a j = a, a k = b } ) . Th us, the set of n o d es is the univ erse of A and there is an edge b et ween tw o elements, if and only if they are cont ained in some tuple b elonging to one of the relations of A . With d A ( a, b ), where a, b ∈ A , w e denote the distance b etw een a and b in G ( A ), i.e., it is the length of a shortest path conn ecting a and b in G ( A ). F or a ∈ A and d ≥ 0 we denote with S A ( d, a ) = { b ∈ A | d A ( a, b ) ≤ d } the d -sph ere around a . If A is clear from the con text, then we will omit the su b script A . W e sa y that the structure A is lo c al ly finite if its Gaifman graph G ( A ) is lo cally fin ite (i.e., ev ery no de h as fi nitely many n eigh b ors). Similarly , the structure A h as b ounde d de gr e e , if G ( A ) h as b ounded d egree, i.e., there exists a constant δ suc h that ev ery a ∈ A is adjacen t to at m ost δ man y other no des in G ( A ); the minimal such δ is called the de gr e e of A . F or a stru cture A of b ounded degree we can define its gr owth function as the mappin g g A : N → N with g A ( n ) = max {| S A ( n, a ) | | a ∈ A} . Note th at if the fu nction g A is not b ound ed then g A ( n ) ≥ n for all n ≥ 1. F or us, it is m ore con venien t to n ot hav e a b ound ed function describ ing the gro wth. Therefore, w e define the normalize d 3 a b b a a a a b b a ( a, a ) ( b, $) ( b, a ) ( a, $) ( a, $) ($ , b ) ($ , b ) ($ , a ) Fig. 1. T he con volutio n of tw o trees gr owth fu nc tion g ′ A b y g ′ A ( n ) = max { n, g A ( n ) } . Note that g A and g ′ A are d ifferen t only in the pathologica l case that all connected comp onen ts of A conta in at most m elements (for some fi xed m ). Clearly , g ′ A ( n ) can gro w at most exp onen tially . W e sa y th at A has exp onential gr owth if g ′ A ( n ) ∈ 2 Ω ( n ) ; if g ′ A ( n ) ∈ n O (1) , then A has p olynomial g r owth . T o define logica l formulas, we fix a coun table infinite set V of v ariables, whic h ev aluate to elemen ts of structures. F ormulas over the signatur e S (or formulas if th e the signature is clear from the con text) are constru cted from the atomic formulas x = y and r ( x 1 , . . . , x m r ), where r ∈ S and x, y , x 1 , . . . , x m r ∈ V , using the Bo olean connectiv es ∨ and ¬ and existen tial quan tifi cation o ve r v ariables from V . The Bo olean connectiv e ∧ and un iversal quanti fi cation can b e derived fr om these op erators in the us ual wa y . T h e quantifier depth of a form u la ϕ is the maximal nesting of quanti fiers in ϕ . The notion of a free v ariable is defined as u sual. A form u la without fr ee v ariables is called close d . If ϕ ( x 1 , . . . , x m ) is a f orm ula with free v ariables among x 1 , . . . , x m and a 1 , . . . , a m ∈ A , then A | = ϕ ( a 1 , . . . , a m ) means that ϕ ev aluates to true in A when the free v ariable x i ev aluate s to a i . The first-or der the ory of A , denoted by F OTh ( A ), is the set of all closed formulas ϕ suc h that A | = ϕ . 2.3 Structures from automata This section recalls string automati c and tree automatic structures and basic results ab out them. Details can b e foun d in the survey [27]. T ree and string aut omat ic structures String automatic str uctures w ere introd uced in [14], their systematic study w as later initiated by [16]. T r ee automatic structur es were in tro du ced in [4], th ey generalize str ing automatic stru ctures. Here, w e will fir st int r o d uce tree automatic structures. Str ing automatic structures can b e considered as a sp ecial case of tree automatic structures. Let Γ b e a finite alphab et and let $ 6∈ Γ b e an additional p adding symb ol. Let t 1 , . . . , t m ∈ T Γ . W e d efine the c onvolution t = t 1 ⊗ · · · ⊗ t m , w hic h is a finite binary tree o ver the alphab et ( Γ ∪ { $ } ) m , as follo ws: dom( t ) = S m i =1 dom( t i ) and for all w ∈ S m i =1 dom( t i ) we d efine t ( w ) = ( a 1 , . . . , a m ), where a i = t i ( w ) if w ∈ dom( t i ) and a i = $ otherwise. In Fig. 1, the th ird tree is the con volutio n of the first tw o trees. An m -dimensional (synchr onous) tr e e automaton o v er Γ is just a tree automaton A o ver the alphab et ( Γ ∪ { $ } ) m suc h that L ( A ) ⊆ { t 1 ⊗ · · · ⊗ t n | t 1 , . . . , t m ∈ T Γ } . S uc h an automaton defines an m -ary relation R ( A ) = { ( t 1 , . . . , t m ) | t 1 ⊗ · · · ⊗ t m ∈ L ( A ) } . 4 A tr e e automatic pr esentation is a tuple P = ( Γ , A 0 , A = , ( A r ) r ∈S ), where: – Γ is a finite alphab et. – S is a signature (the signature of P ), as b efore m r is the arit y of the symbol r ∈ S . – A 0 is a tree automaton ov er the alphab et Γ . – F or ev ery r ∈ S , A r is an m r -dimensional tree automaton ov er th e alphab et Γ ∪ { $ } suc h that R ( A r ) ⊆ L ( A 0 ) m r . – A = is a 2-dimensional tree automaton o ver the alphab et Γ ∪ { $ } suc h that R ( A = ) ⊆ L ( A 0 ) × L ( A 0 ) and R ( A = ) is a congruence on the structure ( L ( A 0 ) , ( R ( A r )) r ∈S ). This p resen tation P is called inje ctive if R ( A = ) is the iden tity relation on L ( A 0 ). In this case, w e can omit the automaton A = and id entify P with the tuple ( Γ , A 0 , ( A r ) r ∈S ). The stru cture present ed b y P is th e quotien t A ( P ) = ( L ( A 0 ) , ( R ( A r )) r ∈S ) / R ( A = ) . A stru cture A is called tr e e automatic if there exists a tree automatic presen tation P such that A ≃ A ( P ). W e will write [ u ] for the elemen t [ u ] R ( A = ) ( u ∈ L ( A 0 )) of the structure A ( P ). W e sa y th at th e present ation P has b ounded degree if the s tr ucture A ( P ) h as b ounded d egree. A string automatic pr esentation is a tree automatic presen tation, wh ere all tree automata are in fact string automata (as explained in Section 2.1), and a stru cture A is called string automatic if there exists a string automatic presen tation P suc h that A ≃ A ( P ). Typica l examples of string automatic structur es are ( N , + ) (Presbu rger’s arithm etic) , ( Q , ≤ ), and all ordinals b elo w ω ω [16,10]. An example of a tree automatic structure, whic h is not string automatic is ( N , · ) (the natural num b ers with m u ltiplication) [4], or the ordinal ω ω [10]. Examples of string automat ic structures of b ounded degree are transition graphs of T uring mac hines and Ca yley-graphs of automatic group s [12] (or ev en right-c ancellativ e monoids [29]). R emark 2.1. Usually a tr e e automatic pr esentat ion for an S -stru cture A = ( A, ( r ) r ∈S ) is defined as a tup le ( Γ , L, h ) suc h th at – Γ is a finite alphab et, – L ⊆ T Γ is a regular set of trees, – h : L → A is a su rjectiv e f unction, – the relation { ( u, v ) ∈ L × L | h ( u ) = h ( v ) } can b e recognized by a 2-dimensional tree automaton, and – for ev ery r ∈ S , the relation { ( u 1 , . . . , u m r ) ∈ L m r | ( h ( u 1 ) , . . . , h ( u m r )) ∈ r } can b e recognized by an m r -dimensional tree automaton. Since for our considerations, tree automatic presentati on s are part of the inp ut for algorithms, w e prefer our d efinition, where a tree automatic present ation is a finite ob ject (a tuple of finite tree automata), whereas in the stand ard definition, the presen tation also conta ins the present ation map h . 5 W e will consider the follo wing classes of tree automatic pr esen tations: SA = the class of all string automatic pr esentati ons SAb = the class of all string automatic pr esen tations of b ounded d egree iSAb = th e class of all injectiv e string automatic p r esen tations of b ounded d egree T A = the class of all tree automatic present ations T Ab = the class of all tree automatic presenta tions of b ound ed degree iT Ab = the class of all injective tree automatic presentati on s of b ou n ded degree The mo del c hecking problem F or the ab o ve classes of tr ee automatic pr esen tations, we will b e in terested in the follo w ing decision problems. Definition 2.2. L et C b e a class of tr e e automatic pr esenta tions. Then the firs t-order mo del c hec k in g problem F O MC( C ) for C denotes the set of al l p airs ( P , ϕ ) wher e P ∈ C , and ϕ is a close d formula over the signatur e of P such that A ( P ) | = ϕ . If C = { P } is a singleton, then the mo del c hecki ng problem F OMC( C ) f or C ca n b e iden tified with the first-order theory of the structure A ( P ). An algorithm deciding the mo del c hec k in g problem f or a non trivial class C decides the first-order theories of eac h elemen t of C uniformly . The follo wing t wo results are th e main motiv ations for in ve s tigating tree automatic struc- tures. Prop osition 2.3 (cf. [16 ,4]) . Ther e exists an algorithm that c omputes fr om a tr e e automatic pr esentat ion P = ( Γ , A 0 , A = , ( A r ) r ∈S ) and a formula ϕ ( x 1 , . . . , x m ) an m -dimensional tr e e automato n A over Γ with R ( A ) = { ( u 1 , . . . , u m ) ∈ L ( A 0 ) m | A ( P ) | = ϕ ([ u 1 ] , . . . , [ u m ]) } . The automaton is constru cted by indu ction on the structure of the form u la ϕ : disj unction corresp onds to th e disjoin t u nion of automata, existen tial quantificati on to pro jection, and negation to complement ation. Th e follo win g r esult is a direct consequence. Theorem 2.4 (cf. [16,4]). The mo del che cking pr oblem F OMC ( T A ) for al l tr e e automatic pr esentat ions is de cidable. In p articular, the first-or der the ory FOTh( A ) of every tr e e auto- matic structur e A is de cidable. R emark 2.5. Strictly sp eaking, [16,4] d evice algorithms that, giv en a tree automatic presen- tation and a closed f orm ula, d ecide whether th e form u la holds in the presente d structure. But a priori, it is n ot clear wh ether it is decidable, whether a giv en tuple ( Γ , A 0 , A = , ( A r ) r ∈S ) is a tree automatic p resen tation. Lemma 2.8 b elo w shows that T A is indeed decidable, w h ic h then completes the pr o of of this theorem. Theorem 2.4 h olds ev en if we add qu an tifiers f or “there are infinitely many x such that ϕ ( x )” [4,5] and “the num b er of elemen ts satisfying ϕ ( x ) is d ivisible by k ” (for k ∈ N ) [19] 1 . This implies in particular th at it is decidable wh ether a tree automatic p r esen tation d escrib es a lo cally fin ite structure. But the d ecidability of the first-order theory is far from efficien t, 1 [19] only p ro vides the pro ofs for string automatic structures. These pro ofs are easily ex tended to tree auto- matic struct ures once the presentation is injectiv e. But every tree a utomatic p resen tation can b e transfo rmed into an equ iv alen t injectiv e one [7, Cor. 4.2]. 6 since ther e are ev en s tring automatic structur es with a nonelemen tary fi rst-order theory [5]. F or instance the stru cture ( { 0 , 1 } ∗ , s 0 , s 1 , ), where s i = { ( w, wi ) | w ∈ { 0 , 1 } ∗ } for i ∈ { 0 , 1 } and is the prefix order on fin ite w ords, has a nonelemen tary fi rst-order theory , see e.g. [9, Example 8.3]. A lo cally finite example (enco ding the set of all finite lab eled linearly ord ered sets [25]) is as follo w s: the un iv erse is the set L = { u ⊗ v | u ∈ { 0 , 1 } + , v ∈ 0 ∗ , | v | < | u |} . In addition, w e h a v e a p artial order { ( u ⊗ v , u ⊗ v ′ ) ∈ L × L | | v | ≤ | v ′ |} that en codes the u n ion of all the linear order r elati ons, and a u n ary relation { u ⊗ v ∈ L | p osition | v | in u carries 1 } that enco des the lab eling. First complexity results: the classes T A etc and b oundedness T his pap er is concerned with the uniform and n on-uniform complexit y of the first-order theory of (some sub class of ) tree automatic stru ctur es of b ound ed degree. Thus, we will consid er algorithms that take as input tree automatic presenta tions (together with closed formulas). F or complexity consider a- tions, we ha ve to define the size | P | of a tree automatic pr esen tation P = ( Γ , A 0 , A = , ( A r ) r ∈S ). First, let us define the size | A | of an m -d imensional tree automato n A = ( Q, ∆, q 0 ) o ver Γ . A transition tup le from ∆ (see (1)) can b e stored with at most 3 log ( | Q | ) + m log( | Γ | ) many bits. Hence, u p to constan t factors, ∆ can b e stored in space | ∆ | · (log( | Q | ) + m log( | Γ | )). W e can assume that every state is the fi rst comp onent of some transition tup le, i.e., | Q | ≤ | ∆ | . F urthermore, the size of the basic alphab et Γ can b e b ounded by | ∆ | as well, but the di- mension m is indep endent from the size of ∆ . Since our complexit y measures will b e u p to p olynomial time red u ctions, it mak es sense to defin e the size of th e tree automaton A to b e | A | = | ∆ | · m . W e assume ∆ to b e n onempt y , hence | A | ≥ 1. Th e size of the present ation P = ( Γ , A 0 , A = , ( A r ) r ∈S ) is | P | = | A 0 | + | A = | + P r ∈S | A r | . Note that |S | ≤ | P | and m ≤ | P | , when m is the maximal arit y in S . It will b e conv enien t to w ork w ith injectiv e string (resp. tree) automatic pr esen tations. The follo wing lemma sa ys that this is no restriction, at least if we d o not consider complexit y asp ects. Lemma 2.6 ( [16, C or. 4.3] and [7, C or. 4.2]). F r om a given P ∈ T A we c an c ompute effe ctively P ′ ∈ iT A with A ( P ) ≃ A ( P ′ ) . If P ∈ S A , then P ′ ∈ iSA with A ( P ) ≃ A ( P ′ ) c an b e c ompute d in time 2 O ( | P | ) . R emark 2.7. In [7], only the existence of an equiv alen t injectiv e tree automatic presenta tion is stated, but the pr oofs of [7, Prop. 3.1 and Theorem 4.1] are effectiv e although the complexit y is difficult to extract. The follo wing lemma sho ws that th e classes of all tree and string automatic present ations are decidable and give s complexit y b ounds. While these tw o results are n ot surpr ising, it is not clear ho w to determine whether A ( P ) h as b ounded degree – this will b e solved b y Pr op. 2.10 b elo w. Lemma 2.8. The c lass T A is in EXPTIME , and the class SA b elongs to PSP A CE . Pr o o f . W e start with a pro of of the first statemen t. Sup p ose we are giv en a finite alphab et Γ , tree automata A 0 o v er Γ , and multi-dimensional tree automata A = and A r for r ∈ S o ver Γ ∪ { $ } . In a first step, w e c hec k that L ( A = ) and L ( A r ) are languages of con volutio ns of elemen ts of L ( A 0 ), in particular L ( A r ) ⊆ L ( A 0 ) ⊗ L ( A 0 ) · · · ⊗ L ( A 0 ) | {z } m r times (2) 7 where m r is the arit y of the automato n A r . An automaton f or the r igh t-hand side has size | A 0 | m r . T h us, the inclusion can b e d ecided in time exp onent ial in | A r | + | A 0 | m r . Since m r dep ends on the inpu t, this yields a doub ly exp onential algorithm. Alternativ ely , w e pr oceed as follo ws: (a) W e c hec k that no tree f r om L ( A r ) conta ins the lab el ($ , . . . , $). T o this aim, replace in all transitions of A r the letters fr om ( Γ ∪ { $ } ) m r \ { ($ , . . . , $) } by ⊤ and the letter ($ , . . . , $) b y ⊥ and c heck whether the language of the resulting au tomaton A ′ r is con tained in T {⊤} (the set of all ⊤ -lab eled b inary trees). Since the set T {⊤} can b e accepted by a fixed automaton, th is inclusion can b e decided in p olynomial time. (b) Let H ⊆ T Γ ∪{ $ } denote the set of those trees t whose Γ -lab eled no des form an initial segmen t of t that b elongs to L ( A 0 ). T o accept H , we extend A 0 as follo ws (where a ∈ Γ ): – W e add a n ew s tate q $ and transitions ( q $ , $), ( q $ , $ , q $ ), and ( q $ , $ , q $ , q $ ). – F or eac h transition ( p, a, q ), we add the transition ( p, a, q , q $ ). – F or eac h transition ( p, a ), w e add th e transitions ( p, a, q $ ) and ( p, a, q $ , q $ ). Let A $ 0 denote th e resulting tr ee automaton and, for 1 ≤ i ≤ m r , let A i r denote th e pro jection of A r to its i th comp onen t. Then w e chec k, for all 1 ≤ i ≤ m r whether L ( A i r ) ⊆ L ( A $ 0 ) which can b e d on e in exp onen tial time. All these tests are passed if and only if (2) holds for A r . In particular, we can from now on sp eak of the relations R ( A = ) and R ( A r ) ov er L ( A 0 ). It remains to b e c hec ked that R ( A = ) is a congruence on the structure ( L ( A 0 ) , ( R ( A r )) r ∈S ). F or this, we pr oceed as follo w s (c) First b uild 2-dimensional tree automata A ◦ , A − 1 , and A id of p olynomial size with R ( A ◦ ) = R ( A = ) ◦ R ( A = ), R ( A − 1 ) = R ( A = ) − 1 , and R ( A id ) = { ( t, t ) | t ∈ L ( A 0 ) } . T hen c h ec k R ( A ◦ ) ∪ R ( A − 1 ) ∪ R ( A id ) ⊆ R ( A = ) whic h can b e done in exp onen tial time. Th is test is passed if and only if R ( A = ) is an equiv alence relation on L ( A 0 ). (d) F or eac h r ∈ S , first construct an 2 m r -dimensional tree automaton A ′ r suc h that the tup le ( s 1 , . . . , s m r , t 1 , . . . , t m r ) b elongs to R ( A ′ r ) if and only if ( s i , t i ) ∈ R ( A = ) for all 1 ≤ i ≤ m r and ( t 1 , . . . , t m r ) ∈ R ( A r ). This can b e achiev ed b y running m r copies of A = as well as one cop y of A r in parallel. T h en p ro ject the automaton A ′ r on to the fi rst m r comp onen ts and c heck wh ether the relation accepted b y the resulting tree automaton is con tained in R ( A r ). Although A ′ r has exp on ential size (since m r dep ends on the presen tation P ), this can b e done again in exp onentia l time: w e complement A r , take the inte rsection with A ′ r and c heck the resulting automaton (of exp on ential size) for emptiness. This finishes the p ro of of the first statement . T o pro ve th e second, one can pro ceed analogously using that the inclusion problem for string automata b elongs to PSP ACE . ⊓ ⊔ F rom the lo we r b oun ds for inclus ion of string/tree automata, it follo ws easily that the upp er b ounds in Lemma 2.8 are sh arp . The follo w in g lemma says that the Gaifman graph of a string (resp. tree) automatic structure is effectiv ely s tr ing (resp. tree) automatic. This is an imm ediate consequence of Prop. 2.3, so the n ov elt y lies in the estimation of the complexit y . Lemma 2.9. F r om a give n tr e e (string) automatic pr esenta tion P = ( Γ , A 0 , A = , ( A r ) r ∈S ) one c an c onstruct a 2- dimensional tr e e (string) automaton A such that R ( A ) = { ( u, v ) ∈ L ( A 0 ) × L ( A 0 ) | ([ u ] , [ v ]) is an e dge of the Gaifman-gr aph G ( A ( P )) } . (3) If m is the maximal arity in S , then A c an b e c ompute d in time O ( m 2 · | P | 2 ) ≤ | P | O (1) . 8 Pr o o f . W e only giv e th e pro of for s tring automatic p resen tations, the tree automatic case can b e sh o wn verbatim. Let E b e the edge relation of the Gaifman-graph G ( A ( P )). Note that for all u, v ∈ L ( A 0 ) w e h a v e ([ u ] , [ v ]) ∈ E iff for some r ∈ S of arit y m r ≤ m and 1 ≤ i, j ≤ m r , ther e exist u 1 , . . . , u m r ∈ L ( A 0 ) with ( u 1 , . . . , u m r ) ∈ R ( A r ), u = u i , and v = u j . Let r ∈ S an d 1 ≤ i, j ≤ m r . Pro jecting the automaton A r on to the tracks i and j , one obtains a 2-dimensional automato n accepting all pairs ( u, v ) ∈ Γ ∗ × Γ ∗ suc h that there exists ( u 1 , . . . , u m r ) ∈ R ( A r ) with u = u i and v = u j . Then the disjoin t union of all these automata (for r ∈ S and 1 ≤ i, j ≤ m r ) s atisfies (3). Sin ce |S | ≤ | P | , th e construction can b e p erformed in time O ( m 2 · | P | 2 ). ⊓ ⊔ Lemma 2.9 allo ws to show that also the b ounded classes T Ab etc. are d ecidable: Prop osition 2.10. The fol lowing hold: (a) The class T Ab is de cidable. (b) The class iT Ab c an b e de cide d in exp onential time (in fact, it c an b e che cke d in p olynomial time whether a g i ven P ∈ iT A has b ounde d de gr e e). (c) The c lass SAb c an b e de cide d in exp onential time. Pr o o f . F or statemen t (a), let P ∈ T A (which is decidable b y Lemma 2.8 in exp onen tial time). By Lemma 2.6, we can assume P to b e in jectiv e. By L emma 2.9 we can compute an automaton A with (3), i.e., A defin es the edge r elatio n of the Gaifman-graph of A ( P ). Since P w as assum ed to b e in j ectiv e (i.e. ev ery equ iv al ence class [ u ] is the singleton { u } ), A ( P ) is of b oun ded degree iff A (seen as a transd ucer) is finite-v alued. Bu t th is is decidable in p olynomial time [30,28]. Th is finish es the p r o of of (a). Next consider statemen t (b): Pro vid ed the inpu t is guarantee d to b e an injectiv e tree automatic presentat ion, the p olynomial time b ound follo ws from the argum en ts ab o v e since there is no need to apply Lemma 2.6. It remains to decide wh ether the inpu t is indeed an injectiv e tree automatic presen tation: Using L emm a 2.8, it suffices to decide injectivit y wh ic h can b e done in exp onential time b y chec king inclusion of L ( A = ) in the conv olution of th e iden tity on T Γ . F or (c), w here we start with a string automatic presenta tion (whic h can b e decided in p olynomial sp ace and therefore exp onentia l time by Lemma 2.8), th e initial app licat ion of Lemma 2.6 leads to an exp onen tial blo w-up , whic h giv es in total an exp onent ial ru nning time for deciding the class SA b . ⊓ ⊔ Finally , since we deal with structures of b ounded degree, it will b e imp ortant to estimate the degree of suc h a stru ctures give n its presenta tion. Su c h estimates are provided by the follo wing result. Prop osition 2.11. The fol lowing hold: (a) If P ∈ iSAb , then the de gr e e of the structur e A ( P ) i s b ounde d by exp(1 , | P | O (1) ) . (b) If P ∈ iT Ab , then the de gr e e of the structur e A ( P ) i s b ounde d by exp(2 , | P | O (1) ) . (c) If P ∈ SAb , then the de gr e e of the structur e A ( P ) is b ounde d by exp(2 , | P | O (1) ) . Pr o o f . F or statemen t (a) let P ∈ iSAb . F rom Lemma 2.9, we can construct a string automa- ton A of size | P | O (1) that accepts the edge relation of the Gaifman graph of A ( P ). Then the degree of A ( P ) equals the maximal outdegree of th e relation R ( A ). F or string transducer, this n u m b er is exp onen tial in the size of A , i.e., it is in exp (1 , | P | O (1) ) [30 ]. 9 F or (b) w e can use a similar argum ent. But sin ce the maximal outdegree of the r elation recognized by a tree transdu cer A is d oubly exp onen tial in the size of A [28], we obtain the b ound exp (2 , | P | O (1) ) f or the degree of A ( P ). Finally statemen t (c) follo ws immediately fr om Lemm a 2.6 and (a). ⊓ ⊔ The b ounds on injectiv e string (r esp . tree) automatic pr esen tations in Prop. 2.11 are sharp: Let E n = { ( uw, v w ) | u, v , w , ∈ { a, b } ∗ , | u | = | v | = n } . Then the structure ( { a, b } ∗ , E n ) has an injectiv e string automatic presentati on of size O ( n ). The d egree of this structure is 2 n . Similarly , let E ′ n the set of all p airs ( t 1 , t 2 ) ∈ T { a,b } × T { a,b } of trees that d iffer at most in the fir st n lev els. Th en ( T { a,b } , E ′ n ) allo ws an injectiv e tree automatic p resen tation of size O ( n ) and the degree of this structur e is doubly exp onen tial in n . But it is not clear whether the doubly exp onen tial b ound for automatic presen tations in Pr op . 2.11(c) can b e realized. Moreo v er, w e cannot give any b ound for general tree automatic p resen tations since, as already remarke d, [7] d o es not provide an y estimate on th e size of an equiv alen t inje ctive tree automatic presentat ion. 3 Upp er b ounds It is the aim of this section to giv e an algorithm that decides the theory of a string/tree auto- matic stru cture of b ounded degree. The algorithm from Theorem 2.4 (that in particular solve s this p roblem) is based on Prop. 2.3, i.e., the inductive construction of an automaton accepting all satisfying assignments. Differen tly , w e base our algorithm on Gaifman’s Theorem 3.1, i.e., on the com b in atorics of spheres. W e therefore start with some mo del theory . 3.1 Mo del-theoretic bac kground The f ollo wing lo calit y principle of Gaifman implies that sup er-exp onentia l distances cannot b e handled in first-order logic: Theorem 3.1 ([13]). L et A b e a structur e, ( a 1 , . . . , a k ) , ( b 1 , . . . , b k ) ∈ A k , d ≥ 0 , and D 1 , . . . , D k ≥ 2 d such that ( A ↾ ( k [ i =1 S ( D i , a i )) , a 1 , . . . , a k ) ≃ ( A ↾ ( k [ i =1 S ( D i , b i )) , b 1 , . . . , b k ) . (4) Then, for every formula ϕ ( x 1 , . . . , x k ) of quantifier depth at most d , we have: A | = ϕ ( a 1 , . . . , a k ) ⇐ ⇒ A | = ϕ ( b 1 , . . . , b k ) . Note that (4) sa ys that there is an isomorph ism b et w een the t wo induced substructur es A ↾ ( S k i =1 S ( D i , a i )) and A ↾ ( S k i =1 S ( D i , b i )) that maps a i to b i for all 1 ≤ i ≤ k . Let S b e a signature and let k , d ∈ N with 0 ≤ k ≤ d . A p otential ( d, k ) -spher e is a tup le ( B , b 1 , . . . , b k ) such that the f ollo wing holds: – B is an S -stru ctur e with b 1 , . . . , b k ∈ B . – F or all b ∈ B there exists 1 ≤ i ≤ k su c h that d B ( b i , b ) ≤ 2 d − i . 10 There is only one ( d, 0)-sphere namely the empty sp here ∅ . F o r our later applications, B will b e alwa ys a finite structure, but in this subsection fi niteness is not n eeded. The p oten tial ( d, k )-sph ere ( B , b 1 , . . . , b k ) is r e alizable in the structur e A if there exist a 1 , . . . , a k ∈ A suc h that ( A ↾ ( k [ i =1 S (2 d − i , a i )) , a 1 , . . . , a k ) ≃ ( B , b 1 , . . . , b k ) . Let σ = ( B , b 1 , . . . , b k ) b e a p oten tial ( d, k )-sph ere and let σ ′ = ( B ′ , b ′ 1 , . . . , b ′ k , b ′ k +1 ) b e a p oten tial ( d, k + 1)-sphere ( k + 1 ≤ d ). Then σ ′ extends σ (abbreviated σ σ ′ ) if ( B ′ ↾ ( k [ i =1 S (2 d − i , b i )) , b ′ 1 , . . . , b ′ k ) ≃ ( B , b 1 , . . . , b k ) . The follo wing definition is the b asis for our d ecision p ro cedure. Definition 3.2. L et A b e an S - structur e, ψ ( y 1 , . . . , y k ) a formula of quantifier depth at most d , and let σ = ( B , b 1 , . . . , b k ) b e a p otential ( d + k , k ) -spher e. The Bo ole an value ψ σ ∈ { 0 , 1 } is define d i nductiv e ly as fol lows: – If ψ ( y 1 , . . . , y k ) is an atomic formula, then ψ σ = ( 0 if B | = ψ ( b 1 , . . . , b k ) 1 if B 6| = ψ ( b 1 , . . . , b k ) . (5) – If ψ = ¬ θ , then ψ σ = 1 − θ σ . – If ψ = α ∨ β , then ψ σ = max( α σ , β σ ) . – If ψ ( y 1 , . . . , y k ) = ∃ y k +1 θ ( y 1 , . . . , y k , y k +1 ) then ψ σ = max { θ σ ′ | σ ′ is a r e alizable p ot ential ( d + k , k + 1) -spher e with σ σ ′ } . (6) The follo w ing result ensures for ev ery closed formula ψ that ψ ∅ = 1 if and only if A | = ψ . Hence the ab o ve defin ition can p ossibly b e us ed to d ecide v alidit y of the f orm ula ϕ in the structure A . Prop osition 3.3. L et S b e a signatur e, A an S -structur e with a 1 , . . . , a k ∈ A , ψ ( y 1 , . . . , y k ) a f ormula of quantifier depth at most d , and σ = ( B , b 1 , . . . , b k ) a p otential ( d + k , k ) -spher e with ( A ↾ ( k [ i =1 S (2 d + k − i , a i )) , a 1 , . . . , a k ) ≃ ( B , b 1 , . . . , b k ) . (7) Then A | = ψ ( a 1 , . . . , a k ) ⇐ ⇒ ψ σ = 1 . Pr o o f . W e pr o v e the lemma b y induction on the stru cture of th e form u la ψ . First assu m e that ψ is atomic, i.e. d = 0. Then we h a v e: ψ σ = 1 ( 5 ) ⇐ ⇒ B | = ψ ( b 1 , . . . , b k ) ( 7 ) ⇐ ⇒ A ↾ ( k [ i =1 S (2 k − i , a i )) | = ψ ( a 1 , . . . , a k ) ⇐ ⇒ A | = ψ ( a 1 , . . . , a k ) , 11 where the last equiv alence holds since ψ is atomic. The cases ψ = ¬ θ and ψ = α ∨ β are straightfo r w ard and therefore omitted. W e fi n ally consider the case ψ ( y 1 , . . . , y k ) = ∃ y k +1 θ ( y 1 , . . . , y k , y k +1 ). First assume that ψ σ = 1. By (6), there exists a realizable p otent ial ( d + k , k + 1)-sphere σ ′ with σ σ ′ and θ σ ′ = 1. Since σ ′ is realizable, there exist a ′ 1 , . . . , a ′ k , a ′ k +1 ∈ A with ( A ↾ ( k +1 [ i =1 S (2 d + k − i , a ′ i )) , a ′ 1 , . . . , a ′ k , a ′ k +1 ) ≃ ( B ′ , b 1 , . . . , b k , b k +1 ) = σ ′ . (8) By indu ction, we ha ve A | = θ ( a ′ 1 , . . . , a ′ k , a ′ k +1 ) and ther efore A | = ψ ( a ′ 1 , . . . , a ′ k ). F rom (7), (8), and σ σ ′ , we also obtain ( A ↾ ( k [ i =1 S (2 d + k − i , a ′ i )) , a ′ 1 , . . . , a ′ k ) ≃ ( A ↾ ( k [ i =1 S (2 d + k − i , a i )) , a 1 , . . . , a k ) and therefore by Gaifman’s T heorem 3.1 A | = ψ ( a 1 , . . . , a k ). Con versely , let a k +1 ∈ A with A | = θ ( a 1 , . . . , a k , a k +1 ). Let σ ′ = ( B ′ , b 1 , . . . , b k , b k +1 ) b e the uniqu e (up to isomorph ism ) p otenti al ( d + k, k + 1)-sph ere suc h th at ( A ↾ ( k +1 [ i =1 S (2 d + k − i , a i )) , a 1 , . . . , a k , a k +1 ) ≃ ( B ′ , b 1 , . . . , b k , b k +1 ) . (9) Then (7) imp lies σ σ ′ . Moreo ver, by (9), σ ′ is realizable in A , and A | = θ ( a 1 , . . . , a k , a k +1 ) implies b y induction θ σ ′ = 1. Hence, b y (6), we get ψ σ = 1 wh ic h finishes the pro of of the lemma. ⊓ ⊔ 3.2 The decision procedure No w sup p ose w e wan t to d ecide whether the closed form u la ϕ holds in a tree automatic structure A of b ounde d de gr e e . By Prop. 3.3 it suffices to compu te the Bo olea n v alue ϕ ∅ . This computation will follo w the inductive definition of ϕ σ from Def. 3.2. Since ev ery ( d, k )-sph ere that is realizable in A is fi nite, we only ha v e to d eal with finite spheres. The crucial p art of our algorithm is to determine whether a fin ite p otenti al ( d, k )-sphere is realizable in A . In the follo win g, for a finite p oten tial ( d, k )-sphere σ = ( B , b 1 , . . . , b k ), we denote with | σ | the n u m b er of elemen ts of B and with δ ( σ ) we d enote the degree of the finite stru ctur e B . W e ha ve to solv e the follo wing realizabilit y problem: Definition 3.4. L et C b e a class of tr e e automatic pr esentations. Then the realizabilit y prob- lem REAL( C ) for C denotes the set of al l p airs ( P , σ ) wher e P ∈ C and σ is a finite p otential ( d, k ) - spher e over the sig natur e of P for some 0 ≤ k ≤ d such that σ c an b e r e alize d in A ( P ) . Lemma 3.5. The pr oblems REAL( iS A ) and RE AL( iT A ) ar e de c idable. M or e pr e cisely: – L et P ∈ i SA and let m b e the maximal arity of a r elation in A ( P ) . L et σ b e a finite p otentia l ( d, k ) - spher e over the signatur e of P . Then it c an b e che cke d in sp ac e | σ | O ( m ) · | P | 2 · 2 O ( δ ( σ )) , whether σ is r e a lizable in A ( P ) . – If P ∈ iT A , then r e alizability c an b e che cke d in time exp(1 , | σ | O ( m ) · | P | 2 · 2 O ( δ ( σ )) ) . 12 Pr o o f . W e fi rst pro ve the statemen t on injectiv e string automatic pr esentati ons. Let P = ( Γ , A 0 , ( A r ) r ∈S ) ∈ i SA . Let σ = ( B , b 1 , . . . , b k ) and let c 1 , . . . , c | σ | b e a list of all elemen ts of B . Note that ev er y b i o ccurs in this list. Let E A ( P ) b e the edge relation of the Gaifman graph G ( A ( P )) and E B that of the Gaifman graph G ( B ). Then σ is realizable in A ( P ) if and only if there are words u 1 , . . . , u | σ | ∈ Γ ∗ suc h that (a) u i ∈ L ( A 0 ) f or all 1 ≤ i ≤ | σ | , (b) u i 6 = u j for all 1 ≤ i < j ≤ | σ | , (c) ( u i 1 , . . . , u i m r ) ∈ R ( A r ) for all r ∈ S and all ( c i 1 , . . . , c i m r ) ∈ r B , (d) ( u i 1 , . . . , u i m r ) / ∈ R ( A r ) for all r ∈ S and all ( c i 1 , . . . , c i m r ) ∈ B m r \ r B , an d (e) there is n o v ∈ L ( A 0 ) such th at, for some 1 ≤ j ≤ | σ | and 1 ≤ i ≤ k with d ( c j , b i ) < 2 d − i , w e hav e (e.1) ( u j , v ) ∈ E A ( P ) and (e.2) v / ∈ { u p | ( c j , c p ) ∈ E B } . Then (a-d) express that the mappin g c i 7→ u i is w ell-defined and an em b edding of B into A ( P ). In (e), ( u j , v ) ∈ E A ( P ) implies that v b elongs to S 1 ≤ i ≤ k S (2 d − i , u i ). Hence (e) expr esses that all elemen ts of S 1 ≤ i ≤ k S (2 d − i , u i ) b elong to the image of this emb edding. W e no w construct a | σ | -dimensional automaton A o ve r the alph ab et Γ th at c hec k s (a-e). At the end, we hav e to c hec k th e language of this automaton f or non-emptiness. The automaton A is the d ir ect pro du ct of automata A a , A b , A c , A d , and A e that chec k the conditions separately . Then A a is the direct pr od uct of | σ | many copies of the automaton A 0 , hence A a has at most | P | | σ | man y states. Next, the automaton for (b) is the dir ect pro duct of O ( | σ | 2 ) many copies of an automaton of fi xed size (that chec ks whether t wo trac ks are d ifferen t). Hence, this automaton has 2 | σ | O (1) man y states. The automaton A c is again a direct pro duct, this time of one au tomaton for eac h r ∈ S (and therefore of at most | P | man y automata). Eac h of these automata is the direct pro d u ct of | r B | many copies of th e automaton A r . Since the arit y of r ∈ S is b ound ed b y m , we ha ve | r B | ≤ | σ | m . Hence, th e automaton A c has at most ( | P | | σ | m ) | P | = | P | | P |·| σ | m man y states. F or A d , w e can argue similarly , but this time using copies of the complement of the automaton A r . This yields for A d the b oun d (2 | P | ) | P |·| σ | m = exp(1 , | P | 2 · | σ | m ) on the n u m b er of states. It remains to construct th e automaton A e . F or this, w e first construct its complemen t, i.e., an automato n A ′ e that c hec ks for the existence of v ∈ L ( A 0 ) w ith the d esired p rop erties. Th is automaton A ′ e is the disjoint un ion of at most | σ | man y automata, one for eac h 1 ≤ j ≤ | σ | suc h that there exists 1 ≤ i ≤ k with d ( c j , b i ) < 2 d − i . Any of these comp onents consists of the direct pro duct of automata A e. 1 and A e. 2 c hec k in g (e.1) and (e.2), resp ectiv ely . By Lemma 2.9, A e. 1 hast at most m 2 · | P | 2 man y states. Recall that the degree of B is δ ( σ ). Hence, th e s et { u p | ( c j , c p ) ∈ E B } con tains at most δ ( σ ) man y elemen ts. Th u s, (e.2) can b e c heck ed by an automaton A e. 2 with 2 O ( δ ( σ )) man y states. Hence, A ′ e is the disjoint union of at most | σ | copies of an automaton of size | P | 2 · m 2 · 2 O ( δ ( σ )) and therefore has at most | σ | · | P | 2 · m 2 · 2 O ( δ ( σ )) man y states. Now the num b er of states of A e can b e b oun d b y exp(1 , | σ | · | P | 2 · m 2 · 2 O ( δ ( σ )) ). In summary , the automaton A has at most | P | | σ | · 2 | σ | O (1) · | P | | P |·| σ | m · 2 | P | 2 ·| σ | m · 2 | σ | ·| P | 2 · m 2 · 2 O ( δ ( σ )) ≤ exp(1 , | σ | O ( m ) · | P | 2 · 2 O ( δ ( σ )) ) 13 man y states. Hence c hec kin g emptiness of its language (and therefore r ealiz ab ility of σ in A ( P )) can b e done in space logarithmic to the n umb er of states, i.e., in sp ace | σ | O ( m ) · | P | 2 · 2 O ( δ ( σ )) whic h pro ves the statemen t for string automatic p resen tations. F or injectiv e tree automatic presentat ions , the construction and size estimate for A are the same as ab o ve . But emptiness of tree automata can only b e chec k ed in deterministic p olynomial time (and not in logspace unless NL = P ). Hence, emptin ess of A can b e chec k ed in time exp(1 , | σ | O ( m ) · | P | 2 · 2 O ( δ ( σ )) ). ⊓ ⊔ In the follo wing, for a tree automatic presenta tion P of b ounded degree, w e d enote with g ′ P = g ′ A ( P ) the normalized gro wth function of the stru cture A ( P ). Theorem 3.6. The mo del che cking pr oblem F O MC( T Ab ) is de cidable, i.e., on input of a tr e e automatic pr esentatio n P of b ounde d de gr e e and a close d formula ϕ over the signatur e of P , one c an effe ctively determine whether A ( P ) | = ϕ holds. M or e pr e cisely (wher e m is the maximal arity of a r elation fr om the signatur e of P ): (1) F OMC ( i SAb ) c an b e de cide d in sp ac e g ′ P (2 | ϕ | ) O ( m ) · exp(2 , | P | O (1) ) ≤ exp(2 , | P | O (1) + | ϕ | ) . (2) F OMC ( S Ab ) c an b e de cide d in sp ac e exp(3 , O ( | P | ) + log( | ϕ | )) . (3) F OMC ( i T Ab ) c an b e de cide d in time exp 1 , g ′ P (2 | ϕ | ) O ( m ) · exp(3 , | P | O (1) ) ≤ exp(4 , | P | O (1) + log( | ϕ | )) . Pr o o f . The decidabilit y follo w s immediately fr om Th eorem 2.4 and Pr op. 2.10(a). W e fi rst giv e the pro of for inj ectiv e string automatic presenta tions. By Prop . 3.3 it suffices to compute the Bo olean v alue ϕ ∅ . Recall the ind uctiv e defi nition of ϕ σ from Def. 3.2 that we no w trans lated in to an algorithm for computin g ϕ ∅ . First note that suc h an algo r ithm has to handle p oten tial ( d, k )-sph eres for 1 ≤ k ≤ d ≤ | ϕ | ( d is the qu an tifier rank of ϕ ) that are realizable in A ( P ). The num b er of no des of a p otentia l ( d, k )-sph ere realizable in A ( P ) is b ounded b y k · g ′ P (2 d ) ∈ g ′ P (2 d ) O (1) since k ≤ d < 2 d ≤ g ′ P (2 d ). T he num b er of relations of A ( P ) is b ound ed b y | P | . Hence, any p oten tial ( d, k )-sph ere can b e describ ed by | P | · g ′ P (2 d ) O ( m ) man y bits. Note that the set of ( d, k )-spheres with 0 ≤ k ≤ d (ordered by th e extension r elatio n ) forms a tree of depth d + 1. The algorithm visits the n o d es of this tree in a depth-first manner (and descen ts when unrav eling an existen tial qu an tifier). Hence we h a v e to store d + 1 many spheres. F or th is, the algorithm needs space ( d + 1) · | P | · g ′ P (2 d ) O ( m ) = | P | · g ′ P (2 d ) O ( m ) . Moreo v er, durin g the unra veling of a quan tifier, the algorithm has to chec k realiza b ilit y of a p oten tial ( d, k )-sph ere for 1 ≤ k ≤ d ≤ | ϕ | . An y su c h sphere has at most g ′ P (2 d ) O (1) man y elements and th e d egree δ of A is b ound ed b y exp(1 , | P | O (1) ) by Pr op. 2.11. Hence, b y Lemma 3.5, r ealiza b ilit y can b e c hec ked in space g ′ P (2 d ) O ( m ) · | P | 2 · exp (2 , | P | O (1) ) ≤ g ′ P (2 | ϕ | ) O ( m ) · exp(2 , | P | O (1) ). A t the end , w e ha ve to chec k wh ether a tup le b satisfies an atomic f orm ula ψ ( y ), wh ic h is trivial. In total, the algorithm runs in space | P | · g ′ P (2 | ϕ | ) O ( m ) + g ′ P (2 | ϕ | ) O ( m ) · exp(2 , | P | O (1) ) ≤ g ′ P (2 | ϕ | ) O ( m ) · exp(2 , | P | O (1) ) . 14 Recall that g ′ A (2 | ϕ | ) ≤ δ 2 | ϕ | and δ ≤ 2 | P | O (1) b y Pr op. 2.11 . S ince also m ≤ | P | , we obtain g ′ P (2 | ϕ | ) O ( m ) · exp(2 , | P | O (1) ) ≤ exp(1 , | P | O (1) · 2 | ϕ | · O ( m )) · exp(2 , | P | O (1) ) ≤ exp(2 , | P | O (1) + | ϕ | ) . This completes the consideration f or inj ectiv e string automatic present ations. If P is jus t automatic, we can tran s form it in to an equiv alen t injectiv e automatic pr esen- tation wh ic h increases the size exp onen tially b y Lemma 2.6. Hence, replacing | P | b y 2 O ( | P | ) yields the space b oun d. Next, we consider inj ective tree automatic pr esentati ons. T he algorithm is the same, i.e., it p arses the tree of all p otenti al ( d, k )-sph er es and c hec ks them for realizabilit y . Note that the n u m b er of p otentia l ( d, k )-sph eres is in exp(1 , | P | · g ′ P (2 d ) O ( m ) ). By Prop. 2.1 1, the degree δ is b ounded b y exp(2 , | P | O (1) ). Hence, by Lemma 3.5, the realizabilit y of an y p oten tial ( d, k )- sphere can b e c h ec k ed in time exp 1 , g ′ P (2 d ) O ( m ) · | P | 2 · exp(3 , | P | O (1) ) ≤ exp 1 , g ′ P (2 | ϕ | ) O ( m ) · exp(3 , | P | O (1) ) . Recall that g ′ P (2 | ϕ | ) ≤ δ 2 | ϕ | and δ ≤ exp(2 , | P | O (1) ) by Prop. 2.11. S ince also m ≤ | P | , we obtain g ′ P (2 | ϕ | ) O ( m ) · exp(3 , | P | O (1) ) ≤ exp(2 , | P | O (1) ) 2 | ϕ | · O ( | P | ) · exp(3 , | P | O (1) ) = exp(2 , | P | O (1) + | ϕ | ) · exp(3 , | P | O (1) ) = exp(3 , | P | O (1) + log( | ϕ | )) . ⊓ ⊔ R emark 3.7. Note that the ab o v e theorem do es not giv e th e complexit y for F O MC( T Ab ), i.e., for arbitrary tree automatic presenta tions of b ound ed degree: Here, one can pro ceed as for string automatic presentat ions , i.e., make the pr esen tation in jectiv e and refer to th e ab o v e result on F OMC( iT A b ) – this gives the d ecidabilit y that we already kno w from Theorem 2.4 and Prop. 2.10. At present, w e cann ot compare the complexit y of this new algorithm with the nonelemen tary one from T heorem 2.4 since the size of the injectiv e p resen tation is not kno wn . W e deriv e a num b er of consequ ences on the uniform and non-un iform complexit y of the first-order theories of string/tree automatic structures of b ounded degree. Th e fir st one con- cerns the uniform mo del chec king problems and is a direct consequence of the ab ov e theorem. Corollary 3.8. The fol lowing holds: – The mo del che cking pr oblem FOMC( iSAb ) b elongs to 2EXPSP A CE . – The mo del che cking pr oblem FOMC( SAb ) b elongs to 3EXPS P A CE . – The mo del che cking pr oblem FOMC( iT Ab ) b elongs to 4EXPTIME . Next we concent rate on the non-un iform complexity , wh ere the structure is fi x ed . F o r string automatic structures, we d o n ot get a b etter upp er b oun d in this case (statemen t (i) b elo w) except in case of p olynomial gro w th (statemen t (ii) b elo w ). 15 Corollary 3.9. L et A b e a string automatic structur e of b ounde d de gr e e. (i) Then FOTh( A ) b elongs to 2EXPSP A CE . (ii) If A has p olynom i al gr owth then F OT h( A ) b elongs to EXPSP A CE . Pr o o f . Since A is string automatic, it has a fixed injectiv e string automatic p resen tation P , i.e., | P | and m are fixed constan ts. Hence the resu lt follo ws immediately from (1) in Theorem 3.6. No w supp ose that A has p olynomial gro w th, i.e., g ′ A ( x ) ∈ x O (1) . Th en, again, th e claim follo ws imm ed iatel y f rom (1) in Theorem 3.6, since g ′ A (2 | ϕ | ) O ( m ) ≤ 2 O ( | ϕ | ) . ⊓ ⊔ The last consequence of Theorem 3.6 concerns tree automatic structures. Here, we can impro ve the upp er b ound from Theorem 3.6 for the non-uniform case by one exp onent. In case of p olynomial gro w th, w e can sa ve y et another exp onen t: Corollary 3.10. L et A b e a tr e e automatic structur e of b ounde d de gr e e. (i) Then FOTh( A ) b elongs to 3EXPTIME . (ii) If A has p olynom i al gr owth then F OT h( A ) b elongs to 2EXPTIME . Pr o o f . Since A is tree automatic, it h as a fixed injectiv e tree automatic presen tation P . Hence, again, the first claim follo ws immed iatel y from (3) in Theorem 3.6. No w supp ose that A has p olynomial gro wth, i.e., g ′ A ( x ) ∈ x O (1) . Th en the claim follo ws since exp(1 , g ′ A (2 | ϕ | ) O ( m ) ) ≤ exp(1 , 2 O ( | ϕ | ) ) = exp(2 , O ( | ϕ | )) , implying that the p roblem b elongs to 2EXPTIM E . ⊓ ⊔ Tw o observ ations on the gro wth function W e complement this section with a sh ort excursion into the field of gro wth functions of automatic structures. The t wo results to b e rep orted ind icate that these growth functions do not b eha ve as n icely as on e would w ish. F ortunately , these negativ e findin gs are of no imp ortance to our m ain concerns. Recall that the gro wth r ate of a regular language is either b oun ded b y a p olynomial from ab o ve or b y an exp onenti al function from b elo w and that it is decidable w h ic h of th ese cases applies. The next lemmas sh o w that the analogous statemen ts for gro wth functions of strin g automatic structures are f alse. Lemma 3.11. Ther e is a string automatic gr aph of interme diate gr owth (i.e., the gr owt h is neither exp onential nor p olyn omial). Pr o o f . Let L = { 0 , 1 } ∗ $ { 0 , 1 } ∗ and let E b e { ( u $ bv, ub $ v ) | u, v ∈ { 0 , 1 } ∗ , b ∈ { 0 , 1 }} ∪ { ( u $ , $ ub ) | u ∈ { 0 , 1 } ∗ , b ∈ { 0 , 1 }} . Then T = ( L, E ) is a string automatic tr ee obtained f r om the complete b inary tr ee $ { 0 , 1 } ∗ b y ad d ing a p ath of length n b etw een u and ub for u ∈ { 0 , 1 } n and b ∈ { 0 , 1 } . Hence, a path of length n starting in the ro ot $ of T branches at distance 0 , 2 , 5 , 10 , . . . , i 2 + 1 , . . . , ⌊ √ n − 1 ⌋ 2 + 1 from the ro ot. Hence, for the gro wth fu n ction g T w e obtain the follo wing estimate: g T ( n ) ∈ Θ ( √ n ) X i =0 ( i + 1) · 2 i = Θ ( √ n ) · 2 Θ ( √ n ) = 2 Θ ( √ n ) ⊓ ⊔ 16 Lemma 3.12. It is unde cidable whether a string automatic gr aph of b ounde d de gr e e has p oly- nomial gr owth . Pr o o f . W e sh o w the undecidabilit y by a reduction of th e halting problem (with empt y in put) for T uring mac hines. So let N b e a T ur ing mac hin e. W e can trans f orm N into a deterministic rev ersib le T uring machine M such that: (i) N halts on empt y inpu t if and only if M do es so. (ii) M do es not allo w in finite s equ ences of bac kw ard s steps (i.e., th ere are no configur atio ns c i with c i +1 ⊢ M c i for all i ∈ N ), s ee also [21] for a similar construction. Let C b e the set of configurations of M (a regular set) and c 0 the initial configuration with empt y input. No w define L = ( { 0 , 1 } C ) + (w e assume that 0 and 1 do not b elong to the alphab et of C ) and E = { ( uac, uac ′ ) | u ∈ L ∪ { ε } , a ∈ { 0 , 1 } , c, c ′ ∈ C, c ⊢ M c ′ } ∪ { ( uac, uacbc 0 ) | u ∈ L ∪ { ε } , a, b ∈ { 0 , 1 } , c ∈ C is halting } . Then ( L, E ) is an automatic directed graph. Since M is rev ers ible, it is a forest of ro oted trees (b y (ii)). First sup p ose there are configurations c 1 , c 2 , . . . , c n with c i − 1 ⊢ M c i for 1 ≤ i ≤ n such that c n is halting. Then the set 0( c n { 0 , 1 } ) ∗ { c 0 , c 1 , . . . , c n } forms an infi nite tree in ( L, E ). An y b ranc h in this tree branches ev ery n steps. Hence ( L, E ) has exp onenti al gro wth. No w assume that c 0 is the starting p oin t of an infinite computation. Let T b e an y tree in the forest ( L, E ). Then its r oot is of the form uac ∈ L with u ∈ L ∪ { ε } , a ∈ { 0 , 1 } , and c ∈ C suc h that c is no successor configu r ation of an y other configuration. There are t w o p ossibilities: 1. The configuration c is the starting configur ation of an in finite compu tatio n of M . Then T is an infin ite path. 2. There is a h alting configuration c ′ and n ∈ N with c ⊢ n M c ′ . Then T starts with a path of length n . The final n od e of this p ath has tw o children, namely uac ′ 0 c 0 and uac ′ 1 c 0 . But, since M do es not halt on the empt y inpu t, eac h of these no des is the ro ot of an infinite path. Th us, in this case ( L, E ) has p olynomial (ev en linear) gro w th . ⊓ ⊔ 4 Lo wer b ounds In this sectio n, we will pro ve that the upp er complexit y b oun ds for the non-u n iform problems (Cor. 3.9 and C or. 3.10) are sh arp. This will imply th at the complexit y of the uniform pr oblem for injectiv e string automatic p r esen tations from Th eorem 3.6 is sh arp as well. F or a bin ary r elati on r and m ∈ N w e denote with r m the m -fold comp osition of r . Th en the follo wing lemma is folklore. Lemma 4.1. L et the signatur e S c ontain a binary symb ol r . F r o m a gi ven numb er m (enc o de d unary), we c an c onstruct in line ar time a formula ϕ m ( x, y ) such that for every S -structur e A and al l elements a, b ∈ A we have: ( a, b ) ∈ r 2 m if and only if A | = ϕ m ( a, b ) . 17 Pr o o f . Let ϕ 0 ( x, y ) = r ( x, y ) an d , for m > 0 defin e ϕ m ( x, y ) = ∃ z ∀ x ′ , y ′ ((( x ′ = x ∧ y ′ = z ) ∨ ( x ′ = z ∧ y ′ = y )) → ϕ m − 1 ( x ′ , y ′ )) . ⊓ ⊔ F or a b it string u = a 1 · · · a m ( a i ∈ { 0 , 1 } ) let v al( u ) = P m − 1 i =0 a i +1 2 i b e the in teger v alue represent ed by u . Vice v ersa, for 0 ≤ i ≤ 2 m − 1 let bin m ( i ) ∈ { 0 , 1 } m b e the unique string with v al(bin m ( i )) = i . Theorem 4.2. Ther e exists a fixe d string automatic structur e A of b ounde d de gr e e such that F OTh ( A ) is 2EXPSP A CE -har d . Pr o o f . Let M b e a fixed T uring machine w ith a sp ace b ound of exp(2 , n ) s uc h that M acce p ts a 2EXPSP ACE -c omplete language; such a mac hin e exists by standard argumen ts. Let Γ b e the tap e alphab et, Σ ⊆ Γ b e th e inpu t alphab et, and Q b e the set of states. Th e initial (resp. accepting) state is q 0 ∈ Q (r esp. q f ∈ Q ), the b lank symb ol is ∈ Γ \ Σ . Let Ω = Q ∪ Γ . A configuration of M is describ ed b y a string from Γ ∗ QΓ + ⊆ Ω + (later, sym b ols of configurations w ill b e preceded with add itional coun ters). F or t wo configurations u and v with | u | = | v | w e write u ⊢ M v if u can ev olv e with a single M -transition into v . Note that there exists a r elatio n α M ⊆ Ω 3 × Ω 3 suc h that for all configurations u = a 1 · · · a m and v = b 1 · · · b m ( a i , b i ∈ Ω ) w e ha ve u ⊢ M v ⇐ ⇒ ∀ i ∈ { 1 , . . . , m − 2 } : ( a i a i +1 a i +2 , b i b i +1 b i +2 ) ∈ α M . (10) Let ∆ = { 0 , 1 , # } ∪ Ω , and let π : ∆ → Ω ∪ { # } b e the pro jection morphism with π ( a ) = a for a ∈ Ω ∪ { # } and π (0) = π (1) = ε . F or m ∈ N , a strin g x ∈ ∆ ∗ is an ac c epting 2 m -c omputation if x can b e factorized as x = x 1 # x 2 # · · · x n # for some n ≥ 1 suc h that the follo wing holds: – F or ev er y 1 ≤ i ≤ n ther e exist a i, 0 , . . . , a i, 2 m − 1 ∈ Ω such th at x i = Q 2 m − 1 j =0 bin m ( j ) a i,j . – F or ev er y 1 ≤ i ≤ n , π ( x i ) ∈ Γ ∗ QΓ + . – π ( x 1 ) ∈ q 0 Σ ∗ ∗ and π ( x n ) ∈ Γ ∗ q f Γ + – F or ev er y 1 ≤ i < n , π ( x i ) ⊢ M π ( x i +1 ). F rom M we no w construct a fix ed string automatic structur e A of b oun ded degree. W e start with the follo win g r egular language U 0 : U 0 = π − 1 (( Γ ∗ QΓ + #) ∗ ) ∩ (11) (0 + Ω ( { 0 , 1 } + Ω ) ∗ 1 + Ω # ) + ∩ (12) 0 + q 0 ( { 0 , 1 } + Σ ) ∗ ( { 0 , 1 } + ) ∗ # ∆ ∗ ∩ (13) ∆ ∗ q f ( ∆ \ { # } ) ∗ # (14) A string x ∈ U 0 is a candidate for an acce pting 2 m -computation of M . With (11) w e describ e the b asic structure of suc h a computation, it consists of a list of configur ations separated b y #. Moreo v er, every symb ol in a configuration is preceded by a bit strin g, which repr esents a c ounter . By (12 ) eve r y count er is non-empt y , the first sym b ol in a configuration is preceded b y a counter f r om 0 + , the last sym b ol is preceded b y a counter from 1 + . Moreo ver, b y (13), the first confi guration is an initial configuration, whereas b y (14), the last configur ation is accepting (i.e. the curr en t state is q f ). F or th e fur ther considerations, let u s fi x some x ∈ U 0 . Hence, w e can factorize x as x = x 1 # x 2 # · · · x n # suc h that: 18 – F or ev ery 1 ≤ i ≤ n , there exist m i ≥ 1, a i, 0 , . . . , a i,m i ∈ Ω and coun ters u i, 0 , . . . , u i,m i ∈ { 0 , 1 } + suc h that x i = Q m i j =0 u i,j a i,j . – F or ev er y 1 ≤ i ≤ n , u i, 0 ∈ 0 + , u i,m i ∈ 1 + , and π ( x i ) ∈ Γ ∗ QΓ + . – π ( x 1 ) ∈ q 0 Σ ∗ ∗ and π ( x n ) ∈ Γ ∗ q f Γ + W e next wan t to construct, from m ∈ N , a small form ula expressing that x is an acc epting 2 m -computation. T o ac hiev e this, w e add some stru cture around strings from U 0 . Then the form u la we are seeking has to ensur e t wo facts: (a) The counters b eha ve correctly , i.e. for all 1 ≤ i ≤ n and 0 ≤ j ≤ m i , we h a v e | u i,j | = m and if j < m i , then v al( u i,j + 1 ) = v al( u i,j ) + 1. Note that this enforces m i = 2 m − 1 for all 1 ≤ i ≤ n . (b) F or t wo s u ccessiv e configurations, the second one is the successor configuration of the first one w ith resp ect to the mac hine M , i.e., π ( x i ) ⊢ M π ( x i +1 ) f or all 1 ≤ i < n . In order to ac h ieve (a), w e int ro duce the follo wing three b in ary relations; it is str aigh tforw ard to exhibit 2-dimensional automata for these relations: δ = { ( w, w ⊗ w ) | w ∈ U 0 } σ 0 = { (0 v 1 #0 v 2 # · · · 0 v n #) ⊗ w , ( v 1 0# v 2 0# · · · v n 0#) ⊗ w | w ∈ U 0 , v 1 , . . . , v n ∈ ( ∆ \ { # } ) ∗ } σ Ω = { ( a 1 v 1 # a 2 v 2 # · · · a n v n #) ⊗ w , ( v 1 a 1 # v 2 a 2 # · · · v n a n #) ⊗ w | w ∈ U 0 , a 1 , . . . , a n ∈ Ω , v 1 , . . . , v n ∈ ( ∆ \ { # } ) ∗ } Hence, δ j ust d uplicates a strin g f rom U 0 and σ 0 cyclicall y rotates ev ery configuration to the left for on e sym b ol, provided the first s y mb ol is 0, whereas σ Ω rotates sym b ols from Ω . Moreo v er, let U 1 b e the follo wing regular language o ver ∆ ∗ ⊗ ∆ ∗ : U 1 = { u ⊗ v | u, v ∈ { 0 , 1 } + , | u | = | v | , v al( u ) = v al( v ) + 1 mo d 2 | u | } ( Ω × Ω ) + (# , #) + Clearly , U 1 is a regular language. T h e cru cial fact is the follo win g: F act 1. F or ev ery m ∈ N , the follo wing t wo prop erties are equiv alen t (recall that x ∈ U 0 ): – There exist y 1 , y 2 , y 3 ∈ ∆ ∗ ⊗ ∆ ∗ suc h that δ ( x, y 1 ), σ m 0 ( y 1 , y 2 ), σ Ω ( y 2 , y 3 ), y 3 ∈ U 1 . – F or all 1 ≤ i ≤ n and 0 ≤ j ≤ m i , we ha ve | u i,j | = m and if j < m i , then v al( u i,j + 1 ) = v al( u i,j ) + 1. Assume n o w th at x ∈ U 0 satisfies one (and hence b oth) of the tw o prop erties from F act 1 for some m . It follo ws that m i = 2 m − 1 for all 1 ≤ i ≤ n and x = x 1 # x 2 # · · · x n # , where x i = 2 m − 1 Y j =0 bin m ( j ) a i,j for ev ery 1 ≤ i ≤ n . (15) In order to establish (b) we need additional structur e. The id ea is, for ev ery counter v alue 0 ≤ j < 2 m , to h a v e a word y j that coincides w ith x , bu t has all the o ccur rences of bin m ( j ) mark ed . Then an automaton can c hec k that successiv e o ccurrences of the coun ter b in m ( j ) ob ey the transition condition of the T urin g mac h ine. There are t wo p roblems with th is appr oac h: first, in order to relate x and y j , we w ould need a b inary relation of degree 2 m (for arbitrary m ) 19 and, secondly , an automato n cannot mark all the occurr ences of b in m ( j ) at once (for some j ). In order to solv e these problems, we introd uce a binary relation µ , whic h for ev ery x ∈ U 0 as in (15) generate s a bin ary tree of depth m with r o ot x ; this will b e the only relation in our string automatic s tr ucture th at causes exp onenti al gro wth. This relation will mark in x ev ery o ccurrence of an arbitrary counte r. F or this, we need t wo copies 0 and 0 of 0 as well as t wo copies 1 and 1 of 1. F or b ∈ { 0 , 1 } , define the mapping f b : { 0 , 0 , 1 , 1 } ∗ { 0 , 1 } + → { 0 , 0 , 1 , 1 } + { 0 , 1 } ∗ as follo ws (where u ∈ { 0 , 0 , 1 , 1 } ∗ , c ∈ { 0 , 1 } , and v ∈ { 0 , 1 } ∗ ): f b ( ucv ) = ( uc v if b 6 = c u cv if b = c W e extend f b to a function on (( { 0 , 0 , 1 , 1 } ∗ { 0 , 1 } + Ω ) + #) ∗ as follo w s: Let w = w 1 a 1 · · · w ℓ a ℓ with w i ∈ { 0 , 0 , 1 , 1 } ∗ { 0 , 1 } + and a i ∈ Ω ∪ Ω #. Th en f b ( w ) = f b ( w 1 ) a 1 · · · f b ( w ℓ ) a ℓ ; this mapping can b e computed with a syn c hronized transd ucer. Hence, the relation µ = f 0 ∪ f 1 = { ( u, f b ( u )) | u ∈ (( { 0 , 0 , 1 , 1 } ∗ { 0 , 1 } + Ω ) + #) ∗ , b ∈ { 0 , 1 }} can b e recognized by a 2-dimensional automaton. Let x ∈ U 0 as in (15), let the w ord y b e obtained from x by o verlining or und erlining eac h bit in x , and let u ∈ { 0 , 1 } m b e some coun ter. W e sa y the c ounter u is marke d in y if ev ery o ccurrence of the coun ter u is mark ed b y o v erlining eac h bit, whereas all other coun ters con tain at least one und erlined bit. F act 2. Let x ∈ U 0 b e as in (15). – F or all coun ters u ∈ { 0 , 1 } m , there exists a unique word y with ( x, y ) ∈ µ m suc h that the coun ter u is mark ed in y . – If ( x, y ) ∈ µ m , th en there exists a unique coun ter u ∈ { 0 , 1 } m suc h that u is mark ed in y . No w, we can ac hiev e our fin al goal, n amely chec king w hether t w o successiv e configurations in x ∈ U 0 represent a transition of the mac h ine M . Let th e coun ter u ∈ { 0 , 1 } m b e marked in y . W e d escrib e a fi nite automaton A 2 that c hec ks on the strin g y , whether at p osition v al( u ) successiv e configurations in x are “lo cally consistent” . The automaton A 2 searc hes for the fi rst marked counter in y . Then it stores the next three symb ols a 1 , a 2 , a 3 from Ω (if the separator # is seen b efore, then only one or tw o sym b ols ma y b e stored), walks righ t until it find s the next m ark ed coun ter, reads the next three sym b ols b 1 , b 2 , b 3 from Ω , and c hecks w h ether ( a 1 a 2 a 3 , b 1 b 2 b 3 ) ∈ α M , w here α M is from (10). If this is not the case, the automaton will r eject, otherwise it will store b 1 b 2 b 3 and rep eat the pr ocedu re describ ed ab o ve . Let U 2 = L ( A 2 ). T ogether with F act 1 and 2, the b ehavi or of A 2 implies that for all x ∈ U 0 and all m ∈ N , x r ep resen ts an accepting 2 m -computation of M if and only if ∃ y 1 , y 2 , y 3 δ ( x, y 1 ) ∧ σ m 0 ( y 1 , y 2 ) ∧ σ Ω ( y 2 , y 3 ) ∧ y 3 ∈ U 1 ∧ ∀ y µ m ( x, y ) → y ∈ U 2 . Let u s no w fi x some input w = a 1 a 2 · · · a n ∈ Σ ∗ with | w | = n , and let a n +1 = an d m = 2 n . Th us, w is accepted b y M if and only if th ere exists an acce p ting 2 m -computation x su c h that in the first confi guration of x , the tap e con tent is of the f orm w + . It remains to add some 20 structure that allo ws us to expr ess the latter by a form u la. But this is straigh tforward: Let ⊲ b e a new symb ol and let Π = ∆ ∪ { 0 , 0 , 1 , 1 , ⊲ } ; this is our fin al alphab et. Define the binary relations ι 0 , 1 and ι a ( a ∈ Ω ) as follo w s: ι 0 , 1 = { ( u ⊲ av , ua ⊲ v ) | a ∈ { 0 , 1 } , u, v ∈ ∆ ∗ , uav ∈ U 0 } ∪ { (0 v, 0 ⊲ v ) | v ∈ ∆ ∗ , 0 v ∈ U 0 } ι a = { ( u ⊲ av , ua ⊲ v ) | u, v ∈ ∆ ∗ , uav ∈ U 0 } . Then, A = ( Π ∗ ∪ ( Π ∗ ⊗ Π ∗ ) , δ , σ 0 , σ Ω , µ, ι 0 , 1 , ( ι a ) a ∈ Ω , U 0 , U 1 , U 2 ) is a string automatic stru cture of b ounded d egree suc h th at w is accepted by M if and only if th e follo win g f orm ula is true in A : ∃ x ∈ U 0 ∃ y 1 , y 2 , y 3 δ ( x, y 1 ) ∧ σ m 0 ( y 1 , y 2 ) ∧ σ Ω ( y 2 , y 3 ) ∧ y 3 ∈ U 1 ∧ ∀ y µ m ( x, y ) → y ∈ U 2 ∧ ∃ y 0 , z 0 , . . . , y n +1 , z n +1 ι m 0 , 1 ( x, y 0 ) ∧ ι q 0 ( y 0 , z 0 ) ∧ n +1 ^ i =1 ι m 0 , 1 ( z i − 1 , y i ) ∧ ι a i ( y i , z i ) By Lemma 4.1 we can compute in time O (log ( m )) = O ( n ) an equiv alen t formula o ve r the signature of A . This concludes the pro of. ⊓ ⊔ The follo w ing theorem, which pro ve s an analogous r esult for tree automatic str uctures, uses alternating T urin g mac hines, see [6,26] for more details. Roughly s p eaking, an alternating T uring machine is a nond etermin istic T ur ing mac hine, w here the set of states is p artitioned in to accepting, existen tial, and un iv ersal states. A confi gu r ation is accepting, if either (i) the current state is accepting, or (ii) the cur ren t state is existen tial and at least one s u ccessor configuration is accepting, or (iii) the current state is universal and eve r y successor configu- ration is accepting. By [6], k EXPTIME is the set of all pr oblems that can b e accepted in space exp( k − 1 , n O (1) ) on an alternating T u ring mac hine (for all k ≥ 1). Theorem 4.3. Ther e exists a fixe d tr e e automatic structur e A of b ounde d de gr e e suc h that F OTh ( A ) is 3EXPTIME - har d. Pr o o f . Let M b e a fixed alternating T u ring mac hine with a sp ace b oun d of exp(2 , n ) such that M accepts a 3EXPTIME -complete language. W.l.o. g. ev ery configuration, where the curren t state is either existen tial or univ ers al h as exactly t wo successor configurations. Let Σ , Γ , Q , and Ω hav e the same meaning as in the previous pro of. Moreo ver, let ∆ = Ω ∪ { 0 , 1 , # ∃ , # ∀ } . The idea is that a binary tree x o ve r the alph ab et ∆ can enco de a computation tree for some in p ut. Configurations can b e encod ed by linear c h ains ov er the alphab et Ω ∪ { 0 , 1 } as in the previous pro of. T he sep arator symbol # ∃ is used to separate an existen tial configuration from a su ccessor configuration, whereas th e separator sym b ol # ∀ is used to separate a univer- sal configuration f rom its t wo successor configurations. Hence, a # ∃ -lab eled no de has exactly one c hild, whereas a # ∀ -lab eled n od e has exactly t wo c h ild ren. Ch ec king wh ether the counte rs b eha ve correctly can b e d on e similarly to the previous pro of by int r od ucing binary relations σ 0 and σ Ω , w hic h rotate sym b ols within configur ations. Remember that in our tr ee enco din g, configurations are just long c hains. Also the markin g of some sp ecific count er can b e done in the same wa y as b efore. Finally , having marked some sp ecific coun ter allo ws to chec k with a top-do wn tree automaton, whether the tree x repr esen ts indeed a v alid computation tree. Of 21 course, the tree automaton h as to c hec k w hether the current configur ation is existen tial or unive r sal. In case of a un iv ersal configur ation, the automaton br anc hes at the next separator sym b ol # ∀ . If e.g. the current configuration is unive rsal but the next separator sym b ol is # ∃ , then the automaton rejects the tree. ⊓ ⊔ The pro of of the next result is in fact a simplification of the p ro of of Theorem 4.2, since w e do n ot n eed counters. Theorem 4.4. Ther e exists a fixe d string automatic structur e A of b ounde d de gr e e and p oly- nomial gr owth (in fact line ar gr owth ) such that F OTh( A ) is EXPSP A CE -har d . Pr o o f . Let M b e a fixed T urin g m achine with a space b ound of 2 n suc h that M accepts an EXPSP ACE -c omp lete language. Let Σ , Γ , Q , q 0 , q f , , and Ω ha ve the u sual meaning. Let ∆ = { # } ∪ Ω . This time, for m ∈ N , an ac c ep ting m -c omputa tion is a string x 1 # x 2 # · · · x n #, where x 1 , . . . , x n ∈ Γ ∗ QΓ + are configur ations with | x i | = m (1 ≤ i ≤ n ), x i ⊢ M x i +1 (1 ≤ i < n ), x 1 ∈ q 0 Σ ∗ ∗ , and x n ∈ Γ ∗ q f Γ + . Let U 0 b e the fixed regular language U 0 = ( Γ ∗ QΓ + #) + ∩ q 0 Σ ∗ ∗ # ∆ ∗ ∩ ∆ ∗ q f ( ∆ \ { # } ) ∗ # . The follo wing bin ary r elations δ and σ Ω can b e easily recognized by 2-dimensional automata : δ = { ( w, w ⊗ w ) | w ∈ U 0 } σ Ω = { ( av ⊗ w , v a ⊗ w ) | w ∈ U 0 , a ∈ Ω , v ∈ ∆ ∗ } Moreo v er, let U 1 b e the follo wing regular language o ver ∆ ∗ ⊗ ∆ ∗ : U 1 = { # u ⊗ v # | u, v ∈ Ω + , | u | = | v | , v ⊢ M u } + { # u ⊗ v # | u, v ∈ Ω + , | u | = | v |} . Then, for ev ery x ∈ U 0 and m ∈ N w e hav e: x is an accepting m -computation if and only if there exist y 1 , y 2 ∈ ∆ ∗ ⊗ ∆ ∗ suc h that δ ( x, y 1 ), σ m Ω ( y 1 , y 2 ), and y 2 ∈ U 1 . Let u s n o w fi x some input w = a 1 · · · a n ∈ Σ ∗ with | w | = n , let a n +1 = , and let m = 2 n . Th us, w is accepted by M if and only if there exists an accepting m -computation x such that in the first confi guration of x , the tap e con tent is of the f orm w + . It remains to add some structure th at allo ws us to express the latter by a form ula. This can b e d one similarly to the p ro of of T heorem 4.2: Let Π = ∆ ∪ { ⊲ } , w here ⊲ is a new symbol and d efine the binary relations ι a ( a ∈ Σ ∪ { } ) as follo ws: ι a = { ( q 0 av , q 0 a ⊲ v ) | v ∈ ∆ ∗ , q 0 av ∈ U 0 } ∪ { ( u ⊲ av , ua ⊲ v ) | u, v ∈ ∆ ∗ , uav ∈ U 0 } Then, A = ( Π ∗ ∪ ( ∆ ∗ ⊗ ∆ ∗ ) , δ , σ Ω , ( ι a ) a ∈ Σ ∪{ } , U 0 , U 1 ) is a fi xed string automatic stru cture of b ounded degree and linear gro wth. F or th e latter note that the Gaifman graph of A is just a disjoin t u nion of cycles and finite paths (in fact, every no de has degree at most 2). Moreo ver, w is accepted by M if and only if the follo wing statemen t is true in A : ∃ x ∈ U 0 ∃ y 1 , y 2 δ ( x, y 1 ) ∧ σ m Ω ( y 1 , y 2 ) ∧ y 2 ∈ U 1 ∧ ∃ y 0 , . . . , y n ι a 1 ( x, y 0 ) ∧ n ^ i =1 ι a i ( y i − 1 , y i ) . (16) By Lemma 4.1 this concludes the pro of. ⊓ ⊔ 22 The next result can b e easily shown by com bining the tec h niques from the pr o of of The- orem 4.3 and 4.4. W e lea v e the details for the reader. Theorem 4.5. Ther e exists a fixe d tr e e automatic structur e A of b ounde d de gr e e and p oly- nomial gr owth (in fact line ar gr owth ) such that F OTh( A ) is 2EXPTIME -har d. 5 Bounded quan t ifier alternation depth In th is section we prov e some facts ab out fi rst-order fragmen ts of fixed quan tifi er alternation depth. These results will follo w easily from the constructions in the preceding section. F or n ≥ 0, Σ n -form u las and Π n -form u las are in ductiv ely defined as follo ws: – A quantifier-free first-order formula is a Σ 0 -form u la as w ell as a Π 0 -form u la. – If ϕ ( x 1 , . . . , x n , y 1 , . . . , y m ) is a Σ n -form u la, then ∀ x 1 · · · ∀ x n : ϕ ( x 1 , . . . , x n , y 1 , . . . , y m ) is a Π n +1 -form u la. – If ϕ ( x 1 , . . . , x n , y 1 , . . . , y m ) is a Π n -form u la, then ∃ x 1 · · · ∃ x n : ϕ ( x 1 , . . . , x n , y 1 , . . . , y m ) is a Σ n +1 -form u la. The Σ n -theory Σ n -F OTh( A ) of a structur e A is the set of all Σ n -form u las in FOTh( A ); the Π n -theory is defined analogo u sly . F or a class C of tree automatic presen tations, the Σ n -mo del che cking pr oblem Σ n - F OMC( C ) of C d enotes the set of all pairs ( P , ϕ ) wh ere P ∈ C , and ϕ ∈ Σ n -F OTh( A ( P )). The follo wing result can b e foun d in [5]: Theorem 5.1 (cf. [5]). The Σ 1 -mo del che cking pr oblem Σ 1 - F OMC( S A ) for al l string auto- matic pr esentat ions i s in PSP ACE . M or e over, ther e is a fixe d string automatic structur e with a PSP ACE -c o mplete Σ 1 -the ory. F rom our construction in the pro of of Th eorem 4.4, we can slightl y sharp en the lo wer b ound in this theorem: Theorem 5.2. Ther e exists a fixe d string automa tic structur e of b ounde d de gr e e and line ar gr owth with a PSP ACE -c omplete Σ 1 -the ory. Pr o o f . T ake the structur e A from the pro of of Th eorem 4.4 and let M b e a fixed lin ear b ounded automaton with a PSP ACE - complete acceptance p roblem. If w e replace the num b er m in the formula (16) b y the input length n , then (16 ) is equiv ale n t to th e follo wing formula, whic h is equiv alen t to a Σ 1 -form u la: ∃ x ∈ U 0 ∃ y 0 , . . . , y n +1 δ ( x, y 0 ) ∧ n ^ i =0 σ Ω ( y i , y i +1 ) ∧ y n +1 ∈ U 1 ∧ ∃ y 1 , . . . , y n ι a 1 ( x, y 1 ) ∧ n ^ i =2 ι a i ( y i − 1 , y i ) . This form ula is tru e in A if and only if the linear b ound ed automaton accepts th e in put w = a 1 · · · a n . ⊓ ⊔ Let us now mo ve on to Σ 2 -form u las and s tructures of arbitrary growth: 23 Theorem 5.3. The Σ 2 -mo del che cking pr oblem Σ 2 - F OMC( S A ) for al l string automatic pr e- sentations is in EXPSP ACE . M or e over, ther e is a string automatic structur e of b ounde d de gr e e with an EXPSP ACE -c omp lete Σ 2 -the ory. Pr o o f . F or the upp er b ound, let P b e a string automatic pr esentati ons of the automatic structure A ( P ) = A and let ψ = ∃ x 1 · · · ∃ x n ∀ y 1 · · · ∀ y m : ϕ b e a Σ 2 -sen tence. The sen tence ψ is equiv alen t to ∃ x 1 · · · ∃ x n ¬∃ y 1 · · · ∃ y m : ¬ ϕ . Negatio n s in ¬ ϕ can b e mo ved down to the lev el of atomic predicates. Then , w e can built an ( n + m )-dimensional automaton for ¬ ϕ with exp(1 , | ψ | O (1) ) many states. Pro jection onto the trac ks corresp onding to the v ariables x 1 , . . . , x n results again into an automaton with exp(1 , | ψ | O (1) ) many states. Hence, for ¬∃ y 1 · · · ∃ y m : ¬ ϕ there exists an n -d im en sional au- tomaton with exp(2 , | ψ | O (1) ) man y states. But, we d o not need to construct this automaton explicitly but only hav e to c heck emptiness of its language, whic h can b e done on the fly in exp onen tial sp ace. F or th e lo we r b ound, w e reuse our construction from the pro of of T heorem 4.2. W e start with an exp(1 , n )-space-b ounded mac hin e M th at accepts an EXPSP ACE -complete language. W e carry out th e same constru ction as in the pr oof of Theorem 4.2, bu t r eplace 2 m (resp. m ) eve r ywhere by m (resp. the inp ut length n ). In addition, w e need the follo wing (trivial) analogue of Lemma 4.1: Let the signature S cont ain a binary symb ol r . F rom a give n num b er n (enco ded u nary), we can construct in linear time a Σ 1 -form u la ϕ ( n ) ( x, y ) such that for ev ery S -stru cture A and all elemen ts a, b ∈ A w e h a v e: ( a, b ) ∈ r n if and only if A | = ϕ ( n ) ( a, b ). Then, the final formula fr om the pr oof of Theorem 4.2 can b e written as ∃ x ∈ U 0 ∃ y 1 , y 2 , y 3 δ ( x, y 1 ) ∧ σ ( n ) 0 ( y 1 , y 2 ) ∧ σ Ω ( y 2 , y 3 ) ∧ y 3 ∈ U 1 ∧ ∀ y ¬ µ ( n ) ( x, y ) ∨ y ∈ U 2 ∧ ∃ y 0 , z 0 , . . . , y n +1 , z n +1 ι ( n ) 0 , 1 ( x, y 0 ) ∧ ι q 0 ( y 0 , z 0 ) ∧ n +1 ^ i =1 ι ( n ) 0 , 1 ( z i − 1 , y i ) ∧ ι a i ( y i , z i ) . This formula is equiv ale n t to a Σ 2 -form u la. Moreo v er, th is formula is true in the strin g au- tomatic structure A (of b ounded degree) from the pr o of of Theorem 4.2, if and only if the input w = a 1 a 2 · · · a n is accepted by the mac hine M . ⊓ ⊔ As b efore, Theorems 5.1–5.3 can b e extended to tree automatic structur es as follo ws: Theorem 5.4. The fol lowing holds: 1. The Σ 1 -mo del che cking pr oblem Σ 1 - F OMC ( T A ) for al l tr e e automatic pr esentations i s in EXPTIME . 2. Ther e exists a fixe d tr e e automatic structur e of b ounde d de gr e e and line ar gr owth with an EXPTIME -c omplete Σ 1 -the ory. 3. The Σ 2 -mo del che cking pr oblem Σ 2 - F OMC ( T A ) for al l tr e e automatic pr esentations i s in 2EXPTIME . 4. Ther e exists a tr e e automatic structur e of b ounde d de gr e e with a 2EXPTIME - c omp lete Σ 2 - the ory. 24 6 Op en problems The most ob vious op en question r egards the unif orm first-order th eory for (injectiv e) tree automatic structures: w e d o n ot know whether it is 4EXPTIME -hard. Moreo ver, we don’t know an u p p er b ound for th e uniform first-order theory for arb itrary tree automatic stru ctures. The reason is that w e do not kn o w th e complexit y of transformin g suc h a p resen tation into an equiv alen t in jectiv e one (w h ic h is p ossible by [7]). In [5,19], it is sho wn that not only the first-order theory of ev ery strin g automatic stru cture is (u niformly) decidable, but eve n its extension by the quan tifiers “there are infin itely many x with . . . ” and “the n u mb er of x satisfying . . . is divisib le b y p ”. In [22], we pro ved that this extended theory can b e decided in triply exp onent ial time f or ( ω )-automatic structures of b ounded degree. It is n ot clear wh ether the doub ly-exp onen tial u p p er b ound pr ov ed in this pap er extend s to this more expr essiv e theory . Recall that there are tree automatic structures wh ic h are not string automatic. Pro vided 2EXPSP ACE 6 = 3EXPTIME , our r esults on th e non-uniform first-order theories imply th e exis- tence of such a structure of b ou n ded degree (namely the tree automatic structure constructed in the pr oof of T h eorem 4.3). Bu t no example is known that do es n ot rest on the complexit y theoretic assumption 2EXPSP A CE 6 = 3EXPTIME . F or n ≥ 3, the p recise complexit y of the Σ n -theory of a string/tree automatic structure of b ounded degree remains op en. W e know that these theories b elong to 2EXPSP ACE for str ing automatic stru ctures and to 3EXPTIME for tree automatic structures. Moreo ver, from our re- sults for the Σ 2 -fragmen t w e obtain lo w er b oun ds of EXPSP ACE and 2EXPTIM E , resp ectiv ely . Conje ctur e 6.1. F or every n ≥ 3, the p r oblems Σ n -F OMC ( SAb ) and Σ n -F OMC ( T Ab ) b elong to EXPSP ACE and 2EXPTIME , resp ectiv ely . A p ossible attac k to th is conjecture wo u ld f ollo w the line of argum en t in the pro of of T heo- rem 3.6 and would th erefore b e b ased on Gaifman’s theorem. T o make this w ork, the exp o- nen tial b ound in Gaifman’s theorem w ould ha ve to b e reduced which leads to the follo w ing conjecture. Conje ctur e 6.2. Let A b e a structur e, ( a 1 , . . . , a k ) , ( b 1 , . . . , b k ) ∈ A k , d ≥ 0, and D 1 , . . . , D k ≥ d · 2 n suc h that ( A ↾ ( k [ i =1 S ( D i , a i )) , a 1 , . . . , a k ) ≃ ( A ↾ ( k [ i =1 S ( D i , b i )) , b 1 , . . . , b k ) . Then, for ev er y Σ n -form u la ϕ ( x 1 , . . . , x k ) of quan tifier depth at most d , we h av e: A | = ϕ ( a 1 , . . . , a k ) ⇐ ⇒ A | = ϕ ( b 1 , . . . , b k ) . References 1. V. B´ ar´ any . Inv ariants of automatic presentatio n s and semi-synchronous transductions. In ST A CS’06 , Lecture Notes in Comp. Science vol. 3884, p ages 289–300. Springer, 2006. 2. V. B´ ar´ any , L. Kaiser, and S . R ubin. Cardinality and counting q uan t ifiers on omega-automatic structures. In ST A CS’ 08 , pages 385–396. I FIB S c hloss Dagstuhl, 2008. 3. M. Benedikt, L. Li b kin, T. Sch wen tick, and L. Segoufin. Definable rela tions and first-order query languages o ver strings. J. ACM , 50(5):694–751 , 2003. 25 4. A. Blumensath. Automatic structu res. T echnical rep ort, R WTH A ac hen, 1999. 5. A. Blumensath and E. Gr¨ adel. Automatic Stru ctures. In LICS’00 , pages 51–62. IEEE Computer Society Press, 2000. 6. A. K. Chandra, D. C. Kozen, and L. J. Stockmeyer. Alternation. J. A CM , 28(1):114–133, 1981. 7. T. Co lcom b et and C. L¨ oding. T ransf orming structures by set in terpretations. L o gic al Metho ds in Computer Scienc e , 3:1–36, 2007. 8. H. Comon, M. Dauchet, R. Gilleron, C. L¨ oding, F. Jacquemard, D. Lugiez, S. Tison, and M. T ommasi. T ree automata techniques and applications. Av ailable on: http:// www.grappa .univ- lille3.fr/tata , 2007. R elease Octob er, 12th 2007. 9. K. C ompton and C. H enson. A uniform method for pro ving lo wer bounds on the computational complexity of logical th eories. Anna ls of Pur e and Applie d L o gic , 48:1– 79, 1990 . 10. C. Delhomm´ e, V. Goranko, and T. K napik. Au tomatic linear orderings. Manuscript, 2003. 11. C. Elgot. Decision problems of finite automata design and related arithmetics. T r ans. A m . Math. So c. , 98:21–5 1, 1961. 12. D. Epstein, J. Cannon, D. Holt, S. Levy , M. Paterson, and W. Thurston. Wor d Pr o c essing In Gr oups . Jones and Bartlett Publishers, Boston, 1992. 13. H. Gaifman. O n lo cal and nonlo cal prop erties. In J. Stern, editor, L o gic Col lo quium ’81 , pages 105–13 5. North-Holland, 1982. 14. B. Hod gson. On direct pro ducts of automaton decidable theories. The or etic al Computer Scienc e , 19:331– 335, 1982. 15. I. I shihara, B. Khoussaino v, and S . Ru bin. Some results on automatic structu res. In LICS’02 , p ages 235–244 . I EEE Computer So ciet y Press, 2002. 16. B. Khoussainov and A. Nero de. Au tomatic presentatio n s of structures. In L o gic and Computational Complexity , Lecture N otes in Comp. S cience vol. 960, pages 367–39 2. Springer, 1995. 17. B. K houssaino v and S. Rub in. Graphs with aut omatic presentations ov er a un ary alphabet. J. Autom. L ang. Comb. , 6:467–480 , 2001. 18. B. Khoussaino v, S. Rubin, and F. Steph an. On automatic partial orders. In LI CS’03 , pages 168–177. IEEE Computer S ociety Press, 2003. 19. B. Khoussainov, S. R ubin, and F. Stephan. Definability and regularit y in automatic structures. In ST A CS’04 , Lectu re Notes in Comp. Science vo l. 2996, pages 440–451. Springer, 2004. 20. D. K usk e. Is Cantor’s theorem automatic? I n LP AR’03 , Lecture Notes in Comp. Science vol. 2850, pages 332–345 . S pringer, 2003. 21. D. Kuske and M. Lohrey . Euler paths and ends in automatic and recursive graphs. I n Automat a and F or m al L anguages 2008 , p ages 245–256. Hungarian A cadem y of Sciences, 2008. 22. D. Kuske and M. Lohrey . First-order and counting theories of ω -automatic structures. Journal of Symb olic L o gic , 73:129–150, 2008. 23. D. Ku sk e and M. Lohrey . Hamiltonicity of automatic graphs. In G. Ausiello, J. Karhum¨ aki, G. Mauri, and L. On g, editors, IFIP-TCS’08 , p ages 445–459. Springer, 2008. 24. M. Lohrey . Automatic structures of b ound ed d egree. In LP AR’03 , Lecture Notes in Comp. Science vol. 2850, pages 344–358. Springer, 2003. 25. A. Meyer. W eak monadic second order theory of one successor is not elemen t ary recursive. In Pr o c. L o gic Col lo qui um , Lectu re Notes in Mathematics v ol. 453, pages 132–154. S pringer, 1975. 26. C. H. Papadimitriou. Computational Complexity . Add ison W es ley , 1994. 27. S. Ru bin. Automata presenting struct ures: A survey of the finite string case. Bul letin of Symb olic L o gic , 14:169– 209, 2008. 28. H. Seidl. Single-v aluedness of tree transducers is decidable in p olynomial time. The or etic al Computer Scienc e , 106:135–181 , 1992. 29. P . V . S ilv a and B. Steinb erg. A geometric characterization of automatic monoids. The Quarterly Journal of Mathematics , 55:333–3 56, 2004. 30. A. W eber. On the v aluedness of fi nite transducers. Ac ta Informatic a , 27:749–780, 1990. 26
Original Paper
Loading high-quality paper...
Comments & Academic Discussion
Loading comments...
Leave a Comment