Computer Science 101 Theory of Computing. Computer Science is... The study of algorithms, with respect to –their formal properties –their linguistic realizations.

Slides:



Advertisements
Similar presentations
Chapter 11: Models of Computation
Advertisements

Turing Machines Memory = an infinitely long tape Persistent storage A read/write tape head that can move around the tape Initially, the tape contains only.
Introduction to Computability Theory
CS 345: Chapter 9 Algorithmic Universality and Its Robustness
THE CHURCH-TURING T H E S I S “ TURING MACHINES” Pages COMPUTABILITY THEORY.
CS 461 – Oct. 21 Begin chapter 3 We need a better (more encompassing) model of computation. Ex. { 1 n 2 n 3 n } couldn’t be accepted by PDA. –How could.
Turing Machines New capabilities: –infinite tape –can read OR write to tape –read/write head can move left and right q0q0 input tape.
Chapter 10 Models of Computation. What is a model? Captures the essence – the important properties – of the real thing Captures the essence – the important.
1 Turing Machines. 2 The Language Hierarchy Regular Languages Context-Free Languages ? ?
Fall 2004COMP 3351 Turing Machines. Fall 2004COMP 3352 The Language Hierarchy Regular Languages Context-Free Languages ? ?
CS 310 – Fall 2006 Pacific University CS310 Turing Machines Section 3.1 November 6, 2006.
Turing Machines.
1 Lecture 13 Turing machine model of computation –Sequential access memory (tape) –Limited data types and instructions –Graphical representation –Formal.
CS5371 Theory of Computation Lecture 10: Computability Theory I (Turing Machine)
Computability and Complexity 3-1 Turing Machine Computability and Complexity Andrei Bulatov.
1 Turing Machines. 2 The Language Hierarchy Regular Languages Context-Free Languages ? ?
Prof. Busch - LSU1 Turing Machines. Prof. Busch - LSU2 The Language Hierarchy Regular Languages Context-Free Languages ? ?
Theory of Computation. Computation Computation is a general term for any type of information processing that can be represented as an algorithm precisely.
Computers Central Processor Unit. Basic Computer System MAIN MEMORY ALUCNTL..... BUS CONTROLLER Processor I/O moduleInterconnections BUS Memory.
Design and Analysis of Algorithms
1 Turing Machines. 2 A Turing Machine Tape Read-Write head Control Unit.
AUTOMATA THEORY VIII.
More Theory of Computing
Turing Machines A more powerful computation model than a PDA ?
CSCI 2670 Introduction to Theory of Computing September 28, 2005.
 Computability Theory Turing Machines Professor MSc. Ivan A. Escobar
Unsolvability and Infeasibility. Computability (Solvable) A problem is computable if it is possible to write a computer program to solve it. Can all problems.
Dale Roberts Department of Computer and Information Science, School of Science, IUPUI CSCI 230 Models of Computation - Turing Machines Dale Roberts, Lecturer.
Alan Turing WWII code-breaker mathematical proof of ‘Turing machines’ …in particular, “Universal Turing machine” laid foundations of computer science father.
Halting Problem Introduction to Computing Science and Programming I.
THE CHURCH-TURING T H E S I S “ TURING MACHINES” Part 1 – Pages COMPUTABILITY THEORY.
CSE 311 Foundations of Computing I Lecture 26 Computability: Turing machines, Undecidability of the Halting Problem Spring
Dale Roberts Department of Computer and Information Science, School of Science, IUPUI CSCI 230 Models of Computation Dale Roberts, Lecturer Computer Science,
Fundamentals of Informatics Lecture 3 Turing Machines Bas Luttik.
TM Design Macro Language D and SD MA/CSSE 474 Theory of Computation.
Computer Theory Michael J. Watts
Lecture 9  2010 SDU Lecture9: Turing Machine.  2010 SDU 2 Historical Note Proposed by Alan Turing in 1936 in: On Computable Numbers, with an application.
Capabilities of computing systems Numeric and symbolic Computations A look at Computability theory Turing Machines.
Theory of computing, part 4. 1Introduction 2Theoretical background Biochemistry/molecular biology 3Theoretical background computer science 4History of.
Turing Machines Lecture 26 Naveen Z Quazilbash. Overview Introduction Turing Machine Notation Turing Machine Formal Notation Transition Function Instantaneous.
1 IDT Open Seminar ALAN TURING AND HIS LEGACY 100 Years Turing celebration Gordana Dodig Crnkovic, Computer Science and Network Department Mälardalen University.
1 Turing Machines - Chap 8 Turing Machines Recursive and Recursively Enumerable Languages.
Lecture 16b Turing Machines Topics: Closure Properties of Context Free Languages Cocke-Younger-Kasimi Parsing Algorithm June 23, 2015 CSCE 355 Foundations.
Automata & Formal Languages, Feodor F. Dragan, Kent State University 1 CHAPTER 3 The Church-Turing Thesis Contents Turing Machines definitions, examples,
1 Introduction to Turing Machines
1 CD5560 FABER Formal Languages, Automata and Models of Computation Lecture 12 Mälardalen University 2007.
1 Turing Machines. 2 The Language Hierarchy Regular Languages Context-Free Languages ? ?
Umans Complexity Theory Lectures Lecture 1b: Turing Machines & Halting Problem.
Chapter 9 Turing Machines What would happen if we change the stack in Pushdown Automata into some other storage device? Truing Machines, which maintains.
Turing Machine Model Are there computations that no “reasonable” computing machine can perform? –the machine should not store the answer to all possible.
1 Turing Machines. 2 The Language Hierarchy Regular Languages Context-Free Languages ? ?
1 Turing Machines. 2 The Language Hierarchy Regular Languages Context-Free Languages ? ?
Theory of Computation Automata Theory Dr. Ayman Srour.
TM Macro Language MA/CSSE 474 Theory of Computation.
8. Introduction to Turing Machines
Turing Machines Finite State Machines.
COSC 3340: Introduction to Theory of Computation
Turing Machines.
Pumping Lemma Revisited
COSC 3340: Introduction to Theory of Computation
Turing Machines Acceptors; Enumerators
Chapter 9 TURING MACHINES.
Foundations of Computer Science
Chapter 3: The CHURCH-Turing thesis
فصل سوم The Church-Turing Thesis
Theory of Computation Turing Machines.
8. Introduction to Turing Machines
COSC 3340: Introduction to Theory of Computation
Recall last lecture and Nondeterministic TMs
P.V.G’s College of Engineering, Nashik
Presentation transcript:

