• Aucun résultat trouvé

Achilles and the Tortoise climbing up the hyper-arithmetical hierarchy.

N/A
N/A
Protected

Academic year: 2021

Partager "Achilles and the Tortoise climbing up the hyper-arithmetical hierarchy."

Copied!
52
0
0

Texte intégral

(1)

HAL Id: hal-02101790

https://hal-lara.archives-ouvertes.fr/hal-02101790 Submitted on 17 Apr 2019

HAL is a multi-disciplinary open access

archive for the deposit and dissemination of sci-entific research documents, whether they are pub-lished or not. The documents may come from teaching and research institutions in France or

L’archive ouverte pluridisciplinaire HAL, est destinée au dépôt et à la diffusion de documents scientifiques de niveau recherche, publiés ou non, émanant des établissements d’enseignement et de recherche français ou étrangers, des laboratoires

Achilles and the Tortoise climbing up the

hyper-arithmetical hierarchy.

Olivier Bournez

To cite this version:

Olivier Bournez. Achilles and the Tortoise climbing up the hyper-arithmetical hierarchy.. [Research Report] LIP 1997-14, Laboratoire de l’informatique du parallélisme. 1997, 2+49p. �hal-02101790�

(2)

Laboratoire de l’Informatique du Parallélisme

Ecole Normale Supérieure de Lyon

Unité de recherche associée au CNRS n°1398

Achilles and the Tortoise climbing up the

hyper-arithmetical hierarchy

OlivierBournez

May 21, 1997

Research Rep ort N o

97-14

Ecole Normale Supérieure de Lyon

Téléphone : (+33) (0)4.72.72.80.00 Télécopieur : (+33) (0)4.72.72.80.80 46 Allée d’Italie, 69364 Lyon Cedex 07, France

(3)

Achilles and the Tortoise climbing up the hyper-arithmetical

hierarchy

OlivierBournez May 21, 1997

Abstract

We pursue the study of the computationalpower of Piecewise Constant Derivative (PCD) systems started in 5, 6]. PCD systems are dynamical systems dened by a piecewise constant di erential equation and can be considered as computational machines working on a continuous space with a continuous time. We prove that the languages recognized by rational PCD systems in dimension d = 2k+3 (respectively: d = 2k +4), k 0, in nite continuous time are precisely the languages of the !kth (resp. !k+ 1th) level of the hyper-arithmetical hierarchy. Hence the reachability

problem for rational PCD systems of dimension d = 2k + 3 (resp. d = 2k + 4), k 1, is hyper-arithmetical and is !k-complete (resp. !k+1-complete).

Keywords:

Real computability, Continuous time computations, Dynamical systems, Hyper-arithmetical hierarchy

Resume

Nous poursuivons l'etude de la puissance de calcul des systemes a derivee constante par morceaux debutee dans 5, 6]. Les systemes PCD sont des systemes dynamiques denis par une equation di erentielle constante par morceaux. Ils peuvent ^etre vus comme des modeles de calcul evoluant sur espace continu avec un temps continu. Nous prouvons que les langages reconnus par des systemes PCD rationnels en dimension d = 2k+3 (respectivement: d = 2k +4), k 0, en temps continu ni sont precisement les langages du !kieme (resp. !k+ 1ieme) niveau de la hierarchie

hyper-arithmetique. Ainsi le probleme de l'atteignabilite des systemes PCD de dimension d = 2k+3 (resp. d = 2k+4), k 1, est hyper-arithmetique et est !k-complet (resp. !k+1-complet).

Mots-cles:

Calculabilite reelle, Calculs en temps continu, Hierarchie hyper{arithmetique, Systemes dy-namiques.

(4)

1 Introduction

There has been recently an increasing interest in the elds of control theory and computer science about hybrid systems. A hybrid system is a system that combines discrete and continuous dynamics. Several models have been proposed in literature. Hybrid systems can be considered as computational machines 1, 2, 3, 7, 8]: they can be seen either as machines working on a continuous space with a discrete time or as machines working on a continuous space with a continuous time.

Several theoretical models of machines working on a continuous space with a discrete time are known: in 4], Blum, Shub and Smale introduce the real Turing machine. Many papers are devoted to this model: see 12] for an up-to-date survey. In 13], Meer introduces a restricted class of real Turing machines called the linear machines: Meer proves that P 6= NP in this class of systems. In 10, 11], Koiran characterizes

the boolean part of the languages recognized by linear machines as P=poly in polynomial discrete time and as unbounded in exponential discrete time.

Simultaneously, in 1, 2, 7, 8], it is shown that several very simple dynamical systems can be considered as non trivial machines that work on a continuous space with a discrete time. In particular, in 1, 2, 3] the attention is focused on a very simple type of hybrid systems: Piecewise Constant Derivative Systems (PCD systems) are dynamical systems dened by a piecewise constant di erential equation. It is shown that the reachability problem for PCD systems of dimension d = 2 is decidable and undecidable for dimensions d 3 1, 3] . In 7], the computational power of Piecewise Constant Derivative systems is characterized as P=poly in polynomial discrete time, and as unbounded in exponential discrete time.

However, hybrid systems are very interesting models since they can be considered as natural computa-tional machines working on a continuous space with a continuous time. The studies of this type of machines are only beginning. In 14], Moore proposes a recursion theory for computations on the reals in continu-ous time. Recently, Asarin and Maler 2] showed, using Zeno's paradox, that every set of the arithmetical hierarchy can be recognized in nite continuous time by a PCD system of nite dimension: every set of the arithmetical hierarchy in kk can be recognized by a rational PCD system in dimension 5k + 1.

Unfortunately, no precise characterization of the sets recognizable by PCD systems is given in 2]. In 6], a precise characterization is given for the restricted class of purely rational PCD systems. However no answer is given about the general class of rational PCD systems.

We provide in this paper a full characterization of the computational power of rational PCD systems: we prove that every arithmetical set can be recognized in nite continuous time in dimension 5. Hence, in one sense, dimension 5 is universal for the arithmetical hierarchy. However, we prove in this paper that there does not exist a dimension d such that PCD systems of dimension d recognize every set of the hyper-arithmetical hierarchy: we prove that the languages recognized by rational PCD systems in dimension d = 2k + 3 (respectively: d = 2k + 4), k 0, in nite continuous time are precisely the languages of the !kth(resp. !k+ 1th) level of the hyper-arithmetical hierarchy. In other words, the reachability problem for

rational PCD systems of dimension d = 2k + 3 (resp. d = 2k + 4) is !k-complete (resp. !k+1-complete).

Section 2 is devoted to general denitions about Piecewise Constant Derivative Systems and about the hyper{arithmetical hierarchy. In section 3, we introduce Real Continuous Time (RCT) machines: we prove that RCT machines can recognize some hyper{arithmetical sets. In section 4, we show that RCT machines can be simulated by PCD systems and we deduce that PCD systems can also recognize some hyper{arithmetical sets. In section 5, we prove that the bounds given in section 4 are optimal: the languages recognized by rational PCD systems in dimension d = 2k + 3 (respectively: d = 2k + 4), k 0 in nite continuous time are precisely the languages of the !kth (resp. !k+ 1th) level of the hyper-arithmetical

hierarchy.

2 Denitions

2.1 PCD systems

A convex polyhedron ofRdis any nite intersection of open or closed half spaces of Rd. A polyhedron of Rdis a nite union of convex polyhedral ofRd. In particular, a polyhedron may be unbounded or at. For

(5)

Denition 2.1 (PCD System)

 A dynamical systemis a coupleH= (Xf) whereX =Rdandf is

a function fromX toX. X is called the spaceanddis called the dimensionofH. A trajectory ofH

starting from x0 is a continuous solution to the dierential equation _xd= f(x), with initial condition

x0, where _xd denotes the right derivative: that is to say  : D R + !X where D is an interval of R + containing 0,(0) = x 0, and

8t2D _d(t) = f((t)). Trajectory is said to continue for ever

if D =R +.

 A piecewise constant derivative (PCD) system 2, 3] is a dynamical systemH= (X =Rdf) where

the range of f is a nite set C X, such that for any c 2C (c is called a slope) f

;1(c) is a nite

union of convex polyhedral sets (called regions).

In other words a PCD system consists of partionning the space into convex polyhedral sets, called regions, and assigning a constant derivative c, called slope to all the points sharing the same region. The trajectories of such systems are broken lines with the breakpoints occuring on the boundaries of the regions 2]: see gure 1.

The signature of a trajectory is the sequence of the regions that are reached by the trajectory. The restriction of a trajectory  : D!Rdto interval ID is the restriction of function  to domain I.

Trajectory Direction

Figure 1: A PCD system in dimension 2. In this paper we will deal only with rational PCD systems:

Denition 2.2

 A PCD system is called rational if all the slopes as well as all the polyhedral regions

can be described using only rational coe cients.

 A PCD system is called purely rational, if in addition, for all trajectory starting from a rational

point, every time enters a region in some pointx,x has rational coordinates.

Some comments are in order: one must understand that a trajectory  can enter a region either by a discrete transition or by converging to a point of the region: see gure 3. Hence, the denition of purely rational PCD systems stipulates that every converging process converges towards a point with rational coordinates. We will see in theorem 5.1 that one can construct a rational PCD system of dimension 5 that is not purely rational.

We can say some words on the existence of trajectories in a PCD system: let x0

2X. We say that x 0

is trajectory well-dened if there exists a  > 0 such that f(x) = f(x0) for all x 2x

0x0+  f(x

0)]. It is

