# INTRODUCTION TO COMPUTER THEORY 2ND EDITION PDF

Introduction to Computer Theory by Daniel I. a. Cohen - Second Edition - Ebook download as PDF File .pdf), Text File .txt) or read book online. The fourth has a close parenthesis before the corresponding open parenthesis. then so are. Where can I get "Intro to Computer Theory by Daniel I.A Cohen 2nd Edition" Wiley; 2 edition (October 25, ); Language: English; ISBN C ISBN Printed in the United It has become clear that some abstract Computer Theory should be included in the.

 Author: KIERSTEN SHINHOLSTER Language: English, French, Dutch Country: Malaysia Genre: Technology Pages: 409 Published (Last): 24.08.2016 ISBN: 828-4-61007-862-1 ePub File Size: 22.69 MB PDF File Size: 16.35 MB Distribution: Free* [*Registration Required] Downloads: 40972 Uploaded by: MIKEL

Automata Theory cover kaz-news.info Introduction to Computer Theory 2nd Edition Daniel I. A. Cohen John. Solution Manual for Introduction to. Thank you for reading introduction to computer theory 2nd edition solution manual. computer theory by daniel cohen solution manual pdf introduction to. Introduction to Computer Theory by Cohen Introduction to Languages and the Theory of Computation, 4th ISBN e-ISBN

The most fundamental component of computer theory is the theory of mathematical logic. Thi s left a cloud over mathematics that needed to be resol ved. The Euclidean notion that the whole is the sum of its parts seems to carry over to infinite sets as well.

Dav id Hilbert. From this we see that even before the first computer was ever built. In fact. We may never fi n d the proof. He had in his mind a specific model of what he wanted. Although the invention of the computer itself was not one of his predictions.

In the nineteenth century. When we input the problem. Given any algebraic problem having a specified number of linear equations.

What had to be invented was a whole field of mathematics that dealt with algorithms or procedures or programs we use these words interchangeably. Hilbert was not merely satisfied that every provable result should be true. First of all. It was not easy for mathematicians to figure out how to follow Hilbert 's plan. And even more significant. Thi s would have been an even more satisfactory situation than existed in Euclidean geometry at the time. The road to studying algorithms was not a smooth one.

Addition and circumscribing circles were certainly allowable steps in an algorithm.

## Introduction to Computer Theory by Daniel I. a. Cohen - Second Edition

If we are presented with a correct Euclidean proposition relating line segments and angles in a certain diagram. The language of algorithms that Hilbert required evolved in a natural way into the language of computer programs.

It was necessary to codify the universal language in which algorithms could be stated. As long as we are tireless and precise in following the rules. We have to be creative.

He showed that either there were some true statements in mathematics that had no proofs. In Euclid's classic texts. Linear algebra guarantees that none of this will ever happen with equations.

Mathematicians then had to retreat to the question of what statements do have proofs and how can we generate these proofs? The people who worked on this problem. It is practically sacrilegious to maintain that World War II had a serendipitous impact on civil ization no matter how unintentional. On the other hand. If some human could figure out an algorithm to solve a particular class of mathematical problem. The model they constructed for a "neural net" was a theoretical machine of the same nature as the one Turing invented.

Warren McCulloch and Walter Pitts. It was as incredible as if a mathematical proof of the existence of intelligent creatures in outer space were to provoke them to land immediately on Earth.

Emil Post. It seems that half the intel lectual forces in the world were leading to the invention of the computer. Independently of all the work being done in mathematical logic. This was another fortuitous phenomenon of this period of history. Andrei Andreevich Markov. Two neurophysiologists. Not only was this an ironic twist of fate. John von Neumann. As we have noted before. What is again of singular novelty is the historical fact that. Stephen Kleene.

On the one hand. Turing then went one step farther. What is language in general? How could primitive humans have developed language? How do people understand it? How do they learn it as children? What ideas can. Modern linguists.

