8/25/2009 Sofya Raskhodnikova Intro to Theory of Computation L ECTURE 1 Theory of Computation Course information Overview of the area Finite Automata Sofya.

Slides:



Advertisements
Similar presentations
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.
Advertisements

Complexity Classes: P and NP
CS 345: Chapter 9 Algorithmic Universality and Its Robustness
8/27/2009 Sofya Raskhodnikova Intro to Theory of Computation L ECTURE 2 Theory of Computation Finite Automata Operations on languages Nondeterminism L2.1.
THE CHURCH-TURING T H E S I S “ TURING MACHINES” Pages COMPUTABILITY THEORY.
Complexity Theory Lecture 1 Lecturer: Moni Naor. Computational Complexity Theory Study the resources needed to solve computational problems –Computer.
CSC 3130: Automata theory and formal languages Andrej Bogdanov The Chinese University of Hong Kong Variants.
January 5, 2015CS21 Lecture 11 CS21 Decidability and Tractability Lecture 1 January 5, 2015.
Complexity 7-1 Complexity Andrei Bulatov Complexity of Problems.
CS21 Decidability and Tractability
1 Introduction to Computability Theory Lecture12: Decidable Languages Prof. Amos Israeli.
1 Introduction to Computability Theory Lecture11: Variants of Turing Machines Prof. Amos Israeli.
Introduction to Computability Theory
1 Introduction to Computability Theory Lecture7: PushDown Automata (Part 1) Prof. Amos Israeli.
P, NP, PS, and NPS By Muhannad Harrim. Class P P is the complexity class containing decision problems which can be solved by a Deterministic Turing machine.
Complexity 5-1 Complexity Andrei Bulatov Complexity of Problems.
FORMAL LANGUAGES, AUTOMATA AND COMPUTABILITY
Automata theory and formal languages Andrej Bogdanov The Chinese University of Hong Kong Fall 2008.
Fall 2005Costas Busch - RPI1 CSCI-2400 Models of Computation.
Lecture 5 Turing Machines
CHAPTER 4 Decidability Contents Decidable Languages
C SC 473 Automata, Grammars & Languages Automata, Grammars and Languages Discourse 01 Introduction.
Quantum Automata Formalism. These are general questions related to complexity of quantum algorithms, combinational and sequential.
CS 490: Automata and Language Theory Daniel Firpo Spring 2003.
Theory of Computing Lecture 20 MAS 714 Hartmut Klauck.
1 Non-Deterministic Finite Automata. 2 Alphabet = Nondeterministic Finite Automaton (NFA)
INHERENT LIMITATIONS OF COMPUTER PROGRAMS CSci 4011.
Final Exam Review Cummulative Chapters 0, 1, 2, 3, 4, 5 and 7.
Design and Analysis of Algorithms
By: Er. Sukhwinder kaur.  Computation Computation  Algorithm Algorithm  Objectives Objectives  What do we study in Theory of Computation ? What do.
Complexity and Computability Theory I Lecture #13 Instructor: Rina Zviel-Girshin Lea Epstein Yael Moses.
Introduction to the Theory of Computation
1 Theory of Computation 計算理論 2 Instructor: 顏嗣鈞 Web: Time: 9:10-12:10 PM, Monday Place: BL 103.
Theory of Computing Lecture 15 MAS 714 Hartmut Klauck.
1 An Introduction to Formal Languages and Automata Provided by : Babak Salimi webAdd:
CS/IT 138 THEORY OF COMPUTATION Chapter 1 Introduction to the Theory of Computation.
REGULAR LANGUAGES.
1 Unit 1: Automata Theory and Formal Languages Readings 1, 2.2, 2.3.
Pushdown Automata (PDAs)
1 Theory of Computation 計算理論 2 Instructor: 顏嗣鈞 Web: Time: 9:10-12:10 PM, Monday Place: BL.
Complexity and Computability Theory I Lecture #11 Instructor: Rina Zviel-Girshin Lea Epstein.
1Computer Sciences Department. Book: INTRODUCTION TO THE THEORY OF COMPUTATION, SECOND EDITION, by: MICHAEL SIPSER Reference 3Computer Sciences Department.
Automata & Formal Languages, Feodor F. Dragan, Kent State University 1 CHAPTER 3 The Church-Turing Thesis Contents Turing Machines definitions, examples,
1Computer Sciences Department. Book: INTRODUCTION TO THE THEORY OF COMPUTATION, SECOND EDITION, by: MICHAEL SIPSER Reference 3Computer Sciences Department.
D E C I D A B I L I T Y 1. 2 Objectives To investigate the power of algorithms to solve problems. To explore the limits of algorithmic solvability. To.
Foundations of (Theoretical) Computer Science Chapter 2 Lecture Notes (Section 2.2: Pushdown Automata) Prof. Karen Daniels, Fall 2010 with acknowledgement.
Automata & Formal Languages, Feodor F. Dragan, Kent State University 1 CHAPTER 3 The Church-Turing Thesis Contents Turing Machines definitions, examples,
CS 461 – Oct. 28 TM applications –Recognize a language √ –Arithmetic √ –Enumerate a set –Encode a data structure or problem to solve Two kinds of TMs –Decider:
Theory of Computational Complexity TA : Junichi Teruyama Iwama lab. D3
Theory of Computation. Introduction to The Course Lectures: Room ( Sun. & Tue.: 8 am – 9:30 am) Instructor: Dr. Ayman Srour (Ph.D. in Computer Science).
Modeling Arithmetic, Computation, and Languages Mathematical Structures for Computer Science Chapter 8 Copyright © 2006 W.H. Freeman & Co.MSCS SlidesTuring.
Theory of Computation. Introduction We study this course in order to answer the following questions: What are the fundamental capabilities and limitations.
Formal Foundations-II [Theory of Automata]
Introduction to the Theory of Computation
Pushdown Automata.
Intro to Theory of Computation
Intro to Theory of Computation
Summary.
Intro to Theory of Computation
Intro to Theory of Computation
Intro to Theory of Computation
Decidable Languages Costas Busch - LSU.
CS21 Decidability and Tractability
Data Structures and Algorithms CSE 465
Intro to Theory of Computation
Recall last lecture and Nondeterministic TMs
Intro to Theory of Computation
Lecture One: Automata Theory Amjad Ali
Sofya Raskhodnikova; Intro Theory of Computation
Intro to Theory of Computation
Presentation transcript:

8/25/2009 Sofya Raskhodnikova Intro to Theory of Computation L ECTURE 1 Theory of Computation Course information Overview of the area Finite Automata Sofya Raskhodnikova; Intro Theory of Computation

Course information 1.Instructors 2.Course website 3.Honors credit 4.Prerequisites 5.Textbook 6.Syllabus 7.Homework logistics 8.Collaboration policy 9.Exams and grading 10.Influenza precautions Sofya Raskhodnikova; Intro Theory of ComputationL1.2 8/25/2009

What is Theory of Computation? You’ve learned about computers and programming Much of this knowledge is specific to particular computing environment Sofya Raskhodnikova; based on lecture notes by Nancy LynchL1.3 8/25/2009

What is Theory of Computation? Theory –General ideas that apply to many systems –Expressed simply, abstractly, precisely Abstraction suppresses inessential details Precision enables rigorous analysis –Correctness proofs for algorithms and system designs –Formal analysis of complexity Proof that there is no algorithm to solve some problem in some setting (with certain cost) Sofya Raskhodnikova; based on lecture notes by Nancy LynchL1.4 8/25/2009

This course Theory basics –Models for machines –Models for the problems machines can be used to solve –Theorems about what kinds of machines can solve what kinds of problems, and at what cost –Theory needed for sequential single-processor computing Not covered: –Parallel machines –Distributed systems –Quantum computation –Real-time systems –Mobile computing –Embedded systems –… Sofya Raskhodnikova; based on lecture notes by Nancy LynchL1.5 8/25/2009

Machine models Finite Automata (FAs): machines with fixed amount of unstructured memory –useful for modeling chips, communication protocols, adventure games, some control systems, … Pushdown Automata (PDAs): FAs with unbounded structured memory in the form of a pushdown stack –useful for modeling parsing, compilers, some calculations Turing Machines (TMs): FAs with unbounded tape –Model for general sequential computation (real computer). –Equivalent to RAMs, various programming languages models –Suggests general notion of computability Sofya Raskhodnikova; based on lecture notes by Nancy LynchL1.6 8/25/2009

