1 Undecidability Everything is an Integer Countable and Uncountable Sets Turing Machines Recursive and Recursively Enumerable Languages.

Slides:



Advertisements
Similar presentations
CS 461 – Nov. 9 Chomsky hierarchy of language classes –Review –Let’s find a language outside the TM world! –Hints: languages and TM are countable, but.
Advertisements

CSCI 4325 / 6339 Theory of Computation Zhixiang Chen Department of Computer Science University of Texas-Pan American.
Copyright © Cengage Learning. All rights reserved.
1 COMP 382: Reasoning about algorithms Unit 9: Undecidability [Slides adapted from Amos Israeli’s]
Week 7 - Wednesday.  What did we talk about last time?  Set proofs and disproofs  Russell’s paradox.
Section 1.6: Sets Sets are the most basic of discrete structures and also the most general. Several of the discrete structures we will study are built.
Decidable A problem P is decidable if it can be solved by a Turing machine T that always halt. (We say that P has an effective algorithm.) Note that the.
1 More Undecidable Problems Rice’s Theorem Post’s Correspondence Problem Some Real Problems.
1 Undecidability Andreas Klappenecker [based on slides by Prof. Welch]
Introduction to Computability Theory
Courtesy Costas Busch - RPI1 A Universal Turing Machine.
CPSC 411, Fall 2008: Set 12 1 CPSC 411 Design and Analysis of Algorithms Set 12: Undecidability Prof. Jennifer Welch Fall 2008.
1 Linear Bounded Automata LBAs. 2 Linear Bounded Automata are like Turing Machines with a restriction: The working space of the tape is the space of the.
1 Undecidability Andreas Klappenecker [based on slides by Prof. Welch]
The Pumping Lemma for CFL’s
CHAPTER 4 Decidability Contents Decidable Languages
1 Decidability continued. 2 Undecidable Problems Halting Problem: Does machine halt on input ? State-entry Problem: Does machine enter state halt on input.
1 Decidability Turing Machines Coded as Binary Strings Diagonalizing over Turing Machines Problems as Languages Undecidable Problems.
Sequence A list of objects arranged in a particular order.
Fall 2004COMP 3351 A Universal Turing Machine. Fall 2004COMP 3352 Turing Machines are “hardwired” they execute only one program A limitation of Turing.
Lecture ,3.3 Sequences & Summations Proof by Induction.
1 Introduction to Computability Theory Lecture11: The Halting Problem Prof. Amos Israeli.
Decision Properties of Regular Languages
Properties of Context-Free Languages
Intro to Maths for CS: 2013/14 Sets (2) – OPTIONAL MATERIAL John Barnden Professor of Artificial Intelligence School of Computer Science University of.
Undecidability Everything is an Integer Countable and Uncountable Sets
Sequences – Page 1CSCI 1900 – Discrete Structures CSCI 1900 Discrete Structures Sequences Reading: Kolman, Section 1.3.
The Halting Problem – Undecidable Languages Lecture 31 Section 4.2 Wed, Oct 31, 2007.
1 Undecidability Reading: Chapter 8 & 9. 2 Decidability vs. Undecidability There are two types of TMs (based on halting): (Recursive) TMs that always.
1 1 CDT314 FABER Formal Languages, Automata and Models of Computation Lecture 15-1 Mälardalen University 2012.
Copyright © Cengage Learning. All rights reserved. CHAPTER 7 FUNCTIONS.
A Universal Turing Machine
Relations, Functions, and Countability
1 Linear Bounded Automata LBAs. 2 Linear Bounded Automata (LBAs) are the same as Turing Machines with one difference: The input string tape space is the.
Introduction to Real Analysis Dr. Weihu Hong Clayton State University 8/27/2009.
CS 208: Computing Theory Assoc. Prof. Dr. Brahim Hnich Faculty of Computer Sciences Izmir University of Economics.
Cardinality with Applications to Computability Lecture 33 Section 7.5 Wed, Apr 12, 2006.
1 Turing’s Thesis. 2 Turing’s thesis: Any computation carried out by mechanical means can be performed by a Turing Machine (1930)
1Computer Sciences Department. Book: INTRODUCTION TO THE THEORY OF COMPUTATION, SECOND EDITION, by: MICHAEL SIPSER Reference 3Computer Sciences Department.
Introduction to Finite Automata
1 Decision Properties of Regular Languages General Discussion of “Properties” The Pumping Lemma Minimizing DFA.
Classifications LanguageGrammarAutomaton Regular, right- linear Right-linear, left-linear DFA, NFA Context-free PDA Context- sensitive LBA Recursively.
1 Melikyan/DM/Fall09 Discrete Mathematics Ch. 7 Functions Instructor: Hayk Melikyan Today we will review sections 7.3, 7.4 and 7.5.
Section 3.2: Sequences and Summations. Def: A sequence is a function from a subset of the set of integers (usually the set of natural numbers) to a set.
Deterministic Finite Automata
Donghyun (David) Kim Department of Mathematics and Computer Science North Carolina Central University 1 Chapter 4 Decidability Some slides are in courtesy.
1 Turing Machines - Chap 8 Turing Machines Recursive and Recursively Enumerable Languages.
1 Undecidability Andreas Klappenecker [based on slides by Prof. Welch]
Section 2.5. Cardinality Definition: A set that is either finite or has the same cardinality as the set of positive integers (Z + ) is called countable.
1 Chapter 9 Undecidability  Turing Machines Coded as Binary Strings  Universal Turing machine  Diagonalizing over Turing Machines  Problems as Languages.
Introduction to Set Theory (§1.6) A set is a new type of structure, representing an unordered collection (group, plurality) of zero or more distinct (different)
1 A Universal Turing Machine. 2 Turing Machines are “hardwired” they execute only one program A limitation of Turing Machines: Real Computers are re-programmable.
Sequences Lecture 11. L62 Sequences Sequences are a way of ordering lists of objects. Java arrays are a type of sequence of finite size. Usually, mathematical.
The Acceptance Problem for TMs
Discrete Mathematics CS 2610
A Universal Turing Machine
CS 461 – Nov. 2 Sets Prepare for ATM finite vs. infinite Infinite sets
Cardinality of Sets Section 2.5.
Andreas Klappenecker [based on slides by Prof. Welch]
CSCE 411 Design and Analysis of Algorithms
Decidable Languages Costas Busch - LSU.
Decidability Turing Machines Coded as Binary Strings
Decidability Turing Machines Coded as Binary Strings
Formal Languages, Automata and Models of Computation
Subject Name: FORMAL LANGUAGES AND AUTOMATA THEORY
Cardinality Definition: The cardinality of a set A is equal to the cardinality of a set B, denoted |A| = |B|, if and only if there is a one-to-one correspondence.
Decidability continued….
Everything is an Integer Countable and Uncountable Sets
Cpt S 317: Spring 2009 Reading: Chapter 8 & 9
Turing Machines Everything is an Integer
Presentation transcript:

