Turing Machines 1
Turing Machines 1
Introduction
-- Sakshi Surve
TM consists of ….
A head which can read or write a symbol or
move to Left or Right or may stay in the same
position.
...... ......
Read-Write head
Control Unit
A Turing Machine (TM) has finite-state control (like PDA), and an
infinite read-write tape.
• The tape is divided into cells, and each cell holds one symbol
from the tape alphabet.
• At any instant, all but finitely many cells hold B….and the
input string has B to its both sides
• The contents of this cell and the current state determine the
next move of the TM.
The Input String :
Input string Blank symbol
...... ......
B B a b a c B B B
head
...... ......
Read-Write head
Read-Write head
1. Reads a symbol
2. Writes a symbol
3. Moves Left or Right or stays at same place
Example: Time 0
...... ......
a b a c
q0
Time 1
...... ......
a b k c
1. Reads a
q0
2. Writes k
( q 0, k , L )
3. Moves Left
Time 1
...... ......
a b k c
q0
Time 2
...... ......
a O k c
1. Reads b q1
2. Writes O
( q1, k , R )
3. Moves Right
A Turing Machine performs following three
actions before the next interval begins :