Computer Science 101 Theory of Computing

Computer Science is... The study of algorithms, with respect to –their formal properties –their linguistic realizations (in programming languages, from Python down to machine code) –their hardware realizations (machine architecture, logic circuits, transistors)

Things to Desire in an Algorithm Correctness Maintainability Efficiency

Wait, can it be solved? There are problems that do not have any algorithmic solution! Algorithms are carried out by computing agents What can these agents do, and what can’t they do?

What is a model? Models –Capture the essence of the real thing –Probably differ in scale from the real thing –Omit some of the details of the real thing –Lack the full functionality of the real thing

A Model of a Computing Agent Computing agent should be able to: –Accept input –Store information in and retrieve it from memory –Take actions according to algorithmic instructions –Produce output

The Turing Machine Developed by Alan Turing to demonstrate theoretical properties of computation 1935, before real computers Still the theoretical basis of computing

The Turing Machine Developed by Alan Turing to demonstrate theoretical properties of computation 1935, before real computers Still the theoretical basis of computing

Components of a TM Memory – a paper tape to which symbols can be written or from which they can be read States – a set of descriptions of actions to be performed (reading, writing, and moving the read/write head on the tape) Alphabet – a set of symbols to be input or output

The TM Tape Consists of squares in which symbols are written Extends an infinite distance in both directions (can always buy more tape) Can read or write a symbol from/to one square at a time

The Read/Write Head and States At startup, the read/write head (the arrow) is placed next to a square on the tape State 1 says “if the tape symbol is a 0, write a 1, move one square to the right, and go into state 2”

The Read/Write Head and a State The change from one state to the next one is called a transition On each transition, an input symbol is read, an output symbol is written, the read/right head moves left or right, and the machine goes into the next state

The Read/Write Head and a State Sometimes, the current state and the next state are the same (like a loop) Sometimes, the input and output symbols are the same The alphabet can contain any symbols

What Can a TM Do? Can execute a whole sequence of instructions Can accept input Can store information in and retrieve it from memory Can take actions according to algorithm instructions Can produce output

A Model of an Algorithm An algorithm must: –Be a well-ordered collection –Consist of unambiguous and effectively computable operations –Halt in a finite amount of time –Produce a result

Turing Machine Examples Turing machine –Must begin in state 1 on the leftmost nonblank cell –Machine state 1 must be a state in which 0s are changed to 1s and 1s are changed to 0s

Bit Inverter State diagram –Visual representation of a Turing machine algorithm –Circles represent states, and arrows represent transitions from one state to another

Invert the Bits This TM needs another transition, which reads a blank, writes a blank, moves left, and goes into State 2 State 2 then has no transitions (no actions), so it’s the halt state

Tuple Representation of States A state can also be represented as a set of tuples Each tuple has the form IN OUT NEXT DIR States for the bit inverter TM: IN OUT NEXT DIR R R b b 2 L State 1 State 2 (halt state)