dddd Theory of Computation Dept. of Electrical Engineering National Taiwan University

Similar documents
Language properties and Grammar of Parallel and Series Parallel Languages

A R "! I,,, !~ii ii! A ow ' r.-ii ' i ' JA' V5, 9. MiN, ;

COMPUTATIONAL COMPLEXITY OF LEFT-ASSOCIATIVE GRAMMAR

A Version Space Approach to Learning Context-free Grammars

A General Class of Noncontext Free Grammars Generating Context Free Languages

Objectives. Chapter 2: The Representation of Knowledge. Expert Systems: Principles and Programming, Fourth Edition

Proof Theory for Syntacticians

Enumeration of Context-Free Languages and Related Structures

Lecture 1: Machine Learning Basics

Evolution of Collective Commitment during Teamwork

Lecture 10: Reinforcement Learning

PH.D. IN COMPUTER SCIENCE PROGRAM (POST M.S.)

On the Polynomial Degree of Minterm-Cyclic Functions

"f TOPIC =T COMP COMP... OBJ

Parsing of part-of-speech tagged Assamese Texts

Radius STEM Readiness TM

Grammars & Parsing, Part 1:

ENEE 302h: Digital Electronics, Fall 2005 Prof. Bruce Jacob

Syllabus for Philosophy of Mathematics Thomas Donaldson; Winter Quarter, 2015

B.S/M.A in Mathematics

Informatics 2A: Language Complexity and the. Inf2A: Chomsky Hierarchy

CS4491/CS 7265 BIG DATA ANALYTICS INTRODUCTION TO THE COURSE. Mingon Kang, PhD Computer Science, Kennesaw State University

RANKING AND UNRANKING LEFT SZILARD LANGUAGES. Erkki Mäkinen DEPARTMENT OF COMPUTER SCIENCE UNIVERSITY OF TAMPERE REPORT A ER E P S I M S

Self Study Report Computer Science

Computer Science 141: Computing Hardware Course Information Fall 2012

ENGBG1 ENGBL1 Campus Linguistics. Meeting 2. Chapter 7 (Morphology) and chapter 9 (Syntax) Pia Sundqvist

Erkki Mäkinen State change languages as homomorphic images of Szilard languages

Syntax Parsing 1. Grammars and parsing 2. Top-down and bottom-up parsing 3. Chart parsers 4. Bottom-up chart parsing 5. The Earley Algorithm

Logical Aspects of Digital Mathematics Libraries (extended abstract)

EECS 700: Computer Modeling, Simulation, and Visualization Fall 2014

We are strong in research and particularly noted in software engineering, information security and privacy, and humane gaming.

WSU Five-Year Program Review Self-Study Cover Page

Introduction to Simulation

IT Students Workshop within Strategic Partnership of Leibniz University and Peter the Great St. Petersburg Polytechnic University

MASTER OF SCIENCE (M.S.) MAJOR IN COMPUTER SCIENCE

Natural Language Processing. George Konidaris

Context Free Grammars. Many slides from Michael Collins

Action Models and their Induction

Grade 6: Correlated to AGS Basic Math Skills

Developing a TT-MCTAG for German with an RCG-based Parser

The Strong Minimalist Thesis and Bounded Optimality

Compositional Semantics

Statewide Framework Document for:

Probability and Game Theory Course Syllabus

Computer Organization I (Tietokoneen toiminta)

School of Innovative Technologies and Engineering

Learning Disability Functional Capacity Evaluation. Dear Doctor,

Backwards Numbers: A Study of Place Value. Catherine Perez

MTH 141 Calculus 1 Syllabus Spring 2017

(Sub)Gradient Descent

Testing A Moving Target: How Do We Test Machine Learning Systems? Peter Varhol Technology Strategy Research, USA

Visual CP Representation of Knowledge

Module 12. Machine Learning. Version 2 CSE IIT, Kharagpur

Logic for Mathematical Writing

Lecture 1: Basic Concepts of Machine Learning