clear that, for any x0

2X, there exists a trajectory starting from x

0 i x0is trajectory well-dened. Given

a rational PCD systemH, one can e ectively compute the set NoEvolution(H) of the points of X that are

not trajectory well-dened. See that a trajectory can continue for ever i it does not reach NoEvolution(H).

2.2 Computing with PCD systems

Let  be a nite alphabet with at least two letters. By renaming if necessary, we can assume without loss of generality that  =f12:::n

 g.

(6)

We write  (respectively: !) for the the set of the nite (resp. nite and innite) words over alphabet

. We write  for the empty word. If w 2 

, we write length(w) for the length of word w. We x a

recursive encoding of the integers over the words of : for any integer n

2N, we denote by n a word of  

encoding integer n.

We describe now how to encode a word of  into a real of 01]. Denote by b

the rst power of 2 that

is greater than 2n+ 2: b= 2

b0

for some b0 

2N.

Denition 2.3 (Encoding by

IJ

)

Let =f12:::n 

gbe the xed nite alphabet.  We denote byJ the mapping from!!J that maps wordw = a

1a2:::ai:::, witha1a2::: 2, to real number J(w) = 1 X j=1 (2aj) (b)j  We denote by JRthe range of J.

 We denote by I the restriction of J to .  We denote by I Rthe range ofI.

PCD systems can be considered as machines recognizing some languages L

as follows:

Denition 2.4 (Computation 2])

 Let H = (Xf) be a PCD system of dimension d. Let x 1x0

be two distinct points of Rd. A computation of system ^H = (RdfIx

1x0) on entry n 2 

 is a

trajectory that can continue forever (dened on all R +) of

H= (Xf) starting from (I(n)0:::0).

The computation is accepting if the trajectory eventually reaches x1, and refusing if it reaches x0. It

is assumed that the derivatives at x1 and x0 are zero.  Language L

 is semi-recognized by ^H if, for everyn 2

, there is a computation on entrynand

the computation is accepting i n2L. Lis said to be (fully-)recognized by ^H when, in addition, this

trajectory reaches x0 i n 62L. X1 X0 Accepted Input Rejected Input Non−accepted Input Accepting Point Rejecting Point Input Port

Figure 2: Some examples of computations by a PCD system.

2.3 Measuring the time on PCD systems

Denition 2.5 (Continuous and Discrete time)

Let n : R +

! X be an accepting computation on

entryn2 .

 The continuous timeTc(n)of the computation isT = minimumft2R +=

n(t) = x1 g

(7)

 Let Tn=ft=n reaches a boundary of a region at timetg. It is easy to see that Tn is a well ordered

set 6]. The discrete time Td(n)of the computation is dened as the order type of well ordered setTn

(= the ordinal corresponding to Tn).

Note that Zeno's paradox appears: to a nite continuous time can correspond a transnite discrete time: see gure 3. (−1,1/2) (−1,1) (1,−1) (1,1) x x/2 0 0 x/2

Figure 3: Zeno's paradox: at nite continuous time 5x = 2:5(x+ x=2 + x=4+ :::) the trajectory is in (00), but it takes a transnite discrete time ! to reach this point.

2.4 Hyper-arithmetical hierarchy

2.4.1 Denition

For y 2N, denote by My the yth Turing machine, by y :  

!

 the function computed by M

y, and by

Wy 

the set of the words accepted by M

y. y2Nis said to be a recursively enumerable index ofX  

i X = Wy. y is called an recursiveindex if in addition My halts on all inputs. Let A

. Denote by an

A exponent the relativizations to oracle A: MAy is the ythTuring machine with oracle A, Ayis the function

computed by MAy, and WAy is the set of the words accepted by MAy. y 2Nis said to be a A-recursively

enumerable index of X 

 i X = WAy. y is called an A-recursive index if in addition MAy halts on all

inputs.

We follow the standard notations of 15, 16]: we x a bijective recursive encoding of  

 into :

< nm > denotes a word of  encoding word n 2   and word m 2  . For X   , we denote X0 = fxjx2N ^ x2WxXg. Let AB  . We write A

m B if there exists a recursive f such that,

for all w 2 , w

2A ,f(w) 2B. In that case, we say that A m B via f. We write A T B if A is

B-recursive. Denote A T B i A T B and B T A.

We recall the following denitions:

Denition 2.6 (Constructive ordinals 16])

We dene by transnite induction simultaneously O  N,

mappingj jfrom 0to a segment of the ordinal numbers and partial ordering <O on O.

The ordinals in the range ofjjare called the constructive ordinals. An ordinalis said to have notation

xix2Oand jxj= .

The transnite induction is as follows:

 Ordinal 0receives notation 1: 12Oj1j= 0.

 Let be an ordinal. Assume that all the ordinals < have received a notation, and assume that <o

has been dened on these notations.

{

If =  + 1 is a successor, receives notation 2x, for all notation x of : for all x 2 O, if jxj= , then2x2Oj2xj= and z <

02x for allz

2O with eitherz = xorz < 0 x.

{

If is a limit, receives notation 3:5y for ally such thatfy(n)gn =1

n=1 is an increasing sequence

of notations of ordinals of limit : for all y 2 N, if fy(n)gn =1

(8)

O, if fjy(n)jgn =1

n=1 is an increasing sequence of ordinals with limit such that

8i8j i < j )

y(i) <0y(j), then 3:5

y2Oj3:5yj= and z < 03:5

yfor allzfor which there existsnsuch that

z <0y(n).

 No other integer y2Nis inO.

Denote x oy if x = y or x < 0y.

Denition 2.7

LetX 

. We dene H as a mapping fromO to the subsets of by:  HX(1) = X.  HX(2x) = (HX(x)) 0.  HX(3:5y) =f< uv >jv2O ^ v < 03:5 y ^ u2HX(v)g.

We note H for H. The following lemma is proved in 16]:

Lemma 2.1 (Spector 16])

LetX 

. Let x

2Oy2Owith jxj=jyj, then HX(x) T HX(y).

As a consequence, for all constructive ordinal , we can dene the classes XXX unambiguously as follows:

Denition 2.8 (Hyper-arithmetical hierarchy)

LetX  .

 For any constructive ordinal 1  < !, and for any y such that  =j2yj:

{

X is the class of the sets that are recursively enumerable inHX(y)

{

X is the class of the sets whose complement is in X.

{

X= X\X.

 For any constructive ordinal  !and for any y such that jyj= :

{

X is the class of the sets that are recursively enumerable inHX(y)

{

X is the class of the sets whose complement is in X.

{

X= X\X.

For all constructive ordinal , we denote for 





.

A set R is said to be hyper-arithmetical (respectively: X-hyper-arithmetical) if R2(resp. R2X)

for some constructive ordinal . R is said to be arithmetical (resp. X-arithmetical) i in addition we have < !. Check that the classes  for 1  < ! are precisely the classes of the arithmetical hierarchy

dened in 2, 6].

One can easily prove:

Proposition 2.1 ( 16])

LetAB

 be some languages.

 For all n2N, for all y2Owith jyj= n, the following conditions are equivalent

{

B2An +1

{

B is recursively enumerable inHA(y)

{

B m HA(2y)

 For all constructive ordinal !, for all y2Owithjyj= , the following conditions are equivalent

{

B2A

{

B is recursively enumerable inHA(y)

(9)

We mention that the hyper-arithmetical hierarchy is strict: for all constructive ordinal  ! (respec-tively:  < !), for all y2Ojyj= , H(2y) (resp. H(y)) is in ;<

We also mention that the hyper-arithmetical hierarchy can be related to the analytical hierarchy: see 16] for the denition of 1

1.

Proposition 2.2 (Kleene 16])

One has:

1 1=

 constructive ordinal

We will use the following two lemmas proved in 16]:

Lemma 2.2 ( 16])

There exists a recursivehsuch that for allxy2Ox oy,H(x) m H(y)viah (xy).

Lemma 2.3 (

+o

)

There exists a recursive function+0 of two variables such that for allxy 2O,  x + 0y 2O  jx + 0y j=jxj+jyj  y6= 1)x < 0x +oy

3 Real Continuous Time machines and the hyper-arithmetical

hi-erarchy

We introduce Real Continuous Time machines (RCT machines). We prove in this section that they can recognize every set of the arithmetical hierarchy and some sets of the hyper-arithmetical hierarchy. We will see in next section that PCD systems can simulate RCT machines.

3.1 RCT machines

3.1.1 First example

We present here an informal description of RCT machines. A formal denition will be given in next subsec-tion.

We deal with machines that have a nite number d of real registers whose values can be any real of 01]. These machines evolve according to a nite program made of assignments and of tests between the real registers. Any instruction I of these programs, that is to say any assignment or any test, has some associated real function cI : 01]d!R

+called the cost of the instruction. The execution of any instruction

I takes a time equal to cI(x1:::xd), where x1:::xd are the values of the real registers of the machine

when the instruction is executed.

Write for example x1 := 2x2 x3] for the instruction that replaces the value of real register x1 by two

times the value of real register x2 in a time given by real register x3: if this instruction is executed at time

t2R, then the value of the rst real register at time t+x

3will be equal to two times the value of the second

real register at time t, where x3 is the value of the third real register at time t.

We want to use a special label \limit" to specify what to do when the time becomes Zeno.

Perhaps, the better is to consider a rst example:

Algorithm 1

program "Hello world".

x1:= 1 1]

