SlideShare a Scribd company logo
1 of 27
Theory of Computation
CSE 2233
Mohammad Imam Hossain | Lecturer, Dept. of CSE | UIU
Chomsky Hierarchy
2
▪ Chomsky hierarchy represents the class of languages that are
accepted by the different machine.
▪ The category of language in Chomsky’s Hierarchy is given
below:
1) Type 0 – Unrestricted Grammar
2) Type 1 – Context Sensitive Grammar
3) Type 2 – Context Free Grammar
4) Type 3 – Regular Grammar
▪ Two major models of automata:
• Generators
– with output and without input
– tell us how to generate all strings in a Language L
• Acceptors
– with input and without output
– tell us if a specific string is in Language L
Mohammad Imam Hossain | Lecturer, Dept. of CSE | UIU
FA >> Schematic Diagram
3
Finite control
a ba a b input
Mohammad Imam Hossain | Lecturer, Dept. of CSE | UIU
Finite Automaton
▸ The control represents the states and transition function.
▸ The tape contains the input string.
▸ The arrow represents the input head, pointing at the next input symbol to be read.
FA can remember a finite amount of information
PDA >> Schematic Diagram
4
z
Finite control
b cc a a
x
y
stack
Mohammad Imam Hossain | Lecturer, Dept. of CSE | UIU
Based on the characteristics of CFG containing recursive rules,
how can we apply a finite state machine to CFG?
▸ The idea to reach the goal is to add a memory device to a FSM.
Push Down Automaton
▸ Input string
▹ Same as FSM
▹ Cannot back up
▸ Stack operations on each transition
▹ READ + POP or, IGNORE
▹ PUSH or, IGNORE
PDA can remember an infinite amount of information but the memory is usable in LIFO manner
TM – Turing Machine
5
Turing Machine
▸Similar to finite automata but with an unlimited and unrestricted memory.
▸TM model uses an infinite tape as its unlimited memory. Initially the tape contains only the input string and is blank
everywhere else.
▸The tape head can read and write symbols and move around on the tape. If the machine needs to store information, it
may write this information on the tape. To read the information that it has written, the machine can move its head back
over it.
▸The outputs accept and reject are obtained by entering designated accepting and rejecting states, if it doesn’t enter an
accepting or a rejecting state it will go on forever, never halting.
▸TM can do everything that a real computer can do. The problems that a TM can’t solve are beyond the theoretical limits
of computation.
Mohammad Imam Hossain | Lecturer, Dept. of CSE | UIU
TM >> Schematic Diagram
6
▸ A Turing Machine can both write on the tape and read from it.
▸ The read-write head can move both to the left and to the right.
▸ The tape is infinite.
▸ The special states for rejecting and accepting take effect immediately.
▸ The ˽ symbol represents blank cell.
Mohammad Imam Hossain | Lecturer, Dept. of CSE | UIU
control
a ab b ˽ input˽
TM >> Formal Definition
7
A Turing Machine is a 7-tuple, (Q, 𝛴, 𝛤, 𝛿, q0, qaccept, qreject), where Q, 𝛴, 𝛤 are all finite sets and
▸ Q is the set of states
▸ 𝛴 is the input alphabet not containing the blank symbol ˽
▸ 𝛤 is the tape alphabet, where ˽ 𝜖 𝛤 and 𝛴 ⊆ 𝛤
▸ 𝛿 : Q x 𝛤 → Q x 𝛤 x { L, R } is the transition function
▸ q0 𝜖 Q is the start state
▸ qaccept 𝜖 Q is the accept state and
▸ qreject 𝜖 Q is the reject state, where qreject ≠ qaccept
Outcomes: accept, reject, or loop
Mohammad Imam Hossain | Lecturer, Dept. of CSE | UIU
TM >> Transition Function
8
Mohammad Imam Hossain | Lecturer, Dept. of CSE | UIU
q
a b a b ˽ ˽
𝛿(q, a) = (r, b, L)
r
a b b b ˽ ˽
L = left
Transition Function,
𝛿(q, a) = (r, b, L)
Mechanism :
When the machine is in a certain state q and
the head is over a tape square containing a symbol a,
The machine writes the symbol b replacing the a,
and goes to state r.
The third component is either L or R and indicates whether the
head moves to the left or right after writing.
TM >> Languages
9
Turing-recognizable Language / Recursively Enumerable Language
▸ A language is Turing-recognizable if some Turing machine recognizes it.
▸ TM can fail to accept an input by entering the qreject state and rejecting, or by looping.
This causes a problem to decide whether the machine is in looping state or taking long time to compute.
Turing-decidable Language / Recursive Language
▸ Turing machines that halt on all inputs are called deciders because they always make a decision to accept or reject and
such machines never loop.
▸ A language is Turing-decidable or simply decidable if some TM decides it.
Mohammad Imam Hossain | Lecturer, Dept. of CSE | UIU
TM >> L = { 0n 1n | n >= 1 }
10
Mohammad Imam Hossain | Lecturer, Dept. of CSE | UIU
Formal Definition
Q = { q0, q1, q2, q3, q4 }
Σ = { 0, 1 }
𝛤 = { 0, 1, X, Y, ˽ }
𝛿 is described the following transition table:
Start state = q0
qaccept = q4
qreject = { }
0 1 X Y ˽
q0
(q1, X, R) - - (q3, Y, R) -
q1
(q1, 0, R) (q2, Y, L) - (q1, Y, R) -
q2
(q2, 0, L) - (q0, X, R) (q2, Y, L) -
q3
- - - (q3, Y, R) (q4, B, R)
q4
- - - - -
TM >> Configuration
11
Mohammad Imam Hossain | Lecturer, Dept. of CSE | UIU
q
a b a b ˽ ˽
𝛿(q, a) = (r, b, L)
r
a b b b ˽ ˽
L = left
Configuration: abqab
Configuration: arbbb
Start configuration: q0 w
Accepting configuration: the state of the accepting
configuration is qaccept
Rejecting configuration: the state of the rejecting
configuration is qreject
Accepting and Rejecting configurations are halting
configurations and do not yield further configuration.
– The configuration C1 yields configuration C2 if the
TM can legally go from C1 to C2 in a single step.
For example,
ua qi bv yields u qj acv ; if 𝛿(qi, b) = (qj, c, L)
and
ua qi bv yields uac qj v ; if 𝛿(qi, b) = (qj, c, R)
TM >> Machine 1 – L = {w # w | w ∈ {0,1}* }
12
Check acceptability for the following strings:
▸ 1011#1011
▸ 001#100
Mohammad Imam Hossain | Lecturer, Dept. of CSE | UIU
TM >> Machine 1 – L = {w # w | w ∈ {0,1}* }
13
How this machine computes … … …
Mohammad Imam Hossain | Lecturer, Dept. of CSE | UIU
TM >> Machine 1 – L = {w # w | w ∈ {0,1}* }
14
Acceptability checking: 011#011
Sequence of configurations:
q1 011#011˽
x q2 11#011˽
x1 q2 1#011˽
x11 q2 #011˽
x11# q4 011˽
x11 q6 #x11˽
x1 q7 1#x11˽
x q7 11#x11˽
q7 x11#x11˽
x q111#x11˽
xx q31#x11˽
xx1 q3 #x11˽
Mohammad Imam Hossain | Lecturer, Dept. of CSE | UIU
xx1# q5 x11˽
xx1#x q5 11˽
xx1# q6 xx1˽
xx1 q6 #xx1˽
xx q7 1#xx1˽
x q7 x1#xx1˽
xx q11#xx1˽
xxx q3 #xx1˽
xxx# q5 xx1˽
xxx#x q5 x1˽
xxx#xx q5 1˽
xxx#x q6 xx˽
xxx# q6 xxx˽
xxx q6 #xxx˽
xx q7 x#xxx˽
xxx q1 #xxx˽
xxx# q8 xxx˽
xxx#x q8 xx˽
xxx#xx q8 x˽
xxx#xxx q8 ˽
xxx#xxx˽ qaccept
TM >> Machine 1 – L = {w # w | w ∈ {0,1}* }
15
Acceptability checking: 001#100
Sequence of configurations:
q1 001#100˽
x q2 01#100˽
x0 q2 1#100˽
x01 q2 #100˽
x01# q4 100˽
Rejected, no transition exists.
Mohammad Imam Hossain | Lecturer, Dept. of CSE | UIU
TM >> Machine 2 – TM for Addition
16
TM for computing sum:
Each number is represented as a sequence
of 0’s i.e. 2 = 00, 3 = 000
Input: 0 0 0 0 c 0 0 0 // 4 + 3
Output: 0 0 0 0 0 0 0 // 7
Mohammad Imam Hossain | Lecturer, Dept. of CSE | UIU
TM >> Machine 3 – TM for Subtraction
17
TM for computing difference from bigger
integer to smaller one:
Each number is represented as a sequence
of 0’s i.e. 2 = 00, 3 = 000
Input: 0 0 0 0 0 c 0 0 0 // 5 - 3
Output: 0 0 // 2
Mohammad Imam Hossain | Lecturer, Dept. of CSE | UIU
TM >> Machine 4 – TM for Comparator (A<B)
18
TM for comparing two numbers:
Each number is represented as a sequence of 0’s
i.e. 2 = 00, 3 = 000
Input: 11 0 1111 // 2 < 4
Output: 0 X X 1 1 // 1’s remain in the right
side, so second argument is greater.
Mohammad Imam Hossain | Lecturer, Dept. of CSE | UIU
TM >> Machine 5 – TM for Comparator (A=B)
19
TM for comparing two numbers:
Each number is represented as a sequence of 0’s
i.e. 2 = 00, 3 = 000
Input: 111 0 111 // 3 = 3
Output: XXX0XXX // no 1’s remain in both
sides, so A=B
Mohammad Imam Hossain | Lecturer, Dept. of CSE | UIU
TM >> Machine 6 – L = {0n 1n 2n | n >=1 }
20
Check acceptability for the following strings:
▸ 001122
▸ 0001112222
Mohammad Imam Hossain | Lecturer, Dept. of CSE | UIU
TM >> Machine 7 – L = { an bm an+m | n,m >=1 }
21
Check acceptability for the following strings:
▸ aabbbaaaaa
▸ aabaaaa
Mohammad Imam Hossain | Lecturer, Dept. of CSE | UIU
TM >> Machine 8 – L = {wwr | w ∈ {0,1}* }
22
Check acceptability for the following strings:
▸ 00111100
▸ 10100101
Mohammad Imam Hossain | Lecturer, Dept. of CSE | UIU
TM >> Machine 9 – L = {ww | w ∈ {0,1}* }
23
Check acceptability for the following strings:
▸ 101101
▸ 101110
Mohammad Imam Hossain | Lecturer, Dept. of CSE | UIU
TM >> Machine 10 – L = {ai dj ck | i>j>k and k>=1}
24
Check acceptability for the following strings:
▸ aaabbc
▸ aabbccc
Mohammad Imam Hossain | Lecturer, Dept. of CSE | UIU
TM >> Machine 11 – L = {ai dj ck | i<j<k and i>=1}
25
Check acceptability for the following strings:
▸ aaabbc
▸ abbccc
Mohammad Imam Hossain | Lecturer, Dept. of CSE | UIU
TM >> Machine 12 – L = { 02 𝑛
| n >=0 }
26
Check acceptability for the following strings:
▸ 0000
▸ 00000
Mohammad Imam Hossain | Lecturer, Dept. of CSE | UIU
27
References:
- Chapter 3(section 3.1), Introduction to the Theory of Computation, 3rd Edition by Michael Sipser
- Reference website: https://www.geeksforgeeks.org/turing-machine-in-toc/
THANKS!
Any questions?
You can find me at imam@cse.uiu.ac.bd

More Related Content

What's hot

TOC 8 | Derivation, Parse Tree & Ambiguity Check
TOC 8 | Derivation, Parse Tree & Ambiguity CheckTOC 8 | Derivation, Parse Tree & Ambiguity Check
TOC 8 | Derivation, Parse Tree & Ambiguity CheckMohammad Imam Hossain
 
Deterministic Finite Automata (DFA)
Deterministic Finite Automata (DFA)Deterministic Finite Automata (DFA)
Deterministic Finite Automata (DFA)Animesh Chaturvedi
 
AI 1 | Introduction to Artificial Intelligence
AI 1 | Introduction to Artificial IntelligenceAI 1 | Introduction to Artificial Intelligence
AI 1 | Introduction to Artificial IntelligenceMohammad Imam Hossain
 
Lecture: Regular Expressions and Regular Languages
Lecture: Regular Expressions and Regular LanguagesLecture: Regular Expressions and Regular Languages
Lecture: Regular Expressions and Regular LanguagesMarina Santini
 
Variants of Turing Machine
Variants of Turing MachineVariants of Turing Machine
Variants of Turing MachineRajendran
 
Nondeterministic Finite Automata
Nondeterministic Finite AutomataNondeterministic Finite Automata
Nondeterministic Finite AutomataAdel Al-Ofairi
 
Chomsky classification of Language
Chomsky classification of LanguageChomsky classification of Language
Chomsky classification of LanguageDipankar Boruah
 
Regular expressions
Regular expressionsRegular expressions
Regular expressionsShiraz316
 
closure properties of regular language.pptx
closure properties of regular language.pptxclosure properties of regular language.pptx
closure properties of regular language.pptxThirumoorthy64
 
Introduction TO Finite Automata
Introduction TO Finite AutomataIntroduction TO Finite Automata
Introduction TO Finite AutomataRatnakar Mikkili
 
1.3.2 non deterministic finite automaton
1.3.2 non deterministic finite automaton1.3.2 non deterministic finite automaton
1.3.2 non deterministic finite automatonSampath Kumar S
 
Propositional logic
Propositional logicPropositional logic
Propositional logicRushdi Shams
 
AI 9 | Bayesian Network and Probabilistic Inference
AI 9 | Bayesian Network and Probabilistic InferenceAI 9 | Bayesian Network and Probabilistic Inference
AI 9 | Bayesian Network and Probabilistic InferenceMohammad Imam Hossain
 
Theory of computing
Theory of computingTheory of computing
Theory of computingRanjan Kumar
 
Regular expressions-Theory of computation
Regular expressions-Theory of computationRegular expressions-Theory of computation
Regular expressions-Theory of computationBipul Roy Bpl
 

What's hot (20)

TOC 8 | Derivation, Parse Tree & Ambiguity Check
TOC 8 | Derivation, Parse Tree & Ambiguity CheckTOC 8 | Derivation, Parse Tree & Ambiguity Check
TOC 8 | Derivation, Parse Tree & Ambiguity Check
 
Turing machine-TOC
Turing machine-TOCTuring machine-TOC
Turing machine-TOC
 
Deterministic Finite Automata (DFA)
Deterministic Finite Automata (DFA)Deterministic Finite Automata (DFA)
Deterministic Finite Automata (DFA)
 
AI 1 | Introduction to Artificial Intelligence
AI 1 | Introduction to Artificial IntelligenceAI 1 | Introduction to Artificial Intelligence
AI 1 | Introduction to Artificial Intelligence
 
Context free grammar
Context free grammar Context free grammar
Context free grammar
 
Lecture: Regular Expressions and Regular Languages
Lecture: Regular Expressions and Regular LanguagesLecture: Regular Expressions and Regular Languages
Lecture: Regular Expressions and Regular Languages
 
Chomsky Normal Form
Chomsky Normal FormChomsky Normal Form
Chomsky Normal Form
 
Variants of Turing Machine
Variants of Turing MachineVariants of Turing Machine
Variants of Turing Machine
 
Nondeterministic Finite Automata
Nondeterministic Finite AutomataNondeterministic Finite Automata
Nondeterministic Finite Automata
 
Chomsky classification of Language
Chomsky classification of LanguageChomsky classification of Language
Chomsky classification of Language
 
Regular expressions
Regular expressionsRegular expressions
Regular expressions
 
closure properties of regular language.pptx
closure properties of regular language.pptxclosure properties of regular language.pptx
closure properties of regular language.pptx
 
Finite automata
Finite automataFinite automata
Finite automata
 
Introduction TO Finite Automata
Introduction TO Finite AutomataIntroduction TO Finite Automata
Introduction TO Finite Automata
 
Finite automata
Finite automataFinite automata
Finite automata
 
1.3.2 non deterministic finite automaton
1.3.2 non deterministic finite automaton1.3.2 non deterministic finite automaton
1.3.2 non deterministic finite automaton
 
Propositional logic
Propositional logicPropositional logic
Propositional logic
 
AI 9 | Bayesian Network and Probabilistic Inference
AI 9 | Bayesian Network and Probabilistic InferenceAI 9 | Bayesian Network and Probabilistic Inference
AI 9 | Bayesian Network and Probabilistic Inference
 
Theory of computing
Theory of computingTheory of computing
Theory of computing
 
Regular expressions-Theory of computation
Regular expressions-Theory of computationRegular expressions-Theory of computation
Regular expressions-Theory of computation
 

Similar to TOC 10 | Turing Machine

state_machines1.pdf
state_machines1.pdfstate_machines1.pdf
state_machines1.pdfrdjo
 
IE 425 Homework 10Submit on Tuesday, 12101.(20 pts) C.docx
IE 425 Homework 10Submit on Tuesday, 12101.(20 pts) C.docxIE 425 Homework 10Submit on Tuesday, 12101.(20 pts) C.docx
IE 425 Homework 10Submit on Tuesday, 12101.(20 pts) C.docxsheronlewthwaite
 
The Effect of Imbalance on the Performance of Unpaced Production Line – A Mat...
The Effect of Imbalance on the Performance of Unpaced Production Line – A Mat...The Effect of Imbalance on the Performance of Unpaced Production Line – A Mat...
The Effect of Imbalance on the Performance of Unpaced Production Line – A Mat...IOSR Journals
 
Time series analysis use E-views programer
Time series analysis use E-views programerTime series analysis use E-views programer
Time series analysis use E-views programerAl-Qadisiya University
 
AI 7 | Constraint Satisfaction Problem
AI 7 | Constraint Satisfaction ProblemAI 7 | Constraint Satisfaction Problem
AI 7 | Constraint Satisfaction ProblemMohammad Imam Hossain
 
Modeling examples
Modeling examplesModeling examples
Modeling examplesanand hd
 
Cost minimization model
Cost minimization modelCost minimization model
Cost minimization modelrowell balala
 
Python for Machine Learning
Python for Machine LearningPython for Machine Learning
Python for Machine LearningStudent
 
Cs1123 5 selection_if
Cs1123 5 selection_ifCs1123 5 selection_if
Cs1123 5 selection_ifTAlha MAlik
 
Control structures.ppt
Control structures.pptControl structures.ppt
Control structures.pptRahul Borate
 
Finite state automaton
Finite state automatonFinite state automaton
Finite state automatonAmmAr mobark
 
Lecture-2-01-02-2022.pdf
Lecture-2-01-02-2022.pdfLecture-2-01-02-2022.pdf
Lecture-2-01-02-2022.pdfZakria Bilal
 
Finite State Machines with Output
Finite State Machines with OutputFinite State Machines with Output
Finite State Machines with OutputMustafa Saeed
 
Chapter 3 Control structures.ppt
Chapter 3 Control structures.pptChapter 3 Control structures.ppt
Chapter 3 Control structures.pptRahulBorate10
 

Similar to TOC 10 | Turing Machine (20)

state_machines1.pdf
state_machines1.pdfstate_machines1.pdf
state_machines1.pdf
 
IE 425 Homework 10Submit on Tuesday, 12101.(20 pts) C.docx
IE 425 Homework 10Submit on Tuesday, 12101.(20 pts) C.docxIE 425 Homework 10Submit on Tuesday, 12101.(20 pts) C.docx
IE 425 Homework 10Submit on Tuesday, 12101.(20 pts) C.docx
 
C012111419
C012111419C012111419
C012111419
 
The Effect of Imbalance on the Performance of Unpaced Production Line – A Mat...
The Effect of Imbalance on the Performance of Unpaced Production Line – A Mat...The Effect of Imbalance on the Performance of Unpaced Production Line – A Mat...
The Effect of Imbalance on the Performance of Unpaced Production Line – A Mat...
 
Time series analysis use E-views programer
Time series analysis use E-views programerTime series analysis use E-views programer
Time series analysis use E-views programer
 
AI 7 | Constraint Satisfaction Problem
AI 7 | Constraint Satisfaction ProblemAI 7 | Constraint Satisfaction Problem
AI 7 | Constraint Satisfaction Problem
 
Modeling examples
Modeling examplesModeling examples
Modeling examples
 
Cost minimization model
Cost minimization modelCost minimization model
Cost minimization model
 
Python for Machine Learning
Python for Machine LearningPython for Machine Learning
Python for Machine Learning
 
Cs1123 5 selection_if
Cs1123 5 selection_ifCs1123 5 selection_if
Cs1123 5 selection_if
 
Control structures.ppt
Control structures.pptControl structures.ppt
Control structures.ppt
 
Finite state automaton
Finite state automatonFinite state automaton
Finite state automaton
 
C++ in 10 Hours.pdf.pdf
C++ in 10 Hours.pdf.pdfC++ in 10 Hours.pdf.pdf
C++ in 10 Hours.pdf.pdf
 
Lecture-2-01-02-2022.pdf
Lecture-2-01-02-2022.pdfLecture-2-01-02-2022.pdf
Lecture-2-01-02-2022.pdf
 
Finite State Machines with Output
Finite State Machines with OutputFinite State Machines with Output
Finite State Machines with Output
 
Chapter 3 Control structures.ppt
Chapter 3 Control structures.pptChapter 3 Control structures.ppt
Chapter 3 Control structures.ppt
 
Icra 17
Icra 17Icra 17
Icra 17
 
Control system unit(1)
Control system unit(1)Control system unit(1)
Control system unit(1)
 
Kalman_filtering
Kalman_filteringKalman_filtering
Kalman_filtering
 
Penyelesaian masalah
Penyelesaian masalahPenyelesaian masalah
Penyelesaian masalah
 

More from Mohammad Imam Hossain

DS & Algo 4 - Graph and Shortest Path Search
DS & Algo 4 - Graph and Shortest Path SearchDS & Algo 4 - Graph and Shortest Path Search
DS & Algo 4 - Graph and Shortest Path SearchMohammad Imam Hossain
 
DS & Algo 1 - C++ and STL Introduction
DS & Algo 1 - C++ and STL IntroductionDS & Algo 1 - C++ and STL Introduction
DS & Algo 1 - C++ and STL IntroductionMohammad Imam Hossain
 
DBMS 3 | ER Diagram to Relational Schema
DBMS 3 | ER Diagram to Relational SchemaDBMS 3 | ER Diagram to Relational Schema
DBMS 3 | ER Diagram to Relational SchemaMohammad Imam Hossain
 
DBMS 5 | MySQL Practice List - HR Schema
DBMS 5 | MySQL Practice List - HR SchemaDBMS 5 | MySQL Practice List - HR Schema
DBMS 5 | MySQL Practice List - HR SchemaMohammad Imam Hossain
 
DBMS 6 | MySQL Practice List - Rank Related Queries
DBMS 6 | MySQL Practice List - Rank Related QueriesDBMS 6 | MySQL Practice List - Rank Related Queries
DBMS 6 | MySQL Practice List - Rank Related QueriesMohammad Imam Hossain
 
TOC 1 | Introduction to Theory of Computation
TOC 1 | Introduction to Theory of ComputationTOC 1 | Introduction to Theory of Computation
TOC 1 | Introduction to Theory of ComputationMohammad Imam Hossain
 

More from Mohammad Imam Hossain (20)

DS & Algo 6 - Offline Assignment 6
DS & Algo 6 - Offline Assignment 6DS & Algo 6 - Offline Assignment 6
DS & Algo 6 - Offline Assignment 6
 
DS & Algo 6 - Dynamic Programming
DS & Algo 6 - Dynamic ProgrammingDS & Algo 6 - Dynamic Programming
DS & Algo 6 - Dynamic Programming
 
DS & Algo 5 - Disjoint Set and MST
DS & Algo 5 - Disjoint Set and MSTDS & Algo 5 - Disjoint Set and MST
DS & Algo 5 - Disjoint Set and MST
 
DS & Algo 4 - Graph and Shortest Path Search
DS & Algo 4 - Graph and Shortest Path SearchDS & Algo 4 - Graph and Shortest Path Search
DS & Algo 4 - Graph and Shortest Path Search
 
DS & Algo 3 - Offline Assignment 3
DS & Algo 3 - Offline Assignment 3DS & Algo 3 - Offline Assignment 3
DS & Algo 3 - Offline Assignment 3
 
DS & Algo 3 - Divide and Conquer
DS & Algo 3 - Divide and ConquerDS & Algo 3 - Divide and Conquer
DS & Algo 3 - Divide and Conquer
 
DS & Algo 2 - Offline Assignment 2
DS & Algo 2 - Offline Assignment 2DS & Algo 2 - Offline Assignment 2
DS & Algo 2 - Offline Assignment 2
 
DS & Algo 2 - Recursion
DS & Algo 2 - RecursionDS & Algo 2 - Recursion
DS & Algo 2 - Recursion
 
DS & Algo 1 - Offline Assignment 1
DS & Algo 1 - Offline Assignment 1DS & Algo 1 - Offline Assignment 1
DS & Algo 1 - Offline Assignment 1
 
DS & Algo 1 - C++ and STL Introduction
DS & Algo 1 - C++ and STL IntroductionDS & Algo 1 - C++ and STL Introduction
DS & Algo 1 - C++ and STL Introduction
 
DBMS 1 | Introduction to DBMS
DBMS 1 | Introduction to DBMSDBMS 1 | Introduction to DBMS
DBMS 1 | Introduction to DBMS
 
DBMS 10 | Database Transactions
DBMS 10 | Database TransactionsDBMS 10 | Database Transactions
DBMS 10 | Database Transactions
 
DBMS 3 | ER Diagram to Relational Schema
DBMS 3 | ER Diagram to Relational SchemaDBMS 3 | ER Diagram to Relational Schema
DBMS 3 | ER Diagram to Relational Schema
 
DBMS 2 | Entity Relationship Model
DBMS 2 | Entity Relationship ModelDBMS 2 | Entity Relationship Model
DBMS 2 | Entity Relationship Model
 
DBMS 7 | Relational Query Language
DBMS 7 | Relational Query LanguageDBMS 7 | Relational Query Language
DBMS 7 | Relational Query Language
 
DBMS 4 | MySQL - DDL & DML Commands
DBMS 4 | MySQL - DDL & DML CommandsDBMS 4 | MySQL - DDL & DML Commands
DBMS 4 | MySQL - DDL & DML Commands
 
DBMS 5 | MySQL Practice List - HR Schema
DBMS 5 | MySQL Practice List - HR SchemaDBMS 5 | MySQL Practice List - HR Schema
DBMS 5 | MySQL Practice List - HR Schema
 
DBMS 6 | MySQL Practice List - Rank Related Queries
DBMS 6 | MySQL Practice List - Rank Related QueriesDBMS 6 | MySQL Practice List - Rank Related Queries
DBMS 6 | MySQL Practice List - Rank Related Queries
 
TOC 1 | Introduction to Theory of Computation
TOC 1 | Introduction to Theory of ComputationTOC 1 | Introduction to Theory of Computation
TOC 1 | Introduction to Theory of Computation
 
DBMS 9 | Extendible Hashing
DBMS 9 | Extendible HashingDBMS 9 | Extendible Hashing
DBMS 9 | Extendible Hashing
 

Recently uploaded

ESP 4-EDITED.pdfmmcncncncmcmmnmnmncnmncmnnjvnnv
ESP 4-EDITED.pdfmmcncncncmcmmnmnmncnmncmnnjvnnvESP 4-EDITED.pdfmmcncncncmcmmnmnmncnmncmnnjvnnv
ESP 4-EDITED.pdfmmcncncncmcmmnmnmncnmncmnnjvnnvRicaMaeCastro1
 
Unraveling Hypertext_ Analyzing Postmodern Elements in Literature.pptx
Unraveling Hypertext_ Analyzing  Postmodern Elements in  Literature.pptxUnraveling Hypertext_ Analyzing  Postmodern Elements in  Literature.pptx
Unraveling Hypertext_ Analyzing Postmodern Elements in Literature.pptxDhatriParmar
 
Grade 9 Quarter 4 Dll Grade 9 Quarter 4 DLL.pdf
Grade 9 Quarter 4 Dll Grade 9 Quarter 4 DLL.pdfGrade 9 Quarter 4 Dll Grade 9 Quarter 4 DLL.pdf
Grade 9 Quarter 4 Dll Grade 9 Quarter 4 DLL.pdfJemuel Francisco
 
Scientific Writing :Research Discourse
Scientific  Writing :Research  DiscourseScientific  Writing :Research  Discourse
Scientific Writing :Research DiscourseAnita GoswamiGiri
 
Q-Factor General Quiz-7th April 2024, Quiz Club NITW
Q-Factor General Quiz-7th April 2024, Quiz Club NITWQ-Factor General Quiz-7th April 2024, Quiz Club NITW
Q-Factor General Quiz-7th April 2024, Quiz Club NITWQuiz Club NITW
 
Student Profile Sample - We help schools to connect the data they have, with ...
Student Profile Sample - We help schools to connect the data they have, with ...Student Profile Sample - We help schools to connect the data they have, with ...
Student Profile Sample - We help schools to connect the data they have, with ...Seán Kennedy
 
Daily Lesson Plan in Mathematics Quarter 4
Daily Lesson Plan in Mathematics Quarter 4Daily Lesson Plan in Mathematics Quarter 4
Daily Lesson Plan in Mathematics Quarter 4JOYLYNSAMANIEGO
 
How to Fix XML SyntaxError in Odoo the 17
How to Fix XML SyntaxError in Odoo the 17How to Fix XML SyntaxError in Odoo the 17
How to Fix XML SyntaxError in Odoo the 17Celine George
 
Grade Three -ELLNA-REVIEWER-ENGLISH.pptx
Grade Three -ELLNA-REVIEWER-ENGLISH.pptxGrade Three -ELLNA-REVIEWER-ENGLISH.pptx
Grade Three -ELLNA-REVIEWER-ENGLISH.pptxkarenfajardo43
 
ICS2208 Lecture6 Notes for SL spaces.pdf
ICS2208 Lecture6 Notes for SL spaces.pdfICS2208 Lecture6 Notes for SL spaces.pdf
ICS2208 Lecture6 Notes for SL spaces.pdfVanessa Camilleri
 
Team Lead Succeed – Helping you and your team achieve high-performance teamwo...
Team Lead Succeed – Helping you and your team achieve high-performance teamwo...Team Lead Succeed – Helping you and your team achieve high-performance teamwo...
Team Lead Succeed – Helping you and your team achieve high-performance teamwo...Association for Project Management
 
Measures of Position DECILES for ungrouped data
Measures of Position DECILES for ungrouped dataMeasures of Position DECILES for ungrouped data
Measures of Position DECILES for ungrouped dataBabyAnnMotar
 
Reading and Writing Skills 11 quarter 4 melc 1
Reading and Writing Skills 11 quarter 4 melc 1Reading and Writing Skills 11 quarter 4 melc 1
Reading and Writing Skills 11 quarter 4 melc 1GloryAnnCastre1
 
Q4-PPT-Music9_Lesson-1-Romantic-Opera.pptx
Q4-PPT-Music9_Lesson-1-Romantic-Opera.pptxQ4-PPT-Music9_Lesson-1-Romantic-Opera.pptx
Q4-PPT-Music9_Lesson-1-Romantic-Opera.pptxlancelewisportillo
 
Blowin' in the Wind of Caste_ Bob Dylan's Song as a Catalyst for Social Justi...
Blowin' in the Wind of Caste_ Bob Dylan's Song as a Catalyst for Social Justi...Blowin' in the Wind of Caste_ Bob Dylan's Song as a Catalyst for Social Justi...
Blowin' in the Wind of Caste_ Bob Dylan's Song as a Catalyst for Social Justi...DhatriParmar
 
MS4 level being good citizen -imperative- (1) (1).pdf
MS4 level   being good citizen -imperative- (1) (1).pdfMS4 level   being good citizen -imperative- (1) (1).pdf
MS4 level being good citizen -imperative- (1) (1).pdfMr Bounab Samir
 
BIOCHEMISTRY-CARBOHYDRATE METABOLISM CHAPTER 2.pptx
BIOCHEMISTRY-CARBOHYDRATE METABOLISM CHAPTER 2.pptxBIOCHEMISTRY-CARBOHYDRATE METABOLISM CHAPTER 2.pptx
BIOCHEMISTRY-CARBOHYDRATE METABOLISM CHAPTER 2.pptxSayali Powar
 
DIFFERENT BASKETRY IN THE PHILIPPINES PPT.pptx
DIFFERENT BASKETRY IN THE PHILIPPINES PPT.pptxDIFFERENT BASKETRY IN THE PHILIPPINES PPT.pptx
DIFFERENT BASKETRY IN THE PHILIPPINES PPT.pptxMichelleTuguinay1
 

Recently uploaded (20)

ESP 4-EDITED.pdfmmcncncncmcmmnmnmncnmncmnnjvnnv
ESP 4-EDITED.pdfmmcncncncmcmmnmnmncnmncmnnjvnnvESP 4-EDITED.pdfmmcncncncmcmmnmnmncnmncmnnjvnnv
ESP 4-EDITED.pdfmmcncncncmcmmnmnmncnmncmnnjvnnv
 
Unraveling Hypertext_ Analyzing Postmodern Elements in Literature.pptx
Unraveling Hypertext_ Analyzing  Postmodern Elements in  Literature.pptxUnraveling Hypertext_ Analyzing  Postmodern Elements in  Literature.pptx
Unraveling Hypertext_ Analyzing Postmodern Elements in Literature.pptx
 
Grade 9 Quarter 4 Dll Grade 9 Quarter 4 DLL.pdf
Grade 9 Quarter 4 Dll Grade 9 Quarter 4 DLL.pdfGrade 9 Quarter 4 Dll Grade 9 Quarter 4 DLL.pdf
Grade 9 Quarter 4 Dll Grade 9 Quarter 4 DLL.pdf
 
Scientific Writing :Research Discourse
Scientific  Writing :Research  DiscourseScientific  Writing :Research  Discourse
Scientific Writing :Research Discourse
 
Q-Factor General Quiz-7th April 2024, Quiz Club NITW
Q-Factor General Quiz-7th April 2024, Quiz Club NITWQ-Factor General Quiz-7th April 2024, Quiz Club NITW
Q-Factor General Quiz-7th April 2024, Quiz Club NITW
 
Student Profile Sample - We help schools to connect the data they have, with ...
Student Profile Sample - We help schools to connect the data they have, with ...Student Profile Sample - We help schools to connect the data they have, with ...
Student Profile Sample - We help schools to connect the data they have, with ...
 
Daily Lesson Plan in Mathematics Quarter 4
Daily Lesson Plan in Mathematics Quarter 4Daily Lesson Plan in Mathematics Quarter 4
Daily Lesson Plan in Mathematics Quarter 4
 
How to Fix XML SyntaxError in Odoo the 17
How to Fix XML SyntaxError in Odoo the 17How to Fix XML SyntaxError in Odoo the 17
How to Fix XML SyntaxError in Odoo the 17
 
Grade Three -ELLNA-REVIEWER-ENGLISH.pptx
Grade Three -ELLNA-REVIEWER-ENGLISH.pptxGrade Three -ELLNA-REVIEWER-ENGLISH.pptx
Grade Three -ELLNA-REVIEWER-ENGLISH.pptx
 
ICS2208 Lecture6 Notes for SL spaces.pdf
ICS2208 Lecture6 Notes for SL spaces.pdfICS2208 Lecture6 Notes for SL spaces.pdf
ICS2208 Lecture6 Notes for SL spaces.pdf
 
Team Lead Succeed – Helping you and your team achieve high-performance teamwo...
Team Lead Succeed – Helping you and your team achieve high-performance teamwo...Team Lead Succeed – Helping you and your team achieve high-performance teamwo...
Team Lead Succeed – Helping you and your team achieve high-performance teamwo...
 
Measures of Position DECILES for ungrouped data
Measures of Position DECILES for ungrouped dataMeasures of Position DECILES for ungrouped data
Measures of Position DECILES for ungrouped data
 
prashanth updated resume 2024 for Teaching Profession
prashanth updated resume 2024 for Teaching Professionprashanth updated resume 2024 for Teaching Profession
prashanth updated resume 2024 for Teaching Profession
 
INCLUSIVE EDUCATION PRACTICES FOR TEACHERS AND TRAINERS.pptx
INCLUSIVE EDUCATION PRACTICES FOR TEACHERS AND TRAINERS.pptxINCLUSIVE EDUCATION PRACTICES FOR TEACHERS AND TRAINERS.pptx
INCLUSIVE EDUCATION PRACTICES FOR TEACHERS AND TRAINERS.pptx
 
Reading and Writing Skills 11 quarter 4 melc 1
Reading and Writing Skills 11 quarter 4 melc 1Reading and Writing Skills 11 quarter 4 melc 1
Reading and Writing Skills 11 quarter 4 melc 1
 
Q4-PPT-Music9_Lesson-1-Romantic-Opera.pptx
Q4-PPT-Music9_Lesson-1-Romantic-Opera.pptxQ4-PPT-Music9_Lesson-1-Romantic-Opera.pptx
Q4-PPT-Music9_Lesson-1-Romantic-Opera.pptx
 
Blowin' in the Wind of Caste_ Bob Dylan's Song as a Catalyst for Social Justi...
Blowin' in the Wind of Caste_ Bob Dylan's Song as a Catalyst for Social Justi...Blowin' in the Wind of Caste_ Bob Dylan's Song as a Catalyst for Social Justi...
Blowin' in the Wind of Caste_ Bob Dylan's Song as a Catalyst for Social Justi...
 
MS4 level being good citizen -imperative- (1) (1).pdf
MS4 level   being good citizen -imperative- (1) (1).pdfMS4 level   being good citizen -imperative- (1) (1).pdf
MS4 level being good citizen -imperative- (1) (1).pdf
 
BIOCHEMISTRY-CARBOHYDRATE METABOLISM CHAPTER 2.pptx
BIOCHEMISTRY-CARBOHYDRATE METABOLISM CHAPTER 2.pptxBIOCHEMISTRY-CARBOHYDRATE METABOLISM CHAPTER 2.pptx
BIOCHEMISTRY-CARBOHYDRATE METABOLISM CHAPTER 2.pptx
 
DIFFERENT BASKETRY IN THE PHILIPPINES PPT.pptx
DIFFERENT BASKETRY IN THE PHILIPPINES PPT.pptxDIFFERENT BASKETRY IN THE PHILIPPINES PPT.pptx
DIFFERENT BASKETRY IN THE PHILIPPINES PPT.pptx
 

TOC 10 | Turing Machine

  • 1. Theory of Computation CSE 2233 Mohammad Imam Hossain | Lecturer, Dept. of CSE | UIU
  • 2. Chomsky Hierarchy 2 ▪ Chomsky hierarchy represents the class of languages that are accepted by the different machine. ▪ The category of language in Chomsky’s Hierarchy is given below: 1) Type 0 – Unrestricted Grammar 2) Type 1 – Context Sensitive Grammar 3) Type 2 – Context Free Grammar 4) Type 3 – Regular Grammar ▪ Two major models of automata: • Generators – with output and without input – tell us how to generate all strings in a Language L • Acceptors – with input and without output – tell us if a specific string is in Language L Mohammad Imam Hossain | Lecturer, Dept. of CSE | UIU
  • 3. FA >> Schematic Diagram 3 Finite control a ba a b input Mohammad Imam Hossain | Lecturer, Dept. of CSE | UIU Finite Automaton ▸ The control represents the states and transition function. ▸ The tape contains the input string. ▸ The arrow represents the input head, pointing at the next input symbol to be read. FA can remember a finite amount of information
  • 4. PDA >> Schematic Diagram 4 z Finite control b cc a a x y stack Mohammad Imam Hossain | Lecturer, Dept. of CSE | UIU Based on the characteristics of CFG containing recursive rules, how can we apply a finite state machine to CFG? ▸ The idea to reach the goal is to add a memory device to a FSM. Push Down Automaton ▸ Input string ▹ Same as FSM ▹ Cannot back up ▸ Stack operations on each transition ▹ READ + POP or, IGNORE ▹ PUSH or, IGNORE PDA can remember an infinite amount of information but the memory is usable in LIFO manner
  • 5. TM – Turing Machine 5 Turing Machine ▸Similar to finite automata but with an unlimited and unrestricted memory. ▸TM model uses an infinite tape as its unlimited memory. Initially the tape contains only the input string and is blank everywhere else. ▸The tape head can read and write symbols and move around on the tape. If the machine needs to store information, it may write this information on the tape. To read the information that it has written, the machine can move its head back over it. ▸The outputs accept and reject are obtained by entering designated accepting and rejecting states, if it doesn’t enter an accepting or a rejecting state it will go on forever, never halting. ▸TM can do everything that a real computer can do. The problems that a TM can’t solve are beyond the theoretical limits of computation. Mohammad Imam Hossain | Lecturer, Dept. of CSE | UIU
  • 6. TM >> Schematic Diagram 6 ▸ A Turing Machine can both write on the tape and read from it. ▸ The read-write head can move both to the left and to the right. ▸ The tape is infinite. ▸ The special states for rejecting and accepting take effect immediately. ▸ The ˽ symbol represents blank cell. Mohammad Imam Hossain | Lecturer, Dept. of CSE | UIU control a ab b ˽ input˽
  • 7. TM >> Formal Definition 7 A Turing Machine is a 7-tuple, (Q, 𝛴, 𝛤, 𝛿, q0, qaccept, qreject), where Q, 𝛴, 𝛤 are all finite sets and ▸ Q is the set of states ▸ 𝛴 is the input alphabet not containing the blank symbol ˽ ▸ 𝛤 is the tape alphabet, where ˽ 𝜖 𝛤 and 𝛴 ⊆ 𝛤 ▸ 𝛿 : Q x 𝛤 → Q x 𝛤 x { L, R } is the transition function ▸ q0 𝜖 Q is the start state ▸ qaccept 𝜖 Q is the accept state and ▸ qreject 𝜖 Q is the reject state, where qreject ≠ qaccept Outcomes: accept, reject, or loop Mohammad Imam Hossain | Lecturer, Dept. of CSE | UIU
  • 8. TM >> Transition Function 8 Mohammad Imam Hossain | Lecturer, Dept. of CSE | UIU q a b a b ˽ ˽ 𝛿(q, a) = (r, b, L) r a b b b ˽ ˽ L = left Transition Function, 𝛿(q, a) = (r, b, L) Mechanism : When the machine is in a certain state q and the head is over a tape square containing a symbol a, The machine writes the symbol b replacing the a, and goes to state r. The third component is either L or R and indicates whether the head moves to the left or right after writing.
  • 9. TM >> Languages 9 Turing-recognizable Language / Recursively Enumerable Language ▸ A language is Turing-recognizable if some Turing machine recognizes it. ▸ TM can fail to accept an input by entering the qreject state and rejecting, or by looping. This causes a problem to decide whether the machine is in looping state or taking long time to compute. Turing-decidable Language / Recursive Language ▸ Turing machines that halt on all inputs are called deciders because they always make a decision to accept or reject and such machines never loop. ▸ A language is Turing-decidable or simply decidable if some TM decides it. Mohammad Imam Hossain | Lecturer, Dept. of CSE | UIU
  • 10. TM >> L = { 0n 1n | n >= 1 } 10 Mohammad Imam Hossain | Lecturer, Dept. of CSE | UIU Formal Definition Q = { q0, q1, q2, q3, q4 } Σ = { 0, 1 } 𝛤 = { 0, 1, X, Y, ˽ } 𝛿 is described the following transition table: Start state = q0 qaccept = q4 qreject = { } 0 1 X Y ˽ q0 (q1, X, R) - - (q3, Y, R) - q1 (q1, 0, R) (q2, Y, L) - (q1, Y, R) - q2 (q2, 0, L) - (q0, X, R) (q2, Y, L) - q3 - - - (q3, Y, R) (q4, B, R) q4 - - - - -
  • 11. TM >> Configuration 11 Mohammad Imam Hossain | Lecturer, Dept. of CSE | UIU q a b a b ˽ ˽ 𝛿(q, a) = (r, b, L) r a b b b ˽ ˽ L = left Configuration: abqab Configuration: arbbb Start configuration: q0 w Accepting configuration: the state of the accepting configuration is qaccept Rejecting configuration: the state of the rejecting configuration is qreject Accepting and Rejecting configurations are halting configurations and do not yield further configuration. – The configuration C1 yields configuration C2 if the TM can legally go from C1 to C2 in a single step. For example, ua qi bv yields u qj acv ; if 𝛿(qi, b) = (qj, c, L) and ua qi bv yields uac qj v ; if 𝛿(qi, b) = (qj, c, R)
  • 12. TM >> Machine 1 – L = {w # w | w ∈ {0,1}* } 12 Check acceptability for the following strings: ▸ 1011#1011 ▸ 001#100 Mohammad Imam Hossain | Lecturer, Dept. of CSE | UIU
  • 13. TM >> Machine 1 – L = {w # w | w ∈ {0,1}* } 13 How this machine computes … … … Mohammad Imam Hossain | Lecturer, Dept. of CSE | UIU
  • 14. TM >> Machine 1 – L = {w # w | w ∈ {0,1}* } 14 Acceptability checking: 011#011 Sequence of configurations: q1 011#011˽ x q2 11#011˽ x1 q2 1#011˽ x11 q2 #011˽ x11# q4 011˽ x11 q6 #x11˽ x1 q7 1#x11˽ x q7 11#x11˽ q7 x11#x11˽ x q111#x11˽ xx q31#x11˽ xx1 q3 #x11˽ Mohammad Imam Hossain | Lecturer, Dept. of CSE | UIU xx1# q5 x11˽ xx1#x q5 11˽ xx1# q6 xx1˽ xx1 q6 #xx1˽ xx q7 1#xx1˽ x q7 x1#xx1˽ xx q11#xx1˽ xxx q3 #xx1˽ xxx# q5 xx1˽ xxx#x q5 x1˽ xxx#xx q5 1˽ xxx#x q6 xx˽ xxx# q6 xxx˽ xxx q6 #xxx˽ xx q7 x#xxx˽ xxx q1 #xxx˽ xxx# q8 xxx˽ xxx#x q8 xx˽ xxx#xx q8 x˽ xxx#xxx q8 ˽ xxx#xxx˽ qaccept
  • 15. TM >> Machine 1 – L = {w # w | w ∈ {0,1}* } 15 Acceptability checking: 001#100 Sequence of configurations: q1 001#100˽ x q2 01#100˽ x0 q2 1#100˽ x01 q2 #100˽ x01# q4 100˽ Rejected, no transition exists. Mohammad Imam Hossain | Lecturer, Dept. of CSE | UIU
  • 16. TM >> Machine 2 – TM for Addition 16 TM for computing sum: Each number is represented as a sequence of 0’s i.e. 2 = 00, 3 = 000 Input: 0 0 0 0 c 0 0 0 // 4 + 3 Output: 0 0 0 0 0 0 0 // 7 Mohammad Imam Hossain | Lecturer, Dept. of CSE | UIU
  • 17. TM >> Machine 3 – TM for Subtraction 17 TM for computing difference from bigger integer to smaller one: Each number is represented as a sequence of 0’s i.e. 2 = 00, 3 = 000 Input: 0 0 0 0 0 c 0 0 0 // 5 - 3 Output: 0 0 // 2 Mohammad Imam Hossain | Lecturer, Dept. of CSE | UIU
  • 18. TM >> Machine 4 – TM for Comparator (A<B) 18 TM for comparing two numbers: Each number is represented as a sequence of 0’s i.e. 2 = 00, 3 = 000 Input: 11 0 1111 // 2 < 4 Output: 0 X X 1 1 // 1’s remain in the right side, so second argument is greater. Mohammad Imam Hossain | Lecturer, Dept. of CSE | UIU
  • 19. TM >> Machine 5 – TM for Comparator (A=B) 19 TM for comparing two numbers: Each number is represented as a sequence of 0’s i.e. 2 = 00, 3 = 000 Input: 111 0 111 // 3 = 3 Output: XXX0XXX // no 1’s remain in both sides, so A=B Mohammad Imam Hossain | Lecturer, Dept. of CSE | UIU
  • 20. TM >> Machine 6 – L = {0n 1n 2n | n >=1 } 20 Check acceptability for the following strings: ▸ 001122 ▸ 0001112222 Mohammad Imam Hossain | Lecturer, Dept. of CSE | UIU
  • 21. TM >> Machine 7 – L = { an bm an+m | n,m >=1 } 21 Check acceptability for the following strings: ▸ aabbbaaaaa ▸ aabaaaa Mohammad Imam Hossain | Lecturer, Dept. of CSE | UIU
  • 22. TM >> Machine 8 – L = {wwr | w ∈ {0,1}* } 22 Check acceptability for the following strings: ▸ 00111100 ▸ 10100101 Mohammad Imam Hossain | Lecturer, Dept. of CSE | UIU
  • 23. TM >> Machine 9 – L = {ww | w ∈ {0,1}* } 23 Check acceptability for the following strings: ▸ 101101 ▸ 101110 Mohammad Imam Hossain | Lecturer, Dept. of CSE | UIU
  • 24. TM >> Machine 10 – L = {ai dj ck | i>j>k and k>=1} 24 Check acceptability for the following strings: ▸ aaabbc ▸ aabbccc Mohammad Imam Hossain | Lecturer, Dept. of CSE | UIU
  • 25. TM >> Machine 11 – L = {ai dj ck | i<j<k and i>=1} 25 Check acceptability for the following strings: ▸ aaabbc ▸ abbccc Mohammad Imam Hossain | Lecturer, Dept. of CSE | UIU
  • 26. TM >> Machine 12 – L = { 02 𝑛 | n >=0 } 26 Check acceptability for the following strings: ▸ 0000 ▸ 00000 Mohammad Imam Hossain | Lecturer, Dept. of CSE | UIU
  • 27. 27 References: - Chapter 3(section 3.1), Introduction to the Theory of Computation, 3rd Edition by Michael Sipser - Reference website: https://www.geeksforgeeks.org/turing-machine-in-toc/ THANKS! Any questions? You can find me at imam@cse.uiu.ac.bd