CSE2002 Theory of Computation and Compiler Design
CSE2002 Theory of Computation and Compiler Design
Module:1
Introduction To Languages and Grammars
3
What is computation?
5
Purpose of Theory of Computation
7
Brief History of Theory of Computation
8
Brief History of Theory of Computation
9
Brief History of Theory of Computation
14
Field Related to TOC
Web search: theory of pattern matching.
Sequential circuits: theory of finite state automata.
Compilers: theory of context free grammars.
Cryptography: theory of computational complexity.
Neural networks : Automata theory
Computational biology: DNA and proteins are strings.
Artificial intelligence: the undecidability of first-order logic.(FL and
Automata)
Natural languages are mostly context-free. Speech understanding
systems use probabilistic FSMs
Algorithm Analysis:Computational complexity
What is Theory of Computation ?
16
Theory of Computation
Solvable FA
Easy
17
Computability Theory
Study of problem solving capabilities of computational
models.
Problem types based on resources
-Impossible problems
-Possible-with-unlimited-resources-but- impossible-with-
limited-resources problems
-Possible-with-limited-resources problems
Problem types based on time
-Undecidable problems
-Intractable problems
-Tractable problems
Advantage -computability help us not to waste time on
“unsolvable problems” 18
Computational complexity Theory
A problem is called “easy”, if it is efficiently solvable.
Examples of “easy” problems are searching for a name in a
telephone directory.
- A problem is called “hard”, if it cannot be solved efficiently, or if
we don’t know whether it can be solved efficiently.
Examples of “hard” problems are (i) factoring a 300-digit integer
into its prime factors. 19
What is Automata Theory?
Study of dynamic behavior of discrete parameter
information systems in the form of abstract computing
devices, or “machines”
20
temporary memory
f(x)= x 3
z2*24
f (x) z * 2
8 input
x2
CPU
output
Program memory
compute xx
compute 2
x 21 2
Automaton [Representation]
temporary memory
Automaton
input
output
transition
state
temporary memory
input
Finite
Automaton
output
Example: Elevators, Vending Machines,
Lexical Analyzers
(small computing power)
24
Pushdown Automaton
Temp.
memory Stack Push, Pop
Pushdown input
Automaton
output
Temp.
memory Random Access Memory
input
Turing
Machine
output
28
29
30