BlflflnlMMHH HHwiHie ■MP I m I ft ^ ■ H ■ • ' 1 H 1 ; Hffitt m Bo till ■ HUinm LIBRARY OF THE UNIVERSITY OF ILLINOIS AT URBANA-CHAMPAIGN 510.84 l£6r no. 480-489 cop.3» UIUCDCS-R-71-W2 October, 1971 DEGREES OF UNSOLVABILITY IN THE THEORY OF PROGRAMMING LANGUAGES by Dennis F. Cudia ^M JHE LIE Y DF NOV 9 1972 .UNIVERSITY OF ILl IAT URBANA-CHAMPAIGN UIUCDCS-R-71-^82 DEGREES OF UNSOLVABILITY IN THE THEORY OF PROGRAMMING LANGUAGES by DENNIS F. CUDIA Department of Computer Science University of Illinois Urbana, Illinois I. Recursively enumerable problems Introduction 2 A. Halting problem 3 B. One-one and many-one reducibility 11 1. Word problem 19 2. Combinatorial systems 31 C. Predicates of formal grammars in y or n KG D. Turing reducibility and degree 0' Gk 1. Incomparable recursively enumerable degrees 71 II. Non-recursive ly enumerable problems Introduction 79 A. Jump operation 80 1. Turing machine problems in 0" B. Predicates of formal grammars in y 9h C. Predicates of type grammars in y and problems in ,M 108 SUMMARY 117 THE PREDICATE TABLE 119 REFERENCES 120 Digitized by the Internet Archive in 2013 http://archive.org/details/synchronizations483carr 2 - Chapter I. RECURSIVELY ENUMERABLE PROBLEMS Introduction One of the more important parts of the theory of computing is the hierarchy of automata and grammars ranging from finite automata and finite state grammars to Turing machines and type grammars. The object of this article is to add two more machines to the top of this hierarchy and show that the sets accepted by these machines bear an important and special relationship to the hierarchy of grammars. The relationship turns out to involve, in a natural way, the complexity of certain predicates and problems of formal grammars. These new machines are called Turing machines with oracles . In section I.D. the preliminaries concerning these machines are introduced, and in II. the sets accepted by them are examined. A survey of the paper can be made by reading the lettered sections while the numbered sections add the detail necessary for a more complete understanding. Sections B and D define successively more general concepts of reducibility from the most restrictive in section B to the most general in section D. Each of these reducibilities gives rise to an equivalence relation and the equivalence classes which result are called degrees ; one-one degrees, many-one degrees, or Turing degrees, according to the reducibility involved. The halting problem for Turing machines is discussed in section A and its generalization to the halting problem for Turing machines with an oracle leads to the definition of the jump operation in section II. A. In section C certain grammatical predicates of context free grammars are defined and shown to be recursively enumerable. Various language predicates of formal grammars are shown to be the negations of recursively enumerable predicates - 3 - Thus they are in the class ir. of the Kleene hierarchy. Examples of these predicates are emptiness, universality, subset, superset, equivalence, and empty intersection of type 1 languages. The first and the last predicates are even in tt., for type languages. A predicate table is begun in section C and extended throughout the discussion so as to keep track of the results. A. Halting problem During the year following the spring of 1935? after he received his undergraduate degree from Cambridge University, Alan Turing started to build a machine for computing an important function in number theory, _ 7 «7 "-7 the so-called Riemann zeta-function, £(z)=l+2"+3 + ^ + ... • He became interested in what sorts of numbers could be computed by such ■ a machine and more generally, what sorts of numbers could be computed by an arbitrary "automatic" machine. The results of this investigation appeared in print in 1937 and the automatic machines or a-machines, as Turing called them, have since come to be known as Turing machines . They will play a central role in our discussion. To get some idea of how a Turing machine operates we shall design one that takes two positive integers m and n as input and produces as output the sum m + n. Suppose that the integers m and n are represented on a linear storage tape by m ones followed by a blank followed by n ones followed by a blank. For example the input tape for the sum of 3 and 5 would be k - where the * is the symbol for blank. If „ e start seanning the left- most square then In order to end up with 8 ones on the tape we should proceed as follows: (i) move right one square until we are scanning the blank square, m (ii) then print a 1, ( ^t\ tt Bn m ° Ve ^ lght Until We are canning a blank square (iv) then move left one square, square, (v) erase the right-most 1, (vi) and halt. The corresponding Turing machine is (i) ^ 1 B q Q (ii) q Q * 1 q x (iii) q 1 1 R q (iv) q ± * L ^ ( v ) Ig 1 * qg (vi) ^ * H ^ ^e interpretation for each quadruple is that ^ q± and ^ are the states of the Turing machine, the third symbol in each quadruple represents the action of the machine when it is ln the state q . scanning * Qp ± ^^^ to the first two entries in the quadruple. If the third entry is a - or 1 then the machine is to print a *, i.e. erase, or print a 1, respectively. If the entry is R or L then the machine is to move one square to the right or one square to the left. An H means to halt. The last entry of a quadruple is the new state the Turing machine assumes after executing the action of the quadruple. - 5 - Several observations need to be made concerning the Turing machine just given. First note that the input and output tape contents as well as which square is initially scanned influences the form and number of the quadruples making up the machine. Note also that every possible pair of state q , q, , q~ and tape symbol 1, * occurs as the first two components of a single quadruple of the machine. Thus the process is completely deterministic. Finally the process is clearly quite different from the operation of a hardware adder in an actual digital computer. Actually the use of quadruples is also different from Turing's original conception in that he used quintuples but ever since the paper by Emil Post 19^7 "the use of quadruples has been more common. The definition of a Turing machine closely parallels the example just given. Definition . Let S be an alphabet of two tape symbols S„. S . The symbol S Q stands for a blank and the symbol S stands for a 1. A finite set of state symbols is given: q , ..., q where K > and q^ is known as the initial state. Then a Turing machine is any nonempty collection of quadruples each of the following form: (1) (q ± , Bj, L, q n ) (2) (q ± , S., R, q n ) (3) (q., S., S n , q n ) or (k) (q., S.., H, q R ) . Furthermore each pair q , S of state and tape symbol occurs as the first pair of symbols of a single quadruple in the collection. Therefore the - 6 - Turing machine will consist of exactly 2(K + 1) quadruples. A Turing machine is given as input a linear storage tape consisting of a finite number of squares each of which contains either a blank or a 1. The Turing machine is started in its initial state o^ scanning the left-most square of the tape and proceeds to execute the appropriate quadruples in its collection. By appropriate is meant that when the machine is in the state q. and scanning a square containing the symbol S., the single quadruple in the collection whose first pair of entries is q., S . is executed. This execution involves moving one square left or right for quadruples of type (l) or (2), respectively, printing the symbol S m in the scored square (printing S Q means erasing) for type (3) quadruples, or halting for type (k) quadruples. After executing the quadruple the machine assumes the state % given as the last entry in the quadruple. If at any time during the operation of the Turing machine it attempts to move off the left end of the finite storage tape by means of a type (l) quadruple or the right end by a type (2) quadruple, a blank square is added to the left or right end of the tape respectively. The Turing machine continues operating in this manner until it comes to a quadruple of type (h) at which time it halts. If the Turing machine halts then its output is the final contents of the tape. In the example Turing machine given above the input was the tape and the output was the tape D - 7 - 1 1 1 1 1 1 1 1 * * Of course a Turing machine will never halt if it has no quadruples of type (k) . But it may never halt even if it does have halting quadruples because it may never reach any of its quadruples of type (k) . It might be conjectured that by starting with all the quadruples of type (h) and working backwards to the quadruples of the initial state that one could determine whether or not a given Turing machine started on a given input tape will reach one of its type (K) quadruples. And for some specific cases this can be done. For example, by analyzing the example Turing machine given above it can be seen that this machine, when started on any finite tape, will always eventually reach its type (k) quadruple and halt. But it is impossible to generalize this analysis so that one can decide for an arbitrary Turing machine started on an arbitrary finite tape whether or not the machine ever reaches one of its type (k) quadruples, that is, whether or not the machine eventually halts. The remainder of this section will be devoted to proving this assertion. There are two keywords in the assertion: one is "decide" and the other is "arbitrary". Definition . Let T be a collection of finite tapes of blanks and ones. By a problem about T is meant a function which assigns the value YES or the value NO to each member of T. A problem P about T is decidable provided there is a Turing machine M such that when M is started on a tape t e T, M will halt on a 1 if P is YES for t and M will halt on a blank if P is NO for t. The Turing machine M is said to decide the problem P. - 8 - One way by which a collection of quadruples defining a Turing machine can he encoded onto a finite linear tape is to first order the quadruples by sorting on the first two components of the quadruples. That is, (q., Bj , ..., ...) precedes ( V S^ ..., ...) provided i < m , and if i = m then J < n. The example Turing machine would then be ordered as i * ! q x 0*11 * * 1 * 1 q lRq O 01R0 * 1. 1 1 -1 * * q l * L ^2 1*L2 1*11*11 q l 1 R ^ ° r 1 1 R 1 ° r 11111*1 q 2* Hq 2 2 * H 2 11*1111*11 q 2 1 "q 2 21*2 111**11 where print * or 1 is encoded as * * or 1 *, move left or right is encoded as 1 1 * or 1 1 1 *, and a halt instruction is encoded as 1 1 1 l *. B y putting four *'s between successive quadruples/ it is clear how this sequence of quadruples can be encoded on a rather lengthy but nevertheless finite tape, Having fixed the definition of a decidable problem a simple example of an undecidable problem can be given. Definition. Let S be the collection of all finite tapes of blanks and ones each of which is a standard encoding of all the quadruples of some Turing achine . The blank halting predicate for Turing machines , denoted by K Q , assigns the value TRUE or FALSE to an element s in S depending on whethl or not the Turing machine M whose quadruples are encoded on s eventually halts on a blank when M is started on the tape containing its own encoding. The Wank halting problem for Turing machines , denoted by^, is the problem of etermining of an arbitrary Turing machine M whether or not K is TRUE m d for M. 9 The definition of ^L has been arranged so that the following fact is almost immediate . Fact , ^l is an undecidable problem . If ^L were decidable let M be a Turing machine that decides 9?L and start M on its own finite tape. Acting in its assumed capacity as a deciding Turing machine for *frL, M must either halt on a one or on a blank. But as a question in tlL, M must either halt on a blank or not halt on a blank when started on the finite tape of itself. If M, as a question in "flu halts on a blank, then M, when deciding this, will halt on a one, Contradiction! If M, as a question in %L does not halt on a blank, then M in its deciding capacity will halt on a blank. Contradiction! Since these contradictions stem from the assumption of the existence of the deciding Turing machine for °fTL, it can be concluded that no such machine exists and that therefore the problem^ is undecidable. There are some observations that can be made about the argument just given. First note that the phenomenon of self -reference is involved since a deciding Turing machine has to decide about itself. Once the definition of a deciding Turing machine is given, a problem which is undecidable by that definition can be given. Thus, if the definition of a deciding Turing machine were such as to require it to halt on a blank to indicate YES and on a 1 to indicate NO then a non-blank halting problem could be formulated and shown to be undecidable in a way analogous to that forTWg. The discussion continues with the definition and proof of the undecidability of a problem that is independent of which of the two above definitions of a deciding Turing machine is chosen. - 10 - The halting proble m for Turing machines is the oldest and most famous undecidable prohlem in automata theory. A closely related problem, the "printing prohlem" for Turing machines, was first formulated and proved undecidable by Turing l 93 6- 7 . By f emulating this problem in the first order predicate calculus Turing was able to show that the decision problem for that calculus was undecidable. The question of the decidability of the decision problem for the first-order predicate calculus, i„ German the Entscheidungspro^em, was declared by the German mathematician, David Hilbert (after whom the Hilbert space used in quantum Mechanics is «d) to be the central problem of m athe m atical logic, one can i m agi„e the impact Turing's paper, written when he was 23 years old, must have had on the mathematical world. A similar conclusion concerning the Entscheidungsproblem was independently reached by Alon Z o Ghurch 1 93 6 fiction. Let T be the collection of all finite tapes of blan.s and ones and recall the set S of standard encodings of Turing Machines of the definition p. 8. Let R = S-T be the set of tapes st for„ed by concatenation of "« B, t e T. The halting predicate for Turing Machines , denoted by K assign, the value TR» or EALSE to an element r = st in R depending on whether or not the Turing Machine M whose quadruples are encoded on s eventually halts after being started on t. The balti^ problem for Turing Machines . Quoted by % , U the probleM of determining for an arbitrary pair of Turing machine M and fimtp f^-n^ +■ ~-p vn Unite tape t of blanks and ones whether or not K is TRUE for that pair. The undecidability of tn is Pa cii lr a u n -u y 01 m^ is easily shown by using the fact of the undecidability of ^ Our strategy will be to Map % into % , tha t -Il- ia each Turing machine M will be mapped into a pair M', t in such a way that M has the blank halting property if and only if M 1 started on t eventually halts. Thus the decidability of 191 would imply the decidability of ^L which would contradict the fact previously established. Now given any Turing machine M obtain another Turing machine M 1 by substituting for each of the type (h) quadruples of M of the form (q_. , S , R, a ) the quadruple (q., S , S , q. ). Note that M' can halt only on a blank. Thus M when started on the finite tape t on which are encoded all of its quadruples will halt on a blank if and only if M' started on t eventually halts. Theorem . The halting problem for Turing machines TIL is undecidable . It is clear how the proof of this theorem could be changed so that the undecidability of a non-blank halting problem would imply the undecidability of 97L.. One need only change the appropriate type (k) quadruples of M so as to obtain another Turing machine M' such that M halts on a non-blank symbol if and only if M' halts. Thus the undecidability of <#L is independent of whether a deciding Turing machine is required to halt on S n to indicate YES and on S to 1 o indicate NO or vice versa. B. One-one and many-one reducibility The great American logician and mathematician Emil L. Post [1897-1954] received his doctoral degree in 1920 from Columbia University where he was a student of Cassius J. Keyser who had himself received his Ph.D. in mathematics from Columbia University in 1902. The title of Post's dissertation was "Introduction to a general theory of elementary propositions" and it appeared in the American Journal of Mathematics in 1921. During the academic year 1920-21 Post was a Jane Eliza Procter Visiting Fellow in Princeton University. From 1921 to 192^ Post was an instructor in mathematics first in Columbia - 12 - University and then in Cornell University. Post returned to New York City where he continued to teach and do research in mathematics, publishing a paper in analysis and transform theory entitled "Generalized differentiation" in the Transactions of the American Mathematical Society in 1930. In I9I+0 Post published in the same journal a massive 1^2 page paper in group theory entitled "Polyadic groups". And in 19^, in a seminal address to the American Mathematical Society, Post initiated the classification theory of recursively enumerable sets. The present section will consider two of the classification methods introduced by Post, one-one reducibility and many-one reducibility. A predicate is a function which assigns the value TRUE or the value FALSE to an element in its domain of definition. A predicate P can be thought of as a "property" and, to those elements in its domain that possess the property, P assigns the value TRUE while to those that do not P assigns the value FALSE. If d is in the domain of P then Pd means that P is TRUE for d and ^Pd means that P is FALSE for d. One-one reducibility and many-one reducibility classify predicates. Definition. A predicate P is many- one reducible to the predicate Q provided there is a Turing machine which when started on a finite input tape r in the domain of definition of P will halt with a finite output tape s in the domain of definition of Q such that Pr if and only if Qs. This situation is denoted by P ^ t^. Those predicates that are one-one reducible to the halting predicate K form an important class. Definition . A predicate is recursively enumerable provided it is one-one reducible to K, the halting predicate for Turing machines. Thus the blank halting predicate for Turing machines is a recursively enumerable predicate. On the other hand the predicates -iK and — »K, representing the negations of K and K, are not recursively enumerable. For if they were the problems <%. and %^ would be decidable by means of the following explicit procedure. Take an arbitrary element s in the domain of K and use the Turing machine given by K <, K to transform the element s into the question of whether or not a Turing machine M halts for an initial tape t-. Use the Turing machine given by the assumption-iK < K to transform the element into another question of whether or not another Turing machine M halts for another finite initial tape t . Then start M on t and M on t and observe which one halts. Since precisely one of K and -iK is TRUE for s, exactly one of M and M will halt. If M n halts then K s whereas if MJialts then -iK s. Since this explicit 1 o 2 o * procedure could be carried out by a Turing machine it would follow that ^/L is decidable. This contradicts the fact p. 9 and a similar argument will show that the assumption of the recursive enumerability of -iK implies the decidability of ^ Fact . The predicates -tK and -»K are not recursively enumerable predicates . Those predicates P such that both F and -iP are recursively enumerable are called recursive predicates. Clearly the problems associated with whether or not P is TRUE and whether or not -.P is TRUE are decidable. Summarizing then, - lit - the recursive predicates are those predicates P such that both P and ^ are recursively enumerable. There are recursively enumerable predicates whose negations are not recursively enumerable. There are also non-recursively enumerable predicates whose negations are recursively enumerable. Finally it will be shown in II. that there are non-recursively enumerable predicates whose negations are also non-recursively enumerable. But for now let us examine the concept of the recursive enumerability of predicates from a different point of view. The concept of an automaton accepting, a set of tapes is familiar in automata theory. F1 „ it e automata accept regular sets ; pushdown storage automata accept context free languages; linear bounded automata accept context sensitive languages. And a Turing machines aec^ts a type language by halting for precisely those input tapes that are sentences in the language. ' But each language is the truth set of a predicate, viz. the predicate whose domain is the set of all finite strings on the terminal vocabulary and whose assignment, of the value TRUE is m ade to exact lv +h„. * ■ mane to exactly those strangs that are sentences in the language. In fact the concept of a recursively enumerable predicate coincides with that of a type language provided an additional retirement is »ade of the domain of definition of a predicate. This requirement will be satisfied by all the predicates we discuss. EaHirement. The domain of definition of each £ redicate is ac^ted ^ a Turing machine M, depending on the predicate . As observed by Turing l 93 6- 7 there is a "universal" machine, which when supplied with suitable instructions, will imitate the behavior of any other These instructions include the collection of quadruples of the Turing machine and the finite initial tape. The halting predicate for such a universal machine is clearly K , the halting predicate for Turing machines. Now given - 15 - a recursively enumerable predicate P, the universal machine could first imitate the Turing machine accepting the domain of definition of P, second, the Turing machine involved in the one-one reduction P<, K, and finally the behaviour of the pair of Turing machine and initial tape into which each element of the domain of P was mapped by the second Turing machine. Then it is clear that the set of elements for which P is TRUE is exactly the set of finite input tapes for which such a universal machine halts. We have just proved the "only if" part of the following theorem whose "if" part is obvious from the definition p. 1$ , Theorem . A predicate is recursively enumerable if and only if there is a Turing machine that accepts exactly the set of elements for which the predicate is true . Continuing with our examination of recursive enumerability, suppose P< Q and Q, is recursively enumerable, that is Q<-,K. Then by serially operating first the Turing machine involved in P< Q and then that involved in Q,<,K it is clear that P<-,K. Thus any predicate which is one-one reducible to a recursively enumerable predicate is itself recursively enumerable. Fact . The predicate K is a maximal recursively enumerable predicate in the sense that if F is recursively enumerable then P< K. It has already been observed that K < K. It is also true that K< K . o-m -in o For given any Turing machine M and finite initial tape t consider the Turing machine M q obtained from M by altering all of its type (h) quadruples of the form (q i , 1, H, q^) to (q., 1, *, r) and adding the quadruples (r, *, H, r) and (r, 1, R, r) where r is a new state not in M. Then M started on t halts if and only if M q started on t halts on a blank. Now consider a Turing machine M' that in addition to the quadruples of M , contains quadruples for erasing its own standard encoding, printing out the finite tape t, positioning itself on the left-most square of t and then transferring to the initial state of M . o Then M started on t halts if and only if M' started on its own standard encoding - 16 - halts on a blank. Since the quadruples of M' could be developed from those of M and the finite tape t by another fixed Turing machine N, K< K . Thus * J -mo the predicates K and K are many-one equivalent , and therefore so are their negations -iK and -*K . If we denote by K the predicate whose domain is the same as that of K and that is TRUE exactly when a Turing machine started on its standard o encoding eventually halts, that is halts on a blank or on a one, then ? substituting the quadruples of M for those of M in M' the argument just given shows that KC.K., . Since K n is a special case of K it follows that KL, <, K. Thus the —1 lo lo T.O— 1 predicates K and K are one -one equivalent , and so therefore are their negations -iK and -iK n . lo Recall that a relation R is an equivalence relation if aRa, aRb implies bRa, and aRb, bRc imply aRc for any a, b, c in the domain of R. Definition . Two predicates P and Q are many-one equivalent provided P< Q, and Q< P. Many-one equivalence is an equivalence relation and the equivalence classes thereof are called many -one degrees . P and Q, are one -one equivalent provided P< Q and QC.P. One-one equivalence is also an equivalence relation and its equivalence classes are called one -one degrees . Note that since one-one equivalence implies many-one equivalence each many-one degree is made up of one or more one -one degrees. By virtue of the discussion following the theorem p. 15, if a one-one degree contains one recursively enumerable predicate then every predicate in that degree is recursively enumerable. A one-one degree or many-one degree that contains a recursively enumerable predicate is called a recursively enumerable one-one degree or recursively enumerable many -one degree , respectively. Notation . The set of all recursively enumerable predicates is denoted by the symbol Z . The set of all predicates whose negations are recursively enumerable - IT - is denoted by the symbol It-, • The reason for this notation is that every recursively enumerable predicate P can be put in the form (gs) R (a, x) where R is a recursive predicate. If -iQ is recursively enumerable then there is a recursive predicate S such that -iQ is of the form (=fx) S (a, x) so Q is of the form (Vx)f(a, x) where T is the negation of S and is also recursive. Note that the recursive predicates make up exactly the set £ nit, since they are the recursively enumerable predicates whose negations are also recursively enumerable. Fact . The predicate K is a maximal predicate in £ . Similarly the predicate -tK i_s a maximal predicate in II since if Pelt then ->Pe£ s_o -iP^K and therefore P 1 and a finite set {(w-^w^), . .., (w,w ' )} for N > 1 of ordered pairs of words over this alphabet. Recall that a word over an alphabet is simply a string of a finite number of occurrences of symbols in the alphabet. The empty word consists of no occurrences of symbols and is denoted by A . Empty words are allowed as components of the ordered pairs of S . The operation of the semi-Thue system S requires a word to be given, say a a a a a^ a^ a a a a . Suppose that (w ,w ' ) of S is (a a a,^, & a ) . Then S is said to immediately derive theword a 3 a 2 a 2 a 2 a l a l a 2 a 2 a i from ^ e gi ven "word by substituting for the subword a a a of the given word, the word a a . The resulting word may now be scanned for a subword w. for some 1 < ,i < N. When such a 3 subword is found, the word w.' is substituted in its place. It is not assumed that there is only one j such that w. occurs as a subword in order for the substitution of w . ' for w. to take place. There may be J J - 20 - many possible substitutions to be made in a given word with the result that many different words may be immediately derivable from a given word. In particular this will happen if A is the first word of some pair, for then the second word of the pair may be substituted to the left or to the right of any symbol in the word. If a is the second word of a pair (w.j a) ? any occurrence of w . in a word may be omitted so as to ijnmed- iately derive the word that does not contain that occurrence of w.. Thus J "erasing" is allowed in arbitrary semi-Thue systems. We can now formulate an important predicate in algebra, topology, and the theory of computing. Definition . The word predicate for semi-Thue systems is denoted by W and has as its domain of definition the set of all triples S, t, v consisting of a semi-Thue system S, and words t, v on the alphabet of S. The predi- cate W assigns the value TRUE to precisely those triples S, t, v for which either t=v or there exists a finite sequence u., , u oS .., u f or m > 2 of 1 2 ' m — words on the alphabet of S such that t=u-, u =v and S immediately derives u. n from u. for each j=l, .... m-1. The word problem for semi-Thue systems is denoted by W and defined to be the problem of determining of an arbitrary triple in the domain of W whether or not W is TRUE for that triple. Before proving the unsolvability of ^f it is well to reflect o on some of the subsequent developments stimulated by the paper of Post 19^+7. A Thue system is a special type of semi-Thue system that, along with an ordered pair (w., w.'), also contains the "inverse" ordered J -J pair (w . T , w.). Therefore every Thue system is a semi-Thue system. J J It is customary to call the unordered pair w., w.' of a Thue system J J a relation , to denote the pair by w .=w . ' , and to speak of the finite J J set of pairs as the relations of the Thue system. A group -Thue system - 21 - is a special type of Thue system in which each element a. of the alphabet has an "inverse" element a7 so that the alphabet is of the form fa., a. , i 11' . . ., a^., a" } for M > 1, and for each 1 < i < M, a.aT = A and a. a. = A are relations of T- Therefore, each group-Thue system is a Thue system. The algebraists usually call the subset fa., ..., aJ of the alphabet of the group-Thue system T, the generators of T. The alphabet of a semi-Thue system generates a free semigroup •while that of a group-Thue system generates a free group. Definition . For any semi-Thue system S the free semigroup generated by S is the set of all words on the alphabet of S, including the empty word A, with semigroup multiplication given by concatenation of words and with A as the identity of multiplication. Each word w / A in the free n. n i k semigroup generated by S can be written in the form a. . . .a, where a., ..., a are in the alphabet of S, n., ..., ri are positive integers, and, for any element a. in the alphabet of S and positive integer n, a. is' a. a. ... a. . Given any group-Thue system T let T' be the group-Thue system whose alphabet is the same as that of T, (a.,a7 , ..., \,>a~ ] and whose relations consist only of a. a. = A and aT a. = A for all 1 < i < M. Then the free group 11 ii — — — — generated by T is the set of equivalence classes of the equivalence relation between words defined by w- [ = w 2 if and only if the word predicate W is TRUE for the triple T', w^, w^ . Each word w / A in the free semigroup generated by T can be written in the form n. n l k a. ... a^ where n.^, ..., n^ are nonzero integers, positive and negative, and for - 22 -n . any positive integer n, a is n By using the relations off it is clear that each equivalence class in the free group has a unique reduced word in which any two successive elements 0. n a., ..., a^ in the expression a. 1 ... a^ are different. Of course, the reduced word of the equivalence class containing A is A itself. The set of reduced words is frequently identified with the free group generated by the group-Thue system. The use of the relations of a Thue system to divide the free semigroup of words into equivalence classes has wide applicability. For a Thue system T the equivalence classes form a semigroup which is said to be finitely presented by T. For a group-Thue system T the equivalence classes form a group which is said to be finitely presented by T. A group G is a finitely presented group provided it is isomorphic to the group finitely presented by some group-Thue system, Given a group-Thue system T with relations w. = w^ the relations of T may be written w.w^ = A by multiplying by the inverse of W J. Let N be the smallest normal subgroup of the free group F that contains all the equivalence classes of F containing w.w" 1 for some i. Then it can be shown that the group finitely presented by T is isomorphic to the quotient group F/N. Definition . The word problem for finitely presented groups is to determine of an arbitrary group-Thue system T and word w on the alphabet of T whether or not the word predicate W is TRUE for the triple T, w, A. Not only was the word problem for semi -Thue systems shown to be unsolvable but Post 1 9 U 7 exhibited a particular Thue system U for - 23 - which the problem whether or not W i s TRUE for U and an arbitrary pair of words w.,w p is unsolvable. An independent proof of this result was also give in 19^7 by the Soviet logician and mathematician A. A. Markov. It was known that any finitely presented group can be the fundamental group of a compact, orientable, four dim en sional manifold. Therefore unsolvability results about finitely presented groups might also be transformed into unsolvability results in topology. A world wide effort was mounted to extend the unsolvability proof for the word problem for Thue systems to that for finitely presented groups. In 1950 A. M. Turing made a large step in this direction by extending the proof to show that the word problem for finitely presented semigroups with cancellation was unsolvable. Finally in 1955 the Soviet mathematician P. S. Novikov extended Turing's proof so as to exhibit a specific group-Thue system whose finitely presented group had an unsolvable word problem. Independently the American mathema- tician W. W. Boone in 195^-57 using different methods also exhibited a specific group-Thue system with an unsolvable word problem. The isomorphy problem for finitely presented groups is to determine of two arbitrary group-Thue systems whether or not they finitely present isomorphic groups. Given any group-Thue system T, a compact, orientable, triangulable, four dimensional manifold M_ may be constructed whose fundamental group is isomorphic to the group finitely presented by T. By analogy with the situation for groups, the manifold M„ is said to be finitely presented by T. The construction is such that two arbitrary finitely presented manifolds ]VL 1VL, are homeomorphic if and t only if the groups finitely presented by the group-Thue systems T, T are isomorphic. Since the isomorphy problem for finitely presented - 2k - groups is unsolvable, A. A. Markov was able to announce the unsolvability of the homeomorphy problem for finitely presented manifolds of dimension greater than three. The announcement was made at the International Congress of Mathematicians held in Edinburgh, Scotland, in 1958. This brief sketch of developments in algebra and topology stimulated by the work of Post and Markov in 19^7 must suffice for the present. More will be said in section D. 1. and the developments in computer science will later be examined in much greater detail. The reader is probably familiar with the concept of an algorithm as a finite set of directions which, when applied to an input will produce an output after a finite number of steps, and never at any stage of the execution of the algorithm is there any choice of what the algorithm is to do next. If different inputs give rise to different outputs then, in analogy to the situation for one-one reducibility, the algorithm is said to be a one-one algorithm . Theorem . (Post I9I+7) There is a one-one algorithm such that when the in P ut i£ ££ arbitrary Turing machine M the output is a semi-Thue system S„ such that M K(M) < x W(S M ). That i£> i^£ halting predicate for M is one-one reducible to the word predicate for s ™- M Proof. If the states of M are q^, ..., q R f or K > let the alphabet of S be the K + 5 symbols c^ ... q K * 1 h s The essence of the proof is to define S M so that M accepts the finite tape t of blanks and ones if and only if W is TRUE for s^ hq^th, hsh. - 25 - Starting from the word hq th, S -will exactly imitate the operation of M. The symbol currently being scanned by M will be the symbol just to the right of the single occurrence of a state symbol q . , representing the current state of M. Define the ordered pairs of S by first con- sidering the quadruples of M of the initial state q . If the quadruple beginning q , * is a move left quadruple of the form (q , *, L, q ) then the following nine ordered pairs are included in S : (* *? *? q^) then include the pair (q o *, q„*) while if it is of the form (q , *, 1, q ) then include the pair If the quadruple beginning q , * is a halt quadruple of the form (q , *, H, q ) then include the following five ordered pairs in S : (%*, s) (*s, s) erase to the left (Is, s) (s*, s) erase to the right (si, s) Now consider the second quadruple of M beginning q , 1. If this quadruple is a move left quadruple of the form (q , 1, L, q ) then include the following three pairs in S : (*q o l, V l) (l4 o l, V l) (hn 1. hn *1 ) . h nn f.hp 1 pft - 27 - If this quadruple is a move right quadruple of the form (q , 1, R, q^) then include the following three ordered pairs in S M : (q o l*, 1^*) (q o ll, 1V> (q lh, lq *h) h on the right If the quadruple is a print quadruple of the form (q , 1, *, q ) then include the pair while if it is of the form (q , 1, 1, q )then include the pair (* i, v). If the quadruple is a halt quadruple of the form (q , 1, H, q ) then include the following five ordered pairs in S M (q Q i, s) (*s, s) erase to the left (Is, s) (s*, s) erase to the right (si, s). Now consider the quadruples of M of the state q if K > 1. Take the quadruple beginning q , * and consider the various cases that might arise in the same manner as was done for the state q and the quadruple beginning q Q ,*. Of course the symbol q will replace q in the first - 28 - component of the ordered pairs thus included in S . Next consider the quadruple beginning q.,,1 and include the corresponding pairs in S as was done for the quadruple q_, 1 with, however, the symbol q replacing the symbol cu in the first component of the ordered pairs thus included in S . If K > 2, then proceed to the consideration of the quadruples of the state q p . Continuing on in this way until the states of M are exhausted the semi-Thue system S is completely defined. It is clear that different Turing machines M and M' given as input to the algorithm will give rise to different semi-Thue systems S and S , as output • Therefore, the algorithm is a one-one algorithm. So closely does S imitate the behavior of M that once it is started on the word hq_th there is exactly one ordered pair that is applicable at each stage of the operation of S... The reason for this is that M itself is a deterministic device. M Now suppose that M halts when started on the leftmost square of t . Then a halting quadruple of M is eventually encountered and hence the symbol s will eventually be inserted. Once s is inserted the erasing rules are applied so as to derive the word h s h. Conversely, since the symbol s only occurs in pairs corresponding to halting quadruples, the only way s can be inserted in a word is if M reaches a halting quadruple. Therefore, M halts when started on t if and only if S„, ultimately derives the word h s h from M the word hq th. Since different tapes t ^ t p give rise to different words hq^h and hq^h, K(m) < W ( S M ) and the theorem is proved. I 29 - Before leaving the construction of S , an observation concerning Turing machines and type grammars will he made. Definition. A type grammar is a semi-Thue system whose alphabet has been divided into two disjunct nonempty subsets called terminals and non-terminals in the latter of which a single element has been designated as the start symbol. It is also required that the first component of an ordered pair of a type grammar be a nonempty word. Thus erasing is allowed but not spontaneous creation. If the start symbol of a type grammar G is designated by S then a sentence of G is a word w (possibly A) on the terminals of G for which W is TRUE for the triple G, S, w. The language generated by G is the set of all sentences of G. - 30 - Given a Turing machine M form the type grammar G whose terminals are * and 1 and whose nonterminals are the K + 5 symbols q^ ... q K r s h S where cu, . .., q for K > are the states of M. Let S be the start symbol of G.. and let the ordered pairs of G., be the following: (S, hsh) inverses of the ordered pairs of S,, M (ha^j erase left h (rl, lr) cross over to right h (r*, *r) (rh, A) erase right h and r Then L(G„) = T(M), the set of finite tapes of blanks and ones accepted by M. The truth of this equality rests on the observation that once hsh is immediately derived from the start symbol S, the semi-Thue system S may be run "backwards" so as to ultimately derive the word hq^th. Recall that once S is started on the word hq^th there is exactly one ordered pair of S that is applicable. Hence, there is exactly one ordered pair of G that can reverse the operation of that ordered pair of S . Thus, G will ultimately derive the word hq^th after which the last four ordered pairs of G will erase hq_, move right, over the tape t, to erase the righthand h, thus leaving t as a sentence in the language of G M « We shall summarize this in the following corollary. Corollary . There is a one-one algorithm such that when the input is an arbitrary Turing machine M the output is a type grammar G such that L(G M ) = T(M). This is , the language generated by CL. _is_ the set of finite tapes accepted by M. B.2. Combinatorial systems For a finite alphabet A = [a.,, •••, a^.} and a positive integer m let L be the set of all lists of m nonempty words on A. Two such lists m «1 Pi • • a p m m are said to correspond provided the following combinatorial condition is met: there is a list i, j, . .., i of positive integers, each less than or equal to m, such that a. a. ... a„ = 8. 6. ... 6 fl . That is, if corresponding words in each list are concatenated, the same final word is produced. In 19^+6 Emil Post introduced the above combinatorial condition and illustrated it with the following example. Suppose the alphabet A = {a, b] and m = 3 • Consider the two lists bb b ab ba b bb If we concatenate corresponding words in each list in the order 1, 2, 2, 3 then the same word will be obtained, namely, bbababb . Therefore, these two lists correspond. Note also that if two lists correspond, then arbitrarily long words can be obtained by repetition. Thus, concatenation of corresponding words 1, 2, 2, 3, 1, 2, 2, 3 of the two lists above produces the word bbababbbbababb . A recursive subset of L is given by a Turing machine M that, when started on an arbitrary list & of L , will halt on a 1 or * according as I is or is not in the subset. Of course, each of the elements of the alphabet A is suitably encoded as a unique word of blanks and ones so that each list I is encoded as a unique finite tape of M. - 32 - Definition. A correspondence class is a recursive subset of L for some finite m alphabet A and positive integer m. The Post correspondence predicate C has as its domain of definition the set of all triples R, £, V of correspondence class R and lists P and V in R. Given any triple R, I, P in its domain of definition, C is TRUE for R, £, V provided £ corresponds to V, otherwise C is FALSE for the triple. The Post correspondence problem is to determine for an arbitrary triple R, £, V whether or not C is TRUE for the triple. In the last paragraph before the appendix to his 19J+7 paper, Post observed that both C and the word predicate W are in the many-one degree of the halting predicate K. We shall use a proof due to Robert Floyd 1965 to arrive at a similar conclusion. Theorem. (Post I9U6, 19U7) There is a one-one algorithm such that when the input is an arbitrary semi-Thue system S whose ordered pairs are nonempty words the output is a correspondence class R such that W(S) < ± C(R g ). That is, the word predicate for S is one-one reducible to the Post correspondence predicate for R . Proof. (Floyd 1965) If the alphabet of S is the finite set A Q = {a , ..., a } then let A= [a -±> '"> v h> --' v I-* -I* + ^ + 1 and if the number of ordered pairs of S is N let m = 2M + 2N + k. Then the correspondence class R g is the subset of L m defined as follows: for each word x, including the empty word A, o.n the alphabet A Q of S define the lists l x and r by setting the first 2M + h elements of | equal to -33- |- x + -| a 1 ... a^ &1 ... a^ + + and the first 2M + h elements of £ equal to \- + x A \ ••• % a ! • • ■ \ + + If the ordered pairs of S are (a , 6 ),..., Col, 3 ) then the last 2N elements of £ are x 8 1 , • • • , 3 N •> B^ , • • • , 3 N and the last 2N elements of 5, ' are x a lS ..., \ 9 V ..., a N where w is obtained from w by replacing each occurrence of a. by a. . Since the ordered pairs of S are nonempty -words it is clear that, "with A* the set of all words on A , E s = tt x : x £ A*} u a; : x AJ} is a recursive subset of L . Different semi-Thue systems will give rise to m different correspondence classes by means of the algorithm. Hence the algorithm is a one-one algorithm. In order to show that W(S) < 0(10 suppose that xeA*. Then | — x + x + x — j can be obtained by concatenating corresponding words of % and I ' so that I corresponds to I ' . Now xx x x suppose x, y , y , ..., y and z are words of S x = y , y = z and S ± d k Ik immediately derives y. from y. so that y. = P. a. Q. J J i. J J arid J for j = 1,..., k - 1. Then concatenations of corresponding words £ and I ' , X z respectively, give rise to |— y + and |— -3k- then then then or |- y ± + ^ B ± and f- P x a± "1 l~ *1 + P l \ *L * md t- P l a i;L Q l |— y-L + y 2 + and |— y 1 + Adding corresponding words of I and I ' results in -A. Z h y x + y 2 + p 2 aBd ^ y i + F ; then then or I- y i + ^2 * P 2 % «« ^ y i + ? 2 \ ^1 + V P 2 % Q 2 + and I" y i + P 2 % *2 ? h y 1 + y 2 + y 3 + and (— y 1 + y 2 + Continuing on in this manner it is clear that the word f- x + y 2 + y 3 + f h + . . . y k _ x + z -| can he obtained hy concatenating corresponding words in I and I ' so that I X. Zi A. corresponds to 1 ' . Note that a repetition of y may be used to insure that k is an odd integer. Conversely suppose that for an ordered pair of words x, z of S, the list I corresponds to the list £ '. Then the concatenated word must begin with | — since that is the only common initial character in corresponding words of £ and SL ' . Hence the concatenated word must continue x z I — x + and, in order to have an equal number of barred or unbarred + symbols, must contain + z -| . In fact the subword beginning with | — and ending with the first occurrence of -j can also be obtained as the concatenation of corresponding words of I and I ' . For in building | — x + from I ' one of the .a. Zp Z a. must have been used unless there is simply a repetition of x. Thus concatenation of corresponding words of I and I ' respectively gives JC Zi then or -35- [— x + P. 6. and |— P n a. I- x + P n 6. Q n + and }— P i a ,- ^n 1 lil '111 + |— x + y 2 + and f- x + Hence S immediately derives y from x. Similarly in "building y from I ' one of the a. must have been used so that z 1 |- x + j 2 + P 2 and [_ x + P 2 |— x + y + P 6. and (— x + P a. and then |- x + y 2 + P 2 B i Q 2 + and |- x + P £ a ± Q, - or ■2 - -2 2 h x + y 2 + y 3 + and |— x + y g + can "be obtained by concatenating corresponding "words of & and H ', respectively. Hence y can be immediately derived from y in S. Using induction one can prove the existence of y, , y , ..., y = z such that S immediately derives y. from y. for j = 3» U,... s k - 1 so that the word predicate W is TRUE the triple S, x, z. Summarizing, W is TRUE for S, x, z if and only if I x corresponds to I ' . Since different ordered pairs of words x, z of S give rise to different lists I and i ' it follows that W(S) < C(R_) completing x z —1 S the proof of the theorem. The restriction on the semi-Thue system in the theorem that its ordered pairs be nonempty words can be removed using the following one-one algorithm. If S is an arbitrary semi-Thue system whose ordered pairs may or may not have the empty word A as a component, define another semi-Thue system S^ whose alphabet is the alphabet of S plus the new symbol *. If (w,w') is - 36 - an ordered pair of S then (**, V ) is an ordered pair of S # and for each . element a. in the alphabet of S include the two ordered pairs (*a a.*) and (a.*, *a.) as ordered pairs of S# . If * is not in the alphabet of S then different semi-Thue systems S give rise to different semi-Thue systems S# . Since a new symbol outside the finite alphabet of S can always be found, the algorithm is a one-one algorithm. Furthermore, w(s) ^ w(sj, for W is TRUE for the triple S, t, v if and only if ff is TRUE for the triple S„ *t, *v. The ordered pairs (* a ., a.*) and (a.* *a. ) of S^ may be used to "walk over" the symbols of t until * is in the position so that the ordered pair (*w, V ) of S^ may be applied, after which * can "walk back" to resume its initial position. Thus W is TRUE for S, t, v only if W is TRUE for S *t *v. Conversely, erasing all occurrences of * in a derivation in S^ produces a derivation in S except for repetitious steps. Hence W is TRUE for S, t, v if W is TRUE for S , *t *v Ao-a-in 4-p * ,• o *. • j., o^, n, -v. Again if * is not in the finite alphabet of S then different pairs t, v give rise to different pairs *t, *v. Fact. ^^ ijL a one^o^ a^^ S6mi - ThUe ^^ £ Bi £«*!* i£ a semi-Thue system S , whose ordered pairs consist ££ nonempty words such that W(S) <^ w(S^). Given two lists /, J in ^ for an arbitrary positive integer m ^ alphabet A each element of A may be encoded into a unique set of blanks and ones and the nonempty words of I followed by those of j* may be encoded on a finite tape. A Turing machine M^ can be given that will systematically check all possible concatenations of words of £ and X« and will halt if and - 37 - only if I corresponds to JL l . Since different pairs of lists will give rise to different finite tapes it follows that C(L ) theorem p. 32, and the fact p. 36 • Fact . (Post 19^7) The word predicate W for semi-Thue systems and the Post correspondence predicate C are in the one -one degree of the halting predicate K for Turing machines . After stating this fact Post observes in the last sentence before the appendix of his 19^7 paper, "This indicates how far practice lags behind theory in this field." In 1965 Donald Knuth introduced a combinatorial condition similar to the correspondence condition. Two lists £ = a , a , ..., a and £,* = (3 , Ppj •'•, P in L are said to partially correspond provided the following combinatorial condition is met : for each positive integer n there is a list of n positive integers \V X n2' '"* X nn each less than or equal to m such that the leftmost subword of length n of the word a. a. . . . a. nl n2 nn is the leftmost subword of length n of the word - 38 - P ± ^ ••• Pi ■ nl n2 1 nn Note that the elements of i and / are nonempty words so that the concatenation of n elements is at least of length n. Definition. The partial correspondence predicate P has as its domain of definition the set of all triples R, I, V of correspondence class R and lists /- and £ in R. Given any triple R, X, j£ in its domain of definition, P is TRUE for R, I, l % provided /partially corresponds to £ , otherwise P is FALSE for the triple. The partial correspondence problem is to determine of an arbitrary triple R, I, £ whether or not P is TRUE for the triple. The domain of definition of P is the same as that of the Post correspondence predicate C. The truth set of p is a subset of that of C. For if I and /} correspond then they partially correspond since arbitrarily long words can be obtained by repetition of the concatenation of corresponding words. However, although C is recursively enumerable, P is not recursively enumerable. The discussion now turns to a demonstration of this fact. First observe that given a positive integer m and finite alphabet A, a Turing machine M^ A can be designed that, when started on a finite tape on which two lists I, V in L m are encoded, will systematically generate all concatenations of n corresponding words of I and V . The M' will examine m, A the leftmost subword of length n of these concatenations to determine whether the subwords are identical. If it finds a pair of concatenations for which the subwords are identical then M^ A will generate all concatenations of n + 1 corresponding words of I and /» . Then M' will examine the leftmost ^f -Pi. subwords of length n + 1 of these concatenations to determine whether there are any identical subwords. If for some positive integer j all of the leftmost subwords of length j of concatenations of corresponding words of JL and £ are different then M^ A will halt. Thus I partially corresponds to ^ if and - 39 - onlv if M' never halts when started on the finite tape on which j£ and V m, A are encoded. Since different lists JL } JU give rise to different finite tapes, it follows that P(L ) < -iK(M« ) . v m — 1 m,A Given any correspondence class R the Turing machine that decides whether a list is in R may be combined with M' to produce a Turing machine Ml 'chat first checks whether the lists X and X' are in R. If and only if they are will Ml imitate M' „ , otherwise Mi, will go into a cycling state and never T* m,A K halt. Hence -I P(R) < ± K(M^), so that-«P, the negation of the partial correspondence predicate, is recursively enumerable. That is P is in II . In the same paper in which Knuth introduced the concept of partial correspondence, a construction similar to that in Floyd's fast proof of theorem p. "52. was used to show the undecidability of the partial correspondence problem. Thus P cannot be in Z . Theorem . (Knuth 1965) There is a one -one algorithm such that when the input is an arbitrary Turing machine M the output is a. correspondence class R^ such that K(M) <^ -»P(R M ) That is , the halting predicate for M is_ one-one reducible to the negation of the partial correspondence predicate for R^. Proof. If the states of M are q_, ..., a r for K > let A = (*, 1, q Q , ..., q R , *, 1, q Q , ..., q R , \~ , +, +} and if the number of "move left" quadruples is F, the number of "move right" -1+0- quadruples is G, and the number of "print" quadruples of M is H, then set m = 1 + (K + 1) + 6 + 3F + 3G + H. Then the correspondence class R^ is the subset of L defined as follows: for each finite tape t of blanks and ones define the list 2, by setting the first T + (K + l) elements of % equal to I- + q Q t + q Q ... q K * * 1 I + + Define the first 7 + (K + l) elements of JP , the axiom list, by a \- i Q ... q K * * 1 1 + + The last 3F + 3G + H elements of the axiom list il ' and the list l^ are obtained a t by successively examining the quadruple beginning q , *, then the quadruple beginning q^, 1, then q , *, then q , 1, and so forth up to the quadruple beginning q^, *, and the quadruple beginning q^, 1. If the examination of the quadruple beginning q. , S. shows it to be a move left instruction of ^~ J the form (q. , S., L, q ) then the following three elements are added to I ' , * q. S. 1 q. S. + q. S. i J 10 i J and three added to 2, , q * S. LlS. + q_ * S. n J Ti J Ti J If the examination of the quadruple beginning q. , S . shows it to be a move -*- J right instruction of the form (q. , S., R, q ) then the following three elements are added to % ' , a q. S. * q. S. 1 q. S. + i J i J i J and three added to £, , S. abS S ^bA A ->baA A ->bbb The language generated by this grammar is the set of words of the form (ab) X b(ba) J bbb for all I, j>0. A left-linear grammar that generates the same language has the productions S ^Abbb A ->Aba A ->Bb A -»b B ->Bab B -» ab with the additional nonterminal B. As one might suspect from this example any right-linear language can be generated by a left-linear grammar and vice versa. A generalization of the concept of a one-sided linear grammar is to allow terminals to be generated on both sides of a single nonterminal. Definition . A linear grammar is a type grammar whose ordered pairs have a nonterminal as the first component and have a nonempty word with at most one occurrence of a nonterminal as the second component. A more complex family of sets that includes the one-sided linear languages can be recognized if the Turing machine can have all four types of quadruples but always eventually halts and is restricted in the total number of blank squares that can be added to the tape during the course of a computation. A deterministic linear bounded automaton is a pair M, N of Turing machine M that always eventually halts and positive integer N. A finite tape t is accepted by M, N if and only if M eventually halts on a 1 wher started on the leftmost square of t and no more than Nltl blank squares are -1+8- - added to the tape during the computation. By |t| is meant the number of squares in t. Thus the number of squares added during the course of a computation in which t is accepted is bounded above by the linear function N |t| of the number |t| of squares in t. Given a linear grammar a deterministic linear bounded automaton can be designed that will accept exactly the language generated by it. In fact given any context free or BW grammar G such an automaton can be designed that will accept the context free language L(G). Definiti ° n - A ^^t free grammar or BNF grammar is a type grammar whose ordered pairs have a nonterminal as the first component and a nonempty word as the second component. Therefore, the productions are of the form A - w where A is a nonterminal and w is a nonempty word. 49- Context free grammars have been widely used as models of portions of programming languages. Operator precedence grammars are context free and have been extensively used in the design of formula translators for FORTRAN compilers, A still larger family of sets that includes the context free languages can be recognized by merely requiring that the accepting machine be a Turing machine that always eventually halts. Then the Turing machine halts on a 1 to accept the tape t and halts on a * to reject t, once it has been started on the leftmost square of t. The machine can print on and enlarge its tape without limit. Under these conditions a very general family of sets that includes the type 1 languages can be recognized and accepted. Definition . A type 1 grammar is a type grammar such that the second component of each ordered pair has an equal or greater number of occurrences of symbols than the first component of the pair. Thus ifw-*w' is a production of a type 1 grammar, the lengths Jw| and |w' J of w and w' satisfy < |wj < |w' | . Note that if a predicate P is defined to be TRUE when and only when a finite tape t is an encoding of a sentence of the type 1 grammar G then P is a G recursive predicate. Thus p«E nn G 1 1 according to the observation preceding the fact p. 17 . If the accepting machine is simply a Turing machine that may or may not halt when started on a finite tape then a still larger family of sets can be accepted. Acceptance of a finite tape t is still defined as halting on a ] when the machine is started on the leftmost square of t. However, since the quadruples of any Turing machine can be altered to obtain another Turing machi that halts on a 1 if and only if the first halts, or, vice versa, halts if and -50- only if the first halts on a 1, acceptance can be defined simply as the halting of the machine after it has been started on the finite tape t. According to the corollary p. 30 the family of sets accepted by Turing machines is contained in the family of type languages. That these families are actually the same can be seen by starting with an arbitrary type grammar G and designing a Turing machine M that, when started on a finite tape t, will systematically G generate all encodings of sentences of G and compare them with t. If NL generates a sentence matching t then it will halt, otherwise it will continue generating sentences and attempting to match t and never halt. In the generating and matching operations performed by M the occur - G rence or non-occurrence of a single event determines the halting or non-halting of 1VL . The event is whether a match for t is generated. This is characteristic of recursively enumerable predicates in that their truth or falsity depends on the occurrence or non-occurrence, respectively, of a single computable event. Thus predicates in Z, are distinguished while predicates in II, have truth sets that depend on the non-occurrence of a single computable event . Parsing is a fruitful source of recursively enumerable predicates. While the generation of a sentence in a language L(G) begins with the start symbol of G and proceeds by the application of ordered pairs of G to ultimately derive the sentence, parsing is the inverse process which begins with a sentence in L(G) and by the appropriate substitution of first components for second components of ordered pairs of G eventually works its way back to the start symbol of G. For example consider the sentence ababbbabababbb in the language of the right-linear grammar of example ^•h'J. Using horizontal lines to represent terminals previously generated, its generation proceeds by the immediate derivations: -51- s a b S — I a b S b A I b a A 1 b a A i b a A J, b b b 1 ababbbabababbb Its parsing would begin with the sentence, that is, the last' line and. work its way back to S. Note that since terminals are generated from left to right, parsing reduces the sentence to S from right to left. One can also reduce the sentence from left to right by using the productions of the left-linear grammar of example p. 47- Its parsing then is the following inverse sequence of immediat derivations: ababbbabababbb T a b Bab 2. Bbl A b a -£- A b a 3- T Aba — A b b b The parsing of a sentence is always relative to a grammar and its ordered pairs or productions . Consider the following context free grammar whose language is a subset of the arithmetic expressions of FORTRAN. Example . The start symbol is S, the nonterminals are S, T, P, the terminals are + - * / ( ) a b, and the productions are : -52- S " S + T T_T*P P-,(B ) S -S-T T ^ T/p p _ )a One of the sentence, of this grammar is b*a/(a + b) and the ^^ ^ is a left to right parse of it. b * a / ( a + b ) ■n T T * a -^ j * p 1 T T l/(al T / ( P 1 T / ( T I r/(sl T / ( S + b t T / ( S + P L T / ( S + T - T / ( S ) T / P T S Note that the left to right parse of a sentence is actually the inverse of the seance of immediate derivations in which the rlghWt nonterminal u ^ replaced using a production of the grammar. * le " t0 rlght Parse Kil1 te °" -odel of the compilation process. ■If there is a sentence in the l a ngu a ge L(G) for which there is more then one left to right perse then the grammar is said to he amhiguous. Ambiguous sentences in a programming language cause trouble because the meaning intended by the user may differ frnm fh Q + «-p +v, j -l-l-lci irom that of the compiler writer. -53- Definition. The rightmost generation of a sentence in the language of a context free grammar G is that sequence of immediate derivations beginning with S, the start symbol of G, and ending with the sentence, in which only the rightmost nonterminal is replaced in each immediate derivation. The left to right parse of a sentence is the inverse sequence of the rightmost generation of the sentence beginning with the sentence and ending with S. The context free grammar G is ambiguous if there is at least one sentence in L(G) for which there is more than one left to right parse or, equivalently, more than one rightmost generation. Beginning with a context free grammar G a Turing machine ]VL can be specified that will systematically generate and store rightmost generations of sentences in L(G) . As each sequence of rightmost generations is obtained the sentence generated will be checked with sentences obtained from previous gener- ations. If and when some sentence is discovered that has two distinct rightmost generations M will halt. Otherwise M will continue to generate rightmost G G generations and search its storage tape forever. Since the assignment of M n to G may be made in a one-one algorithmic manner the following fact can be stated Fact . The ambiguity predicate , defined for all context free grammars G as TRUE if and only if G i_s ambiguous, is recursively enumerable and therefore in E . As early as i960 it was realized by Robert Floyd that the ambiguity problem was unsolvable . In a private communication to E. Shamir, it was observed by Floyd that this unsolvability result easily followed by using a method developed in a paper by Y. Bar-Hillel, M. Perles, and E. Shamir 1961. The method associated a linear grammar to every pair of lists of m nonempty words on a finite alphabet. Suppose that a and p are two such lists and that the ter- minals * and 1 are not in the finite alphabet. Then form the linear grammar G(a,3) whose productions are: ■5*f- s-s s - s l s o - ^fPl s 1 - i*s lPl • ■ s l - u * s lp 2 • J- 1 m s o~* S -» * If a corresponds to p so that then x*»...iV^...a t . 1 V.. 1 JnS lPr .» is an ajnbiguous sentence in the language of sf„ a l ,„ . . "«uage 01 b(a,pj. Conversely if 0(a a) is ambiguous, then the languages generated by the first anrt ,. I , productions of G(a fi) must have . COlUI ° nS ° f the u\u,,p) must nave a common sentenop tv,-?* „ be of the fon iV-.^W a rv • +! " " "^ form iV. l^l 1 ^ 6 s * \' * M 6 f " St C ° 1Umn ^^ and ° f «» correspond to ft ™ J 4 " "^ C ° 1Um " lm *»*'- Th "efore a mU st It I: w • aSSOCiati ° n ° f thS """ " G ^> *° *» pair of Usts w was done ln a one - one algorlttalc manner . R ls Me to c, implying the following fact. univalent fist ('^^)£i.o aS:2S . afi! ^ £iaa .^^ E ^ linear grammars . £ — ■ — It is interesting to observe that the dignity predicate for one-sided linear gr-ar. i s recursive but when generation is allowed on both sides as „ ^ ear g _, thus allowing self-embedding, the problem becomes undatable. This phenomenon will be seen many times. In the left to right parse of the sentence b*a/ (a + b) on r> SP the characters appearing to the left of the vertical arrow are In a pill stack That is, terminals and nonterminals are placed on the stack on a last-in first- out "basis. Furthermore the only way a nonterminal can appear on the stack is when it is substituted for the righthand side of a production that appears on the top portion, that is, the rightmost portion of the stack. This substi- tution is what makes parsing the inverse of generation, whereas in generation the second component is substituted for the first, in parsing the first com- ponent is substituted for the second. On examining the productions of the grammar of the example p. 51 it becomes clear that vhen the righthand side of a production occupies the top of the stack, then it is only necessary to examine a single character to the left of the righthand side and the currently scanned character on the input string in order to determine whether to parse the righthand side or put the currently scanned character on the stack. This context free grammar is an example of a bounded right context grammar with left bound 1 and right bound 1. The following definition due to Floyd 196^ gives the situation in general. Definition . Let G be a context free grammar. Suppose at each stage of a left to right parse of any sentence in L(G) it can be determined whether to substi- tute the nonterminal lefthand side for the righthand side of a production on the top portion of the stack, or whether to transfer a single character from the input string to the top of the stack. And suppose that this determination can be made by examining at most j characters below the righthand side in the stack and looking ahead at most k characters on the input string. Then G is said to be a bounded right context grammar with left bound j_ and right bound k or G is BRC(j,k) . By showing that there are twelve different ways in which a right- hand side may be incorrectly parsed on the stack and observing that each of the twelve is a decidable relation, Floyd was able to prove that for a fixed j -56- and k, the problem of whether a context free grammar isBRC(j,k) is decidable. Since G is a bounded right context grammar if and only if there exist non- negative integers j and k such that G is BBC(;j,k) the following fact can be stated. Fact. (Floyd 196^) The bounded right context predicate for context free grammars is recursively enumerable and therefore in X, ♦ Using the linear grammar G(a,P) previously defined from the lists a and p, and the undecidability of the partial correspondence problem proved in theorem p. 39 > Donald Knuth 1965 was able to show that the bounded right context problem for context free grammars is undecidable. Recall that sentences in the language of G(q,P) are of the form l i *...r 5 *l 1 **a. a a„ or l i *...l J *l 1 **p. 6....P . 1 J £ The first parsing decision must be made at the second consecutive * whether to replace * by S or S . If the former is decided then parsing must continue by the productions of the first column of G(a,P). While in the latter case parsing must proceed by the productions in the second column of G(a, p) . If the lists a and p partially correspond then for any positive integer k there are sentences of G(u,P) for which it is impossible to determine how to parse the second consecutive * by only looking k characters beyond it. Thus G(a, (3) is not a bounded right context grammar. Conversely, if a and p do not partially correspond then for some positive k the first k characters of the words concatenated from any k corresponding elements of a and (3 must differ. Hence by looking k char- acters beyond the second * of a sentence in L(G(^ f3)") it can be determined whether to parse it as S or as S . Therefore G(q,P) is BRC(0,k). Hence a and p do not partially correspond if and only if G(o,p) is a bounded rig ht - 57 - context grammar. K is one-one equivalent to ->P, implying the following fact. Fact. (Knuth 1965) K is one-one reducible to the bounded right context predi- cate for linear grammars . A generalization of the concept of a bounded right context grammar was introduced in the paper of Knuth 1965 mentioned above . He noted that some grammars that intuitively can be parsed from left to right by looking k char- acters ahead without backtracking are not BRC(j,k) for any j^O. Example. The start symbol is S, the nonterminals are S, A, the terminals are ( ) a and the productions are S - ( A ) A - ( S ) S ■* a A -* a The sentences consist of _a surrounded by an equal number of left and right parentheses on the left and right sides, respectively, of a_. The first parsing decision must be made when a_ is on the top of the stack. If an even number of left parentheses are below a_ on the stack then a should be parsed to S, but for an odd number, _a should be parsed to A. Note that this information cannot be obtained for every sentence by simply examining a fixed number of characters belowja_on the stack. But if a two-state finite automaton is available to keep track of the "parsing state" of the stack then the correct decision can be made. Suppose that in the left to right parse of any sentence generated by a context free grammar G the determination whether to parse or to transfer a single character from the input string to the top of the stack can be made by examining the state of a finite automaton and looking ahead at most k characters on the input string. Then G is said to be left to right translatable with k symbol look-ahead or G is LR(k) . -58- Knuth was able to show that for a fixed k > the problem of whether G is LR(k) is decidable . Fact . (Knuth 1965) The predicate defined to be TRUE for a context free grammar G if and only if there exists an integer k > such that G is LR(k) is recur- sively enumerable and therefore in Z-, • The concept of a bounded context grammar introduced by Floyd 196^ and of a bounded context parsable grammar introduced by Williams 1969 form a specialization and a generalization, respectively, of bounded right context in which the parsing sequence is not restricted to be the left to right parse. However given a fixed j and k the problems of whether a context free grammar is Bc(j>k) or whether it is BCP(j,k) are decidable. For a linear grammar the concepts of bounded context grammar, bounded right context grammar, and bounded context parsable grammar coincide. And for the linear grammar G(otP) introduced above the concepts of bounded right context grammar and left to right translatable grammar coincide. Therefore the recursive enumerability and the undecidability of all these predicates for context free grammars and linear grammars, respec- tively, follows from the facts pp. 56 , 57, and 58 • Finally, the dual defini- tions of bounded left context grammar and right to left translatable grammar were also introduced by Floyd 196^ and Knuth 1965 and similar methods suffice to prove the analogous statements concerning recursive enumerability and undecid- ability of these predicates. Let us collect these and other results to be proved later in this section in the following predicate table. Table One is an extension of a similar table that appeared in Cudia 1970 • ■59- o -p X -p (IJ d rH o 3 1-^ o l-H" ui hH UI o o o_ a u d CD C ■H H m 3 i-q o rH o /!» O H O i-q ^ ll pi i-q m o 1-5 pi 03 CD d •H o cr3 JH ft ra •H U U d -P d ra d £ d EH •H > •H fH . g l d l No- where K or -»K appears the predicate is one-one equivalent to K or~*K, respectively, for the domain of definition of the predicate given at the top of the column. A dash indicates the predicate is not defined for the domain at the top of the column. The entries -,K' and Up for type grammars are of higher degree of un solvability than Z or II and will be filled in later. As usual denotes decidability of the predicate for the indicated domain. The heading at the top of the third column makes use of the important fact proved by Knuth 1965 that a context free grammar G is LR(k) for some k if and only if L(g) is accepted by a deterministic pushdown storage automaton. For any list a of m nonempty words on a finite alphabet let G(oi) be the linear BRC(l,0) grammar S - 1 * S a a a 1 s a • 11 -* s a a 2 s a - ^ •tt s a a m s a — > * Clearly L(G(oi)) is a deterministic language and therefore its complement is also accepted by a deterministic pushdown storage automaton. Let G(a) be the LR(k) grammar that generates that complement. Given two lists Cd and p of m nonempty words let G(o:, p) be the context free grammar whose language is L(G(a)) U L(G(p)). Note that the association of the LR(k) grammars G(cc) andG"(a), and the context free grammar G(cc, (3) with the list a and the pair ot, fi, respectively, can be done in a one -one algorithmic manner. Given a type grammar G, a Turing machine IVL can be designed that will systematically apply all combinations of productions of G and check to see if any of the resulting generations end with a word on the terminals of G. -61- If such a word is found then L(G) ^ and M Q halts. Otherwise L(g) = and M Q never halts. Starting with two type grammars G and G' with the productions of G and G' on a finite tape t, M_ will check as before whether L(g) f $ and if true will go on to check whether the sentence in L(g) is also in L(G') by systematically checking all possible generations in G'. Thus M with the initial tape t will eventually halt if and only if L(G) D ICG') ^ 0. Of course the same will be true if the grammar G' is taken to be a fixed type grammar G . Thus the predicates 8, ^, and 9-1 are in II for the most general domain of type grammars. Given any pair a, p of lists, the intersection L(g(oi)) D L(G(p)) of linear context free languages is a type 1 language (even acceptable by a deterministic linear bounded automaton) that will be empty if and only if a does not correspond to p. This shows the rightmost two columns of line 8. (Scheinberg i960) Since G(a) and G(p) are linear BRC(l, 0) grammars the entries of line 9 a ^e valid. (Bar-Hillel, Perles, and Shamir 196l) Using the concept of the Post correspondence predicate with axiom of definition p. ^3 , one of the lists a may be held fixed. If G is the linear BRCfl.O) grammar O O 7/0 G(a ) then the entries of line 9-1 follow. (Bar-Hillel, Perles, and Shamir 1961) The remaining predicates of table one are concerned with either the equality of two type 1 languages or the containment of one by the other. The most important property of type 1 grammars is that their languages are recursive sets. This is because of the non-decreasing nature of type 1 productions which forces the successive generation of words whose length never decreases. As observed in the definition p. ^9 the membership predicate for a type 1 grammar is recursive. Now given two type 1 grammars G, G' a Turing machine can be given that will systematically check all words on the terminals of G to determine first if a word is in L(g) and if so, if it is in L(G')- Only - 62 - if it finds a word in L(G) that is not in L(G') will the machine halt, other- wise it will continue the search forever. Thus L(G) c L(G') if and only if the Turing machine never halts. Of course, the same is true if one of the grammars is fixed. If the equality of two languages is to be determined then the Turing machine can intermittently check whether L(G) c L(G') and L(G') cz L(G) and only if L(G) = L(G') will the Turing machine never halt. Otherwise, if the machine halts, either L(G) cj: L(G") or L(G') L(G Q ) = = L(G(a)) U l(g(p)) = L(G(a,p)) - 63 - demonstrating the entries for the context free and type 1 domains of the predicates on lines 10, 12, and 12.1. (Bar-Hillel, Perles, and Shamir 196l) The entry for the LR(k) domain of the predicates on lines 10, and 12.1 follows because when G is an LR(k) grammar and G is a fixed one-sided linear grammar, there is a context free grammar G-, such that L(G-,) = L(G„) C\ L(G) = if and only if L(G ) CL(G). Now L(G ) = is decidable showing lines 10 and 12.1. The same argument shows the one-sided linear entry for line 11.2. The one-sided linear entry for line 11.1 follows because L(G-.) c L(G) if and only if L(G n ) D L(G) = and this is decidable for context free G n and one-sided linear G. Although the LR(k) entry for line 12 must be or -iK, it is at present an open question which is the correct degree of unsolvability. - 6U - D. Turing reducibility and degree ' In the Spring of 1936, Alan Turing submitted for publication his paper entitled "On computable numbers, with an application to the Entscheidungsproblem" which subsequently proved to be his most famous contribution to mathematics. Turing spent the next two academic years at the Graduate College in Princeton University. During the second year, he was a Jane Eliza Proctor Visiting Fellow, as Emil Post had been seventeen years earlier. With the advice and assistance of Professor Alonzo Church, the work Turing did during his second year was gathered together to form his doctoral dissertation entitled, "Systems of logic based on ordinals ", In his dissertation, Turing developed a modification of the a-machines, or automatic machines, first defined in his 1936 paper. These new machines were called o-machines, or oracle machines, and, by means of them, the concept of Turing reducibility is defined. An oracle machine is distinguished from a Turing machine in that it has access to an oracle. In a certain state of the oracle machine, with a question printed on a portion of the tape, the oracle machines goes into one or the other of two states accordingly as the answer to the question is YES or NO. The decision as to which is the case is made by the oracle. - 65 - The definition of an oracle machine closely parallels the definition p. 5 of a Turing machine. However, a new kind of quadruple is allowed. Definition . Let S be an alphabet of two tape symbols S_, S, . The symbol S stands for a blank and the symbol S stands for a 1. A finite set of state symbols is given: qu, . .., q where K > and q^ is known as the initial state . Then a Turing machine with an oracle for the problem -p, denoted by-#M, is defined to be any nonempty collection of quadruples each of the following form: (1) (q., S.., L, q n ) (2) (q., S., R, q n ) (3) (q., S., S , q ) (k) (q., S Jf H, q n ) (5) ( V s y V %h Furthermore, each pair q., S. of state and tape symbol occurs as the first- pair of symbols of a single quadruple in the collection. Therefore, -£M will consist of exactly 2(K+l) quadruples. -66- A Turing machine with an oracle for a problem ~P is given as input a linear storage tape consisting of a finite number of squares each of which contains either a blank or a 1. Then PM is started in its initial state q scanning the leftmost square of the tape and proceeds to execute the appropriate quadruples in its collection. The execution of any one of the quadruples of types (l), (2), (3), or (h) proceeds exactly as for an ordinary Turing machine. Thus the Turing machine portion of the Turing machine with an oracle for "P will execute any one of the quadruples of type (l), (2), (3), or (h) . However, the oracle for "P executes the quadruples of type (5), (q. 5 S., q , q)y> » in the following manner. The oracle will examine the contents of all the squares of the storage tape that lie to the right of the currently scanned square. The oracle will determine whether that contents is of the form CURRENTLY SCANNED 1 i i for a finite tape t of the problem ~P and u an arbitrary non-negative integer. If the contents is of this form then the oracle will switch the state of the Turing machine to q or q according as the answer to the problem "P for the finite tape t is YES or NO so that the next quadruple to be executed will be of the form ( q , S . , . . . , . . . ) or ( q , S . , . . . , . . . ) respectively. If the oracle ever executes a quadruple of type (5) for which the contents of the tape to the right of the scanned square is not a tape t of "P followed by a non-negative number of blank squares, then the oracle will simply add a blank square to the right end of the tape. Then the oracle will execute the quadruple again adding another blank square, and so on. Therefore, in this event -pM will never halt. -67- Note that a Turing machine is itself a special case of a Turing machine with an oracle so that the halting problem for oracle machines is undecidable. In fact, virtually the same argument given on page 9 "to prove that tlL. is undecidable may be used to show that the problem ~PftL cannot be decided by a Turing machine with an oracle for ~P . By the notation ^77L is meant the problem correspond- ing to 9?L for Turing machines with an oracle for the problem p . Thus ■fifffL is the problem of whether an arbitrary Turing machine with an oracle for -p will halt on a blank when started on a standard encoding of its own set of quadruples. Note that the problem 97L is a subset of the problem ^ a ^ R « Now a problem P is Turing reducible to a problem 3. provided there is an oracle machine ©2.M that can decide P . Therefore, let us formulate more carefully what it means for a Turing machine with an oracle to decide a problem. Definition . A problem ~P is decidable in the problem *L provided there is a Turing machine with oracle <2-M such that 2.K can decide p . That is, when $M. is started on the leftmost square of a finite tape t then SM will halt if and only if t is a question in the problem p. Furthermore, if such is the case then HJH will halt on a 1 if the answer to the question is YES and on a * if the answer is NO. During the course of the computa- tion by S.M, blank squares may be added only to the righthand end of the storage tape. - 68 - If #M is an ordinary Turing machine so that it has no quadruples of type (5) then the foregoing definition is equivalent to the definition p. 7 of a decidable problem given earlier. The requirement that blank squares may be added only to the right end of the tape is not an essential restriction. By considering the odd and even numbered squares of a one way unbounded tape as the right and left sides, respectively, of a two way unbounded tape that has been folded over on itself, a Turing machine operating on the two way tape can be simulated by another Turing machine operating on the one way unbounded tape. Using Turing's concept of an oracle machine, Post l^kk was able to formulate the most general form of reducibility between two problems. Definition . A problem "P is Turing reducible to the problem S. provided "A is decidable in &.. Two problems are said to be Turing equivalent provided each is Turing reducible to the other. As this terminology implies, and as we shall see, Turing equivalence is an equivalence relation between problems. The equivalence classes are called Turing degrees . Notice that any decidable problem is Turing equivalent to any other decidable problem and so the decidable problems make up a Turing degree. This degree is denoted by 0. The Turing degree containing is a decidable problem. A Turing degree is said to be a recursively enumerable Turing degree or simply a recursively enumerable degree provided it contains a recursively enumerable problem. It is clear that if two predicates P and Q are one-one or many-one equivalent then the problems -p> and 5. are Turing equivalent where -^ = P and g_ = Q. In fact, only one quadruple of type (5) need be in the oracle machine that decides ~p or the oracle machine that decides 5. This is the case because according to definition p. 12 each question of -ft gives rise to a single question of 2. and vice versa. Thus the results obtained in sections B and C already give some information as to the structure of Turing degrees. In particular, all of the problems studied up to this point are recursively enumerable problems. Since any decidable problem is decidable in any problem the degree is the minimal recursively enumerable degree in the sense that any problem in is Turing reducible to any other problem. According to the fact p. 15 every recursively enumerable problem i^ has either 'P- or "A~ one-one reducible to K. Since K is Vl^ it follows that every recursively enumerable problem is Turing reducible toTlU so that 0', the degree of ffu y is the maximal recursively enumerable degree. That is, any recursively enumerable problem is Turing reducible to any problem in 0' . The discussion now turns to the existence and nature of recursively enumerable degrees other than and ' . - 71 - D. 1 . Incomparable recursively enumerable degrees . During the years 19kh, 19k&t and !9U7 Emil L. Post published three papers each of which has proved to be of lasting significance in logic, the theory of computing, and mathematics. The use of the Post correspondence problem to obtain unsolvability results in formal grammars has already been discussed in section C. The 19M> paper proved the un- solvability of the Post correspondence problem. The results established in the 19i+7 paper have been used in section B.2. and the subsequent developments in algebra and topology stimulated by it have been outlined in section B.l. However, looming over both of these papers is Post's seminal address to the American Mathematical Society in 19M+* This paper marks an epoch in logic as much for the questions Post was unable to resolve as for the classifi- cation theory he was able to delineate. The classification theory for one-one and many-one degrees and for Turing degrees has been examined in sections B and D, respectively, and it is employed extensively throughout the discussion. Post also introduced the concept of bounded and unbounded truth table reducibility in his classification theory but our discussion will make no use of these concepts. One of the questions Post was unable to resolve in the 19U+ paper was the question of whether there is, among the recursively enumerable i problems, a lower degree of unsolvability than , the maximal recursively enumerable degree, or whether they are all of the same degree of unsolv- ability. This question came to be known as Post's problem and it was to remain unanswered for twelve years until it was resolved concurrently and independently by the American logician R. Friedberg 1957 and the Soviet logician A. A.Muchnik 1956. The solution of Post's problem involved the - 72 - construction of two recursively enumerable sets A and B of non-negative integers such that neither of their decision problems was Turing reducible to the other. Definition . Given any set A of non-negative integers the decision predicate for A is defined to be TRUE for any non-negative integer n provided neA, otherwise the predicate is FALSE for t>. The decision problem for A is the problem of determining of an arbitrary non-negative integer n whether or not r\£k. The set A is recursively enumerable provided there is a Turing maching M. that halts for exactly the set of finite tapes that consist only of n + 1 consecutive ones where n*A. Here is represented by 1 , 1 is represented by 11, 2 by 111, etc. Note that if A is a recursively enumerable set then its decision problem is Turing reducible to 9 tIL. Thus the construction of the sets A and B of non-negative integers yielded two decision problems each of which was reducible to TTu while at the same time neither was Turing reducible to the other. That is, these two decision problems were incomparable with respect to Turing reducibility. Therefore their predicates were also incomparable with respect to one-one and many-one reducibility. In key steps, the methods used by Friedberg and Muchnik were similar in that both employed a priority argument to define the sets A and B. Our discussion will not consider the details of such an argument but will merely assume the existence of recursively enumerable sets of non-negative integers whose decision problems are incomparable. According to the definition p. 70 every recursively enumerable degree must contain a recursively enumerable problem. For any finite tape t let l(t) be the positive integer obtained by adding a one to the left end of t, and interpreting the blanks as ! s in a binary expansion. Thus if - 73 - t = **11*1* then l(t) in binary is 10011010. For any r.e. problem r\ if A + is an r.e. predicate, then a recursively enumerable set A may be defined by setting A =il(t) : t is a tape in"£ }. Clearly "A is Turing reducible to the decision problem for A and the de- cision problem for A is Turing reducible to r. Thus the degree containing "p also contains the decision problem for A. An analogous argument is applicable if A is a recursively enumerable predicate. Hence we can formulate the follow- ing equivalence. Fact . A Turing degree is a recursively enumerable degree if and only if it contains the decision problem for a recursively enumerable set of non- negative integers . In particular it follows that there are incomparable Turing degrees. Having noted the existence of incomparable r.e. degrees, the next step is to examine their structure. Several questions can be raised. Does every r.e. degree contain the halting problem for some Turing machine? For every r.e. degree is there a semi-Thue system or a Thue system or a finitely presented group whose word problem is in that degree? Does every r.e. degree contain a correspondence class whose Post correspondence problem or whose partial correspondence problem is in that degree? The answers to all these questions are YES but the proofs are somewhat lengthy. An investigation into the first question suggests why this might be so. As set forth in the definition p. 72. a recursively enumerable set A is given by specifying the quadruples of a Turing machine M that accepts the set A. Since neA if and only if M halts when started on a finite tape containing only n + 1 squares each marked with a one, it is -Ik- clear that the decision problem for A is Turing (even one-one) reducible to the halting problem for M. . But the halting problem for M. concerns all possible finite tapes of blanks and ones not simply tapes consisting only of n + 1 consecutive ones. And the fact that the halting or non- halting of M., when started on a finite tape containing embedded blanks, cannot always be reduced to the decision problem for A indicates why degree analogues for the halting problem might require lengthy proofs. For some Turing machines the degree of the full halting problem is definitely greater than that of the halting problem for tapes consisting only of 1's. However by carefully constructing another Turing machine from M. the English logician J. C. Shepherdson 1965 showed that there is a Turing machine that has a full halting problem that is Turing equivalent to the decision problem for A. A similar situation prevails with respect to the existence of a semi-Thue system whose word problem is in a preassigned recursively enumer- able degree. During the course of the proof of the theorem p. 24 the halting problem for a Turing machine M was one-one reduced to the word problem for the semi-Thue system S„. It was shown that M will eventually halt when started on a finite tape t if and only if S ultimately derives the word hsh from the word hq th. But the word problem for EL, has to do with whether or not an arbitrary word w on the alphabet of EL, can ultimately derive a second arbitrary word w„ on the alphabet of EL.. It is not obvious how the word problem for S can be reduced to the halting problem fo>r M. Thus even if the halting problem for M was in the r.e. degree D it is not clear that the word problem for EL. is also in D. However, in 1966 the logician W. W. Boone gave an explicit construction which, when given an arbitrary r.e. set N of non-negative integers, produces a Thue system T„ -75- (and hence a semi-Thue system) whose word problem is Turing equivalent to the decision problem for N. In a sequel on finitely presented groups Boone specified an explicit group- theoretic construction which, when applied to an arbitrary Thue system T, resulted in a group-Thue system G„ whose word problem was Turing equivalent to the word problem for T. Thus it was established that every r.e. degree contains a word problem for some Thue system and a word problem for some group-Thue system, in addition to the halting problem for a Turing machine. Furthermore, all of these constructions were explicit one-one algorithms in the sense of p. 14-. For any r.e. degree d, the existence of a correspondence class whose Post correspondence problem or partial correspondence problem is in d follows easily from the proofs of theorem p. 32. and theorem p. 39 • First, suppose that M is a Turing machine that accepts a recursively enumerable set N whose decision problem is in d. In the proof of theorem p. 72 it was shown that x ultimately derives z in the semi-Thue system S iff 1 t corresponds to 1 . Therefore using Post's reduction p. 24 of the halting problem for M to the word problem for a semi-Thue system S M it follows that: n«N if and only if M halts when started on t n if and only if hq t h ultimately derives hsh in EL, if and only if 1, corresponds to 1, , , o n where t is the tape consisting only of n + 1 ones. Therefore if we set h m t V t h : " £ °} o n then the decision predicate for N is one-one reducible to the predicate ^A^^N'^hsh^' ' Bu ~ t because ©very list in R_ came from a tape t of M it follows that ^(^A^g^) is one-one reducible to the decision predicate for N. I -76- Thus the simple device of separating out a recursive subset of lists has given us a predicate C.(R„,1, , ) that is one-one equivalent to the decision predicate for N. Now set i Then given two lists from IL. a Turing machine can decide if they are both t from R-, or "both equal to 1, , in which cases they correspond. Therefore f the Post correspondence problem for the recursive class R„ is Turing equivalent to the Post correspondence problem with axiom for (R^,l,. ) which in turn is one-one equivalent to the decision predicate for N. A nearly identical argument shows that there is a recursive class whose partial correspondence problem is Turing equivalent to the decision problem for N. We can thus formulate the following theorem. Theorem. (Cudia 1970) There is a one-one algorithm such that the result of applying the algorithm to any recursively enumerable set N of non- negative integers is two recursive classes of lists with axioms (Rrr»l ) and (S.^,1 ) such that C.(R^,1 ) and - iP.(S„,l ) are each one-one equivalent to the decision predicate for N. Furthermore, the Post correspondence problem for the recursive class R^ = RvrV/{l } and the partial correspondence problem for the recursive class S„ = S„u{l j are in the same Turing degree that contains the decision problem for IT. Now let us use this theorem to obtain degree analogues for some of the predicates of formal grammars defined in section C. First suppose that the pair (R,f3 ) is a recursive class R of lists with 3 an axiom list. Using the construction defined just before fact p. 54 , the context free grammar G(o / ,0 ) is ambiguous if and only if ^ is Turing reducible to the problem Si then the halting predicate "PfKr is one-one reducible to the halting predicate £Wki' That is, given any pair t,"^M of finite tape t and Turing machine with oracle f or "P there is a unique Turing machine with oracle for #, 5.M ? , such that PK halts for t if and only if SCPU halts for t. Proof . Since "Ais Turing reducible to «£ there is a Turing machine with oracle for £ that can decide "P . Call this oracle machine JtM. The idea of the proof is to construct the oracle machine 5^M„ from pM. by substituting the quadruples of£M for the type(5>) quadruples of "AM . The operation of the resulting oracle machine <£Mp proceeds exactly as Pk. except that 83 - whenever the oracle for "p would have been consulted, the deciding oracle machine 3M determines whether the answer to the question is YES or NO. Control then switches to the appropriate state and #Mp proceeds again exactly as -p¥L until another type (5) quadruple is encountered. Whereupon control is again transferred to 2M. Clearly ^NU will halt when started on the finite tape t if and only if -#YL eventually halts when started on t. It is also clear that #IVL depends uniquely on ~pM so that the predicate fiTfL is one- one reducible to the predicate &ffru . Although the idea of the proof is simple enough, there are some details that should be discussed. For example, when replacing the type (5) quadruples of-^M- by the quadruples of <£M, additional quadruples must be added to check whether the tape contents to the right of the scanned square is a question in "P followed by an arbitrary non-negative number of blanks. If such is the case and if the finite tape t of blanks and ones constitutes the question, the deciding oracle machine 3. M must be started on the leftmost square of t . After &M has decided t all its computations must be erased, the original scanned square must be located and control transferred to the correct state of jJJVL depending on the answer to the question t . All of these details can be handled. -6V The theorem just proved shows that the jump operation is a well defined mapping of the Turing degrees among themselves. That is, the degree a* is independent of which problem^ea is chosen to form "Pfcr* Therefore let us apply the jump operation to the Turing degree 0' of definition p. 68 . Definition . The Turing degree 0" is that Turing degree obtained by apply- ing the jump operation to 0' . Similarly the Turing degree 0'" is that Turing degree obtained by applying the jump operation to 0". Therefore 0" = [wy^l and 0'" = [ (%7^)%\ where ["^] is the Turing degree containing r. Proceeding inductively, with (1) =0', o^LoW' n>i serves to define an increasing sequence of Turing degrees that is especially useful as reference points in the ordering of degrees. Now according to theorem p. 45 a recursively enumerable predicate is precisely one for which there is a Turing machine that accepts the truth set of the predicate. Thus using the notation p. 16 , 2 1 is "the set of all those predicates whose truth sets are accepted by Turing machines. The definition of 0" and 0'" allows us to generalize the concept of recursively enumerable predicate by generalizing the accepting machines. Definition . A predicate P is recursively enumerable in 0' if and only if there is a Turing machine with an oracle for a problem «£ in 0' , £M, such that 4fM accepts the truth set of P. That is, for any finite tape t of blanks and ones, Pt if and only if AM eventually halts when started on t. -85- The class of predicates recursively enumerable in 0' is denoted by JL. Similarly, a predicate P is recursively enumerable in 0" if and only if there is a Turing machine with an oracle for a problem <£ in 0" that accepts the truth set of P. The class of predicates recursively enumerable in 0" is denoted by ZL. The class of predicates whose negations are in 2-L is denoted bylL. Similarly, the class of predicates whose negations are in ^1 is denoted by IX. The remainder of this section will be devoted to making several observations about the figure p. 81 • By theorem p. 82 , if there is an oracle machine #M that accepts the truth set of a predicate P and if £ is Turing reducible to fi then there is an oracle machine <.M that also accepts the truth set of P. Therefore we have the following fact. Fact. A predicate P is recursively enumerable in 0' if and only if for every problem c?e0' there is an oracle machine £M that accepts the truth set of P. A similar statement applies for predicates that are recursively enumerable in 0". Clearly 9/j_ is Turing reducible to %■%& which in turn is Turing reducible to (f/ fyity- Therefore: Pact . JLCX^XL. Which implies TTgUgglL. If FeTL , then -.P^X so there is a Turing machine M that halts for a tape t if and only if -,Pt. Therefore M never halts when started on t if and only if Pt. Now the special halting problem for M is clearly a subset of the general halting problem WL. Therefore there is an oracle machine Wy^ that halts when started on t if and only if M never halts when started on t. That is, the truth set of P is accepted by tot . Since #Lf0' it follows that^eX. Therefore we have the following fact. Pact. TI^S?. Which implies S ^"T^. -86- Now suppose P cTL. Then -»P e^Io so there is an oracle machine then according to definition p. 84- there is a Turing machine with an oracle for a problem <£ in _0' that accepts the truth set of P. Since 5. is Turing reducible to r //L it follows from theorem .p. 82 that there is an oracle machine ^/LM that also accepts the truth set of P. Thus for any finite tape t in the domain of definition of P, Pt if and only if f tofM halts when started on t. According to definition p.<2 , P <.%M + ! 1 ^#r r + = K» • Hence we have that P < K 1 . That K' is a recursively enumerable in 0' predicate follows because there is a universal Turing machine with an oracle for ^/'L, 1 ; ip f that can imitate the action of an arbitrary Turing machine with oracle f or ft:_ on an arbitrary finite tape t. Thus '//^U accepts t i K 1 so that K' is recursively enumerable in . Now if P < K then by definition p. 12 there is a Turing machine M that transforms a tape s in the domain of definition of P into a pair t,'"?/LM in the domain of K so that Ps if and only if ^M eventually halts when started on t. By first operating M q and then '/figU on the output of M , the combined operation will be that of a Turing machine with oracle for 1/L that accepts the truth set of P. Hence by definition p.S4,P^. Thus K is maximal in X and the one-one i degree containing K is the maximal recursive isomorphism type inJL. An analogous argument shows that P*2L if and only if P < K" and the last statement of the theorem follows from this equivalence. ■ -88- It can be shown that a predicate P is in 5L if and only if it can be put in the form 3x VyR(a,x,y) and that P is in 2. if and only if it can be put in the form 3xYy32S(a,x,y,z) where R and S are decidable, that is, recursive, predicates. Notice that in the first case there is one pair of adjacent but unlike quantifiers whereas in the second case there are two pairs of such quantifiers. Similarly all predicates in IX can be put in the form VxjyU(a,x,y) and those in TL can be put in the form Vx:$r7zV(a,x,y, z) where U and V are recursive predicates. -89- A.1. Turing machine problems in 0". Define the emptiness problem for Turing machines to be that of determining for an arbitrary Turing machine M whether there exists a finite tape t of blanks and ones such that M eventually halts when started on t. The emptiness problem is denoted by 1 "))!,. Observe that %, is undecidable. For if (t,M)€^ then a Turing machine M' can be constructed such that when M r is started on any finite tape t' , M' will check whether t' is t and if not M' will go into a loop and never halt. If M' finds that t is t', then M' will simulate M on t' so that M' will halt if and only if M halts when started on t. Since M' must simulate M the association of M' to pairs t,M is one-to-one. Fact. )}' is one-one equivalent to K. But what concerns us in this section is the fact that K' is one-one reducible to ffi v , the co-emptiness predicate for Turing machines. Definition . The co-emptiness problem for Turing machines is denoted by 7?t -n, and defined to be the problem of determining for an arbitrary Turing machine M whether or not there exists a finite tape t of blanks and ones such that M never halts when started on t. The finiteness problem for Turing machines is denoted by WL and defined to be the problem of determining of an arbitrary Turing machine M whether or not there are only finitely many finite initial tapes t such that M eventually halts when started on t. The interesting point is that the predicates "ft£ „ and #tt are recursively isomorphic. -90- Theorem - ^ E -1 ™F -1 *£oE' Proof . To prove the first reduction associate to every Turing machie M another Turing machine M' such that M 1 halts when started on a finite tape t if and only if M' determines, by simulating M starting on each tape t with |t |<|t|, that M eventually halts when started on each tape t with |t |<|t|. The symbol |t| denotes the number of blanks and ones on the tape t. Note that M 1 halts for only finitely many initial tapes if and only if there is an initial tape t such that M never halts when started on t . Since M' must simulate M it follows that the reduction o is one-one. To prove the second reduction associate to every Turing machine M another Turing machine M 1 such that M' halts when started on a finite tape t if and only if M' determines, by simulating M starting on tapes t. with |t 1 |3>|t|, that there exists a tape t. with |t |>|t| such that M eventually halts when started on t . Thus there is a tape t such that M' never halts when started on t if and only if there does not exist a tape t. with |t. |>|t| nuch that M halts when started on t. . That is, M halts for only finitely many initial tapes. Since M' must simulate M it follows that M' is uniquely determined by M and the reduction is a one-one reduction. Having established the one-one equivalence of the predicates im „ and 4?u, let us locate them in the Kleene hierarchy. Define a Turing machine with oracle frLM that when started on an encoding of the quadruples of a Turing machine M will systematically generate all finite tapes t of blanks and ones and ask its oracle for *WL whether or not M eventually halts when started on t . Define ftLM so that it halts when started on the encoding of M if and only if the oracle answers NO to some question whether M eventually halts when started on t . Then, frLM accepts fa „ so -91- that by definition p.84> ^t E is recursively enumerable in 0'. Fact . ?7l + „ and, therefore, tt£ are predicates in 2>. The next theorem shows that the predicates *fti and #L, are maximal in S>. Theorem . K' <, #£ oE < -, K« . Proof . The second reduction follows from the fact just proved and theorem p. #7. Thus only the first reduction need be shown. Since K' =%ptr it must be shown that for every pair t, f/U/[ of finite tape t and Turing machine with oracle, 9?LM, there is another Turing machine M' such that %tM eventually halts when started on t if and only if there is a finite tape t' such that M' never halts when started on t'. Because M' must do so much checking of the tapes on which it is started, the machine M' will be called a checking Turing machine. What sorts of things must M' check? Define a tape-state sequence for the oracle machine 9?LM to be a finite string of the form ( S ) Ql XXXXcy XXXX q* XXXX , . . XXXXff where each a. is a tape contents of blanks and ones together with exactly one occurrence of a state symbol q . of fftM. Furthermore require that the single occurrence of q. not be the rightmost symbol of a. so that q. is the state of 9?LM while it is scanning the tape symbol, * or 1, immediately to the right of q.. Now M' must check its finite tapes t' to make sure J they are of the form (S) and that a. is the next tape-state following a. according to the quadruples of 0LM. It is clear that M' can check whether a i+1 follows from a. if a quadruple of type(5) is not involved. But how can M 1 check for proper execution of a type (5) quadruple for which the -92- oracle for ft_ is consulted? This depends on whether the question t ,M asked of the oracle has answer YES or NO. If the answer is YES so that M o eventually halts when started on t , then M' can check to make sure that between a. and a. in (S) there is a tape-state sequence for M starting on t and halting: (q) p xxxx g xxxx g xxxx . . . xxxx g where (3 . follows from . according to the quadruples of M . On the other hand, if the answer is NO then M' can check this by simulating M starting on t and never halting. Of course M' cannot in general decide whether the answer is YES or NO so it must guess. If at any time during its checking M 1 finds that the tape t 1 is not of the proper form, M 1 will halt. M' will never halt only if M' reaches the right end of t' having checked that t 1 is *o 1 2 x /*1 j k la i • n p where Q, , ...,Q are strings of the form (Q) each of which is a tape-state sequence for a question in 17L. and having checked that each a. follows from a. according to the quadruples of VLM. By the time M 1 reaches the right end of t' it will be simulating M. starting on t, where (t, ,K ) 47?£« M' can simulate several such Turing machines in parallel and if any of them halt so that (t, ,M. ) €Wl, then M' will halt. Only under a precise set of conditions will M' never halt. Note that the case where only questions with answer YES are asked of the oracle can be determined by M' and handled separately by letting M' go into a loop and never halt after reaching the right end of t'. Because M' must first check that q t is the initial tape- state and must simulate < tarM, the association of M' to the pair t,^t|M is one-to-one. Thus t»LM eventually halts when started on t if and only if -93- there exists a tape t' such that M 1 never halts when started on t'. For all tapes not of the above form t', M eventually halts. Because of the deterministic nature of fyM, M ! can never halt for at most one initial tape which must be of the above form t'. The equivalence predicate for type grammars was defined after fact p. 77 in section I.D.1. The next definition concerns the equivalence problem for Turing machines. Definition . The equivalence problem for Turing machines is denoted by £ and defined to be the problem of determining of two arbitrary Turing machines whether or not they accept the same set of finite tapes. First observe that the predicate £~ is recursively enumerable in liu. It is clear that one can define a Turing machine with an oracle, 9/uM, that when given two arbitrary Turing machines M and M ? will systematically generate all finite tapes t of blanks and ones and determine from the oracle for ^ft^whether or not the questions t,M. and t»M have the same answer. The oracle machine ^&JVI will halt if and only if different answers ever turn up. Thus ^7LM accepts precisely the questions in $ with answer NO so that g is recursively enumerable in 0' . By definition p. 54 » £~ is in 2 2 and by theorem p. 87 , i~ < 1 K 1 . In addition, the predicate lit „ is a subset of £ where one of the Turing machines halts for every finite tape. Thus by theorem p.9f , K'< trC -, < £~ • Fact . K 1 < . g < K' . In particular, the problem £ is in the degree 0". -3k- B. Predicates of formal grammars in ZL. A language property is a property of the language L(g) generated by a grammar G. An example is the property that L(G) is a deterministic context free language where G is a context free grammar. Language predi- cates are to he contrasted with grammatical predicates, which are concerned with parsing and are recursively enumerable. Examples of grammatical predicates are the ambiguity predicate of fact p. 53 and the LR(k) predicate of fact p. 58 . The following predicate is very useful in dealing with language properties. Definition . The equivalence predicate is denoted by E and defined for arbitrary pairs of type grammars to be TRUE for G , G ? if and only if L(G. ) = L(Gp). The restriction of E to pairs of type 1 grammars is the equivalence predicate for type 1 grammars and it will be denoted by E . In view of the corollary p. 30 and the paragraph following definition p. 49 > the predicate E is recursively isomorphic to the predicate g+ where g is the equivalence problem for Turing machines of definition p. 95 • According to fact p. 93 , $ is one-one equivalent to K' so E is one-one equivalent to -tK* . This locates E in the Kleene hierarchy as being maximal inTL. The predicate E can be located by referring to table p.5^ , line i2 , where it is seen that E is recursively isomorphic to -JC and therefore is maximal in IT . Definition . The equivalence problem for type 1 grammars is denoted by e and defined by setting £T = E . . That is, £ is the problem of determining of two arbitrary type 1 grammars whether or not they generate the same language. -95- Now language properties of type 1 grammars are recursively- enumerable in £, and because &.C 0' , they are recursively enumerable in 0' . On the other hand the grammatical predicates of the first seven lines of table p. 59 are all recursively enumerable. Consider the language property that L(G) is a context free language where G is in arbitrary type 1 grammar. A Turing machine can be constructed that will successively generate all possible context free grammars as quadruples ("V„,V_,S,P) of nonterminals, terminals, start symbol, and productions. Of course the vocabulary of the grammars would be suitably encoded in terms of blanks and ones. Incorporate this Turing machine into a Turing machine with oracle <§.M so that when the oracle machine is started on a finite tape containing the quadruple (V ,V , S ,P ) of an arbitrary type 1 grammar, the oracle for '$,, will be consulted to determine whether or not one of the successively generated context free grammars (V„,V_,S,P) generates the same language i i i i i as the type 1 grammar G = (V„,V ,S ,P ). The oracle machine &M is defined to halt if and only if it generates a context free grammar whose language is L(G ). Therefore the context free language predicate for an i arbitrary type 1 grammar is recursively enumerable in . Clearly this argument suffices for any class of type 1 grammars whose finite descriptions as quadruples (V^, V" T ,S,P) can be successively generated by a Turing machine. More generally, the argument also applies to any class C of type 1 grammars whose quadruples can be successively generated by^>M , a i Turing machine with an oracle for a problem -peO . For then the Turing machine with an oracle *pN Q can be incorporated into the oracle machine £ M so as to obtain an oracle machine (£vg )M 2 that halts for exactly those type 1 grammars G for which there is a G« C such that L(g) = L(G ). The notation Put^ is the problem consisting of the union of questions in ~P and in g . -96- Clearly if ^«0', then "P is Turing reducible to i*V&. and £ is Turing reducible to "f* so that TuS. € 0* . An example of an interesting class of type 1 grammars that can be successively generated by #LM is the class of context free grammars whose complements are also context free languages. Of course, any class of type 1 grammars that can be successively generated by a Turing machine can be successively generated by a Turing machine with an oracle for a problem in 0' . Therefore the one-sided linear grammars and the LR (k) grammars can be successively generated by a Turing machine with an oracle for a problem in 0' . Fact . Suppose that C is a class of type 1 grammars that can be successively generated by a Turing machine with an oracle for a problem in OJ . Then P,-,(type 1) Is recursively enumerable in 0/ where the predicate ^(type t) is defined for an arbitrary type 1 grammar G to be TRUE if and only if there is a G 6 C such that L(G n ) = L(G). — o u This fact provides an upper bound for the degree of unsolvability of language predicates of type 1 grammars. In 1967 the American computer scientist and mathematician Juris Hartmanis gave an undecidability con- struction that provides a lower bound on the degree of unsolvability for certain domains of definition of language predicates. Indeed, the un- decidability construction of Hartmanis 1967 provides a basis for several of the undecidability results in formal grammars that appear in section I.C. This use of the Hartmanis construction in showing the undecidability of recursively enumerable problems is illustrated at the end of this section. -97- The idea of a tape-state sequence was used in the proof of theorem p. 91. The proof of the following theorem uses the idea of an "alternating tape-state sequence" in which every odd numbered tape-state a . is replaced by its reversal or mirror image a . The notation a — *•$ 2i+l c.i+1. means the tape-state p follows from the tape-state a by the execution of one quadruple of M. Theorem . (Hartmanis 1967) There is a one-one algorithm such that when the input is an arbitrary Turing machine M the output is two LR (k) grammars G,„,G„ and two context free grammars G.-.G., such that M' M 2 M' M L(G„) = l(g') n l(g") M M M r R R R M . = \a ma^mouma m. . .ma^.ma TT mm : a = q t, a. — »-a. n . a TT is a haltii I o 1 2 3 2i El o x> 1 i+l' H tape-sta: Furthermore , L(G ) = L(G ) U L(G M ) and the ambiguous sentences generated by G are exactly the sentences in L(G ) (1 L(G ). Proof . Define the two sets L and L by L' = {om3 R m: aAp)*m L" =U U a o R M * R a m{a mpm : a— ►p} ajmn, where the first union for L" is over all finite initial tape-states a = q t * 0^0 and the second union is over all possible halting tape-states. By a halting -98- tape- state is meant one whose state and scanned symbol corresponds to a type(U) halting quadruple of M. The asterisk superscript indicates the Kleene star or semi-group closure operation. Now observe that the sequence R R R a mor.mapma-m. . .mofp.mofp. mm is in L' if and only if MM M ^""V a 2 ^ a 3"~> a 2i— a 2i+1 and that R R R a mo\ma' ma'm. . .ma .ma . „mm o 1 2 3 2i 2i+1 is in L" if and only if oc is an initial tape-state, a ? . is a halting tape- state and M M M M Thus L 1 accounts for the moves of M from the even subscripted tape-states and L" accounts for the moves of M from the odd subscripted tape-states and insures that the first tape-state is of the form q t, for t a finite tape of blanks and ones, and that the last tape-state is a halting tape-state of M. The next observation is that the deterministic nature of the Turing machine M insures that the sets L' and L" are deterministic context free languages . To see this for L 1 define a deterministic pushdown storage automaton that begins by stacking the symbols in a until an m is encountered, this being the signal to unstack and compare symbol by symbol with 3 until the state symbol is reached. Since M is deterministic there is only one way the state, scanned symbol pair of at can match with the ■p state-scanned symbol pair of (3 and that is by virtue of a unique quadruple ■p of M. If the state-scanned symbol pairs of at and 3 appropriately match then the remaining tape symbols of at are unstacked and checked against the -99- •D remaining tape symbols of P until an m is encountered, whereupon the whole process is repeated. The process must end with an empty stack when two consecutive m's are found. If at any stage in the process the stack is not empty when an m is encountered then the end of the string will be reached with a non-empty stack so the string will be rejected. Therefore L' is accepted by a deterministic pushdown storage automaton by beginning and ending with an empty stack. Hence by the equivalence between LR(k) languages and sets accepted by deterministic pushdown storage automaton * i established by Khuth 1965» it follows that there is an IR(k) grammar G M such that i ■ ■. , i L " L(G M } A similar argument establishes that L is accepted by a deterministic push- down storage automaton that begins and ends with an empty stack. So that there is an LR(k) grammar CL. such that L = L(G^). The deterministic pushdown automaton and hence the LR(k) grammars G M and G„ produced from them depend in a one-to-one manner on the Turing machine M. i ii It can be assumed that G„ and G„ contain no common non- terminals. If S 1 i ii is the start symbol of G^ and S" that of G^ then define the context free * * i grammar G^ by taking as its productions P those of (L. together with those ii .* # of G^ and adding the productions S ->• S' and S -•> s". If * . i ii * * x g m - a H is a halting' tape- state. if and only if the bracketed set is a finite set . Proof . The "if" part of the assertion is clear so suppose that the bracketed set is L(g) for some context free grammar G. Then by the uvwxy-theorem of Bar-Hillel, Perles, and Shamir 1961 there are constants p and q depending only on G such that if there is a word z«L(g) such that |z| > p, then z may be written z = uvwxy where |vwx| < q and w ^A , vx^A, and uvSjxV € L(G) for all i > 0. Suppose there exists a z e L(G) such that ■p T> T) z = a racCnttpmaCm. . .map-maunm has more than p symbols, i.e., |z| >p. It follows that z can be written as uvwxy in such a way that uv 1 wx 1 y€L(G) for all i > 0. Now the essential reason why uv wx y cannot be an alternating tape- state sequence of a halting computation for every i > is that an alternating tape-state sequence is completely determined by its initial tape-state o> = q t because 00 M is a deterministic machine. Thus if uvSjx'V is to be an alternating tape- state sequence for all i > the initial tape- state a must be different — * o for different i > 0. By hypothesis M always executes at least two quadruples -102- before halting so that every alternating tape-state sequence of a halting computation must begin with R a ma^ma m. . . o 1 2 There is no way that different initial tape- states can be propagated through this initial substring by different values of i > in the string uv wx y. The only way out of this contradiction is to conclude that there is no z«L(g) such that |z| > p. Therefore for all zCL(G) we have |z| < p. Thus L(g) is finite and so is the bracketed set in the statement of the corollary. Before applying the theorem and its corollary it will be necessary to remove the restriction in the theorem that not all halting computations can be described by alternating tape-state sequences. This is the case because there are only an. even number of executions of quadruples in an alternating tape-state sequence, including the final execution of a type(lj.) halting quadruple. The second restriction that must be removed is the restriction in the corollary that the Turing machine always executes at least two quadruples. Given any Turing machine T, replace every quadruple of T of the form (q. ,S.,X,q ) by the two quadruples: where X is L, R, S or H corresponding to quadruples of type (l), (2), (3), or (I4.). The Turing machine M, defined by the set of quadruples obtained by this substitution, imitates the moves of T by first passing 1 1 from q. to q. and then from q. to q . Since M is obtained in a one-to-one manner from T we have the following fact. -103- Fact. There is a one-one algorithm that when given an arbitrary Turing machine T as input will produce as output a Turing machine M such that M always executes at least two quadruples and T eventually halts when started on the finite tape t if and only if M eventually halts when started on t and executes exactly an even number of quadruples, including the final halting quadruple . The following definition will be useful in applying the Hartmanis construction of theorem p. 97 • Definition . A class of context free grammars C is said to have the finite - complemented property provided: (i) C can be successively generated by a Turing machine with t an oracle for a problem in . (ii) For any finite set S of words there is a G€C such that L(g) = S (iii) If G«C then there is a G€C such that l(g) = L(G). For any class C with the finite-complemented property the predicate X_ is defined for an arbitrary context free grammar G to be TRUE if and only if there is a GJE C such that L(G ) = L(g). Using the definition of P c (type 1) in fact p. % the following theorem can be proven. Theorem . (Hartmanis and Hopcroft 1968) If C is any class of context free grammars having the finite- complemented property then ^5 1 X C < 1 P c (type 1) < 1 k'. -1 (Dis- proof. By fact p. % , P c (type l) < K and X„ is a subset of P c (type 1) so the second reduction follows. In order to prove the first reduction let M be an arbitrary Turing machine. By applying the one-one algorithm of fact p. {03 followed by the one-one algorithm of theorem p. 97 one obtains a context free grammar G M such that the complement L((L.) is context free if and only if it is a finite set, according to corollary p. 101 . If XpCL. so that there is a G t C such that L(G Q ) = L(G^) then L(G Ivr ) = L(G ) for some G € C because C has the finite- complemented property. Therefore L(G M ) is context free. Hence if X^G^. then M6^?V, by corollary p. 101 • 0* 1 the other hand, if -^pG^ then there does not exist a G €C such that o L(G q ) = L(G M ). Then there does not exist a G £ C such that o L(G Q ) = L[G~y and hence LCgTj is not finite since C can generate any finite set. Thus if iX c G„ then M€*?C by corollary p. 101 . Hence M6*?£ if and only if X G^ and since the association of G^ to M is defined by a one-one algorithm, 97Li £ 1 X_ and the proof is completed. This theorem will be applied to extend the predicate table begun in section I.C. Recall that the intersection of context free languages is a type 1 language. -105- EH -p rf CD o u o H -P ^—> cd m ^ +3 -H S<2^ d o3 CD CD CD CM CM CM ■H -P CD p o CQ •H CM •H CD -P •H P •H > p O P U P4 Pi CD CD P u a a CD CQ CQ CD CD ■H ^3 ^H EH -P CD • vo iH CM •H CD > if Fh o -P -H I 'd Jj cp o ^ Pi Ph H fH iH O -106- That fa£, the finiteness predicate for Turing machines, is recursively isomorphic to K' follows from theorems p. 90 and p. 91 • Accord- ing to corollary p. JO » every Turing machine M corresponds to a type grammar CL. that generates exactly the set accepted by M. To every type grammar G there corresponds a Turing machine M^, that accepts precisely Li- the language L(g) . Thus the type entry for line 13 is K' . Since the intersection of type languages is a type language and line 13 is a special case of line ll+ with L(Gp) = V^, the type entry for line lk follows. The remaining Zj~ and K 1 entries of lines 13 and li+ follow from theorem p. 97 and fact p. 96 • (Hartmanis and Hopcroft 1968) The 5ZL and K' entries of lines 15 and 16 also follow from theorem p. 97 and fact p. 96 . (Hartmanis 1968) The S ? and K' entries of lines 17, 18, 19, 20 follow from theorem p. 103 and the observation that the class of one-sided linear grammars and the class of LR(k) grammars have the finite- complemented property. (Hartmanis and Hopcroft 1968) The entries of lines 21 and 22 follow from theorem p. 97 together with corollary p. 101 and the fact that the intersection of con- text free languages is a type 1 language. The context free and there- fore the linear entry of line 23 follow from theorem p. 97 and its corollary. (Hartmanis 1968) The type 1 entry of line 2J4. is that of line 21, while the context free entry of line 21+ is that of line 19 . The K' entry, and hence the 2-L entries of line 25 follow from the last statement of theorem p. 97 • (Hartmanis 1968) The 5j entry of line 23 with a type 1 domain of definition follows because this predicate is recursively enumerable in 97U by virtue of the following argument. Let 9701 be an oracle machine that when started on a type 1 grammar G will successively generate -107- all type 1 grammars G 1 and ask of an oracle for 97L. whether a Turing machine which tests strings for non-sentencehood in L(G) and sentencehood in L(G')» ever halts. The Turing machine is defined so as to halt if and only if it finds a string not in L(G) and not in L(G' ) or a string in L(g) and in L(G')» The oracle machine 97LM is defined so as to halt if and only if it receives the answer from the oracle for ^7L that the Turing machine never halts. Thus the type 1 grammars with type 1 complements are recursively enumerable in 0' and therefore the predicate of line 23 is in 'Emu- The determination of the lower bound on the degree of unsolvability of this predicate, the context sensitive complement problem, is one of the outstanding open problems of formal grammars. The fact p. 89 that the emptiness problem for Turing machines #L is undecidable, the fact p. 103 , and the last statement of theorem p. 97 provide an alternate proof of the undecidability of the ambiguity problem for context free grammars. In the same manner the first statement of theorem p. 97 provides an alternate proof of the undecidability of the empty intersection problem for context free grammars. This alternate approach is systematically developed by Hartmanis 1967. -108- C. Predicates of type grammars in 2_i-. and problems in . All of the domains of definition of predicates discussed up to this point yield predicates in L* 2 since by fact p. 8£ S s E 2 aaa H; c "Z 2 . However when arbitrary type grammars are allowed in the domain of a predicate its degree of unsolvability may jump. The basic reason for this phenomenon is that the halting problem for Turing machines, and hence, by corollary p # 30 > the sentencehood problem for type grammars is unsolvable. Now sentencehood of type 1 grammars is decidable. To the degree of unsolvability of the predicate for type 1 grammars, then, is added the unsolvability of sentencehood when the domain is expanded to arbitrary type grammars. The change of degree with domain was also observed in section I.D.1 where for each recursively enumerable degree d there corresponded a domain of definition for which a predicate with that domain of definition was in d. Not all predicates jump a degree when the domain is increased from type 1 to type grammars. According to the predicate table p. 59 the emptiness predicate and the empty intersection predicate both remain constant when the domain is increased to arbitrary type grammars. The same is true for the finiteness and finite intersection predicates of lines 13 and IJ4. of the predicate table p. 105 . However note the jump of the emptiness predicate line 8 of table p. 59 and the finiteness predicate line 13 of table p. 105 in going from context free to arbitrary type 1 grammars, the latter being a jump of two degrees from to K 1 . The solvability of the finiteness predicate for context free grammars as well as its K* degree of unsolvability for type 1 grammars depends in both cases on the uvwxy- theorem. Recall that the uvwxy- theorem is used in -109- the proof of corollary p. 101 . However some predicates do jump a degree. In particular the type entry of table p. 59 > lines 10, 11, 11.1, 12, and 12.1 is -£' which is the jump of the entry for type 1 grammars. The reason for this _ t is that the predicate ffl - is one-one equivalent to -JC by theorem COMj p. 91 and, by the equivalence between type languages and sets accepted by Turing machines, fyC _ is recursively isomorphic to the predicate L(G) = Vm of line 10, table p. 59 > for arbitrary type grammars. Now if G is a right linear LR(k) grammar that generates all finite strings of blanks and ones, then L(G) = V T = L(G ) if and only if V = L(G ) C L(G). Therefore the degree of unsolvability of all these entries is at least t iK . However, an enumerability argument shows that these predicates are __ t in Up so that their degree of unsolvability is no more than -*K . The enumerability argument is similar to that of p. 61 for type 1 grammars except that, for type grammars, sentencehood is one-one equivalent to tyl-rr. Therefore these predicates for arbitrary type grammars are only accepted by Turing machines with an oracle for *?^Itt. As in the argument of p. 61 for type 1 grammars, these predicates for type grammars are TRUE if and only if a Turing machine with an oracle for 7fL never halts. Hence they, as well as the predicate of line 11.2 are in TL* The TT 2 entries of line 26 of table p. 105 follow from the fact that the negation of the ambiguity predicate for type 1 grammars is accepted by an oracle machine (& u &.)M and d v §. 6 . The problem 0. \J ^ is the union of t0" . Then the problem "Pu$ is in 0". Given any type grammar G = (V ,V ,P,S,), an oracle machine ( "pui?)M can successively generate grammars G' in C consulting the oracle to answer questions in "fi and then consulting the oracle to answer questions in & . The oracle machine ("Pu i )M is defined to halt if and only if a G' in C is found such that L(G) = L(G'). -111- Thus the following fact can be stated. Note that it is exactly analogous to the fact p. 96 for type 1 grammars. Fact . Suppose that C is a class of type grammars that can be successive- ly generated by a Turing machine with an oracle for a problem in 0". Then P (type 0) is recursively enumerable in 0" where the predicate P_(type 0) is defined for an arbitrary type grammar G to be TRUE if and only if there is a G € C such that L(G ) = L(g). o u As before, the cofinite sets, the one-sided linear grammars, the LR(k) grammars, the context free grammars, and the type 1 grammars can all be successively generated by Turing machines and hence form suitable classes C for the application of this fact. Since the inter- section of type languages is also a type language it follows from the fact just proven that the type entries for lines 15-22 and 2k are in S-_. In order to show that the entry for line 23 is in £j observe that an oracle machine ( 'ftLr #L.)M can be defined that, when started on an arbitrary type grammar G, will successively generate type gr amm ars G' and use the oracle for Wl 9fl to determine whether L(G') = L(G). The questions asked of the oracle for tn^lTL will be whether or not an oracle machine ''^M ever halts when started on the pair of quadruples defining G and G' . This oracle machine will generate all strings s of blanks and ones and ask its oracle for WL whether s £ L(G' ) and s €L(G) or whether s^L(G') and s^L(G). In either case L(G' ) ^ L(G) and the oracle machine 972^ is defined to halt under these circumstances. Thus L(G') = L(G) -112- if and only if MLM* never halts. The original oracle machine (Tfyr^TljM keeps generating type grammars G until it gets the answer that the oracle machine VIM. never halts, whereupon it halts. Hence the type grammars G that generate recursive sets, i.e., such that L(G) is also a type language, are accepted by a Turing machine with an oracle for fTLVL . Therefore they are recursively enumerable in 0" and the predicate of line 23 is in ^-"o* Notice that this argument is analogous to the argument p. 107 showing that the context sensitive complement predicate is in ;?• Having established the upper bounds for the degree of the predicates of lines 15-21+, the next two theorems give the lower bound on their degree of unsolvability for the domain of type grammars. Notice that the next theorem is the "jump" of theorems p. 90 and p. 91 Theorem. K" S,^^ <-,%*£ Proof . Since K" = (fy Iju)*}^ , the first reduction is analogous to the first reduction of theorem p. 91 • Thus it must be shown that for every pair t, fyl tlLM there is another oracle machine ^IJYP such that ^flfJM eventually halts when started on t if and only if there is a finite tape t' such that ITIM 1 never halts when started on t 1 . The oracle machine tfLM' is a checking oracle machine that must check tape-state sequences for 97L,^?ZJYI. As before the halting tape-state sequences for questions in <77L971tt are inserted in their proper places and since 4JLM 1 can consult its oracle for f/U when the oracle machine of the question does, the checking can be done by ^LM' . Similarly if the answer to a question in frTg ftZg is that a Turing machine with an oracle for 97L. never halts, then IX^M' can simulate its behavior and never halt. Since the proof is so -113- analogous to that of K 1 < °fft -, of theorem p. 91 it will be left to the reader. Note that because of the deterministic nature of (Wlg^OM, 97LM' never halts for at most one initial tape t'. Furthermore the tape t' must be of the proper form with all the halting checking sequences inserted into their proper places. For all other tapes tot-M' will eventually halt. The proof of the second reduction is the same as that of 171 < ^7lt of theorem p. 90 except that the oracle machines involved can consult their oracles for the problem #L. The following definition plays the same role for type grammars that definition p. 103 played for context free grammars. The cofinite- recursive property is analogous to the finite- complemented property and Z is analogous to X„. Definition . A class of type grammars C is said to have the cofinite- recursive property provided: (i) C can be successively generated by a Turing machine with an oracle for a problem in 0". (ii) For any finite set S of words there is a G € C such that the oomplement L(G) = S. Thus C generates all cofinite sets. (iii) For all GeC, L(g) is a recursive set. Thus C generates only recursive sets. For any class C with the cofinite-recursive property the predicate Z is defined for an arbitrary type grammar G to be TRUE if and only if there is a G € C such that L(G ) = L(G). o o The final theorem is the analog for type grammars of theorem p. 103 -Illl- Theorem. (Hartmanis and Hopcroft 1968) If C is any class of type grammars having the cofinite-recursive property then tfZg^ S, Z c <, P c (type 0) 21 has the cofinite-recursive property, the type entry for lines 1^-22 of table p. 105 is K". (Hartmanis and Hopcroft 1968) In addition the class of type grammars whose languages are recursive sets and the class of type 1 grammars both have the cofinite-recursive property. Hence the type entry for lines 23 and 2\\ of the predicate table is also K". (Hartmanis and Hopcroft 1968) -117- STJMMARY Grammatical predicates of context free grammars are recursively- enumerable and hence are in 21 . The ambiguity predicate for context free grammars is an example of a grammatical predicate. Grammatical predicates concern parsing and depend on the productions of the grammar. Since they are in S they are accepted by a Turing machine. Language predicates of type 1 grammars are recursively enumerable in 1 and hence are in *-L, Weak equivalence of type 1 grammars, that is, whether two type 1 grammars generate the same language, is an example of a language predicate in *-» ? but not in i-i . Language predicates are concerned only with the language generated by a grammar and thus are less dependent on the productions of the grammar than grammatical predicates. Language predicates of type 1 grammars are accepted by a Turing machine with an oracle for a problem in 0' . A jump in the degree of unsolvability often occurs when a language predicate is considered for arbitrary type gr amm ars - To the degree of unsolvability of the predicate for type 1 languages is added the unsolvability of sentencehood for type languages. The greater computational complexity of type languages over recursive sets such as type 1 languages causes the jump in the degree of unsolvability. Thus language predicates of type grammars are recursively enumerable in 0" and hence are in Z_j_. Weak equivalence of type grammars is an example of a language predicate in I-L but not in Tj . Language predicates of type grammars are accepted by a Turing machine with an oracle for a problem in 0". By extending the hierarchy of automata to include oracle machines greater insight is obtained into the relations*!^ between automata and formal grammars. -11b- language predicates of type grammars. (inherent ambiguity of type languages is in TL) language predicates of type 1 grammars. finiteness of type grammar. grammatical predicates of context free grammars universality, subset and weak equivalence of type grammars. inherent ambiguity of type 1 languages. Liniversality, subset , and weak equivalence nf +.ypp 1 grammara . SffiBt.uiess of type. gx, II n Figure. Compare Figure p. 81 . Recall that TL^ *-L and TL^.^-*_. Thus grammatical predicates of context free grammars are in 5J-, . Predicates concerning type 1 languages are in £-1 Predicates concerning type languages are m *-^. -119- Predicate one sided linear linear LR(k) ( deter - ministic). context free type 1 type 1. 2. 3- k. 5- 6. 7- 8. 9. 9-1 10. 11. n.i 11.2 12. 12.1 13- Ik. 15. 16. IT- 18. 19. 20. 21. 22. S3- 24. 25. 26. G is ambiguous. G is BRC. G is LR(k). G is BC. G is BLC. G is KL(J). G is BCP. L(G) =. L(G) n L(G') - 0. 3 linear LE(k)G Q 9.L(G) n L(G Q ) L(G) - V£ L(G) c L(G'). 3. linear LR(k)G Q 3. L(G Q ) c L(g). 3LR(k)G 3.L(G) c- L(G 1 ) L(G) =L(G') 3 l-sided linear LR(k)G 9.L(G) L(G) is finite. L(G ) PI L(G 2 ) is finite. L(G) is cofinite. L(G,) n L(G 2 ) is cofinite. L(G) is regular. L(G ) n L(G 2 ) is regular. L(G) is deterministic. L(G, ) fl L(Gp) is deterministic. L(G) is context free. L(G 1 ) n L(G 2 ) is context free. Vt - L(G) is the same type. L(G) is of next higher type. G is finitely ambiguous. L(g) is inherently ambiguous. L(G Q ) YES YES YES YES YES YES YES 2 NO K K K K K K K nK -,K % \ \ -.K \ \ 2 YES NO Z l YES IL. nK nK nK nK h K' E 2 K* YES K' YES K' YES Z 2 NO NO K K K K K K K -.K -,K K' K* K" K' K' K' K' YES K' K' K' K' -.K -,K -,K nK -,K ■JE K' V K' K' K' K' K' K' K' K' Z 2 K' nK -.K -,K' -,K' n 2 -,K' -,K' K 1 K' K" K" K" K" K" K" K" K" K" K" THE PREDICATE TABLE -120 REFERENCES Y. Bar-Hillel, M. Perles, and E. Shamir 1961 W. W. Boone 1957 1966 1966 1936 1936 B. F. Cudia 1967 1970 1970 A. Church On formal properties of simple phrase structure grammars, Zeitschrift fur Phonetik, Sprachwissenschaften , und Kommunikationsforschungen , Vol. ll+, pp. 11+3-172. Certain simple, unsolvable problems of group theory, V, VI, Indaga t i ene s Mathemat i cal , Vol. 19» pp. 22-27, pp. 227-232. ( Koninklyke Nederlandse Akademie van Vetenschappen, Proceedings, series A, Vol. 60.) Word problems and recursively enumerable degrees of unsolvability: A first paper on Thue systems, Annals of Mathematics , Vol. 83, pp. 520-571. A sequel on finitely presented groups, Annals of Mathematics , Vol. 81+ , pp. 1+9-8U. A note on the Entscheidungsproblem, The Journal of Symbolic Logic , Vol. 1, pp. 1+0-1+1. Correction to a note on the Entscheidungsproblem, The Journal of Symbolic Logic , Vol. 1, pp. 101-102. Equivalence of some unsolvable problems used in formal grammars (abstract), Notices of the American Mathematical Society , Vol. ll+, pp. 81-82. General problems of formal grammars, Journal of the Association for Computing Machinery , Vol. 17, pp. 31-1+3' The degree hierarchy of undecidable problems of formal grammars, Second Annual ACM Symposium on Theory of Computing , pp. 10-21, SIGACT. -121- R. W. Floyd i960 Private communication to E. Shamir. I96U Bounded context syntactic analysis, Communications of the Association for Computing Machinery , Vol. 7, pp. 62-67. 1965 New proofs of old theorems in logic and formal linguistics, Research Paper C. A. -6505-14H; Computer Associates, Inc. R. Friedberg 1957 Two recursively enumerable sets of incomparable degrees of unsolvability (solution of Post's problem, 191|4), Proceedings of the National Academy of Science , Vol. k~5, pp. 236-238. S. Ginsburg and S. Greibach 1966 Deterministic context free languages, Information and Control , Vol. 9, pp. 620-6^8. J. Hartmanis 1967 Context-free languages and Turing machine computations, ' Proceedings of Symposia in Applied Mathematics , Vol. 19, pp. 42 -51, American Mathematical Society. 1968 Private communication, May 1, 1968. J. Hartmanis and J. Hopcroft 1968 Structure of undecidable problems in automata theory, Conference Record of 1968 Ninth Annual Symposium on Switching and Automata Theory, pp. 327-333, IEEE. S. C. Kleene 19^3 Recursive predicates and quantifiers, Transactions of the American Mathematical Society, Vol. 53, pp. 41-73. S. C. Kleene and E. L. Post 1954 The upper semi-lattice of degrees of recursive unsolvability, Annals of Mathematics, Vol. 59, pp. 379-407. D. E. Knuth 1965 On the translation of languages from left to right, Information and Control, Vol. 8, pp. 607-639. ■ 122- F. D. Lewis 1970 A. A. Markov 191+7 1958 A. A. Muchnik 1956 J. Myhill 1955 P. S. Novikov 1955 E. L. Post 1921 1930 19U0 19UU 191+6 Decision problems for complexity classes of computable functions, Second Annual ACM Symposium on Theory of Computing , pp. 22-30, SIGACT. Impossibility of certain algorithms in the theory of associative systems (Russian) , Doklady Akademii Nauk SSSR , Vol. S$, pp. 587-590, Vol. 58, pp. 353-356. The problem of homeomorphy (Russian) , Proceedings of the International Congress of Mathematicians , 1958, Cambridge University Press, London, pp. 300-306 (i960) Negative answer to the problem of reducibility of the theory of algorithms (Russian), Doklady Akademii Nauk SSSR , Vol. 108, pp. 191+-197. Creative sets, Zeitschrift fur Mathematische Logik und Grundlagen der Mathematik , Vol. 1, pp. 97-108. On the algorithmic unsolvability of the word problem in group theory (Russian) , Trudy Mathematicheskogo Institutainmeni V.A. Steklova , No. 1|1+. Introduction to a general theory of elementary propo- sitions, American Journal of Mathematics , Vol. 1+3, pp. 163-185. Generalized differentiation, Transactions of the American Mathematical Society , Vol. 32, pp. 723-781. Polyadic groups, Transactions of the American Mathematical Society , Vol. 1+8, pp. 208-350. Recursively enumerable sets of positive integers and their decision problems, Bulletin of the American Mathematical Society , Vol. 50, pp 28U-316. A variant of a recursively unsolvable problem, Bulletin of the American Mathematical Society , Vol. 52, pp. 261+-268. -123- 19U7 19U8 S. Scheiriberg I960 Recursive unsolvability of a problem of Thue, The Journal of Symbolic Logic , Vol. 12, pp. 1-11. Degrees of recursive unsolvability: Preliminary Report (abstract), Bulletin of the American Mathematical Society , Vol. $h 9 PP» 61+1-61+2. Note on the Boolean properties of context-free languages, Information and Control, Vol. 3» PP« 372-375* J. C. Shepherds on A. Thue 1965 Machine configuration and word problems of given degree of unsolvability, Zeitschrift fur Mathematische Logik und Grundlagen der Mathematik , Vol. 11, pp. 11+9-175 • 1911+ Probleme uber Veranderungen von Zeichenreiken nach gegebenen Regeln, Skrif ter utgit av Videnskapsselskapet i Kristiania , I. Mathematisk-naturVidenskabeligklasse, No. 10, 31+ pp. A. M. Turing 1937 1939 1950 J. H. Williams 1969 On computable numbers, with an application to the Entscheidungsproblem, Proceedings of the London Mathematical Society , Vol. 1+2, pp. 230-265. Systems of logic based on ordinals, Proceedings of the London Mathematical Society , Vol. 1+5, pp. 161-228. The word problem in semi-groups with cancellation, Annals of Mathematics . Vol. 52, pp. 1+91-505 • Bounded context parsable grammars, Computer Sciences Department Technical Report No. 58 , The University of Wisconsin, \\G pp. HI H HHti H H n BWM HI sHU HHhh rai n KHH^B^H HHH1 UNIVERSITY OF ILLINOIS-URBANA UNIVERSITY OF .LLINO.S-URBANA S1QMILBHiMi.C002no.4B0-4MfH?1 Sv nc h ronlz.tlon^.m1«..t«'«vl«'on 3 0112 088400061 ■ ■ BH H v* h^hvhH Hfl Hi HI »-vA"Vw5 ! % H *j ■ ■ *