x2:= 1 1]

(10)

while

(true)

do

/*transform (x1x2x3) = (1=2 n1=2n1 + 1=2 + :::1=2n;1) at time 3 + 3(1 + 1=2 + :::1=2n;1) for some n, to (x 1x2x3) = (1=2n+11=2n+11 + 1=2 + :::1=2n) at time 3 + 3(1 + 1=2 + :::1=2n)*/ x3:= x3+ x1 x2] x1:= x1=2 x2] x2:= x2=2 x2]

end while

limit: /*here, we have(x

1x2x3) = (001)at time

9. */

x1:= x3 1] /*now set, (x1x2x3) = (101)at time 10.

*/

Try to simulatethe evolution of this program. At time 3, (x1x2x3) = (110) and the program is starting

to execute the while loop. At time 3+ 3 the program is starting to execute the loop for the second time. At time 3+3+3=2 the program is executing the loop for the third time. At time 3+3+3=2+3=22+:::+3=2n;1,

for all n2N, the program is executing the loop for the nthtime. And at time 9 = 3 + P

1

j=03=2

j? ...The

answer is the following: the program is executing the instruction labeled by limit. So this program is made

such that, at time 9, the machine copies x3 into x1. Check that variables x2 and x1 tend to 0 and that

variable x3 tends to 1 during the execution of the innite while loop. As a consequence, we consider that at

time 9 the value of the rst two real registers of the machine is 0 and that the value of the third real register is 1. Hence, the previous program is a program that always halts and that stops with x1= 1x2= 0x3= 1

at time 10.

In other words, we consider nite programs made of assignments and tests with a real cost, with a special label denoted by limit: label limit always denotes the instruction to do at a limit time, when the time

becomes \Zeno": that is to say when a converging process happens in nite time.

3.1.2 Formal denitions

Now we give some formal denitions of the programs we consider. We will prove in section 4 that these programs can be simulated by PCD systems.

We consider programs made of instructions with a cost: the execution of an instruction I takes a time equal to the cost of instruction I.

Denition 3.1 (Instruction, Test)

 An assignmentin dimensiondis a couple(fc)wheref, called

the operation, is a partial mapping from01]dto01]d and c, called the cost function, is a partial

mapping from 01]dtoR +.

 A test in dimension dis a couple (Rc), whereRis a partial relation over 01]d, and c, called the

cost function, is a partial mapping from01]d toR +.

 An instruction of dimension d is either an assignment or a test of dimensiond.

For the simplicity of notations, we denote by \xi:= g(x1:::xd)c]", the assignment (g

0h0) where, for all

x1:::xd

201], g

0and h0are dened on (x

1:::xd) i g(x1:::xd)

201], and when g

0and h0are dened

on (x1:::xd), then g 0(x 1:::xd) = (x1:::xi;1g(x1:::xd)xi+1:::xd) and h 0(x 1:::xd) = c. We denote by \xi:= g(x1:::xd) 00 the assignment x i:= g(x1:::xd) 1]. We denote by \R? c]", where R is a

relation, the test (Rc). We denote by \R?00the test R? 1].

We will dene below the set of the assignments and the set of the tests denoted by Assgnmtd and by

Testd respectively that are admissible in dimension d.

A RCT machine of dimension d is a machine with d real registers that evolves according to its program. Its program is nite and is made of the assignments of Assgnmtd and of the tests of Testd. The execution

(11)

the variables converge, the machine enters a special limit state limit, and the execution goes on from this

state. Formally:

Denition 3.2 (RCT machine)

 A Real Continuous Time machine(RCT machine)M, or a RCT

program of dimensiond, is a 6-upleP = (Qq0q +

fq;

flimit )where:

{

Qis a nite set and q0q +

fq;

flimit 2Q.

{

is a mapping fromQ toQ Q (AssgnmtdTestd)  An instantaneous description (ID) of M is an element (qx

1:::xdt)of Q

01]d R

+. q is the

internal state,t is the timeand x1:::xd are the values of the real registers of M at time t.  LetID

1= (qx1:::xdt)and ID2= (q 0x0

1:::x 0

dt0) be two IDs ofM. We writeID 1

`dID 2 i

{

either (q) = (q0q00Assgnmt), with Assgnmt = (fc)

2Assgnmtd, and:  (x

1:::xd)is in the domain of function f and of function c.  (x

0 1:::x

0

d) = f(x1:::xd).

{

or (q) = (q00q000Test), withTest = (Rc)

2Testd, and:  (x

1:::xd)is in the domain of relationRand of functionc.  (x 0 1:::x 0 d) = (x1:::xd)  (q 0= q00 and R(x 1:::xd))or (q 0= q000and :R(x 1:::xd)).  A computation of M starting from (x

1:::xd) is a sequence (IDi = (q

ixi

1:::xidt

i))i

I of IDs of

M, whereI is an ordinal, such that:

{

ID0= (q0x1:::xd0)

{

For all j I, if j is a successor then IDj ;1

`dIDj

{

For all j I, if j is a limit point then  ftj

0 jj

0< j

gis a set bounded above by some real number.  for all1 i d,limj

0 !jj 0<jxj 0 i exists  tj= supftj 0 jj 0< j g  for all1 i d,xji = limj

0 !jj 0<jxj 0 i  qj = limit 

 The computation is accepting (respectively: rejecting) if there exists j 0

I (this implies that tj 0 2R is nite) with qj0 = q + f (resp: qj0 = q ;

f) and such that 8j < j 0qj 62fq + fq; fg. In that case, tj 0 2R

is called the (continuous) time of the computation. If the computation is accepting, we say that M maps (x1:::xd) to (x

j0 1:::x

j0

d ) in time tj0.

 Program M can be considered as an instruction: the assignment corresponding to the execution

of program M is the assignment (f0c0) of dimension d where functions f0 and c0 are dened on

(x1:::xd)

201]d i there is an accepting computation starting from(x

1:::xd). When functions

f0 and c0 are dened on(x

1:::xd)thenf 0(x 1:::xd) = (x 0 1:::x 0 d), c0(x 1:::xd) = t 0 iM maps (x1:::xd)to(x 0 1:::x 0 d)in time t0.

An instruction of dimension d;1 can be considered as an instruction of dimension d:

Denition 3.3 (Embedding instructions of dimension

d;1

into dimension

d

)

Letd 2be an

in-teger.

 Let(fc)be an assignment in dimension d;1.

We still denote by (fc)the assignment (f0c0)of dimensionddened, for all x

1:::xd 201]by: f0(x 1:::xd;1xd) = (f(x1:::xd;1)xd) c0(x 1:::xd;1xd) = c(x1:::xd;1)

(12)

 Let(Rc) be a test in dimension d;1.

We still denote by (Rc) the assignment(R0c0)of dimensiond dened, for allx

1:::xd

201]by:

R(x1:::xd;1xd) = R(x1:::xd;1)

c0(x

1:::xd;1xd) = c(x1:::xd;1)

We dene now the transformation =xd+1on instructions: this transformation is equivalent to making the

change of variable xi becomes xi=xd+1 for all i:

Denition 3.4 (Transformation

=xd+1

on instructions)

 Let(fc)be an assignment in dimension

d. We write(f=xd+1c=xd+1)for the assignment in dimensiond + 1dened as follows:

{

f=xd+1 and c=xd

+1 are dened on (x

1:::xd+1) i all the following conditions hold:  xd

+1> 0  (x

1=xd+1:::xd=xd+1)

201]d

 function f and c are dened on value (x

1=xd+1:::xd=xd+1)

{

whenf=xd+1 and c=xd +1 are dened on (x 1:::xd), f=xd+1(x1:::xd+1) = xd+1f(x1=xd+1:::xd=xd+1) c=xd+1(x1:::xd+1) = xd+1c(x1=xd+1:::xd=xd+1)  Let(Rc)be a test in dimensiond. We write(R=xd

+1c=xd+1)for the test in dimensiond+ 1dened

as follows:

{

R=xd+1 and c=xd+1 are dened on(x1:::xd+1)i all the following conditions hold:  xd

+1> 0,  (x

1=xd+1:::xd=xd+1)

201]d  Rand c are dened on value (x

1=xd+1:::xd=xd+1).

{

whenR=xd+1 and c=xd+1 are dened on(x1:::xd+1),

R=xd+1(x1:::xd+1) = R(x1=xd+1:::xd=xd+1)

c=xd+1(x1:::xd+1) = xd+1c(x1=xd+1:::xd=xd+1)

Take an example: consider instruction I dened as x1 := x1+ 1] where

2 Q. When x

3 > 0 and

x1=x3

2 01], I=x

