0% found this document useful (0 votes)
11 views17 pages

Turing Machine 2831

This document presents an overview of Turing machines, a mathematical model of computation introduced by Alan Turing in 1930. It describes the components of a Turing machine, including its structure, states, and transition functions, as well as an example of a Turing machine that accepts a specific language. The document also explains the concepts of acceptance and halting states in relation to Turing machines.

Uploaded by

s.gul45803
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
11 views17 pages

Turing Machine 2831

This document presents an overview of Turing machines, a mathematical model of computation introduced by Alan Turing in 1930. It describes the components of a Turing machine, including its structure, states, and transition functions, as well as an example of a Turing machine that accepts a specific language. The document also explains the concepts of acceptance and halting states in relation to Turing machines.

Uploaded by

s.gul45803
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 17

Turing Machines

Welcome to this presentation on Turing machines

by Mudassar Ali 2831


Introduction to Turing Machine
It was first introduced by Alan Turing in 1930. A Turing machine (TM) is a
mathematical model of computation. It is a language acceptor for the class
of languages known as recursively enumerable languages. Recursively
enumerable languages are also called Turing recognizable languages.

A Turing machine is a finite automaton that can read, write, and


erase symbols on an infinitely long tape. The tape is divided into
squares, and each square contains a symbol. The Turing machine can
only read one symbol at a time, and it uses a set of rules (the
transition function) to determine its next action based on the current
state and the symbol it is reading.
A TM is expressed as a 7-tuple (Q, T, B, ∑, δ, q0, F) where:

• Q is a finite set of states


• T is the tape alphabet (symbols which can be written on Tape)
• B is blank symbol (every cell is filled with B except input alphabet initially)
• ∑ is the input alphabet (symbols which are part of input alphabet)
• δ is a transition function which maps Q × T → Q × T × {L,R}. Depending on
its present state and present tape alphabet (pointed by head pointer), it
will move to new state, change the tape symbol (may or may not) and
move head pointer to either left or right.
• q0 is the initial state
• F is the set of final states. If any state of F is reached, input string is
accepted.
• A Turing machine consists of a tape of infinite length on which
read and writes operation can be performed. The tape
consists of infinite cells on which each cell either contains
input symbol or a special symbol called blank. It also consists
of a head pointer which points to cell currently being read and
it can move in both directions.
Tape A Turing Machine
...... ......

Read-Write head
Control Unit

5
Turing Machine Example

Let us construct a turing machine for L={0^n1^n|n>=1}

Q = {q0,q1,q2,q3} where q0 is initial state.


T = {0,1,X,Y,B} where B represents blank.
∑ = {0,1}
F = {q3}
Transition function δ is given in Table 1 as:
Turing Machine Example
A Turing machine that accepts the language:
aa *

a  a, R

  , L
q0 q1

9
Time 0   a a a  

q0

a  a, R

  , L
q0 q1

10
Time 1   a a a  

q0

a  a, R

  , L
q0 q1

11
Time 2   a a a  

q0

a  a, R

  , L
q0 q1

12
Time 3   a a a  

q0

a  a, R

  , L
q0 q1

13
Time 4   a a a  

q1

a  a, R Halt & Accept

  , L
q0 q1

14
Final States
q1 q2 Allowed

q1 q2 Not Allowed

• Final states have no outgoing transitions


• In a final state the machine halts

15
Acceptance
If machine halts
Accept Input
in a final state

If machine halts
in a non-final state
Reject Input or
If machine enters
an infinite loop
16
THANK YOU

You might also like