Even for the topics we do cover. How do people construct sentences from the ideas in their minds? This is our goal. His theory grew to the point where it began to shed light on the study of computer languages. Turing machines. The languages humans invented to communicate with one another and the languages necessary for humans to communicate with machines shared many basic properties. When we do. Computer theory extends further to such topics as complexity and verification. It includes three major fundamental areas: We then arrive at what we may believe to be the most powerful machine possible.

Our subject is sometimes called computation theory rather than computer theory. Just as the term "number theory" is not limited to a description of calligraphic displays of number systems but focuses on the question of which equations can be solved in integers. By considering the possible inputs on which these machines can work. Because of the many influences on its development.

This book is divided into three parts corresponding to these topics. Along the way. It became a word processor. Metaphorical ly. As intriguing and engaging as the field has proven so far. The software invented to interpret programming languages was applied to human languages as well.

We shall study different types of theoretical machines that are mathematical models for actual physical processes. This will be our ultimate result.

Although we do not know exactly how humans understand language. If it compiles. Certain sets of commands become a program with or without data that can be compiled. It is very hard to state all the rules for the language "spoken Engl ish.

What we are looking for are ways of determining whether the input is a valid communication. No liberties are tolerated. This is due to slang. What is more important to note is that. There is a certain parallelism between the fact that groups of letters make up words and the fact that groups of words make up sentences.

How do they do that? This situation also exists with computer languages. Certain groups of sentences make up coherent paragraphs. When we call our study the theory of formal languages.

Not all collections of letters form a val id word. It is important that the program compiles whether or not it does what the programmer intended. Certain strings of words are recognizable commands. For our purposes at this time. Just as with any set. The analogy can be continued. To construct a general theory that unifies all these examples.

If we wished to be supermeticulous. If a certain language L does not contain the word A and we wish to add it to L. This is not because the Greek word for "alphabet" starts with the letter sigma-the Greek word for alphabet is alphahetor and starts with an A. For clarity. Two words are considered the same if all their letters are the same and in the same order. If we have a method for producing a language and in a certain instance the method produces nothing.

We shall call this the alphabet. There is a subtle but important difference between the word that has no letters. The alphabet is the usual set of letters plus the apostrophe and hyphen. To some it makes computer theory seem more mathematical and to some this is an advantage. We begin with only one finite set of fundamental units out of which we build structures. The most familiar example of a language for us is English. This we call the empty string or null string. This has become a time-honored tradition.

This language i s not the same as L. In this basic model. It is a long list. We shall wish to al low a string to have no letters. The symbols in the alphabet do not have to be Latin letters. Those strings that are permissible in the language we call words. We shall face j ust such a situation later. For example. If we go by the rules of grammar only. It is grammatically correct.

If we tried to define a language of infinitely many words by an infinite list. Mathematical symbolism is of value only when it is somehow better than seeing the same thought expressed in human language. There are two problems with pure mathematical symbolism: It alienates some who for want of familiarity could otherwise understand the concepts being expressed. Only a language with finitely many words can be defined by an all-inclusive list called a dictionary.

This is because we could never produce a complete list of all possible words in this language. B ut even though there are tricks to overcome the searching problem as we shall soon see. Theoretical ly. Languages in the Abstract 9 In the preceding line. Of course. How could we be handed an infinite dictionary? It would have to be described to us in some manner. I ate two apples. I ate one apple.

Let us call this alphabet r. Since the goal in a textbook is not to minimize the space required to explain concepts but to maximize the chance of understanding. Meaning is something. The belief that mathematical symbolism is more rigorous and therefore more accurate than English prose is quite ridiculous since every mathematical symbol was defined in English in the first place and every mathematical formula can be translated into English if need be.

This results in perfectly understandable communication. If we wish to make a fonnal definition of the language of the sentences in English. Let us consider some simple examples of languages. If the Earth and the Moon ever collide. If we start with an alphabet having only one letter. To be an acceptable specification of a language. Earlier we mentioned that we could define a language by presenting the alphabet and then specifying which strings are words.

