Sei sulla pagina 1di 12

06-05934 Models of Computation The University of Birmingham

Spring Semester 2009 School of Computer Science


Volker Sorge February 9, 2009

Handout 4
Summary of this handout: Turing Machines — Algorithms — Sequence of Configurations — General
Computation — High-Level Diagrams
The automata we had so far are good for answering the decision problem for some languages: if a string
belongs to some language depends on whether or not an automaton’s computation ends in an accepting
state. Obviously this is not enough if we want to simulate general computational devices, which can
solve more general computational problems — computing some specified output given some input. We
therefore shift now to machine models, which also have output capabilities.
The primary difference is that an automaton performs the computation

L ⊆ Σ∗ → yes and L ⊆ Σ∗ → no,

while a machine computes a function between two languages potentially over two different alphabets:

L ⊆ Σ∗ −→ M ⊆ Γ∗

Languages L and M are generally called computational data types. We will discuss decision and com-
putational problems as well as computational data types in more detail in Handout 7.

III. Turing machines


The primary machine model we will work with in the lecture are Turing machines. Turing machines are
a general mathematical model of computation that will give us

1. a precise notion of the concept of an algorithm;

2. a means to compare different hardware architectures and programming languages;

3. indivisible computation steps for an exact and scalable complexity measure.

1. Concept of Algorithm: The word algorithm goes back to al-Khwārizmı̄, a ninth century Persian
mathematician and astronomer (actually algorithm was a mistranslation of his name). However the no-
tion of algorithm is much older. For example Euclid’s algorithm, for calculating the greatest common
divisor of two positive numbers was published more than 2000 years ago, the Chinese Remainder The-
orem, a procedure for solving a simultaneous system of congruences, is at least 1500 years old. In the
Middle Ages, most of Mathematics consisted of algorithms for everyday computational tasks, such as
calculating interest on some capital. Since the Renaissance the question of finding algorithmic solutions
to problems was becoming increasingly important, eventually culminating in David Hilbert’s challenge
in 1928 to show whether every mathematical question can be formulated in First Order Logic and de-
cided mechanically (a question directly related to the halting problem). Although this was shown to be
impossible by Kurt Gödel in 1931 it has led to interest in defining a precise notion of algorithm, i.e., an
effective procedure to compute a class of problems. Both Alonzo Church and Alan Turing achieved this
in 1936. We will have a look at Church’s solution, the λ-Calculus towards the end of this term. Turing’s
approach yielded the Turing Machine, a model that he originally used to show the Halting Problem.
2. Compare Architectures and Languages: The Turing Machine model can be used to compare dif-
ferent hardware architectures and different programming languages, and to ask whether one is more
powerful than the other. Note that this means expressive power in terms of what can and cannot be cal-
culated, and not speed, which differs from machine to machine. As far as we can tell today, there are no
differences of expressiveness between any of today’s mainstream machines or languages. For example,

39
in order to show that Java and Prolog have equivalent expressiveness, we have to simulate programs
written in one language by programs written in the other. This could be a rather complicated and tedious
process. Instead, we will use the Turing machine and show that it is capable of simulating the behaviour
of common computer hardware. In order to show that Prolog, then, can simulate Java programs, all we
need to do is simulate a Turing machine in Prolog. As a picture:
Compilation Simulation Simulation
Java Program Machine Code Turing Machine Prolog
In this sequence, the first transformation is effected by any Java compiler, the second step will be the
topic of the next handout, and the third is very easy because Turing machines are very primitive devices
as we will see in this handout.
3. Complexity Measure: Turing machines give us a precise means to measure the relative computational
difficulty of a computational function. This is called the complexity of a problem. It happens quite
often that an implementation for some problem has a straightforward solution for small instances, but
a completely different strategy has to be chosen for larger instances. For example, multiplying two
integers is easy so long as the numbers and the result fit into single integer variables. For very large
integers (such as the ones used in Cryptography), one must implement arithmetic operations on arrays of
integer variables. What we need for a study of the eventual complexity of algorithms is a machine model
which scales up without changes.
Again, complexity is independent from the speed of an actual machine. Hardware designers come up
with ever new ideas of speeding up processors, caches at several levels, longer and more registers,
pipelining, code look-ahead, etc. The result of these advances is that it is no longer possible to say
precisely how many cycles a particular machine instruction will need for its execution. In contrast, the
Turing machine model offers a clearly defined notion of a single indivisible computation step.
Please note that Turing machines are not meant to be practical devices.