Specification and Evaluation of Machine Translation Toy Systems - Criteria for laboratory assignments

Lecture 1.1: What is a group?

Infrared Paper Dryer Control Scheme

Foothill College Summer 2016

Physics 270: Experimental Physics

CS 598 Natural Language Processing

Dublin City Schools Mathematics Graded Course of Study GRADE 4

A Minimalist Approach to Code-Switching. In the field of linguistics, the topic of bilingualism is a broad one. There are many

CS 1103 Computer Science I Honors. Fall Instructor Muller. Syllabus

GACE Computer Science Assessment Test at a Glance

Ensemble Technique Utilization for Indonesian Dependency Parser

Abstractions and the Brain

CS177 Python Programming

Strategies for Solving Fraction Tasks and Their Link to Algebraic Thinking

TEACHING AND EXAMINATION REGULATIONS PART B: programme-specific section MASTER S PROGRAMME IN LOGIC

ENME 605 Advanced Control Systems, Fall 2015 Department of Mechanical Engineering

Toward Probabilistic Natural Logic for Syllogistic Reasoning

Data Structures and Algorithms

Basic Parsing with Context-Free Grammars. Some slides adapted from Julia Hirschberg and Dan Jurafsky 1

Computer Science (CS)

Enhancing Unlexicalized Parsing Performance using a Wide Coverage Lexicon, Fuzzy Tag-set Mapping, and EM-HMM-based Lexical Probabilities

Chinese Language Parsing with Maximum-Entropy-Inspired Parser

CS 101 Computer Science I Fall Instructor Muller. Syllabus

Designing a Computer to Play Nim: A Mini-Capstone Project in Digital Design I

MYCIN. The MYCIN Task

11/29/2010. Statistical Parsing. Statistical Parsing. Simple PCFG for ATIS English. Syntactic Disambiguation

University of Groningen. Systemen, planning, netwerken Bosman, Aart

On Human Computer Interaction, HCI. Dr. Saif al Zahir Electrical and Computer Engineering Department UBC

Improving Fairness in Memory Scheduling

Software Development: Programming Paradigms (SCQF level 8)

Level 6. Higher Education Funding Council for England (HEFCE) Fee for 2017/18 is 9,250*

AGS THE GREAT REVIEW GAME FOR PRE-ALGEBRA (CD) CORRELATED TO CALIFORNIA CONTENT STANDARDS

Lecture 2: Quantifiers and Approximation

CS 100: Principles of Computing

Introduction to HPSG. Introduction. Historical Overview. The HPSG architecture. Signature. Linguistic Objects. Descriptions.

AP Calculus AB. Nevada Academic Standards that are assessable at the local level only.

Short vs. Extended Answer Questions in Computer Science Exams

CALCULUS I Math mclauh/classes/calculusi/ SYLLABUS Fall, 2003

Lecture Videos to Supplement Electromagnetic Classes at Cal Poly San Luis Obispo

COMPUTER SCIENCE GRADUATE STUDIES Course Descriptions by Methodology

PHYSICS 40S - COURSE OUTLINE AND REQUIREMENTS Welcome to Physics 40S for !! Mr. Bryan Doiron

Approaches to control phenomena handout Obligatory control and morphological case: Icelandic and Basque

Page 1 of 11. Curriculum Map: Grade 4 Math Course: Math 4 Sub-topic: General. Grade(s): None specified

IAT 888: Metacreation Machines endowed with creative behavior. Philippe Pasquier Office 565 (floor 14)

Mathematics. Mathematics

Transcription:

dddd Theory of Computation ddd Dept. of Electrical Engineering National Taiwan University

Class Information Instructor: ddd E-mail: yen@cc.ee.ntu.edu.tw Web: http://www.ee.ntu.edu.tw/ yen Time: 9:10-12:10, Monday Place: BL 114 Office hours: by appointment Class web page: http://ccf.ee.ntu.edu.tw/ yen/courses/toc-2012.html