The set of rules defining English is a grammar in a very precise sense. We shall be like the bad teacher who is interested only in the correct spelling. Either they will be presented as an alphabet and the exhaustive list of all valid words.

As we make clear in Part II of this book. English itself used to have a letter called "eth" that has thankfully disappeared. They can either tell us how to test a string of alphabet letters that we might be presented with. In general. The word "specify" is trickier than we may at first suppose. The words in this language are clearly analogous to the positive integers. We could have defined it so as to include A.

Then to denote the word formed by concatenating a and h. In these simple examples. In this example. The integers have other mathematical properties. In this language. Let us begin with the alphabet: We shall see that this is sometimes a messy business.

Introduction to Defining Languages 11 where w e have identified letter j uxtaposition with algebraic multiplication. Because of the way we have defined it. In English when we concatenate "house" and "boat. If we wanted to define the language L3 so that it includes the string word 0. When we present an example of a point in the text. This box serves the same purpose. We write this function using the word "length.

The language L3 does not include A. This may seem like belaboring a trivial point. In L3 it is very important not to confuse 0. Di scovering when th is does happen is left as a problem at the end of th is chapter. In this way. If a is a word in some language L. Introduction to Defining Languages 13 This is not necessari ly a better definition of L3. There is some inherent ambiguity in the phrase "any finite string. Notice that when we wrote out the first several words in the language.

In a dictionary. This language we shall call the closure of the alphabet. This ordering i s cal led lexicographic order. We shal l now generalize the use of the star operator to sets of words. Whereas both orderings are useful for the problem of searching for a given word. In the language just above. When we say "infinite language. We shall usual ly follow this method of sequencing a language.

When this happens. Any string without the substring bb that begins with an a can be factored into terms of ah and a. It is Also. I By the phrase "double b. This is the only way to factor this string into factors of a and ab. In the last example. The substring bb is impossible. The string. Let us ask the question.

In cases where parentheses are letters of the alphabet. On this l i st we write down how to form. Most of the theorems in this book w ill be proven by the method of constructive algorithm. S uppose that somebody did not bel ieve this and needed conv incing. Symbol ical ly. A l which is a l so true but for a different reason. Let us observe that if the alphabet has no letters. We have just establ ished a mathematical fact by a method of proof that we have rarely seen in other courses.

The K leene closure always produces an infinite language unless the underlying set was one of the two examples above. We may have a difficult time sel l i ng powers of. Unless we insist on cal l ing K leene c losure a very forgiving. How did you form the word x1 7? Why don 't you j ust concatenate another factor of xx in front of this and then you w i l l have the word x that you wanted. Let us say that we work our way successfu l l y up to xn.

The method is to begi n with. Obv iously. Th is is the most i mportant tool in our whole study. The method of prov ing that something exists by showing how to create it is called proof by constructive algorithm. If S is a set of strings not including A. This "plus operation" is sometimes called positive closure. If S is a language that does contain A. What happens if we apply the closure operator twice?

In this case. Kleene Closure 17 rule of grammar anything goes. It is already a problem. I t can. The Kleene closure of two sets can end up being the same language even if the two sets that we started with were not. Anyone who does not think that the null string is confusing has missed something. Even if the set S has infinitely many words. Thi s should present no problem since every string in the closure of a set is a combination of only fi n i tely many words from the set.

I t i s analogous t o saying that if people are made up of molecules and molec ules are made up of atoms. Let us say we concatenated aaha and haaa and aaha. From now on we shall let the closure operator apply to infinite sets as well as finite sets. Prove that for al l sets S. Can any word in this language contain the substrings aaa or hhh? What is the smallest word that is not in this language?

I n how many ways can x 19 be written as the product of words in S? This means: How many different factorizations are there of x 1 9 into xx and xxx? How many words does this language have of length 2? How many words does this language have of length 4? What can be said in general? Be careful. Is the string ahhha a word in this language? Write out all the words in this language with six or fewer letters. How many words is that? Show that the words aahaa. Can any word in this language be interpreted as a string of elements from S in two different ways?