III.1 Definition
There are many variations on the definition of a Turing machine in the literature and we will use a rather
simple one. Later on, we will see that all those definitions are equivalent anyway.
The basic idea of a Turing machine is to carry out a computation on an unlimited tape that is used both
for input and output. The tape can be accessed in a random access manner to perform read and write
operations. These are controlled using a finite number of states and their changes similar to a finite or
pushdown automaton. In overview the Turing machine consists of the following components:
Tape of unlimited size (in both directions) which is divided into cells or fields. Each cell can hold
exactly one symbol.
Read/Write Head which at any moment will be above exactly one cell of the tape. It can be moved left
or right by one field.
Control Unit which decides on the next action. The next action depends on the symbol the head is
currently reading, and the state the control unit is currently in. There are only finitely many states.
The next action can be
Writing a symbol into the current cell of the tape (thereby erasing the symbol that was there);
Moving the head one cell to the left or to the right;
Stopping the computation entirely.
A picture will help to understand the setup:
a b a tape
read/write head

control unit

40
Here’s the formal definition of all the components of the model:

Definition 18 (Turing Machine) A deterministic Turing Machine is a five-tuple (Σ, T, Q, q0 , δ) con-


sisting of the following components:

(i) A finite alphabet Σ, called the input alphabet.

(ii) A finite alphabet T , called the tape alphabet. We assume that Σ ( T , i.e. T will contain all symbols
of Σ but can contain additional auxiliary symbols. In particular at least one more symbol, namely,
the blank. We denote the blank by . In pictures we leave cells containing the blank empty.

(iii) Two special symbols r, l 6∈ T denoting the head moving on the tape right or left, respectively and
a special symbol stop 6∈ T denoting the termination of computation.

(iv) A finite set Q of states.

(v) A start state q0 ∈ Q.

(vi) A (partial) transition function δ: Q × T 99K (Q × (T ∪ {r, l})) ∪ {stop}.

The possible actions of the Turing machine are determined by the transition function δ. When given a
state and a tape symbol, δ will return the next state of the control unit and a symbol. This symbol can be
either a tape symbol, or one of the letters r and l. A tape symbol indicates a write-command, whereas
r and l indicate a movement of the head without changing the tape contents. Instead of returning a pair,
consisting of a new state and an action, we allow δ to also return just the special action stop to indicate
that the Turing machine will stop the computation.
If we only want to change state on some input symbol, without moving the head or changing the input
symbol, δ will return a pair containing the new state as well as the symbol in the current tape cell (i.e.,
the tape cell will be overwritten with the same symbol and therefore not changed).
Example: If the input alphabet is Σ = {a, b} and the only auxiliary symbol is the blank, and if the
machine has only the two states q0 = 0 and 1, then the following would be a possible table for the
transition function:
δ a b
q0 = 0 (1, r) (1, r) stop
1 stop stop stop
It describes a machine which will move its head one place to the right if the current tape symbol is either
a or b, and then stop. If the current tape symbol is a blank, it stops immediately. Some authors call the
transition table the program of the Turing machine.

III.2 Computations
To precisely describe the computations of a Turing machine we need to define the configuration of a
machine. At any point in time the tape will only contain finitely many symbols different from blank.
The head will be above one cell, and the control unit will be in a certain state. A configuration of a
machine is thus defined by these three pieces of information: (1) tape content, (2) head position, and
(3) state of the control unit.
At the beginning of a computation we assume that the tape contains only blanks except for some finite
string of input symbols somewhere on the tape. Unless explicitly stated we generally don’t make any
special assumptions about the position of the head but will say things like: “The Turing machine was
started on aabba, with the head immediately left of the first a.”
Computation proceeds stepwise from one configuration to the next. The nature of the atomic steps is
prescribed in the transition table. There are essentially three different types of actions corresponding to
writing, moving, and stopping:

41
1. If, for the current state and the current symbol on the tape, the transition function returns the
pair (q, x), where q ∈ Q and x ∈ T , then the tape content at the current position is overwritten
with x and the control unit assumes state q. The head does not move.

2. If δ returns (q, r) or (q, l) then the head moves one position to the right, respectively to the left,
but tape content is left unaltered. The new state is again q.

3. If δ returns stop, then nothing happens at all; the machine stops.

Unless otherwise stated, we say that the result of the computation is the string of input symbols immedi-
ately to the left of the read/write head after the computation has terminated.
37. Sequence of Configurations
We can give the computation of a Turing machine for a given input as a sequence of configurations. We
can write down a string of symbols for all the cells left of the current head position (up to the leftmost
symbol different from ) and a string for all symbols to the right, including the symbol currently read
by the head. As a separator between the two strings we can write down the current state. The whole
configuration is then described by one long (but finite) string.
The following is an example of a machine which goes to the right end of its input, prints an a and stops.
The sequence of configurations, when started on aabba with the head two fields left of the first a, is
given next to it. ↓
0 aabba aab 1 ba
↓ ↓
δ a b 0 aabba aabb 1a
↓ ↓
q0 = 0 (1, r) (1, r) (0, r)
0 aabba aabba 1
1 (1, r) (1, r) (2, a)
↓ ↓
2 (3, r) (3, r) (3, r) a 1 abba aabba 2 a
3 stop stop stop ↓ ↓
aa 1 bba aabbaa 3
↓ ↓
stop
Note that the machine will run forever if it is started with its head to the right of the input. Also note
that the two last entries in the transition table in row 2 are redundant. This is because the machine,
reaching this state from state 1, has just written a on the tape, so those two cases can never apply. Such
redundancies are not always avoidable, but the entries can be omitted.
38. Transition Diagram
Similar to finite automata, it is possible to draw a state transition diagram for a Turing machine. In such
a diagram the nodes stand for states of the machine. Every transition is denoted with a string of the form
x/y where x is the symbol in the current cell of the tape and y is the action the machine will perform.
Additionally there is one accepting state that is reached when the machine stops.
/r a, b/r

a, b/r /a , a, b/r
0 1 2 3

Note that in order to trace the behaviour of a Turing machine it is not enough to follow transitions in this
state graph. It is essential that one also records how the tape and the head position are changing.
39. Tasks for Turing Machines
Turing machines can be designed for every type of computational problem. For example, if the task
is to program a function from integers to integers, then we can use the alphabet Σ = {0, 1} of binary
digits (although in our examples we will generally use the letters a and b, to keep the distinction with

42
states clear) to write the input number on the tape. After the machine has finished its computation,
then according to the convention above, the result will be the longest contiguous string consisting of 0’s
and 1’s immediately to the left of the read/write head.
In the same vein, a machine can be designed for a function of two integer variables. The two inputs
can then be written on the tape in binary notation, separated by a blank. If all we are interested in is a
decision problem, then we can designate one symbol x from Σ to stand for “yes”, and another one, say y,
to stand for “no”. The input string would be on the tape at the beginning of the computation and when
the machine stops, we look at the symbol immediately to the left of the read/write head. If it is x then the
string was accepted, if it is y then it was rejected. Alternatively, we can request the head to stop either
left or right from the input string to indicate acceptance or not.
As mentioned before, it can happen that a Turing machine runs forever when started on some input. His-
torically, the name “Halting Problem” comes from the question of whether one can find out mechanically
whether a given Turing machine will eventually stop or not.
40. Concrete vs General Computation
A sequence of configurations describes a concrete computation of a Turing machine on some given input.
However, every Turing machine defines a procedure to compute functions on langaguages or data types.
Alternatively, a Turing machine can also be used to decide languages, similar to an automaton. This is
what we mean when we speak of the general computation of a Turing machine.
Example: The general computation of the small machine above can be described as: For every w ∈
{a, b}∗ the machine returns wa.
To find the general computation of a Turing machine one often has to test several concrete computations.

III.3 Designing Turing Machines


Turing machines can be built in a modular fashion, by designing larger machines from small ones. The
following machines are particularly simple:

r a b l a b a a b
q0 = 0 (1, r) (1, r) (1, r) q0 = 0 (1, l) (1, l) (1, l) q0 = 0 stop (0, a) (0, a)
1 stop stop stop 1 stop stop stop

The first one moves the head one place to the right and stops, the second one moves it left and stops, and
the third one prints a into the current cell and stops. Obviously, we have a basic machine x of the latter
kind for every symbol x in the tape alphabet.
We can use these machines to build more complicated ones in the following way. If M1 and M2 are
Turing machines, then we can create a Turing machine which will first behave like M1 and then like
M2 by first changing the names for states in the second one so that they become all different from the
ones used for M1 , then writing the two transition tables below each other, and finally changing all entries
stop in the M1 -part into (q0 , x), the name of the start state of M2 together with the tape symbol of the
particular column.
Let us in this way create a machine ar which writes a and then moves its head to the right:
a a b a a b
0 stop (0, a) (0, a) 0 stop (0, a) (0, a)
a b
0 stop (0, a) (0, a)
=⇒ =⇒
1 (2, r) (2, r) (2, r)
r a b r a b
2 stop stop stop
0 (1, r) (1, r) (1, r) 1 (2, r) (2, r) (2, r)
1 stop stop stop 2 stop stop stop ⇓
ar a b
0 (1, a) (0, a) (0, a)
1 (2, r) (2, r) (2, r)
2 stop stop stop

43
41. High-Level Diagrams
In general, if we combine M1 and M2 in this way, we write M1 M2 for the resulting machine. For
example, the machine Mrargrgrire will write the name Maggie on the tape (assuming that M, a, g,
i, and e are valid tape symbols). We can build recursive machines by allowing machines to return to
previous tables. In our notation we indicate this with arrows. For example, the following machine writes
a’s forever.

ar
Finally, we can control recursion by annotating arrows with symbols from the tape alphabet. This means
that a certain transition is only possible if the currently scanned symbol is the one written next to the
arrow. When putting transition tables together, what this means is that only those stop entries are replaced
by the start state of the other machine which appear in the right column.
This is quite a powerful formalism for describing Turing machines and we don’t actually have to write
down transition tables anymore. For example, the following machine searches for the first blank to the
right of the current head position:

6=

r
We call diagrams of the above form composite or high-level diagrams that describe the computation of a
Turing machine in terms of smaller, easier to understand components. It is usually clear where to start in
such a diagram but we can emphasise it by including a “dangling” arrow if necessary.
Example: We design a larger machine which shifts its input one field to the right (assuming that initially
the head is to the left of the input):

6=
a ral
r 6= r l stop
start
b rbl

Described in words, the above machine will first scan over blanks until it finds a non-blank. It will then
go to the end of the non-blank stretch and start working from the right. It will now do the following
repeatedly: Go one step to the left, remember the symbol scanned in the state, print a blank, go to the
right, print the symbol remembered and go left again. Writing out the transition table shows how the
decision on which symbol is currently scanned is implemented (for clarity, we leave out the cases which
can never occur):
a b
q0 = 0 (1, r) (1, r) (0, r)
1 (1, r) (1, r) (2, l)
2 (3, ) (4, ) stop
3 (5, r)
4 (6, r)
5 (7, a)
6 (7, b)
7 (1, l) (1, l)
This is how this machine would behave on the input aab (where we include a blank at each end to
make the absolute position of the tape contents clear): 0 aab → a 1 ab → aa 1 b →

44
aab 1 → aa 2 b → aa 4 → aa 6 → aa 7 b → aa 1 b →
a 2 a b → a 3 b → a 5 b → a 7 ab → a 1 ab → 2 a ab →
3 ab → 3 ab → 7 aab → 1 aab → 2 aab → stop.
Finally we have look at the transition diagram for the “shift-right-machine” from above:

/r a, b/r
/r
3 5
/a
a/
0 1 2 7
a, b/r /l b/ /b
/r
4 6 a, b/l

III.4 More Examples


42. Copying
Let us define a machine which copies a stretch of input symbols using a high-level diagram only. When
started on a tape which contains one word of input symbols to the left of the head, it will create a second
copy of the word to the right of the first copy, separated by a blank from the initial copy. We use the
abbreviations L for a machine which searches for the first blank to the left of the current position of the
head, and similarly R for a machine which finds the first blank to the right:

a RRaLLa

start L r R stop

b RRbLLb

43. Accepting a Language


As a final example, let us build a Turing machine that checks whether a string contains an equal number
of a’s and b’s. If the input string is of that form, the Turing machine will stop with the read/write head to
the right of the string on the tape, otherwise it will stop with the head to the left of the string. The actual
input string can be destroyed during the computation.
Idea: We search the string and if we

1. first find an a we mark it and search for a matching b. If we find the matching b we mark it and
start our computation at the beginning of the string again. If we do not find a matching b, we go
all the way to the left of the string and stop.

2. first find a b we search for a matching a similar to (1).

3. cannot find an a or b in the string anymore, we stop to the right of the string.

We define the components of our Turing machine M as Σ = {a, b} and T = {a, b, , x, y}, where x
and y are auxiliary symbols, which we use to mark already counted a’s and b’s.

45
We could now try to give the transition function δ immediately. However, it is generally easier to think
first about the computations of the machine in terms of smaller machines. So let r be a machine that
moves one step to the right, let L be a machine that searches for the first blank to the left of the current
position of the head, and let x and y be machines that write x and y on the tape, respectively, we can then
give the following diagram for our computations:

a,y,x

xL r b yL
start a

r stop L
x,y
b
yL r xL
a

b,y,x

We can now translate more easily the single computational steps of M into the transition function δ. For
example, we start with the computation of the machine r:

• On input x and y it will repeat its computation: we go right and stay in the same state.

• On input a it will execute the machine x: we write x and go to a new state.

• On input b it will execute the machine y: we write y and go to a new state. Now observe that
this has to be a different state from the one we enter after reading an a, which is indicated by the
diverging arrows in the diagram.

• On input we stop.

This corresponds to the first row in the table below:

δ a b x y
q0 = 0 (1, x) (4, y) (0, r) (0, r) stop
1 (1, l) (1, l) (1, l) (1, l) (2, r)
2 (2, r) (3, y) (2, r) (2, r) (6, l)
3 (3, l) (3, l) (3, l) (3, l) (0, r)
4 (4, l) (4, l) (4, l) (4, l) (5, r)
5 (3, x) (5, r) (5, r) (5, r) (6, l)
6 (6, l) (6, l) (6, l) (6, l) stop

Now row 1 corresponds to the machine L, which moves all the way to the left of the string. Row 2
corresponds to the part
a,y,x

b y
r

in the diagram. State 3 is the machine L before we move back to the start state. State 6 is the machine
L that leads to stop. Note, that we have to use different states here, since in state 3 we had a successful
match, whereas in state 6 the matching has failed.

46
In the lower half of the diagram we have a symmetrical situation: Here row 4 is very similar to row 1.
However it needs to be a different state since we remember that we have just read a b and now look for
an a, as opposed to having read an a and looking for a b as in the case of row 1. And state 5 is analogous
to state 2.
We can now draw the state transition diagram for our automaton:
x, y/r a, b, x, y/l a, x, y/r a, b, x, y/l b, x, y/l b, x, y/r a, b, x, y/l

a/x /r b/y /r /l
0 1 2 3 4 5 6

/r a/x

/l
b/y

And finally let’s apply M to two input strings abba and aba. The former is accepted by the automaton,
the latter is not, i.e. on input abba the read/write head should stop to the right of the string at the end
of the computation, whereas for aba it should stop to the left. Let’s observe M ’s computation with a
sequence of configurations for both input strings:


0 aba
x 1 yx
↓ ↓
↓ ↓
0 abba xy 0 ba 1 xba
xy 3 yx 1 xyx
↓ ↓ ↓
↓ ↓
1 xbba xy 4 ya 1 xba
x 3 yyx 1 xyx
↓ ↓ ↓
↓ ↓
1 xbba x 4 yya 2 xba
3 xyyx 2 xyx
↓ ↓ ↓
↓ ↓
2 xbba 4 xyya x 2 ba
3 xyyx x 2 yx
↓ ↓ ↓
↓ ↓
x 2 bba 4 xyya x 3 ya
0 xyyx xy 2 x
↓ ↓ ↓
↓ ↓
x 3 yba 5 xyya 3 xya
x 0 yyx xyx 2
↓ ↓ ↓
↓ ↓
3 xyba x 5 yya 3 xya
xy 0 yx xy 6 x
↓ ↓ ↓
↓ ↓
3 xyba xy 5 ya 0 xya
xyy 0 x x 6 yx
↓ ↓ ↓
↓ ↓
0 xyba xyy 5 a x 0 ya
xyyx 0 6 xyx
↓ ↓ ↓
↓ ↓
x 0 yba xyy 3 x xy 0 a
stop 6 xyx
↓ ↓ ↓

xy 1 x
stop

While our machine does the required task, it is obviously not the only way to construct a Turing machine
that checks input strings for equal numbers of a’s and b’s. An alternative approach would have been to
always search for an a in the string, then find the matching b and start over again with searching for an
a. In case there are no more a’s left in the string the machine would search the entire string again if there
are any b’s left. If there is no b left in the string the input would be accepted, otherwise not.

47
Exercise Sheet 5
Quickies (I suggest that you try to do these before the Exercise Class. Hand in your solutions to the tutor
at the end of the class.)
20. Find out more about Alan Turing at http://www.turing.org.uk/turing/index.html

21. Consider a Turing Machine M over input alphabet Σ = {a} and tape alphabet T = {a, b, } with
transition function δ:
δ a b
q0 = 0 (0, b) (1, r) (0, r)
1 (1, r) (2, r) (1, b)
2 stop stop stop
(a) Give the general computation M performs on an input string containing m a’s, assuming the
read/write head is somewhere left of the input.
(b) Draw the transition diagram for M . 2+1

Classroom exercises (Hand in to your tutor at the end of the exercise class.)
22. Design a Turing machine M over input alphabet Σ = {a, b} that, started on an input string con-
taining a’s and b’s in arbitrary order, replaces each original a by b and each original b by a. For
example the input string abaabb would be transformed into babbaa. Assume that the read/write
head is initially left of the input string.
(a) Give the high-level diagram for the computation of M .
(b) Give the transition function δ for M .
(c) Give the state transition diagram for M .
(d) Test M by giving the computations of your Turing machine for the input abaabb with a
sequence of configurations. 2+2+1+2

Homework exercises (Submit via the correct pigeon hole before next Monday, 9am.)
23. Consider a Turing Machine M over input alphabet Σ = {a} and tape alphabet T = {a, b, }
given by the following high-level diagram, where the machines a,b,r,l are defined as in the
lecture: 4
b

a a a a
a l stop
start r a b r rb r r a l l b a
b
b
a b
al l l r

What is the general computation performed by M applied to an input tape containing am an ,


m, n > 0 (i.e., two strings with m and n a’s separated by a blank). Assume that the read/write
head of M starts left of the input string.
24. Design a Turing machine M over input alphabet Σ = {a, b, c} that decides whether a word is
of the form ai bi ci , i > 0, i.e., a positive number of a’s, followed by the same number of b’s,
followed by the same number of c’s. Assume that the read/write head of M starts left of the input
string. At the end of the computation the read/write head should be to the right of the resulting
string to indicate that the input string indeed had been accepted (i.e. was of the form ai bi ci or
left of the string if it has not been accepted. Your Turing machine is allowed to destroy the input
during the course of the computation.

48
(a) Give the high-level diagram for the computation of M .
(b) Give the transition function δ for M .
(c) Test your Turing machine by carrying out the computations for the input aabbcc , abbc ,
abac with sequences of configurations. 2+2+2

Stretchers (Problems in this section go beyond what we expect of you in the May exam. Please submit
your solution through the special pigeon hole dedicated for these exercises. The deadline is the same as
for the other homework.)

S5. Design a Turing machine which adds two given binary numbers. Take as input alphabet Σ = {0, 1}
and assume that the input numbers are given as two strings devided by one empty cell. For instance,
10 101 would be the input for 2 + 5. Assume also that the read/write head is initially left of
both input strings. It is enough to give the high-level diagram for your machine. You might want
to modularise the problem and design single component machines in order to construct your final
machine. You can use as many auxiliary symbols as you like and you are allowed to destroy the
input in the course of the computation.
[Hint: It is easiest to write the result left of the two input strings on the tape.] 20 bonus points

49
Models of Computation Glossary 4
Algorithm An effective procedure to decide or compute a class of problems. 39

Cell The smallest unit of the tape of a Turing Machine. Each field can hold 40
exactly one symbol.
Complexity The relative computational difficulty of computational functions. The 40
complexity of a problem is given by the most efficient algorithm to de-
cide or compute that problem.
Composite Diagram Another word for high-level diagram. 44
Computational Data Type A class of objects that are suitable for computation. 39
Computational Problem The problem of computing some specified output given some input. This 39
corresponds to finding a general computation from one computational
data type into another.
Configuration The computational state of Turing Machine, which is given by the state 41
of the control unit, the content of the tape, and position of the read/write
head.

Decision Problem The problem of deciding whether a given word belongs to a particular 39
language. The answer to decision problems is “yes” or “no” only.

Field The smallest unit of the tape of a Turing Machine. Each field can hold 40
exactly one symbol.

General Computation The function between two languages or computational data types com- 43
puted by the procedure the Turing Machine implements.

High-level Diagram A high-level description of the computational behaviour of a Turing ma- 44


chine via smaller machines.

Program of a Turing Machine Another expression for the transition function of the Turing Machine. 41

Read/Write Head The input/output device of a Turing Machine. 40

Sequence of Configurations A method of observing the computation of a Turing machine by giving 42


the single configuration it goes through.

Tape The storage device of a Turing Machine holding both input and output. 40
Tape Alphabet The alphabet that a Turing Machine uses to write to its tape. It contains 41
the symbols from the input alphabet together with auxiliary symbols.
Turing Machine A machine that has a randomly accessible unlimited tape as input and 41
output device. It is the most powerful computational model known to
date.

Potrebbero piacerti anche