Machine models Resource-bounded TMs (time and space bounded): –“not that different” on different models: “within a polynomial factor” Probabilistic TMs: extension of TMs that allows random choices Most of these models have nondeterministic variants: can make nondeterministic “guesses” Sofya Raskhodnikova; based on lecture notes by Nancy LynchL1.7 8/25/2009

Problems solved by machines 1.What is a problem? 2.What does it mean for a machine to “solve” a problem? In this course, problem is a language. A language is a set of strings over some “alphabet” Sofya Raskhodnikova; based on lecture notes by Nancy LynchL1.8 8/25/2009

Examples of languages L 1 = {binary representations of natural numbers divisible by 2} L 2 = {binary representations of primes} L 3 = {sequences of decimal numbers, separated by commas, that can be divided into 2 groups with the same sum} –(5,3,1,3)  L 3, (15,7,5,9,1)  L 3. L 4 = {C programs that loop forever when run} L 5 = {representations of graphs containing a Hamiltonian cycle} –{(1,2,3,4,5); (1,2),(1,3),(2,3),…} alphabet = {0,1} alphabet = {0,1,…,9,comma} visits each node exactly once verticesedges alphabet = all symbols: digits, commas, parens Sofya Raskhodnikova; based on lecture notes by Nancy LynchL1.9 8/25/2009

Theorems about classes of languages We will define classes of languages and prove theorems about them: inclusion: Every language recognizable (i.e., solvable) by a FA is also recognizable by a TM. non-inclusion: Not every language recognizable by a TM is also recognizable by a FA. completeness: “Hardest” language in a class robustness: alternative characterizations of classes –e.g., FA-recognizable languages by regular expressions (UNIX) Sofya Raskhodnikova; based on lecture notes by Nancy LynchL1.10 8/25/2009

Why study theory of computation? a language for talking about program behavior feasibility (what can and cannot be done) –halting problem, NP-completeness analyzing correctness and resource usage computationally hard problems are essential for cryptography computation is fundamental to understanding the world – cells, brains, social networks, physical systems all can be viewed as computational devices IT IS FUN!!! Sofya Raskhodnikova; Intro Theory of ComputationL1.11 8/25/2009

Is it useful for programmers? Sofya Raskhodnikova; from “Computers and Intractability” by Garey and JohnsonL1.12 Boss, I can’t find an efficient algorithm. I guess I ‘m just too dumb. Boss, I can’t find an efficient algorithm, because no such algorithm is possible. 8/25/2009

Parts of the course Sofya Raskhodnikova; Intro Theory of Computation 8/25/2009 I.Automata Theory II.Computability Theory III.Complexity Theory L1.13

Finite automata (FA) Sofya Raskhodnikova; based on slides by Nick Hopper 0 0, accepted rejected 8/25/2009 Each string is either accepted or rejected by the automaton depending on whether it is in an accept state at the end. L1.14

Anatomy of finite automaton 8/25/ , L1.15 Sofya Raskhodnikova; based on slides by Nick Hopper states q0q0 q1q1 q2q2 q3q3 start state (q 0 ) accept states (F)

Formal Definition 8/25/2009 Q is the set of states Σ is the alphabet  : Q  Σ → Q is the transition function q 0  Q is the start state F  Q is the set of accept states A finite automaton is a 5-tuple M = (Q, Σ, , q 0, F) L(M) = the language of machine M = set of all strings machine M accepts L1.16 Sofya Raskhodnikova; based on slides by Nick Hopper

Examples of FAs 8/25/2009 Sofya Raskhodnikova; based on slides by Nick Hopper L1.17 0,1 q0q0 L(M) = {w | w is a string of 0s and 1s}  q0q0 L(M) = {ε} where ε denotes the empty string 0,1 q1q1

Examples of FAs 8/25/2009 Sofya Raskhodnikova; based on slides by Nick Hopper q0q0 q1q L1.18 L(M) = {w | w has an even number of 1s}

qq q0q0 q ,1 Build an automaton that accepts all (and only those) strings that contain 001 8/25/2009 Sofya Raskhodnikova; based on slides by Nick Hopper L1.19 Examples of FAs

A language is regular if it is recognized by a finite automaton L = { w | w contains 001} is regular L = { w | w has an even number of 1s} is regular 8/25/2009 Sofya Raskhodnikova; based on slides by Nick Hopper L1.20 Regular languages Many interesting programs recognize regular languages NETWORK PROTOCOLS COMPILERS GENETIC TESTING ARITHMETIC