Can any word in this language have an odd total number of a 's? Step 2. If what remains is the string A. Give another description of this language. Find a string that disproves thi s algorithm. S uppose that for some language L we can always concatenate two words i n L and get another word in L if and only if the words are not the same. Prove that this cannot happen. I f what remains is not A t h i s means some letters are left.

Is abaabbabbaabb? Is i t bigger than S? That is. Step I. There is a reason that the third defin ition is less popular than the others: I t is much harder to use in most practical applications. Another way we might try i s this: One standard way of defining this set is EVEN is the set of all positive whole numbers divisible by 2. The set EVEN i s defined by these three rules: Let us take an example.

Rule only elements in the set EVEN are those that can be produced from the two rules above. To prove that 14 i s i n EVEN by the second defi n ition. A recursive definition i s characteristical ly a three-step process. The third method we present is sneaky. To show this using the first defi n ition. Again by Rule 2. B y Rule 2. The fact that 6 i s in is in EVEN. Rule 2 I f. Once more applying Rule 2. In later chapters. We can now prove that 1 4 is in EVEN in fewer steps: By Rule Then by Rule 2.

Whether or not we want a recursive definition depends on two things: Now applying Rule 2 to 8. For instance. Thi s. We EVEN. The set EVEN. Before leaving this example. EVEN using the recursive defi nition is a lengthier process. This does define some set. Let us consider the way pol ynomials are usually defined: A polynomial is a finite sum of terms.

But the problem is that there is no smallest positive real number x on which to build the rest of the set. The symbol pq. We could try: Since l. Rule I Rule 2 O! Before proceeding to more serious matters. As soon as we prove that the derivative of a number is 0 and that the derivative of x is I. There are some advantages to this defi nition as wel l as the evident disadvantages. S i nce the topic of this book i s computer theory.

It is for this reason that recursive defi n i tions are important to us. On the plus side. This becomes a theorem that c a n b e proven directly from the recursive defi nition. I n computer languages. S uppose for a moment that we were studying calcu l us and we had j ust proven that the derivative of the sum of two functions is the sum of the derivatives and that the derivative of the product f:!?

Given a soldier. Thi s defi n ition clears up the matter: Thi s is a l i ttle more complicated to see if we had to prov ide a proof based on the c lassical definition. These definitions have the same self-referential sense. The reason that these definitions are called "recursive" i s that one of the ru les used to define the set mentions the set itself. Are there stil l more? An Important Language: Rule I If S is a language.

Are there more rules? The thi rd contains the forbidden substring. The defi n ition can be written as: Rule I Rule 2 Any n umber positive.

The fourth has a close parenthesis before the corresponding open parenthesis. We return to this point in Part II. If neither. This definition determines the set AE i n a manner useful for prov ing many theorems about arithmetic expressions.

We imagine it in our mind broken down into its components. By apply ing Rule 2. Any AE formed by Rule 2 must begin and end with parentheses or begin with a minus sign. There is no doubt that the string is a word in AE. One can add only carrots to the pot. We shall show that it must have been Rule 3 iv. Even w i thout knowing exactly in what order the chefs v i si t the pot or how often. This method of argument should sound fami liar.

One can add only meat to the pot. Arithmetic Expressions be introduced by Rule 2. One can add only potatoes to the pot. Now we know that w. Let a shortest of these be a string called w. The long-winded but careful proof of the l ast theorem i s g iven to i l l ustrate that recursive defin itions can be conveniently employed in rigorous mathematical proofs.

Our fi rst question is: Which was the last rule used in the production of w? Thi s is easy to answer. But si nce both. In computer science. Using the second recurs ive defi n i tion of EVEN. Write another recursive defini tion for the language L 1 of Chapter 2. Without too much difficulty. What would it mean?

What are you. Another common use for recursive defin i tions is to determ i ne what expressions are valid in symbolic logic. The version we shall defi ne here uses only negation -. Rule I. Rule 3 If p and q are WFFs. Some sequences of applications of these rules enable us to show that p. As with AE. U s i n g the second recursive definition of the s e t EVEN. Any single Lati n letter is a WFF. Show that the fo l l owing is another recursive defi nition of the set EVEN: As a final note in this section.