3 is equivalent to instruction x1 := x1+ x3x3]. When x3 = 0 or x1=x3 > 1 then no

evolution is possible.

We are ready to dene the admissible operations in dim d: this is done inductively.

Denition 3.5 (Admissible operations in dim

d

)

We dene inductively the set of the assignments de-noted by Assgnmtd (respectively: the set of the tests denoted by Testd) that are admissible in dimension

d:

For all d, for allijk2f12:::dg, for all 2Q, for all +

2Q

+, for all#

2f> < =6=g:  \Linear machines instructions"

{

\xi := xi+ xk 1]"2Assgnmtd

{

\xi := xj 1]"2Assgnmtd.

{

\xi := +x i 1]"2Assgnmtd.

{

\xi := 1]"2Assgnmtd.

{

\xi := xi+ 1]"2Assgnmtd.

{

\xi# +? 1]" 2Testd.  \Special instructions"

(13)

{

\xd := xd=2 xd]"2Assgnmtd, if d > 2.

{

\xd := 2xd xd]"2Assgnmtd, if d > 2.

{

\xd := xd+ xk xk]"2Assgnmtd, if2 < k < d  \Subprograms"

{

If P is a program of dimension d, then (fc + 1) 2 Assgnmtd, where (fc) is the assignment

corresponding to the execution of P.

 \Assgnmtd ;1 Assgnmtd", \Testd ;1 Testd"

{

If (fc)2Assgnmtd ;1 then(fc) 2Assgnmtd.

{

If (Rc)2Testd ;1 then(Rc) 2Testd.  \Zeno instructions"

{

If (fc)2Assgnmtd ;1 and d > 2then (f=xdc=xd) 2Assgnmtd.

{

If (Rc)2Testd ;1 and d > 2 then(R=xdc=xd) 2Testd.

RCT machines can be considered as machines recognizing some languages L

 as follows:

Denition 3.6

Let be the xed nite alphabet. Language L  

 is semi-recognized by RCT machine M if, for all n 2 

, M has an accepting

computation starting from(I(n)0:::0)in2L.

L is fully-recognized if in addition, for all n 2 

, there is a rejecting computation starting from

(I(n)0:::0) in62L.

We will write the RCT programs in a high level programming language style using all the usual ow control instructions (while, if, for, goto) as in algorithm 1.

3.2 RCT machines can simulate Turing machines

We show in this subsection that one can simulate any Turing machine by a RCT machine. This is nothing but a restatement of 10].

3.2.1 Two stacks pushdown automata can simulate Turing machines

It is well known that Turing machines are equivalent to two stacks pushdown automata (2PDA)9]: the two stacks correspond to the content of the tape on the right and on the left respectively of the head of the Turing machine.

We go here into the precise details of what we call a 2PDA or an !-2PDA. A 2PDA is equivalent to a Turing machine, and an !-2PDA is equivalent to a Turing machine with a semi-innite tape.

Write 0for 

fg. If w2!, write w

+for the element of 0equal to the rst letter of w if w

6

=  and equal to  if w = . If w6= , denote w

; for the word such that w = w+w;. If i

2f12g, denote ~i = 3;i.

Denition 3.7 (2PDA)

 A two stacks pushdown automaton(2PDA) (respectively: an!-2PDA), is

a 5-tuple(Q q0F)whereQis a nite set,q0

2Qis the initial state,F Qis the set of the nal

states, is a mapping fromQ  0

 0toQ

Q InstructionSet, whereInstructionSetis the following

nite set of symbols: InstructionSet =fPushi(a)Popi(a)Topi(b)?ji2f12ga2b2 0

g  An Instantaneous Description (ID) of a 2PDA (resp. of an !-2PDA) is an element (qw

1w2) of Q     (resp. of Q ! 

). q is the internal state,w

1,w2 are the contents of the rst and

(14)

 The relation `d between IDs is dened as follows: (qw1w2) `d (q 0w0 1w 0 2) iff 8 > > > > > > > > > > < > > > > > > > > > > : (qw+ 1w + 2) = (q 00q000instr) and 8 > > > > > > > > < > > > > > > > > :

(instr = Pushi(a)q0= q00

w0

i= awiw0 ~i= w

~i)

or (instr = Popi(a)q0= q00w+

i = a w0 i= (wi);w0 ~i= w ~i) or (instr = Topi(b)?w0 1= w 1w 0 2= w 2 and  (q0= q00 and w+ i = b) or (q0= q000 and w + i 6= b))  Let` 

d be the transitive closure of `d. An inputw2

 (respectivelyw

2!) is accepted by a 2PDA

(resp. by an !-2PDA) i there exists an accepted IDIDacc such that (q0w) `



d IDacc.

 We say that a 2PDA (resp.an !-2PDA) maps (w

1w2) to(w 0 1w 0 2), where w 1w2w 0 1w 0 2 2   (resp. w1w 0 1 2!w 2w 0 2 2 ) , i(q 0w1w2) `  d(qw0 1w 0 2)for someq 2F.

3.2.2 RCT machines can simulate Two stacks pushdown automata

We show now that RCT machines can simulate 2PDAs using only the linear machine instructions: this is a restatement of 10].

Lemma 3.1

One can simulate any two stacks pushdown automaton (respectively any!-two stacks pushdown automaton) M by a RCT machine M0 of dimension 2whose program is only made of the linear machine

instructions.

Proof

: One build a RCT machine M0that simulates M: when the stacks of M are words w

1w2, the registers of M0are x 1 = J(w 1) and x2= J(w 2). The program of M

0is obtained by taking the program of

M, and by replacing one after the other the 2PDA instructions of M by some linear machine instructions using the correspondence of gure 4.

2

Theorem 3.1

LetS be a discrete language.

 Assume that S is recursively enumerable. ThenS is semi-recognized by a RCT machine of dimension

2

 Assume that S is recursive. Then S is fully-recognized by a RCT machine of dimension 2.

Proof

: Immediate from lemma 3.1 and from the fact that any Turing machine can be simulated by a two stacks pushdown automaton 9].

2

Convention 3.1

We use the following convention:

2 4 (w1w2) 7!(w 0 1w 0 2)

where

\conditions" 3 5

denotes any RCT program M0 that, for allw

1w2 verifying \conditions", maps real registersx1 = J(w 1), x2 = J(w 2) to x1 = J(w 0 1)x 2 = J(w 0 2): to obtain M

0, consider any !-2PDA M such that, for all

w1

2!w 2

2

 verifying \conditions", M maps (w

1w2)to(w 0 1w

0

2): recall that 2PDAs are equivalent to

Turing machines. Now apply the transformation of the proof of lemma 3.1 onM to get RCT machineM0.

As an example, 2 4 (ww0) 7!(ww)

where

ww0 2 w = w0 3

5 is any RCT program that, for all ww 0 2  such that w = w0, maps ( J(w)J(w 0)) to ( J(ww)0).

(15)

Two stacks automata RCT machine instruction instructions Pushi(j)i2f12gj2 xi:= xi=b + (2 j)=b 1] Popi(j)i2f12gj2 x 1:= b (x 1 ;(2j)=b ) 1] Topi()?i2f12g xi= 0? 1] Topi(j)?i2f12gj2 ((xi (2j)=b )? 1] and (xi (2j + 1)=b )? 1])

Figure 4: Correspondence between 2PDA instructions and RCT instructions. The RCT instructions corre-sponding to the 2PDA instructions Pushi(j)Popi(j)Topi(j)? will be still denoted by Pushi(j), Popi(j),

Topi(j)?.

3.3 RCT machines and the arithmetical hierarchy

3.3.1 Speedup properties of RCT machines

In denition 3.4, we dened the transformation =xd+1on instructions: the transformation =xd+1on a RCT

program P is obtained by transforming instruction by instruction the instructions of P:

Denition 3.8 (Transformation

=xd+1

on RCT programs)

LetP be a RCT program of dimension d:

P = (Qq0q +

fq;

flimit ).

We denote byP=xd+1the RCT program of dimensiond+1dened byP=xd+1= (Qq0q +

fq;

flimit 0)

where for allqq0q00andInstr

2Testd Assgnmtd, (q) = (q 0q00Instr) , 0(q) = (q0q00Instr=x d+1) We prove:

Lemma 3.2 (Speedup lemma)

LetP be a RCT program of dimension d. For all 2(01], for allx

1x2:::xd

201],P=xd

+1 started with real registers( x1 x2::: xd )

simulates the evolution of P on (x1:::xd)but the simulation of P by P=xd+1 goes1= times faster than

P.

Proof

:

Let 2(01] and let x

1:::xd

201] be xed.

Denote by (qjxj

1:::x

j

dtj)j2J the computation of P starting from (x1:::xd).

Denote by (q0j x0j0 1 :::x 0j0 d x0j0 d+1t 0j0 )j0 2J 0 the computation of P 0 starting from ( x 1 :::  xd ). It is

