fall 2006costas busch - rpi1 csci-2400 models of computation

17
Fall 2006 Costas Busch - RPI 1 CSCI-2400 Models of Computation

Upload: austin-beasley

Post on 21-Dec-2015

214 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Fall 2006Costas Busch - RPI1 CSCI-2400 Models of Computation

Fall 2006 Costas Busch - RPI 1

CSCI-2400

Models of Computation

Page 2: Fall 2006Costas Busch - RPI1 CSCI-2400 Models of Computation

Fall 2006 Costas Busch - RPI 2

Syllabus: tentative class schedule can be found in course web page

http://www.cs.rpi.edu/~moorthy/Courses/CSCI2400

Instructor: Moorthy

General Info for the Course

Book: Introduction to the Theory of Computation

Michael Sipser, 2nd edition

Page 3: Fall 2006Costas Busch - RPI1 CSCI-2400 Models of Computation

Fall 2006 Costas Busch - RPI 3

Computation

CPU memory

Outline of the course contents

Page 4: Fall 2006Costas Busch - RPI1 CSCI-2400 Models of Computation

Fall 2006 Costas Busch - RPI 4

CPU

input

output

Program memory

temporary memory

Page 5: Fall 2006Costas Busch - RPI1 CSCI-2400 Models of Computation

Fall 2006 Costas Busch - RPI 5

CPU

input

outputProgram memory

temporary memory

3)( xxf

compute xx

compute xx 2

Example:

Page 6: Fall 2006Costas Busch - RPI1 CSCI-2400 Models of Computation

Fall 2006 Costas Busch - RPI 6

CPU

input

outputProgram memory

temporary memory

3)( xxf

compute xx

compute xx 2

2x

Page 7: Fall 2006Costas Busch - RPI1 CSCI-2400 Models of Computation

Fall 2006 Costas Busch - RPI 7

CPU

input

outputProgram memory

temporary memory3)( xxf

compute xx

compute xx 2

2x

42*2 z82*)( zxf

Page 8: Fall 2006Costas Busch - RPI1 CSCI-2400 Models of Computation

Fall 2006 Costas Busch - RPI 8

CPU

input

outputProgram memory

temporary memory3)( xxf

compute xx

compute xx 2

2x

42*2 z82*)( zxf

8)( xf

Page 9: Fall 2006Costas Busch - RPI1 CSCI-2400 Models of Computation

Fall 2006 Costas Busch - RPI 9

Automaton

CPU

input

output

Program memory

temporary memory

Automaton

Page 10: Fall 2006Costas Busch - RPI1 CSCI-2400 Models of Computation

Fall 2006 Costas Busch - RPI 10

Automaton

input

output

temporary memory

Automaton

state

transition

Page 11: Fall 2006Costas Busch - RPI1 CSCI-2400 Models of Computation

Fall 2006 Costas Busch - RPI 11

Different Kinds of Automata

Automata are distinguished by the temporary memory

• Finite Automata: no temporary memory

• Pushdown Automata: stack

• Turing Machines: random access memory

Page 12: Fall 2006Costas Busch - RPI1 CSCI-2400 Models of Computation

Fall 2006 Costas Busch - RPI 12

input

output

temporary memory

Finite Automaton

Finite Automaton

Example: Elevators, Vending Machines

(small computing power)

Page 13: Fall 2006Costas Busch - RPI1 CSCI-2400 Models of Computation

Fall 2006 Costas Busch - RPI 13

input

output

Stack

Pushdown

Automaton

Pushdown Automaton

Example: Compilers for Programming Languages

(medium computing power)

Push, PopTemp.memory

Page 14: Fall 2006Costas Busch - RPI1 CSCI-2400 Models of Computation

Fall 2006 Costas Busch - RPI 14

input

output

Random Access Memory

Turing

Machine

Turing Machine

Examples: Any Algorithm

(highest computing power)

Temp.memory

Page 15: Fall 2006Costas Busch - RPI1 CSCI-2400 Models of Computation

Fall 2006 Costas Busch - RPI 15

Finite

Automata

Pushdown

Automata

Turing

Machine

Power of Automata

Less power More power

Solve more

computational problems

Simple problems

More complexproblems

Hardestproblems

Page 16: Fall 2006Costas Busch - RPI1 CSCI-2400 Models of Computation

Fall 2006 Costas Busch - RPI 16

Turing Machine is the most powerful computational model known

Question: Are there computational problems that a Turing Machine cannot solve?

Answer: Yes (unsolvable problems)

Page 17: Fall 2006Costas Busch - RPI1 CSCI-2400 Models of Computation

Fall 2006 Costas Busch - RPI 17

Time Complexity of Computational Problems:

NP-complete problems

P problems

Believed to take exponential time to be solved

Solved in polynomial time