We shall be interested i n one particular branch of symbolic logic cal led sentential calculus or propositional calculus. The valid expressions in this l anguage are traditional ly called WFFs for well-formed formulas. Rule 2 If p is a WFF. Describe a good method for show i ng that is in EVEN.

Using any recursive definition of the set EVEN. What i s the complete l i st of substri ngs of length 2 that cannot occur? I n this chapter. Show that there are infinite l y many different recursive defin itions for the set EVEN.

What is the longest forbidden substring that does not contain a shorter forbidden substring? Write a recursive definition for the set of al l polynomials in the two variables x and y. Defi ne the set of val id algebraic expressions ALEX as follows: The rules given earlier for the set AE allow for the peculi ar expressions 9 and.

Show that if n is less than 3 1. Rule 2 If xy: What is it? Prove it. The language L defined in this way is a famous mathematical set. Fix this problem. We might define a l anguage by the symbols: We defined L 1 i n Chapter 2 b y the symbols: I but now the symbols are becoming more of an IQ test than a clear defi n i tion. I and again we could presume that we all agree on what words are in this language.

Let us reconsider the language L4 of Chapter 2: I I n that chapter. As shorthand for thi s. More preci sion and less guesswork are required. In this chapter. We might even have defi ned the l anguage L2 by the symbols: I and we presumed that we all understood exactly which values n could take. No string can contain a blank unless a blank is a character in the alphabet l. If we want blanks to be in the alphabet.

It stands for any string of. We can apply the Kleene star to the whole string ah if we want. Since the star represents some kind of exponentiation. It represents an arbitrary concatenation of copies of that letter maybe none at a l l.

L 4 is then the set of all possible strings of. We can think of the star as an unknown power or undeterm i ned power. This is why we use the word "language" in the equation.

You might also like: INTRODUCTION TO WORK STUDY PDF

The star operator appl ied to a letter is analogous to the star operator appl ied to a set. Notice that ha and aha are not in this language. Our symbo li sm e l iminates this ambiguity. The 1 notation i s a convenience.

It would be a subtle m istake to say onl y that this l anguage i s the set of all words that begin and end with an a and have only h 's in between. For every set of choices. The set of al l strings that can be produced by this method i s the language of the expression. I A l l the words in T begin with an a or a c and then are followed by some number of h's. Care should be taken so as not to confuse this with " as an exponent. Each set of choices is a word.

We l e t the word "some" always mean "some o r no. A regular language is one that can be defined by a regular expression even though it may also have many other fine definitions. Formal Definition of Regular Expressions 35 The first letter of each word in L is either an a or a h.

This is a very powerful notation. This is a very important expression and we shall use it often. A regular expression. As is no surprise to those who have read the title of this chapter. The third letter of each word in L is either an a or a h. The second letter of each word in L is either an a or a h.

## Introduction to Computer Theory by Daniel I. a. Cohen - Second Edition

The string "French" is both a word an adjective and a language-defining name a noun. For any r. Every word in such a book is a book-definer. The same confusion occurs in everyday speech. Rule 2 If r 1 and r2 are regular expressions. Context and typography will guide us. Do we really need to invent yet another symbol for the regular expression that defines the language with no words?

Would it simply be the regular expression with no characters. It is analogous to a book that lists all the books in print. A itself is a regular expression. Both are regular expressions and both can be generated from the rules. As with the recursive definition of arithmetic expressions. However difficult computer theory may seem. Because of Rule 1. This is a language of language-definers. The definition we have given for regular expressions contains one subtle but important omission: In the expression above.

We have done this with languages as sets before. In other words. We should note that this use of the plus sign is consistent with the principle that in these expressions plus means choice. A a hhaah or ahb a ab or ahha a h If the only words left out of the language defined by the expression above are the words without a's A and strings of b's. We shall avoid this philosophical crisis by never using this symbolism and avoiding those who do.