easy to prove by transnite induction that, for all j 2J, one has j 2J

0, qj = q 0j , x0j d+1 = , x 0j i = xji for all 1 i d, and t 0j = tj. 2 We get immediately:

Theorem 3.2

Assume thatSis semi-recognized (respectively: fully-recognized) by a programPin dimension

din timeT. For anyk2N

+,Sis semi-recognized (resp. fully-recognized) in dimensiond+1in time2+T=k.

Proof

:

Assume that S is semi-recognized by P. S is semi-recognized (resp. fully-recognized) in dimension d + 1 in time 2 + T=k by the following program P0:

Algorithm 2

Program P0

x1:= x1=k 1]

xd+1:= 1=k 1]

P=xd+1

(16)

3.3.2 From semi-recognition to recognition

We see now that one can transform a program that semi-recognizes a set S in dimension d to a program that fully-recognizes S in nite time in dimension d + 1.

We need rst some denitions: a clocked program is a program where some instructions are marked and where the execution of the marked instructions can be used as the tops of a clock: there must exists an upper bound  for the time between two successive tops, and any bounded time interval must contain a nite number of tops:

Denition 3.9

 A clocked programis any programP = (Qq 0q

+

fq;

flimit )such that:

{

some instructions ofP are marked: there exists some Q0 Q.

{

there exists2R

+, called the time period of P, such that any computation ofP executes a nite

number nI 1of marked instructions on any time interval I of width : for all computation

C = (qjxj 1:::x j dtj)j2J of P, for allt 2R +, if there is somej

2J with tj t + , then the

cardinality of the set fj 0 jj 0 2Jqj 0 2Q 0t j0

2tt + ]gis nite and greater than1.

 An !-clocked program is a clocked program such that a computation ofP executes a nite number of

marked instructions i the computation is accepting.

 If P is a clock program, and Ris a program, we writePRfor the program that one gets by inserting

in P a copy of programRat each marked instruction ofP

As an example, take any 2PDA M that semi-recognizes a set L 

. Assume that M never enters a

\reject" state but loops for ever on an input w2

with w

62L. Then the RCT program M

0of dimension

2 given by lemma 3.1 that simulates M can be !-clocked: mark all the instructions of M0and take  = 1

as time period.

We use the following convention: we assume any program given by lemma 3.1 (and therefore any program given by the notation

2 4 (w1w2) 7!(w 0 1w 0 2)

where

conditions 3

5) marked with all the instructions marked. Moreover, when P

is marked, we consider that P=xd+1is marked, where the marked instructions of P=xd+1are the instructions

corresponding to the marked instructions of P. In particular, if R is a program, and P is a marked program then (P=xd+1)

R is the program that one gets by transforming all the instructions of P by transformation

=xd+1 and by inserting a copy of R at each instruction corresponding to a marked instruction of P.

Let d 2 be an integer. We will use the following program:

Algorithm 3

Program Div2d+1

x1:= x1=2 xd+1] x2:= x2=2 xd+1] ... xd;1:= xd;1=2 xd+1] xd:= xd=2 xd+1] xd+1:= xd+1=2 xd+1]

And the following program:

Algorithm 4

Program Mul2d+1

x1:= 2x1xd+1]

x2:= 2x2xd+1]

...

xd;1:= 2xd;1 xd+1]

(17)

xd+1:= 2xd+1 xd+1]

We claim:

Theorem 3.3

Assume that S is semi-recognized by an !-clocked program in dimension d. Then:

 There exists a program of dimension d + 1that fully recognizesS.  Moreover, for all k 2 N

+, there exists a program of dimension d + 1 that fully recognizes S in time

2 + 1=k.

Proof

:

Assume that S is semi-recognized by P. Let 0 < 1 be some rational constant.

Consider the following program P0



Algorithm 5

P0  x1:= x1 1] xd+1:= 1] (P=xd+1) (Div2d +1) limit: Reject It is su(cient to take P0

1 to prove the rst assertion and to take P 0

1=(2k(+d+1)) to prove the second

assertion, using lemma 3.3 proved below.

2

Here is the trick:

Lemma 3.3 (Super-speedup lemma)

LetP be an!-clocked RCT program of dimensiondof time period

. For all 2(01], for allx

1x2:::xd

201],(P=xd +1)

Div2d

+1 started with real registers ( x 1 x2

..., xd ) simulates the evolution ofP on(x1:::xk)but the whole simulation ofP byP=xd+1 is made in

a nite bounded time upper bounded by2 ( + d + 1). Moreover, whenever P accepts, (P=xd+1)

Div2d

+1 accepts. Whenever P does not accept, (P=x

d+1) 

Div2d+1 converges to its limit state with all its real registers set to 0.

Proof

: Let 2(01] and x

1:::xd

201] be xed.

Denote by (qjxj

1:::x

j

dtj)j2J the computation of P starting from (x1:::xd). Let Q0

Q gives the marked instructions of P. Denote by (q0j0 x0j0 1 :::x 0j0 d t0j0 )j0 2J 0 the computation of (P=xd +1) Div2d +1 starting from ( x 1 :::  xd ). Denote by j1< j2< :::

2J the sequence of the indexes corresponding to the execution of the marked

instructions of P: for all j2J, either qj 2Q

0and j = jk for some k or q

j62Q 0.

For j 2J, let nj denote the number of marked instructions of P executed between time 0 and time tj:

nj is the cardinality of set fkjtjk< tjg.

It is easy to prove by transnite induction on j 2J that, for all j 2 J

0, one has j 2 J, q 0j +nj(d+1) = qjx0j +nj(d+1) i = xji=2nj for all 1 i d, x 0j +nj(d+1) d+1 = =2 nj, t0j +nj(d+1) = Pnj k=1(t jk;tjk ;1 + d + 1)=2k;1+ (tj ;tjnj)=2nj with t

0= 0, and that for all k and l

d + 1, q 0tjk

+(k;1)(d+1)+lcorresponds to an

instruction of program Div2d+1.

This means that (P=xd+1) Div2d

+1 simulates P: if P accepts then (P=x

d+1) Div2d +1 accepts: qj 0 = q + f for some j0 2J implies q 0j 0+nj 0 (d+1)= q +

f. For all k2N, we have tjk;tjk ;1

. As a consequence, for

all j 2J, tj 2 ( + d + 1). Hence, (P=xd +1)

Div2d

+1 accepts at some nite time bounded above by

2 ( + d + 1).

If P does not accept its input, since P is assumed to be !-clocked, a non nite number of Div2d+1

are executed. As a consequence, for all 1 i d + 1, the sequence (xji)j

(18)

supj2Jt

j 2 (+d+1). That means that (P=xd +1)

Div2d

+1 reaches the ID (limit0:::0t) at nite

time t= sup j2Jt 0j , with t 2 ( + d + 1). 2

3.3.3 Recognizing arithmetical sets

The following lemma will be used in the proof of lemma 3.5:

Lemma 3.4

There exists an injective mapping E fromI to(1=21]such that, for any d 3,  There exists a RCT program Encd of dimension d that, for all y

1 2 I, maps (y 1::::::) to (E(y 1)y1:::: E(y 1)).

 There exists a RCT program Decd of dimension d that maps (:::::E(y

1)) to (y1:::::) for all

y1 2I.

We say that a RCT machine M of dimension d maps (1:::d) to (1:::d), where for all 1

i d,

either i201] or i is the symbol :, and either i201] or i is the symbol :, i for all (x

1:::xd) with

xi= i for all i such that i6= :, M maps (x

1:::xd) to some (x 0 1:::x

0

d) with x0

i= i for all i such that

i 6= :.

Proof

: Let # be a letter of . Denote by number : 

!Nthe function that maps any word w2 

onto its number in some xed recursive enumeration of the words of . For all n

2N, denote by wnthe

nthword of : number(w

n) = n.

For all w2

, we dene

E(I(w)) as the unique point which is simultaneously in interval (1=21] and in

the setf2k=3number (w)

jk2Zg.