Textbook - HMU 3rd Edition Introduction to Automata Theory, Languages, and Computation John E. Hopcroft, Rajeev Motwani, Jeffrey D. Ullman (Addison-Wesley, 2006)

HMU 2nd Edition Introduction to Automata Theory, Languages, and Computation John E. Hopcroft, Rajeev Motwani, Jeffrey D. Ullman (Addison-Wesley, 2001)

HU 1st Edition Introduction to Automata Theory, Languages, and Computation John E. Hopcroft, Jeffrey D. Ullman (Addison-Wesley, 1979)

Grading HW/Project : 20% Midterm exam.: 40% Final exam.: 40%

A Simple Computer input: switch output: light bulb actions: flip switch states: on, off

A Simple Computer (cont d) input: switch output: light bulb actions: f for dflip switchd states: on, off bulb is on if and only if there was an odd number of flips

Another Computer inputs: switches 1 and 2 actions: 1 for dflip switch 1d actions: 2 for dflip switch 2d states: on, off bulb is on if and only if both switches were flipped an odd number of times

A Design Problem Can you design a circuit where the light is on if and only if all the switches were flipped exactly the same number of times?

A Design Problem (cont d) Such devices are difficult to reason about, because they can be designed in an infinite number of ways By representing them as abstract computational devices, or automata, we will learn how to answer such questions

Modeling Power They can describe the operation of any small computer, like the control component of an alarm clock or a microwave They are also used in lexical analyzers to recognize well formed expressions in programming languages: ab1 is a legal name of a variable in C 5u= is not

Different Kinds of Automata This was only one example of a computational device, and there are others. We will look at different devices, and look at the following questions: - What can a given type of device compute, and what are its limitations? - Is one type of device more powerful than another?

Some Devices We Will See

Why Study Automata Theory? Finite automata are a useful model for important kinds of hardware and software: Software for designing and checking digital circuits. Lexical analyzer of compilers. Finding words and patterns in large bodies of text, e.g. in web pages. Verification of systems with finite number of states, e.g. communication protocols.

Why Study Automata Theory? (cont d) The study of Finite Automata and Formal Languages are intimately connected. Methods for specifying formal languages are very important in many areas of CS, e.g.: Context Free Grammars are very useful when designing software that processes data with recursive structure, like the parser in a compiler. Regular Expressions are very useful for specifying lexical aspects of programming languages and search patterns.

Why Study Automata Theory? (cont d) Automata are essential for the study of the limits of computation. Two issues: What can a computer do at all? (Decidability) What can a computer do efficiently? (Intractability)

Applications

Aims of the Course To familiarize you with key Computer Science concepts in central areas like - Automata Theory - Formal Languages - Models of Computation - Complexity Theory To equip you with tools with wide applicability in the fields of CS and EE, e.g. for - Compiler Construction - Text Processing - XML

Fundamental Theme What are the capabilities and limitations of computers and computer programs? - What can we do with computers/programs? - Are there things we cannot do with computers/programs?

Studying the Theme How do we prove something CAN be done by SOME program? How do we prove something CANNOT be done by ANY program?

Example: The Halting Problem (1) Consider the following program. Does it terminate for all values of n 1? while (n > 1) if even(n) n = n/2; else n = n 3 + 1;

Example: The Halting Problem (2) Not as easy to answer as it might first seem. Say we start with n = 7, for example: 7, 22, 11, 34, 17, 52, 26, 13, 40, 20, 10, 5, 16, 8, 4, 2, 1 In fact, for all numbers that have been tried (a lot!), it does terminate...... but in general?

Example: The Halting Problem (3) Then the following important undecidability result should perhaps not come as a total surprise: It is impossible to write a program that decides if another, arbitrary, program terminates (halts) or not. What might be surprising is that it is possible to prove such a result. This was first done by the British mathematician Alan Turing.