When we add sets to form a union. The only words left out are those that have only h's and the word A. All told. If we combine these two.

The expressions below also describe the language of words with at least two a's: In this set are ahhhahh and aaaaa. We are taking the union of two sets. Formal Definition of Regular Expressions 39 which describes such words as aah.

To make the word aah. Such words as ha and hhaaaa are not included in this set. When these are included. There is a simpler expression that defines the same language. It means that all the words that do not contain the substring ah which are accounted for in the first term are all a's. If l is a finite language that includes the null word A.

We can represent a finite language by using the plus sign union sign alone. Let V also contain the word A: We have a hybrid system: But the analogies to algebra should be approached very suspiciously. Expressions may be distributed but operators cannot. Rule 2 If r 1 is a regular expression associated with the language L 1 and r 2 is a regular expression associated with the language L2.

Some words in this language are ennuiverboten and souffleGesundheit. As we might suspect. As we build up a regular expression from the rules. The rules seem to show us how we can interpret the regular expression as a language.

Another fundamental question is this: We may be centuries away from being able to do that.

## Introduction to Computer Theory, 2nd Edition

This correspondence between regular expressions and languages leaves open two other questions. As to the first and perhaps most important question. This is a question of meaning. Is there some way of telling when this happens?

By "way" we mean. We shall present an algorithmic procedure in Chapter 1 1 to determine whether or not two regular expressions define the same language. The situation for languages with infinitely many words is different. In our next theorem. Before we can construct an algorithm for obtaining understanding. We need only show that at least one regular expression exists. We can think of it as arbitrary double letter arbitrary Let us now ask.

But since all strings with three or more a 's are themselves already strings with two or more a 's. The first term above clearly represents all words that have at least three a's in them.

Before we analyze the second term.

Let us break up the middle plus sign into its two cases: If one had not just seen this explained. Let us start with the observation that all strings either have a double a or isolated a 's as in the example above: If we are simply interested in being devilish and creating a mess.

Then we finish up with a final a or we leave the last b's as they are. It cannot contain more than everything. The language defined by the regular expression on the right cannot contain any word with a double b. The typical word here starts with some b's. And so on. Once we have found the balancing unmatched pair. We know that another undoubled pair will be coming up to balance off the initial one. By "balancing. If this were all we wanted to conclude. One method is to keep two binary flags.

One property of this section of the word is that it has an even number of a 's and an even number of h's. But there is another method that also works which uses only one flag.

We start both flags at 0 and check to be sure they are both 0 at the end. We are about to feed in a long string of a's and h's. The proof of this parallels our argument above.

## Related titles

All words in the language of E are made up of these three types of substrings and. This method will work. We read the letters in two at a time. Consider a word w with even a 's and even h's. Let us consider this as a computer algorithm. The total effect is that every word of the language of E contains an even number of a ' s and an even number of h's.

## Introduction To Computer Theory, 2Nd Ed

Every time an a is read. If the flag starts at 0. After this section of type 3. All strings with an even number of a 's and an even number of b 's belong to the language of E. If they are the same. Consider them bookends or open and close parentheses. To some the obvious solution was to ignore the existence of set theory. Some others thought that set theory had a disease that needed to be cured, but they were not quite sure where the trouble was. The naive notion of a general "set" seemed quite reasonable and in nocent.

When Cantor provided sets with a mathematical notation, they should have become mathematical objects capable of having theorems about them proven. All the theorems that dealt with finite sets appeared to be unchallengeable, yet there were definite problems with the acceptabil ity of infinite sets.

In other branches of mathematics the leap from the finite to the infinite can be made without violating intuitive notions. Calculus is full of infinite sums that act much the way finite sums do; for example, if we have an infinite sum of infinitesi mals that add up to 3, when we double each term, the total will be 6. The Euclidean notion that the whole is the sum of its parts seems to carry over to infinite sets as well ; for example, when the even integers are united with the odd integers, the result i s the set of all integers.