It is su(cient to consider program Encd as the following RCT program:

Algorithm 6

Encd 2 4 (ww0) 7!(w#number (w))

where

ww0 2  3 5 /*Setx2 to I(#number (w))*/ xd:= 1

while

(x2 6 = 0?)

do

/*Do number(w) times x1 := x1=3xd = xd=3 */ x2:= b (x 2 ;(2#)=b ) x1:= x1=3 xd:= xd=3

end while

/*Now, while xd 62 (1=21] multiply x

1 and xd by2*/

while

(xd 1=2?)

do

x1:= 2x1 xd:= 2xd

end while

And program Decd as:

Algorithm 7

Decd

x2:= 0 /*Don := 0: setx2=

I(# 0)*/

while

(xd6= 1?)

do

/*While (xd6= 2k=3n for somek) do*/

x2:= x2=b+ #=b /*Don := n+ 1: transformx2= I(#n)into x2= I(#n +1)*/ xd:= 3xd

(19)

while

(xd > 1?)

do

xd:= xd=2

end while

end while

2 4 (w#n) 7!(wn)

where

w2 n 2N 3 5 /*Putx1= I(wn).*/ 2

We need to improve theorem 3.3: we show that any language that is semi-recognized in dimension d can be fully-recognized in dimension d + 1 by a clocked program that returns its input when it accepts.

Lemma 3.5

LetS be a discrete language. Assume that S is semi-recognized by an !-clocked program P in dimension d. Then

S is fully-recognized in dimensiond + 1 by some clocked program ~P: for allw2   if w62S then ~P rejects inputJ(w)and stops with all its real registers set to0.

 if w2S then ~Paccepts input J(w) and stops with its rst real register set toJ(w) and all its other

real registers set to 0.

Proof

:

Denote by Encd+1 and Decd+1the programs of lemma 3.4, and by

E : I!(1=21] the function of lemma

3.4.

Take ~P dened as follows:

Algorithm 8

Program ~P Encd+1 /*Maps x1 = y1 to x1 = E(y 1)y1xd+1 = E(y 1)*/ (P=xd+1) (Div2xd +1) /*SimulateP on inputy 1*/

while

(xd+1 1=2? 1])

do

xd+1:= 2xd+1 1]

end while

/*If it stops then undo all the divisions by 2

done on variablexd+1 during the simulation.

At the end of the while loop we have xd+1= E(y 1).*/ Decd+1 /*Map xd+1 = E(y 1)tox1= y1.*/ xd+1:= 0 1] x2:= 0 1]

Accept /*And accept.*/

limit:

Reject /*Else reject.*/

Let x1:::xdxd+1

2 01] be xed. If (x

1:::xd) is not accepted by P, then from lemma 3.3,

(x1:::xdxd+1) is rejected by this program, and all the registers are set to 0.

Now, assume (x1:::xd) is accepted: by the proof of lemma 3.3, RCT program (P=xd+1)

(Div2xd +1)

stops with its d + 1th real register equal toE(x 1)=2

nj0, where nj 0

2Nis the number of marked instructions

of the accepting computation of P starting from (x1:::xd). It is easy to see that the while loop will be

executed nj0 times and that the end of the while loop the content of the d + 1

th real register will be set to

E(x

1). Hence, after the Decd+1 program, the rst real register of ~P will return to value x1.

By lemma 3.3, program (P=xd+1)

(Div2xd

+1) is always executed in a bounded time. As a consequence,

~P can be clocked: mark all the instructions but those of (P=xd+1)

(Div2xd

+1). Take as time period of ~P

the maximum of 1 and of the time needed to execute program (P=xd+1)

(Div2xd +1).

2

(20)

Lemma 3.6

Assume thatB is a discrete language such that all the languages ofB

1 are semi-recognized by

some!-clocked RCT program in dimension d0 2.

LetS be a discrete language withS2Bk,k2Nk 1. ThenS is semi-recognized by an!-clocked RCT

program in dimension d0+ k ;1.

Proof

: We prove the assertion by induction over k. Case k = 1 is true by hypothesis.

Assume k 2 and the hypothesis at rank k ;1. Let S 2 Bk. There exists S 0

2 Bk

;1 such that

x 2 S , 9n 2 N < nx >62 S

0: see 16]. By induction hypothesis S0 is semi-recognized in dimension

k + d0

;2 by an !-clocked RCT program Pk

;1. Let ~Pk;1 be the marked program that one gets by applying

lemma 3.5 on program Pk;1.

S is semi-recognized by the following RCT program Pk:

Algorithm 9

Program Pk 2 4 (ww0) 7!(< 0w >w 0)

where

ww0 2  3 5

while

( ~Pk;1 accepts) 2 4 (< nw >w0) 7!(< n + 1w >w 0)

where

ww0 2 n 2N 3 5

end while

Accept

Pk can be !- clocked: mark all the instructions but those that were not marked in ~Pk;1. Take as time

period the maximum of 1 and of the time period of ~Pk;1. Pk is of dimension d + k 0

;1.

2

Lemma 3.7

Assume thatB is a discrete language such that all the languages ofB

1 are semi-recognized by

an!-clocked RCT program in dimension d0 2.

Let S be a discrete language with S 2Bk, k2Nk 2. Then S is fully-recognized by a RCT program

in dimensiond0+ k ;1.

Proof

: By denition of Bk, there must exists S0S00 2Bk ;1 such that x 2S,9n2N < nx >62S 0 and x62S,9n2N < nx >62S 00: see 16].

By lemma 3.6, S and S0 are respectively semi-recognized by some !-clocked programs P

k;1P 0 k;1 in dimension k + d0 ;2. Denote ~Pk ;1, ~P 0

k;1 the programs that one gets by applying lemma 3.5 on Pk ;1 and

P0

k;1respectively. S is fully recognized by the following RCT program Mk:

Algorithm 10

Program Mk 2 4 (ww0) 7!(< 0w >w 0)

where

ww0 2  3 5

while

( ~Pk;1 accepts)

do

if

( ~P0 k;1 accepts)

then

2 4 (< nw >w0) 7!(< n + 1w >w 0)

where

ww0 2 n 2N 3 5

else

Reject

end if

(21)

end while

Accept

2

Theorem 3.4

LetS be a discrete language.

 Assume S2k,k 1. ThenS is semi-recognized by an !-clocked RCT program of dimension1 + k.  Assume S2k,k 1. ThenS is fully-recognized by a RCT program of dimension 1 + k.

Proof

: Immediate from theorem 3.1, and from lemma 3.6 and lemma 3.7 respectively with B =. 2

3.4 RCT machines and the hyper-arithmetical hierarchy

3.4.1 Realizing any 2PDA program in time

kxd+1

We prove rst a technical lemma: if a 2PDA can do some job, one can build a RCT machine of dimension d + 1 3 that does the same job but in time bounded by kxd+1 for some k:

Lemma 3.8

Let d 2. Let M be an!-2PDA. Assume that, for all w1

2!w 2 2 , M maps (w 1w2) to(f1(w1w2)f2(w1w2)) 2!  .

There exists somekM 2R

+ and a RCT machineM0of dimensiond + 1 that, for allw 1

2!w 2

2 ,

for ally3:::yd

201], for alln2N, maps

(J(w 1)=2 nJ(w 2)=2 ny 3=2 n:::yd=2n1=2n) to (J(f 1(w1w2))=2 nJ(f 2(w1w2))=2 ny 3=2 n:::yd=2n1=2n)

in a time bounded above bykM=2n.

Proof

: The idea is to build a machine that simulates M, that does some Div2d+1 instructions every

two steps and that counts in parallel the number of Div2d+1 instructions already executed. The machine

simulates M until M accepts. At this moment, the machine does some Mul2d+1 instructions in order to

come back to xd+1= 1=2

n.

Let"be a letter of . If i2f12g, denote ~i for 3;i. Assume without loss of generality that any ID of

any computation of M on any input is of type (qw1w2), q 2Qw

1w2 2

 with the rst letter of w 1 and

the rst letter of w2 di erent from letter ".

Replace one after the other the 2PDA instructions of M by some new instructions using the following correspondence, , where RCT instructions Topi(j)?, Popi(j), Pushi(j) are dened in gure 4:

Old !-2PDA instruction New RCT instructions Pop1(j)j 2 Transfer 2)(Pop 1(j))=x d+1)(Push 1( "))=xd +1) Div2d+1)Transfer 1 Push1(j)j 2 Transfer 2)(Push 1(j))=x d+1) (Push1( "))=xd +1)Div2 d+1)Transfer 1 Top1(j)?j 2 Transfer 2)(Top 1(j)?)=x d+1) (Push1( "))=xd +1)Div2 d+1)Transfer 2 Pop2(j)j 2 (Pop 2(j))=x d+1)(Push 1( "))=xd +1) Div2d+1 Push2(j)j 2 (Push 2(j))=x d+1)(Push 1( "))=xd +1)Div2 d+1 Top2(j)?j 2 (Top 2(j)?)=x d+1)(Push 1( "))=xd +1)Div2 d+1

(22)

where Transferi, i2f12gtransfers all the"from register ~i to register i and is the following sequence of instructions:

Algorithm 11

Transferi

while

