Presentation is loading. Please wait.

Presentation is loading. Please wait.

AUTOMATA THEORY VIII.

Similar presentations


Presentation on theme: "AUTOMATA THEORY VIII."— Presentation transcript:

1 AUTOMATA THEORY VIII

2 Dept. of Computer Science & IT, FUUAST Automata Theory
Automata Theory VII Turing Machines Dept. of Computer Science & IT, FUUAST Automata Theory

3 Dept. of Computer Science & IT, FUUAST Automata Theory
Automata Theory VII What is Formal Definition of a Turing Machine “A Turing machine is the simplest form of a computer. The concept was invented by Alan Turing in 1936.  This was the first computer invented (on paper only).” "A Turing machine is a finite-state machine associated with an external storage or memory medium." (Minsky (1967), p. 117) "A Turing machine is essentially a finite-state sequential machine that has the ability to communicate with an external store of information." (Booth (1967), p. 354) Deterministic TM’s (DTM) Nondeterministic TM’s (NDTM) Dept. of Computer Science & IT, FUUAST Automata Theory

4 Formal Definition of a Turing Machine
Automata Theory VII Formal Definition of a Turing Machine A DTM is a 7-tuple: M = (Q, Σ, Γ, δ, q0, B, F) Q A finite set of states Γ A finite complete tape alphabet B (#) A distinguished blank symbol, which is in Γ Σ A finite input alphabet, which is always a subset of Γ– {B} q0 The initial/starting state, q0 is in Q F A set of final/accepting states, which is a subset of Q δ A next-move function, which is a mapping (i.e., may be undefined) from Q x Γ –> Q x Γ x {L,R} Intuitively, δ(q,s) specifies the next state, symbol to be written, and the direction of tape head movement by M after reading symbol s while in state q. Dept. of Computer Science & IT, FUUAST Automata Theory

5 Deterministic Turing Machine (DTM)
Automata Theory VII Deterministic Turing Machine (DTM) …… …….. Two-way, infinite tape, broken into cells, each containing one symbol. Two-way, read/write tape head. Finite control, i.e., a program, containing the position of the read head, current symbol being scanned, and the current state. An input string is placed on the tape, padded to the left and right infinitely with blanks, read/write head is positioned at the left end of input string. In one move, depending on the current state and the current symbol being scanned, the TM 1) changes state, 2) prints a symbol over the cell being scanned, and 3) moves its’ tape head one cell left or right. Many modifications possible. B 1 Finite Control Dept. of Computer Science & IT, FUUAST Automata Theory

6 Dept. of Computer Science & IT, FUUAST Automata Theory
Automata Theory VII Def’s. An accepting configuration of TM is a configuration in which the state is the accept state. A rejecting configuration of TM is a configuration in which the state is the reject state. Accepting and rejecting configurations are halting configurations and accordingly do not yield further configurations. We say that a language is recursive if there exists a Turing machine to decide the language. For instance, the language L = {wcw | w {0, 1}*} is recursive. We say that a language is recursively enumerable if it is accepted by some Turing machine. For instance, the language L = {wcw | w  {0, 1}*} is recursively numerable. Note that every recursive language is also recursively enumerable, but a recursively enumerable language is not necessarily a recursive language. Turing machines that halts on all input strings are called deciders, as they always make a decision to accept or reject. A decider that recognizes some language is said to decide that language. Dept. of Computer Science & IT, FUUAST Automata Theory

7 Dept. of Computer Science & IT, FUUAST Automata Theory
Automata Theory VII Turing Machine as Transducer Consider the entire nonblank portion of the initial tape as input, and treat the entire nonblank portion of the tape when the machine halts as output. Dept. of Computer Science & IT, FUUAST Automata Theory

8 Dept. of Computer Science & IT, FUUAST Automata Theory
Automata Theory VII Universal Turing Machines The most striking positive result concerning the capabilities of Turing machines is the existence of Universal Turing Machines (UTM). When started on a tape containing the encoding of another Turing machine, call it T, followed by the input to T, a UTM produces the same result as T would when started on that input. Essentially a UTM can simulate the behavior of any Turing machine (including itself.) One way to think of a UTM is as a programmable computer. When a UTM is given a program (a description of another machine), it makes itself behave as if it were that machine while processing the input. Dept. of Computer Science & IT, FUUAST Automata Theory

9 Dept. of Computer Science & IT, FUUAST Automata Theory
Automata Theory VII Instantaneous Description For a state q and two strings u and v over the tape alphabet ¡, we write u q v for the configuration where the current state is q, the current tape contents is uv, and the current head location is the first symbol of v. For instance, 1011 q7 0111 represents the configuration when the tape is , the current state is q7, and the head is currently on the second 0 of from left to right. We say that configuration C1 yields configuration C2 if the Turing machine can legally go from C1 to C2 is a single step. This notion can be formalized via the transition function. Dept. of Computer Science & IT, FUUAST Automata Theory

10 Dept. of Computer Science & IT, FUUAST Automata Theory
Automata Theory VII Let a, b, and c be symbols of , let u and v be strings over , and let qi and qj be any two states (not necessarily distinct) in Q. Then, we say that ua qi bv yields u qj acv if in the transition function (qi, b) = (qj, c, L). That handles the case where the Turing machine moves leftward. For a rightward move, we say that ua qi bv yields uac qj v if in the transition function (qi, b) = (qj, c, R). Dept. of Computer Science & IT, FUUAST Automata Theory

11 Dept. of Computer Science & IT, FUUAST Automata Theory
Automata Theory VII Working Dept. of Computer Science & IT, FUUAST Automata Theory

12 Dept. of Computer Science & IT, FUUAST Automata Theory
Automata Theory VII Dept. of Computer Science & IT, FUUAST Automata Theory

13 Dept. of Computer Science & IT, FUUAST Automata Theory
Automata Theory VII Example: Language of TM is Sequence of moves of M when input is 0011 Dept. of Computer Science & IT, FUUAST Automata Theory

14 Dept. of Computer Science & IT, FUUAST Automata Theory
Automata Theory VII Transition Diagram Dept. of Computer Science & IT, FUUAST Automata Theory

15 Dept. of Computer Science & IT, FUUAST Automata Theory
Automata Theory VII End of Chapter 8 Dept. of Computer Science & IT, FUUAST Automata Theory


Download ppt "AUTOMATA THEORY VIII."

Similar presentations


Ads by Google