In the year 1 , Dav id Hilbert, as the greatest l iving mathematician, was invited to ad dress an international congress to predict what problems would be important in the century to come.

Either due to his influence alone, or as a result of his keen analysis, or as a tribute CHAPTER 1 Background to his gift for prophecy, for the most part he was completely correct.

The 23 areas he indi cated in that speech have turned out to be the major thrust of mathematics for the twentieth century. Although the invention of the computer itself was not one of his predictions, several of his topics tum out to be of seminal importance to computer science.

First of all, he wanted the confusion in set theory resolved. He wanted a precise ax iomatic system built for set theory that would parallel the one that Euclid had laid down for geometry. In Euclid's classic texts, each true proposition is provided with a rigorous proof in which every line is either an axiom or follows from the axioms and previously proven theo rems by a specified small set of rules of inference.

Hilbert thought that such an axiom sys tem and set of rules of inference could be developed to avoid the paradoxes Cantor and oth ers had found in set theory. Second, Hilbert was not merely satisfied that every provable result should be true; he also presumed that every true result was provable.

And even more significant, he wanted a methodology that would show mathematicians how to find this proof. He had in his mind a specific model of what he wanted. In the nineteenth century, mathematicians had completely resolved the question of solv ing systems of linear equations.

Given any algebraic problem having a specified number of linear equations, in a specified set of unknowns, with specified coefficients, a system had been developed called linear algebra that would guarantee one could decide weather the equations had any simultaneous solution at all, and find the solutions if they did exist. Thi s would have been an even more satisfactory situation than existed in Euclidean geometry at the time. If we are presented with a correct Euclidean proposition relating line segments and angles in a certain diagram, we have no guidance as to how to proceed to pro duce a mathematically rigorous proof of its truth.

We have to be creative - we may make false starts, we may get completely lost, frustrated, or angry. We may never fi n d the proof. Linear algebra guarantees that none of this will ever happen with equations. As long as we are tireless and precise in following the rules, we must prevail, no matter how little imagination we ourselves possess. Notice how well this de scribes the nature of a computer.

Today, we might rephrase Hilbert's request as a demand for a set of computer programs to solve mathematical problems. When we input the problem, the machine generates the proof. It was not easy for mathematicians to figure out how to follow Hilbert 's plan. Math ematicians are usually in the business of creating the proofs themselves, not the proof-gener ating techniques.

What had to be invented was a whole field of mathematics that dealt with algorithms or procedures or programs we use these words interchangeably. From this we see that even before the first computer was ever built, some people were asking the question of what programs can be written. It was necessary to codify the universal language in which algorithms could be stated. Addition and circumscribing circles were certainly allowable steps in an algorithm, but such activities as guessing and trying infinitely many possibilities at once were definitely prohibited.

The language of algorithms that Hilbert required evolved in a natural way into the language of computer programs. The road to studying algorithms was not a smooth one. The first bump occurred in when Kurt Godel proved that there was no algorithm to provide proofs for all the true state ments in mathematics. In fact, what he proved was even worse. He showed that either there were some true statements in mathematics that had no proofs, in which case there were cer tainly no algorithms that could provide these proofs, or else there were some false state ments that did have proofs of their correctness, in which case the algorithm would be disas trous.

Mathematicians then had to retreat to the question of what statements do have proofs and how can we generate these proofs? The people who worked on this problem. They each fashioned various but simi lar versions of a univer sal model for all algorithms- what, from our perspective, we wou ld call a un iversal al gorithm machine.

Turing then went one step farther. He proved that there were mathematically definable fundamental questions about the machine itself that the ma chine could not answer. On the one hand, this theorem completely destroyed all hope of ever achieving any part of Hilbert's program of mechanizing mathematics, or even of deciding which classes of problems had mechanical answers.

On the other hand, Turing 's theoretical model for an al gorithm machine employing a very simple set of mathematical structures held out the possi bility that a physical model of Turing's idea could actually be constructed.

If some human could figure out an algorithm to solve a particular class of mathematical problem, then the machine could be told to follow the steps in the program and execute this exact sequence of instructions on any inserted set of data tirelessly and with complete precision.