Hilbert, Russell and Whitehead Late 1800 s to early 1900 s Axiomatic schemes: - Axioms plus sound rules of inference - Much of focus on number theory First Order Predicate Calculus - x y(y > x) Second Order (Peano s Axiom) - P((P(0) x(p(x) P(x + 1)) xp(x))

Hilbert In 1900 declared there were 23 really important problems in mathematics. Belief was that the solutions of these would help address math s complexity. Hilbert s Tenth asks for an algorithm to find the integral zeros of polynomial equations with integral coefficients. This is now known to be impossible (In 1972, Matiyacevic showed undecidable; Martin Davis et al. contributed key ideas to showing this). Hilbert s Belief: All mathematics could be developed within a formal system that allowed the mechanical creation and checking of proofs.

Gödel In 1931 he showed that any first order theory that embeds elementary arithmetic is either incomplete or inconsistent. He did this by showing that such a first order theory cannot reason about itself. That is, there is a first order expressible proposition that cannot be either proved or disproved, or the theory is inconsistent (some proposition and its complement are both provable). Gödel also developed the general notion of recursive functions but made no claims about their strength.

Turing, Post, Church, Kleene In 1936, each presented a formalism for computability. - Turing and Post devised abstract machines and claimed these represented all mechanically computable functions. - Church developed the notion of lambda-computability from recursive functions (as previously defined by Godel and Kleene) and claimed completeness for this model. Kleene demonstrated the computational equivalence of recursively defined functions to Post-Turing machines. Church s notation was the lambda calculus, which later gave birth to Lisp.

More on Alan Turing (1912d1954) Introduced an abstract model of computation, Turing Machines, to give a precise definition of what problems that can be solved by a computer even before real computers existed. A pioneer of automata theory. Instrumental in the success of British code breaking efforts during WWII.

More on Emil Post In the late 1930 s and the 1940 s, Post devised symbol manipulation systems in the form of rewriting rules (precursors to Chomsky s grammars). He showed their equivalence to Turing machines. In the 1920 s, starting with notation developed by Frege and others in 1880s, Post devised the truth table form we all use now for Boolean expressions (propositional logic). This was a part of his PhD thesis in which he showed the axiomatic completeness of the propositional calculus. Later (1940s), Post showed the complexity (undecidability) of determining what is derivable from an arbitrary set of propositional axioms.

Noam Chomsky (1928d) American linguist who introduced Context Free Grammars in an attempt to describe natural languages formally. Also introduced the Chomsky Hierarchy which classifies grammars and languages and their descriptive power.

Theory of Computation: A Historical Perspective

Computer vs. Automaton Computer Automaton

Various Automata Finite Automaton Linear-bounded Automaton Pushdown Automaton Turing Machine

Chomsky Hierarchy Classifying automata, grammars and languages and their descriptive power.

Topics (1) Finite automata, Regular languages, Regular grammars: deterministic vs. nondeterministic, one-way vs. two-way finite automata, minimization, pumping lemma for regular sets, closure properties. (2) Pushdown automata, Context-free languages, Context-free grammars: deterministic vs. nondeterministic, one-way vs. two-way PDAs, reversal bounded PDAs, linear grammars, counter machines, pumping lemma for CFLs, Chomsky normal form, Greibach normal form, closure properties.

Topics (cont d) (3) Linear bounded automata, Context-sensitive languages, Context-sensitive grammars (4) Turing machines, Recursively enumerable sets, Type 0 grammars: variants of Turing machines, halting problem, undecidability, Post correspondence problem, valid and invalid computations of TMs.

Topics (cont d) (5) Basic recursive function theory: Primitive recursive function, µ-recursive function, partial recursive function, total recursive function. (6) Basic complexity theory: Various resource bounded complexity classes, including NLOGSPACE, P, NP, PSPACE, EXPTIME, and many more. reducibility, completeness. (7) Advanced topics: Weighted automata, tree automata, quantum automata, probabilistic automata, interactive proof systems, oracle computations, cryptography.

Our Focus