((Top~i (")?)=xd +1)

do

(Pop~i ("))=xd +1 (Pushi("))=xd +1 /*Transfer one

"from stack~ito stacki*/

(Pushi("))=xd +1 Div2d+1 (Pushi("))=xd +1 Div2d+1 (Pushi("))=xd +1 Div2d+1 /*Add 3

"since the transfer of the"was done

with3instructions*/

end while

One gets a RCT program PM of dimension d + 1: this program simulates M, does some Div2d+1

instructions every two steps and has the following property: at every step of the simulation of M, the value of the rst real register of PM is of type J("p w), w 2 

, where p

2 N, is the number of instructions

Div2d+1 already executed by P

M.

Consider now M0as the following RCT program:

Algorithm 12

Program M0 PM /*Map x1 = J(w 1)=2n , x2 = J(w 2)=2n, x3 = y3=2n, ..., xd = yd=2n, xd+1 = 1=2n to x1 = J("p f 1(w1w2))=2n +p , x 2 = I(f 2(w1w2))=2n +p,x 3= y3=2n +p,...,x d= yd=2n+p,x d+1= 1=2n +p).*/

while

((Top1( ")?)=xd +1)

do

(Pop1( "))=xd

+1 /*Get back to xd+1 = 1=n by undoing the

Div2d+1 instructions*/

Mul2d+1

end while

Program M0is executed in a time bounded above by k

M1=2nfor some xed kM 2R +. 2

Convention 3.2

We denote by 0 @ (w1w2) 7!(w 0 1w 0 2)

where

\conditions" 1 A jxd +1

any RCT program of dimensiond+1given by lemma 3.8 that for allw1w 0 1 2!,w 2w 0 2 2  verifying

\con-ditions", and for ally3:::yd

201], for alln2N, maps(J(w 1)=2 nJ(w 2)=2 ny 3=2 n:::yd=2n1=2n)to (J(w 0 1)=2 nJ(w 0 2)=2 ny 3=2

n:::yd=2n1=2n)in a time bounded by k=2nfor somek.

3.4.2 Setting the

mth

digit of a real in time

k=2m

for some

k

The following lemma is the main trick that will be used in lemma 3.10 to show that one can recognize some hyper-arithmetical sets: one can build a RCT machine of dimension d + 2 that, on input m2N, add 1=2m

to real register xd+2in a time proportional to maximum(1=2

mxd

(23)

Lemma 3.9

Let#$2be two distinct letters of used as delimiters.

For alld 2, there exists somek2R

+and a RCT machineWriteDigit

d+2 of dimensiond+2that, for

ally3:::ydyd+2 201]mn2Nw2!w 0 2 , maps (J(#nm$w)=2nI(w 0)=2ny 3=2 n:::yd=2n1=2nyd +2) to (J(#nm$w)=2nI(w 0)=2ny 3=2 n:::yd=2n1=2nyd +2+ 1=2 m)

in a time upper bounded by k1=2minimum(mn).

Proof

: The general idea is to do some Mul2d+1=Div2d+1 instructions in order to get x

d+1= 1=2m, then

to do a xd+2:= xd+2+xd+1xd+1] instruction, and then to do some Div2d

+1=Mul2d+1instructions to come

back to xd+1= 1=2n.

Assume without loss of generality that one can nd two distinct letters"and#in  di erent from letter

$ and from letter #.

WriteDigitd+2 is the following RCT program , where RCT instructions Top

i(j)? Popi(j), Pushi(j) are

dened in gure 4:

Algorithm 13

WriteDigitd+2 0 B B B B B B B B @ (#nm$ww0) 7!(move 1$move2$w 0$#nm$w)

where

w2!w 0 2 mn 2N move1move2 2  (move1move2) = 8 < : (#m ;n "m ;n) if m > n ("n ;m #n ;m) if m < n () if m = n 1 C C C C C C C C A jxd +1 /*Map 8 < : x1= J(#nm$w)=2n x2= I(w 0)=2n xd+1= 1=2 n to 8 < : x1= J(move 1$move2$w 0$#nm$w) =2n xd+1= 1=2n

in a time bounded byk11=2nfor somek1: see

lemma 3.3.*/

GoUpOrDown /*Call some Mul2d+1=Div2d+1 instructions

to getxd+1= 1=2m*/

xd+2:= xd+2+ xd+1 xd+1] /*Add1=2m toxd+2*/

GoUpOrDown /*Call some Div2d+1=Mul2d+1 instructions

to getxd+1= 1=2n*/ 0 @ (w0$#nm$w) 7!(#nm$ww 0)

where

w2!w 0 2 mn 2N 1 A jxd +1 /*Set x1 = J(#nm$w)=2n, x 2 = I(w 0)=2n in time bounded by k21=2 nfor somek 2. */

where program GoUpOrDown is the following RCT program:

Algorithm 14

program GoUpOrDown

(24)

if

(Top1( "))=xd +1

then

while

((Top1( "))=xd +1)

do

(Pop1( "))=xd +1 Mul2d+1

end while

end if

if

(Top1( #))=xd +1

then

while

((Top1( #))=xd +1)

do

(Pop1( #))=xd +1 Div2d+1

end while

end if

(Pop1($))=x d+1

The execution of the calls to program GoUpOrDown are done in a time upper bounded by k31=2

min(mn)

for some k3. As a consequence, there exists some k 2 R

+ such that the whole execution of program

WriteDigitd+2 is done in a time bounded above by k1=2

minimum(mn).

2

3.4.3 Outputting reals encoding languages

In denition 2.3, we dened mappingJ that encodes any word of ! into a real of 01]. Now, we dene

mappingLthat encodes any discrete language L

 into a real of 01]:

Denition 3.10 (Encoding by

L

)

Let =f01:::n 

gbe the xed nite alphabet. Let and be two

letters ofwith 6= .  LetL

 be a discrete language. We denote by w

L the innite word a0a1a2:::ai:::such that, for

all i2N,ai= (respectively: ai= ) i theith word of 

 is inL (resp. is not inL)  Denote byP(

)the set of the subsets of .

We denote by Lthe mapping fromP(

)to01]that, for all L 

, mapsL to

L(L) =J(wL).

Check that J(w ) is in

Qand that a machine can do with any problem x 1:=

L().

Using lemma 3.9, we show that if we can enumerate a set then we can output a real encoding this set in nite time:

Lemma 3.10

Letd 2. Let$#be two letters ofused as delimiters. Assume we have a function f : N 

 ! !  , a constant k f 2R + and a RCT machine M f of

dimension d + 1that, for alln2Nw2 L  y 2 2I, maps (J(#n$w$wL)=2ny 2=2 n:::::1=2n) to (J(f(nwwL)$wL)=2ny 2=2 n:::::1=2n)

in a time bounded above bykf1=2n.

Then there exists a RCT machine M0

f of dimension d + 2 that for all discrete language L

, for all word w 2   and real y 2 2 I, maps (J(w$wL)y 2::::) to ( J(w$w ~ L(w))y 20:::0) in a bounded time, whereL(w) =~ fw 0 jw 0 2  ^ 9n2Nf(nwwL) = w 0 g

(25)

Proof

: The general idea is to write a program that, on input x1=

J(w$wL), x 2=

I(w

0), using lemma

3.9, writes digit by digit onto its real register xd+2the real value of

J(w$w 0$w

~

L(w)).

Denote by number : 

!Nthe function that maps any word w2

onto its number in the enumeration

of the words of . For k

2Nw2

, denote lttr(wk) for kthletter of word w. We assume xed a recursive

enumeration of the nite subsets of similar to the one of 16]: for any integer n

2N, Dndenotes the nth

nite subset of .

M0

f is given by the following algorithm, where RCT instructions Topi(j), Popi(j),Pushi(j) are dened

in gure 4 and integer b0

 is dened page 3:

Algorithm 15

Program M0 f 2 6 6 4 (w$wLw0) 7!($wLw$w 0$u 0)

where

wL2!ww 0 2  u0 2NDu 0=  3 7 7 5

/*Initialize the computation: setn = 0*/

xd+1:= 1 /*Set initial speed to1*/

xd+2:= 0 /*Setxd+2 to0*/

while

0 (

true

)

do

/*While (true)*/

B B B B B B @ (#n$wLw$w0$u n) 7!(#nb 0  n;2an$wLw$w 0$u n)

where

wL 2!ww 0 2 , nun2Nan2 an=   if n > length(w$w0$) lttr(w$w'$,n) if n length(w$w 0$) 1 C C C C C C A jxd +1

WriteDigitd+2 /*Set the nth digit of xd+2 to default value

an*/ 0 @ (#nm$wLw$w0$u n) 7!(#n$w$wL#n$w$w 0$u n)

where

wL2!ww 0 2 nu n2N 1 A jxd +1

Mf /*Get w00 the nth word of the enumeration

given byMf*/ 0 B B B B B B B B B B B B B B @ (w00$w L#n$w$w0$u n) 7!(#nm$wLalreadyin$w$w 0$u n+1)

where

ww0w00 2 w L2! nunun+1 2Nalreadyin2 m = b0  (number(w) + length(w$w 0$) + 1) ;2(;) if w00 2Dun then alreadyin = #, un+1= un else alreadyin = $,Dun+1= Dun fw 00 g 1 C C C C C C C C C C C C C C A jxd +1

if

((Top2($))=x d+1)

then

/*If wordw

00 has not been yet output*/

(Pop2($))=x

d+1

WriteDigitd+2 /*Then change the digit of real registerxd+2

corresponding tow00 from valueto value.

*/

else

(Pop2(#))=x

d+1 /*Else do nothing*/

(26)

0 @ (#nm$wL$w$w0$u n+1) 7!(#n +1$w Lw$w0$u n+1)

where

wL2!ww 0 2 u n+1nm 2N 1 A jxd +1 /*Don := n + 1*/ Div2d+1

end while

limit :

x1:= xd+2 /*Copy the result intox1*/

xd+2:= 0 /*Setxd+2 to0*/ 2 4 (w$w0$w L) 7!(w$wLw 0)

where

wL2!ww 0 2  3 5

/*Put back the result in the good form*/

2

3.4.4 Climbing up the hyper{arithmetical hierarchy

We start by an easy lemma used in lemma 3.12:

Lemma 3.11

 For all y 2O, fxjx2 O ^ x < 0 y

gis recursively enumerable uniformly in y: there

exists a recursivef :N!Nsuch that for ally2O, the range of f (y) is

fxjx < 0y

g  Given xy2Owithx oy ory

0 as input, a Turing machine can eectively tell if x = y, if x <0y

or if y <0x.

 There exists a recursive l such that, for allz

1z2 withz1 0z2,H(z1) = W H(z 2 ) l(z 1z2 )

Proof

: See 16] for the rst assertion. For the second assertion enumerate in parallel the predecessors of x and of y until x or y is found. For all z1z2, set l(z1z2) as number of the Turing machine with oracle that,

on any input w, test the membership of word h(z 1z

2)(w) to its oracle, where h is the recursive function of

lemma 2.2.

2

Now, we apply recurrently lemma 3.10 in order to get some machines that outputL(L) for some discrete

languages L2

 in higher and higher levels of the hyper-arithmetical hierarchy. We dene !0 as 1.

Lemma 3.12

Letk 0.

There exists zk2Owithjzkj= !k, there exists fk :N  

!!

, there exists some xed C

k2R

+

and:

 a RCT machine Mk of dimension 2k + 2 that, for all n 2 Nw 2  L   y 2 2 I, maps (J(#n$w$wL)y 2:::::)to( J(fk(nwwL)$wL)y 2:::::)  a RCT machine M 0

k of dimension 2k + 3 that, for all n 2 Nw 2  L   y 2 2 I maps (J(#n$w$wL)=2ny 2=2 n:::::1=2n)to(J(fk(nwwL)$wL)y 2=2 n:::::1=2n)in a time bounded above by Ck=2n.

such that, for allz2O, ifL = H(z)thenL(z) =~ fw 0 jw 0 2  ^ 9n2Nf(nzwL) = w 0 g= H(z + 0zk)

Proof

: It is known that there exists a recursive g such that for all L2 m

2N, the range of function

Lg(m)is is WLm16]. Let Munivbe an !-2PDA such that on input #

n$m, Munivsimulates MLg

(m)on input n,

answering the queries of MLg(m) on any word w

0to its oracle L by comparing the digit of w

L corresponding

to w0to letter . M

univ is an !-2PDA that for all n2Nm2Nw 0 2 L  , maps (#n$m$w Lw0) to (wmn$wLw0), where wmn= Lg (m)(n).

(27)

Denote by Puniv the RCT machine given by lemma 3.1 that simulates Muniv.

Using lemma 3.8, for all d 2 one can build a RCT machine P0d +1

univ of dimension d + 1 that, for all n2 Nm2Ny 2 2IL  , maps ( J(#n$m$wL)=2ny 2=2 n : ::: : 1=2n) to (J(wnm$wL) =2ny 2=2 n: ...,

:1=2n) in time k=2nfor some xed k2R

+. Apply lemma 3.10 on this machine: one gets a RCT machine of

dimension d+2 that, for all L m 2Ny 2 2I, maps (J(m$wL)y 2:::::) to ( J(m$wWLm)y 20:::0)

in nite time. Denote this RCT machine by P00d +2

univ .

Now, we are ready to prove the assertions of the lemma by induction over k: Assume k = 0: it is known that there exists m0

2N, such that for all L

, L0= WLm

0 16]. Consider

M as the !-2PDA that on input (#n$w$wLw0) calls M

univ with input (#n$m0$wLw 0). M

0 is the RCT

machine of dimension 2 given by lemma 3.1 that simulates M, and M0

0 is the RCT machine of dimension 3

given by lemma 3:8 that simulates M. Assume now k 1: denote by 123:

N!Nsome recursive functions such that

n7!(

1(n)2(n)3(n))

is a bijective recursive function fromNto N N N. Denote by f and l the recursive functions of lemma

3.11.

Lemma 3.10 can be applied on machine M0

k;1: one get a RCT machine M 00 k;1 of dimension 2k + 2 that for all z0 2O, for all y 2 2I maps (J(z 0$w H(z 0 )) y2:::::) to J(z 0$w H(z 0 +zk ;1 )y20:::0) in a bounded

time. Set zk = 3:5nk where nk(0) = 1 and nk(n + 1) = nk(n) +0zk;1 for all n 2N.

Mk is given by the following program, where RCT instructions Topi(j), Popi(j),Pushi(j) are dened in

gure 4:

Algorithm 16

Program Mk 2 4 (#n$z$wLw0) 7!(z$wL#$#n$z$w 0)

where

wL2!w 0 2 z 2On2N 3 5

while

(Top2(#)?)

do

/*Call

1(n) times programM 00 k;1 */ M00 k;1 2 6 6 6 6 6 6 6 6 6 6 4 (zp$wL#$#n$z$w0) 7!(zp +1$wLcontinue$# n$z$w0)

where

wL 2!w 0 2 z pzp+1 2On2N zp+1= zp+0yk;1 if zp+1 onk( 1(n)) then continue = # else continue = $ 3 7 7 7 7 7 7 7 7 7 7 5

end while

/*Here, if the initial input was #n$z$wH

(z), z 2 O, we have x 1 = J(zp$wH (zp)) where zp= nk(1(n)) */ 2 6 6 6 6 4 (zp$wL$$#n$z$w0) 7!(# 2 (n)$m$w L#n$z$w0$z 00$z p)

where

wL2!w 0 2 z 2Omn2N z00=  f(zp)(3(n)) (we have z 0 0zp) m = l(z00z

p) is the integer such that WH(zp)

m = H(z00) 3 7 7 7 7 5 Puniv /* Compute z00 =  f(zp)(3(n)). We have z00 o zp. Get w 00 the  2(n)th word of H(z00)*/

(28)

2 6 6 4 (w00$w L#n$z$w0$z 00$z p) 7!(m$wL#n$w 00$z 00$w 0)

where

wL2!w 0w00 2 zz00z p2Omn2N

m = l(zzp) is the integer such that WH(zp)

m = H(z) 3 7 7 5 P00 2k+2

univ /*Put back inx1 the value ofwH(z)*/

2 4 (m$wL#n$w00$z 00$w 0) 7!(< w 00z00> $w Lw0)

where

wL2!w 0w00 2 z00 2On2N 3 5 /*Output< w00z00> $w H(z) */ M0

k is easy to obtained from the program of Mk: add the instruction x2k+3 := 11] at the beginning of

program Mk, replace 2 4 (m$wL#n$w00$z 00$w 0) 7!(< w 00z00> $w Lw0)

where

wL2!w 0w00 2 z00 2On2N 3 5 by 0 @ (m$wL#n$w00$z 00$w 0) 7!(< w 00z00> $w L" 1(n)$w0)

where

wL2!w 0w00 2 z00 2On2N 1 A jxd +1

replace in program Mk all the other instructions of type

2 4 (w1w2) 7!(w 0 1w 0 2)

where

conditions 3 5 by 0 @ (w1w2) 7!(w 0 1w 0 2)

where

conditions 1 A jxd +1 replace Puniv by P0 2k+3 univ , P00 2k+2 univ by P00 2k+2

univ =x2k+3, and replace the call to M 00

k;1 by the instructions

M00

k;1)Div2

2k+3, and add the program GoUpOrDown dened page 20 at the end of the program.

2

We get:

Lemma 3.13

Letk 1.

 Any language of !k can be fully-recognized by a RCT machine of dimension 2k + 2.  Any language of !k can be semi-recognized by a RCT machine of dimension2k + 2.

Proof

: Consider the machine Mk and the integer zk 2O of lemma 3.12. Mk is of dimension 2k + 2, and jzkj= !k. Let L be a language of !k (respectively: !k). L is recursively enumerable (resp. recursive) in

H(zk) by some machine MH(zk)

n .

See that there exists a recursive g such that, for all u2 v

2O, u62H(v),g(u)2H(2v): see 16].

L is semi-recognized (resp. fully-recognized) by the RCT machine of dimension 2k + 2 that simulates MH(zk)

n , simulating every query of MH(zk)

n of type < uv >2 H(zk)? by a subprogram that runs Mk on

input x1=

J(#n$1$w

) for n = 12::: until either x1=

J(< uv > $w ) or x1= J(< g(u)2v> $w ) is output. 2

We are ready to prove the main assertion of the section: RCT machine can recognize some hyper-arithmetical sets. We dene !0= 1.

Figure

Figure 1: A PCD system in dimension 2.
Figure 2: Some examples of computations by a PCD system.
Figure 3: Zeno's paradox: at nite continuous time 5x = 2:5(x+ x=2 + x=4+ :::) the trajectory is in (00), but it takes a transnite discrete time ! to reach this point.
Figure 4: Correspondence between 2PDA instructions and RCT instructions. The RCT instructions corre- corre-sponding to the 2PDA instructions Push i (j)Pop i (j)Top i (j)? will be still denoted by Push i (j), Pop i (j), Top i (j)?.
+7

Références

Documents relatifs