The electronic discoveries that were needed for the implementation of such a dev ice in cluded vacuum tubes, which just coincidentally had been developed recently for engineering purposes completely unrelated to the possibility of building a calculating machine.

This was another fortuitous phenomenon of this period of history. All that was required was the impe tus for someone with a vast source of money to be motivated to invest in this highly specula tive project. It is practically sacrilegious to maintain that World War II had a serendipitous impact on civil ization no matter how unintentional, yet it was exactly in this way that the first computer was born - sponsored by the Allied military to break the German secret code, with Turing himself taking part in the construction of the machine.

What started out as a mathematical theorem about mathematical theorems-an abstrac tion about an abstraction - became the single most practically applied invention since the wheel and axle. Not only was this an ironic twist of fate, but it all happened within the re markable span of IO years. It was as incredible as if a mathematical proof of the existence of intelligent creatures in outer space were to provoke them to land immediately on Earth.

Independently of all the work being done in mathematical logic, other fields of science and social science were beginning to develop mathematical models to describe and analyze difficult problems of their own. As we have noted before, there is a natural correspondence between the study of models of computation and the study of linguistics in an abstract and mathematical sense. It is also natural to assume that the study of thinking and learning branches of psychology and neurology-play an important part in understanding and facili tating computer theory.

What is again of singular novelty is the historical fact that, rather than turning their attention to mathematical models to computerize their own applications, their initial development of mathematical models for aspects of their own science directly aided the evolution of the computer itself.

It seems that half the intel lectual forces in the world were leading to the invention of the computer, while the other half were producing ap plications that were desperate for its arrival. Two neurophysiologists, Warren McCulloch and Walter Pitts, constructed a mathemati cal model for the way in which sensory receptor organs in animals behave. The model they constructed for a "neural net" was a theoretical machine of the same nature as the one Turing invented, but with certain limitations.

Modern linguists, some influenced by the prevalent trends in mathematical logic and some by the emerging theories of developmental psychology, had been investigating a very similar subject: What is language in general? How could primitive humans have developed language? How do people understand it? How do they learn it as children? How do people construct sentences from the ideas in their minds? Noam Chomsky created the subject of mathematical models for the description of lan guages to answer these questions.

His theory grew to the point where it began to shed light on the study of computer languages. The languages humans invented to communicate with one another and the languages necessary for humans to communicate with machines shared many basic properties. Although we do not know exactly how humans understand language, we do know how machines digest what they are told.

Thus, the formulations of mathematical logic became usefu l to linguistics, a previously nonmathematical subject. Metaphorical ly, we could say that the computer then took on linguistic abilities. It became a word processor, a translator, and an interpreter of simple grammar, as well as a compiler of computer lan guages. The software invented to interpret programming languages was applied to human languages as well.

One point that will be made clear in our studies is why computer lan guages are easy for a computer to understand, whereas human languages are very difficult.

Because of the many influences on its development, the subject of this book goes by various names.

It includes three major fundamental areas: the theory of automata, the the ory of formal languages, and the theory of Turing machines. This book is divided into three parts corresponding to these topics. Our subject is sometimes called computation theory rather than computer theory, be cause the items that are central to it are the types of tasks algorithms or programs that can be performed, not the mechanical nature of the physical computer itself.

However, the name "computation" is misleading, since it popularly connotes arithmetical operations which com prise only a fraction of what computers can do. The term computation is inaccurate when de scribing word processing, sorting, and searching and awkward in discussions of program verification.I t i s analogous t o saying that if people are made up of molecules and molec ules are made up of atoms. All the theorems that dealt with finite sets appeared to be unchallengeable.

Any table of the form a x b y z in which the dots are filled with the letters x. We now have a perfectly defined finite automaton. The situation with bb is analogous.

Or else we could read the three letters baa and go to state 2 from which the final letter. The people who worked on this problem. It is easy to see how this string can be accepted by this machine. I f what remains is not A t h i s means some letters are left.