A hierarchy within three different types of references was shown:All three different types of reference are equal. (It was remarked, that the result of Turing machines, that don't halt, is undefined.)
- Turing machines that halt for all inputs
are a subset of
Turing machines that halt for some inputs
are a subset of
Turing machines
- total recursive functions
are a subset of
partial recursive functions
are a subset of
functions
- recursive sets
are a subset of
the set of recursively enumerable sets
is a subset of
sets
- Recursively enumerable sets
are sets for which there exists a Turing machine which can test whether the input is a member of the set. If the input is a member, the Turing machine halts, otherwise it doesn't halt.
- Recursive sets
are sets for which such a Turing machine halt for any input with the positive or negative answer of membership in the set.
TURING COMPLETENESS
A model of computation is "Turing complete", if it can simulate any arbitrary Turing machine. If a model of computation is Turing complete, then the halting problem is indecidable.To show that the Dataflow-model is Turing complete, three different machines were mentioned:
- The Turing-Post machine
This machine consists out of finite controller and a tape. The finite controller has 7 different operations to handle the tape as defined in the last lecture. The finite controller is equal to a finite state machine.
- The Two-Stack-machine
The finite controller operates on two stacks instead of on a tape. It can push and pop. The stacks are unbounded, after they reached their bottom, they produce a "0" for every pop. The one stack can be seen as the left part of the tape of the Turing-Post machine, the other stack can be seen as the right part. It can be shown, that the Turing-post machine and the Two-Stack-machine are equal.
- Counter machine
The Counter machine has three instructions:
- count up
- count down
- test for zero
Two counter machines can implement a stack. For this purpose the stack is denoted as follows:
c = b_0 + 2 b_1 + 2^2 b_2 + ... + 2^m b_m
b_0 represents the top of the stack, b_m represents the bottom of the stack. c is always a finite integer. The operations of push and pop can be implemented with two Counter machines by the following algorithms (c is in counter A, counter B contains 0):All instructions, which are not in the set of a Counter machine, are implemented in a finite state machine. As the Counter machines can simulate a stack, Counter machines plus a finite state machine are equal to the Two-Stack-machine and therefore Turing complete.
push b (c' = 2c + b): while (A != 0) { decrement A increment B increment B } if b then increment Bpop bit (c' = floor[c/2]) bit = 0 while (A != 0) { decrement A if A = 0 {bit = 1; break } decrement A increment B }It was mentioned, that if V = N, then synchronous Dataflow is Turing complete. The question arose, whether a general Dataflow-model is Turing complete. Each actor by itself is a finite state machine, that does not imply Turing completeness. Therefore it can't be the actors and the values, it must be the buffers to fulfill Turing completeness.
To show that a general Dataflow-model is able to implement a Counter machine, a finite state machine with four inputs was constructed. A Kahn-McQueen network therefore is Turing Complete, the halting problem (the deadlock problem) is not decidable for the whole class.