1 Undecidability Everything is an Integer Countable and Uncountable Sets Turing Machines Recursive and Recursively Enumerable Languages

2 Integers, Strings, and Other Things uData types have become very important as a programming tool. uBut at another level, there is only one type, which you may think of as integers or strings. uKey point: Strings that are programs are just another way to think about the same one data type.

3 Example: Text uStrings of ASCII or Unicode characters can be thought of as binary strings, with 8 or 16 bits/character. uBinary strings can be thought of as integers. uIt makes sense to talk about “the i-th string.”

4 Binary Strings to Integers uThere’s a small glitch: wIf you think simply of binary integers, then strings like 101, 0101, 00101,… all appear to be “the fifth string.” uFix by prepending a “1” to the string before converting to an integer. wThus, 101, 0101, and are the 13 th, 21 st, and 37 th strings, respectively.

5 Example: Images uRepresent an image in (say) GIF. uThe GIF file is an ASCII string. uConvert string to binary. uConvert binary string to integer. uNow we have a notion of “the i-th image.”

6 Example: Proofs uA formal proof is a sequence of logical expressions, each of which follows from the ones before it. uEncode mathematical expressions of any kind in Unicode. uConvert expression to a binary string and then an integer.

7 Proofs – (2) uBut a proof is a sequence of expressions, so we need a way to separate them. uAlso, we need to indicate which expressions are given.

8 Proofs – (3) uQuick-and-dirty way to introduce new symbols into binary strings: 1.Given a binary string, precede each bit by 0. uExample: 101 becomes Use strings of two or more 1’s as the special symbols. uExample: 111 = “the following expression is given”; 11 = “end of expression.”

9 Example: Encoding Proofs … A given expression follows An ex- pression End of expression Notice this 1 could not be part of the “end” A given expression follows Expression End

10 Example: Programs uPrograms are just another kind of data. uRepresent a program in ASCII. uConvert to a binary string, then to an integer. uThus, it makes sense to talk about “the i-th program.” uHmm…There aren’t all that many programs.

11 Finite Sets uIntuitively, a finite set is a set for which there is a particular integer that is the count of the number of members. uExample: {a, b, c} is a finite set; its cardinality is 3. uIt is impossible to find a 1-1 mapping between a finite set and a proper subset of itself.

12 Infinite Sets uFormally, an infinite set is a set for which there is a 1-1 correspondence between itself and a proper subset of itself. uExample: the positive integers {1, 2, 3,…} is an infinite set. wThere is a 1-1 correspondence 1 2, 2 4, 3 6,… between this set and a proper subset (the set of even integers).

13 Countable Sets uA countable set is a set with a 1-1 correspondence with the positive integers. wHence, all countable sets are infinite. uExample: All integers. w0 1; -i 2i; +i 2i+1. wThus, order is 0, -1, 1, -2, 2, -3, 3,… uExamples: set of binary strings, set of Java programs.

14 Enumerations uAn enumeration of a set is a 1-1 correspondence between the set and the positive integers. uThus, we have seen enumerations for strings, programs, proofs, and pairs of integers.

15 How Many Languages? uAre the languages over {0,1}* countable? uNo; here’s a proof. uSuppose we could enumerate all languages over {0,1}* and talk about “the i-th language.” uConsider the language L = { w | w is the i-th binary string and w is not in the i-th language}.

16 Proof – Continued uClearly, L is a language over {0,1}*. uThus, it is the j-th language for some particular j. uLet x be the j-th string. uIs x in L? wIf so, x is not in L by definition of L. wIf not, then x is in L by definition of L. Recall: L = { w | w is the i-th binary string and w is not in the i-th language}. x j-th LjLj

17 Proof – Concluded uWe have a contradiction: x is neither in L nor not in L, so our sole assumption (that there was an enumeration of the languages) is wrong. uComment: This is really bad; there are more languages than programs. uE.g., there are languages with no membership algorithm.

18 Turing-Machine Theory uThe purpose of the theory of Turing machines is to prove that certain specific languages have no algorithm. uStart with a language about Turing machines themselves. uReductions are used to prove more common questions undecidable.

Turing Machines 19