# CS 3719 (Theory of Computation and Algorithms) Lecture 4

Save this PDF as:

Size: px
Start display at page:

## Transcription

1 CS 3719 (Theory of Computation and Algorithms) Lecture 4 Antonina Kolokolova January 18, Undecidable languages 1.1 Church-Turing thesis Let s recap how it all started. In 1990, Hilbert stated a list of problems for mathematicians of the next century; some of these problems asked to devise a procedure ; two of those problems are devise a procedure for solving an equation over integers (Diophantine equations) that you have seen in the first lecture, and devise a procedure that, given a statement of mathematics, would decide if it is true or false. Alan Turing was working on Hilbert s problem that asked for an algorithm that for any statement of mathematics would state whether it is true or false; Gödel has shown (his famous Incompleteness Theorem) that there are statements of mathematics for which such answer cannot be given, but it remained open at that time whether there is such a procedure for statements for which that answer could be given. There were several mathematicians working on this problem at that time; notably, Alonco Church solved this problem (to give a negative answer) at about the same time, by inventing lambda-calculus. Turing s approach is somewhat more computational: he defined a model of computation which we now call the Turing machine, equivalent to Church s model in terms of power, and used it to show undecidability results, thus giving a negative answer to Hilbert s problem. Definition 13 (Church-Turing thesis). Anything computable by an algorithm of any kind (our intuitive notion of algorithm) is computable by a Turing machine. The material in this set of notes came from many sources, in particular Introduction to Theory of Computation by Sipser and course notes of U. of Toronto CS 364. Many thanks to Richard Bajona for taking notes! 1

2 Since this statement talks about an intuitive notion of algorithm we cannot really prove it; all we can do is that whenever we think of a natural notion of an algorithm, show that this can be done by a Turing machine. In this lecture we will show that even though Turing machines are considered to be as powerful as any algorithm we can think of, there are languages that are not computable by Turing machines. Thus, for these languages, it is likely that no algorithm we can think of would work. We will present two proofs of existence of undecidable languages. The first proof is nonconstructive, using Cantor s diagonalization. The second proof presents an actual language that is undecidable. 1.2 Diagonalization The Diagonalization method is used to prove that two (infinite) sets have different cardinalities, that is, a set A is larger than the set B. By definition of cardinalities, this means that there is no one-to-one correspondence between elements of the two set, so the elements of A cannot be enumerated by elements of B. The proof is by contradiction: assume that there is such a enumeration. Then, construct an element of A which is not in the list. In our case, the larger set A will be the set of all languages (for simplicity, over Σ = {0, 1}, but any alphabet with at least 2 symbols will work). And B will be the set of all Turing machines. First, let us say how we describe languages. Recall that a characteristic string of a set is an infinite string of 0s and 1s where, for a given order (usually lexicographic order) of elements in the set there is a 0 in i th position in the string if i th element in the order is not in the set and 1 if it is in the set. For example, for a set L = {1, 01} over {0, 1} the characteristic string would be , since out of the lexicographic ordering {ɛ, 0, 1, 00, 01, 10, 11, 000,... } of {0, 1} only the 3rd and 5th elements are in L. Thus, for every language over {0, 1} (or any alphabet with at least 2 elements) there is a (unique) characteristic string describing this language. Now, we need to describe Turing machines and state how to enumerate them (show that the set of all Turing machines is countable). For that, we show that every Turing machine can be encoded by a distinct finite binary string (and is thus a subset of all finite binary strings, which is countable since every string can be treated as a binary number with the leading 1 missing). To encode a Turing machine, it is sufficient to write, in binary, the tuple (Q, Σ, Γ, δ, q 0, q accept, q reject ). However, we are not interested in specific names of symbols in Q, Σ, Γ; we are just interested in how many symbols are in each. A Turing machine which accepts all even-length strings over {a, b} operates exactly the same way as a Turing machine accepting all even-length strings over {0, 1}, with a changed to 0 and b changed to 1 everywhere in its description. 2

3 We assign an order to elements of Q, Σ and Γ, and refer to elements as 1st symbol of Σ, 5th state in Q and so on. So all we need to write is the number of states in Q (for simplicity, we can even rename states to have q 0 be the first state in the list, q accept second and q reject third, since every Turing machine will have these three states), number of symbols in Σ and Γ (say Γ consists of Σ followed by followed by possible extra symbols). Finally, we need to write out δ, using the indices of symbols in Q, Σ and Γ in the description of transitions. Here is one way of doing the description. We can start by writing Q 1s, then a 0, then Σ 1s, then another 0, then Γ 1s, and a 0 again. We could also write all elements of δ in unary (since it is finite), but we can also do so in binary, by introducing a special separator symbol, into Σ. If we have to stick to Σ = {0, 1}, then we can still write δ in binary as follows: associate 11 with,, 00 with 0 and 01 with 1. For example, say we want to encode a transition (q 3, a) (q 4, b, L). With separators, it can be coded in binary as 11, 0, 100, 1, 0 (here, code L by 0 and R by 1). Using the transformation to encode the transition in binary obtain Note that this method of coding allows us to talk about all sorts of objects as an input to a Turing machine, be it Java code or descriptions of graphs. Notation 1. We will use the notation M to mean a binary string encoding of a Turing machine M. We can use the same notation to talk about encodings of other objects, e.g. M, w encodes a pair Turing machine M and a string w; N encoding a NFA N, G for a graph G and so on, Now, notice that for every Turing machine there is a finite binary description. Treating this description as a binary number, obtain an enumeration (by a subset of N of all Turing machines. Finally, we can do the diagonalization argument. Start by assuming that it is possible to enumerate all languages by Turing machines. Write elements of characteristic strings as columns, and Turing machine descriptions as rows. Put a 1 in cell (i, j) if the i th Turing machine M i accepts string number j in the enumeration, and 0 if it does not accept this string. We obtain a table as in the following example (for different enumerations of Turing machines the 0s and 1s would be different), and use diagonalization argument to construct a language not recognized by any Turing machine. Indeed, if that language were recognized by some Turing machine, say M k, it would be the string in the k th row of the table; however, it differs from the diagonal language in k th element. M M M M M ots D

4 1.3 Universal Turing machine and undecidability of A T M In this section we will present a specific, very natural problem and show that it is undecidable. It will lead us to a whole class of problems of similar complexity. Definition 14. The language A T M = { M, w M is a Turing machine and w is a string over the input alphabet of M and M accepts w} That is, the language A T M consists of all pairs M, w of Turing machine + a string in L(M). Theorem 15. A T M is semi-decidable, but not decidable. Proof. Let us first show that A T M is semi-decidable. That is, there exists a Turing machine M AT M accepting all and only strings in A T M. Note that if M does not halt on w, neither does M AT M on M, w M AT M : On input M, w Simulate M on w. If M accepts w, accept. If M rejects w, reject. Note that the above algorithm is essentially an interpreter; that is a program which takes as input both a program P and an input w to that program, and simulates P on input w. In this case the program P is given by a Turing machine M. In particular, the Turing machine interpreter M AT M is known under the name of a Universal Turing Machine. Turing described a universal Turing machine in some detail in his original 1936 paper, an ideal which paved the way for later interpreters operating on real computers. This is quite a meta-mathematical concept, though: a single Turing machine, and a simple one at that, that could do the job of any other Turing machine provided it is given the description of the TM it is supposed to simulate and a string to work on. Now, let us show that A T M is not decidable. Assume for the sake of contradiction that it is, so there is a Turing machine H that takes as an input M, w and halts either accepting (if M accepted w) or rejecting (if M did not accept w). Now, define the following language: Diag = { M M is a Turing machine and M / L(M)}. That is, Diag is a language of all descriptions of Turing machines that do not accept a string that is their own encoding. This is exactly the diagonal language from our diagonalization table. Now, notice that H deciding A T M can also be used to decide Diag: H( (M, M ) ) halts and accepts if M accepts its own encoding and rejects if M does not accept its own encoding. A decider H Diag for Diag would run H( (M, M ) ) and accept if H rejects, reject if H accepts. But what should it do on input H Diag? It cannot accept this input, since that would mean 4

5 that H Diag accepts its own encoding, so it should not be in Diag. And it cannot reject its own encoding, since it would make it a Turing machine not accepting its own encoding and thus it has to be in Diag. Contradiction. This contradiction is akin to Russell s paradox from logic, and other self-referential paradoxes of the form I am lying. 1.4 Closure properties of decidable and semi-decidable languages Now, here is a question. Suppose you are given two languages, L 1 and L 2. What can you say about a language L 1 L 2 = {x x L 1 or x L 2? For example, suppose you are interested in all strings either code Turing machines or are prime numbers when viewed as a binary number; in this case, your L 1 could be all encodings of Turing machines and L 2 all prime numbers. Similarly, you may want to ask about L 1 L 2 which contains strings which are in both languages (that is, encodings of TMs which are primes when viewed as binary numbers, in our example.) Suppose you know that L 1 and L 2 are both decidable, or both semi-decidable what does it tell you about decidability (semi-decidability) of their union and intersection? Theorem 16. The class of semi-decidable languages is closed under union and intersection operations. Proof. Let L 1 and L 2 be two semi-decidable languages, and let M 1, M 2 be Turing machines such that L(M 1 ) = L 1 and L(M 2 ) = L2. We will construct Turing machines M L1 L 2 and accepting union and intersection of L 1 and L 2, respectively. M L1 L 2 Consider the union operation first; intersection will be similar. Let x be the input for which we are trying to decide whether it is in L 1 L 2. The first idea could be to try to run M 1 on x, and if it does not accept, then run M 2 on x. But M 1 is not guaranteed to stop on x, and we would still like to accept x if M 2 accepts it. So the solution is to run M 1 and M 2 in parallel, switching between executing one or the other. If at some point in the computation either M 1 or M 2 accepts, we accept; if neither accepts, can run forever but this is OK, because if neither M 1 nor M 2 accepts x then x / L 1 L 2. So we define M L1 L 2 as follows: M L1 L 2 : On input x Fori = 1 to Run M 1 on x for i steps. If M 1 accepts, accept. Run M 2 on x for i steps. If M 2 accepts, accept. 5

6 The intersection, in this case, is very similar. The only difference is that we accept at stage i if not just one, but both M 1 and M 2 accepted in i st eps. Corollary 17. A T M is not semi-decidable. Moreover, complement of any semi-decidable, but undecidable language is not semi-decidable. Proof. Otherwise, running Turing machines M AT M and M AT M simultaneously, as in the proof above, we could decide A T M. Same holds for any semi-decidable, but undecidable language. This shows that the class of semi-decidable languages is different (incomparable) from the class of co-semi-decidable ones. Also, there are languages that are neither semi-decidable nor co-semi-decidable. For example, consider a simple language 0 1A tm = {< M, w > TM M accepts 01 and loops on 1w}. Intuitively, testing if < M, w > is in the language requires solving an A T M problem and a A T M problem. The first one makes it not co-semi-decidable, the second not semi-decidable. 6

### Computability Theory

CSC 438F/2404F Notes (S. Cook and T. Pitassi) Fall, 2014 Computability Theory This section is partly inspired by the material in A Course in Mathematical Logic by Bell and Machover, Chap 6, sections 1-10.

### Theory of Computation Prof. Kamala Krithivasan Department of Computer Science and Engineering Indian Institute of Technology, Madras

Theory of Computation Prof. Kamala Krithivasan Department of Computer Science and Engineering Indian Institute of Technology, Madras Lecture No. # 31 Recursive Sets, Recursively Innumerable Sets, Encoding

### Turing Machines: An Introduction

CIT 596 Theory of Computation 1 We have seen several abstract models of computing devices: Deterministic Finite Automata, Nondeterministic Finite Automata, Nondeterministic Finite Automata with ɛ-transitions,

### Sets and Subsets. Countable and Uncountable

Sets and Subsets Countable and Uncountable Reading Appendix A Section A.6.8 Pages 788-792 BIG IDEAS Themes 1. There exist functions that cannot be computed in Java or any other computer language. 2. There

### CSE 135: Introduction to Theory of Computation Decidability and Recognizability

CSE 135: Introduction to Theory of Computation Decidability and Recognizability Sungjin Im University of California, Merced 04-28, 30-2014 High-Level Descriptions of Computation Instead of giving a Turing

### 3515ICT Theory of Computation Turing Machines

Griffith University 3515ICT Theory of Computation Turing Machines (Based loosely on slides by Harald Søndergaard of The University of Melbourne) 9-0 Overview Turing machines: a general model of computation

### We give a basic overview of the mathematical background required for this course.

1 Background We give a basic overview of the mathematical background required for this course. 1.1 Set Theory We introduce some concepts from naive set theory (as opposed to axiomatic set theory). The

### Computational Models Lecture 8, Spring 2009

Slides modified by Benny Chor, based on original slides by Maurice Herlihy, Brown Univ. p. 1 Computational Models Lecture 8, Spring 2009 Encoding of TMs Universal Turing Machines The Halting/Acceptance

### Notes on Complexity Theory Last updated: August, 2011. Lecture 1

Notes on Complexity Theory Last updated: August, 2011 Jonathan Katz Lecture 1 1 Turing Machines I assume that most students have encountered Turing machines before. (Students who have not may want to look

### CS154. Turing Machines. Turing Machine. Turing Machines versus DFAs FINITE STATE CONTROL AI N P U T INFINITE TAPE. read write move.

CS54 Turing Machines Turing Machine q 0 AI N P U T IN TAPE read write move read write move Language = {0} q This Turing machine recognizes the language {0} Turing Machines versus DFAs TM can both write

### (IALC, Chapters 8 and 9) Introduction to Turing s life, Turing machines, universal machines, unsolvable problems.

3130CIT: Theory of Computation Turing machines and undecidability (IALC, Chapters 8 and 9) Introduction to Turing s life, Turing machines, universal machines, unsolvable problems. An undecidable problem

### 6.080 / 6.089 Great Ideas in Theoretical Computer Science Spring 2008

MIT OpenCourseWare http://ocw.mit.edu 6.080 / 6.089 Great Ideas in Theoretical Computer Science Spring 2008 For information about citing these materials or our Terms of Use, visit: http://ocw.mit.edu/terms.

### FORMAL LANGUAGES, AUTOMATA AND COMPUTATION

FORMAL LANGUAGES, AUTOMATA AND COMPUTATION REDUCIBILITY ( LECTURE 16) SLIDES FOR 15-453 SPRING 2011 1 / 20 THE LANDSCAPE OF THE CHOMSKY HIERARCHY ( LECTURE 16) SLIDES FOR 15-453 SPRING 2011 2 / 20 REDUCIBILITY

### Outline. Database Theory. Perfect Query Optimization. Turing Machines. Question. Definition VU , SS Trakhtenbrot s Theorem

Database Theory Database Theory Outline Database Theory VU 181.140, SS 2016 4. Trakhtenbrot s Theorem Reinhard Pichler Institut für Informationssysteme Arbeitsbereich DBAI Technische Universität Wien 4.

### Lecture 2: Universality

CS 710: Complexity Theory 1/21/2010 Lecture 2: Universality Instructor: Dieter van Melkebeek Scribe: Tyson Williams In this lecture, we introduce the notion of a universal machine, develop efficient universal

### ECS 120 Lesson 17 Church s Thesis, The Universal Turing Machine

ECS 120 Lesson 17 Church s Thesis, The Universal Turing Machine Oliver Kreylos Monday, May 7th, 2001 In the last lecture, we looked at the computation of Turing Machines, and also at some variants of Turing

### 1 Definition of a Turing machine

Introduction to Algorithms Notes on Turing Machines CS 4820, Spring 2012 April 2-16, 2012 1 Definition of a Turing machine Turing machines are an abstract model of computation. They provide a precise,

### Chapter 7 Uncomputability

Chapter 7 Uncomputability 190 7.1 Introduction Undecidability of concrete problems. First undecidable problem obtained by diagonalisation. Other undecidable problems obtained by means of the reduction

### Sets and set operations

CS 441 Discrete Mathematics for CS Lecture 7 Sets and set operations Milos Hauskrecht milos@cs.pitt.edu 5329 Sennott Square asic discrete structures Discrete math = study of the discrete structures used

### Introduction to Turing Machines

Automata Theory, Languages and Computation - Mírian Halfeld-Ferrari p. 1/2 Introduction to Turing Machines SITE : http://www.sir.blois.univ-tours.fr/ mirian/ Automata Theory, Languages and Computation

### A TM. Recall the A TM language: A TM = { M, w M is a TM and M accepts w.} is undecidable. Theorem: The language. p.2/?

p.1/? Reducibility We say that a problem Q reduces to problem P if we can use P to solve Q. In the context of decidability we have the following templates : If A reduces to B and B is decidable, then so

### Computing basics. Ruurd Kuiper

Computing basics Ruurd Kuiper October 29, 2009 Overview (cf Schaum Chapter 1) Basic computing science is about using computers to do things for us. These things amount to processing data. The way a computer

### Automata and Computability. Solutions to Exercises

Automata and Computability Solutions to Exercises Fall 25 Alexis Maciel Department of Computer Science Clarkson University Copyright c 25 Alexis Maciel ii Contents Preface vii Introduction 2 Finite Automata

### 6.080 / 6.089 Great Ideas in Theoretical Computer Science Spring 2008

MIT OpenCourseWare http://ocw.mit.edu 6.080 / 6.089 Great Ideas in Theoretical Computer Science Spring 2008 For information about citing these materials or our Terms of Use, visit: http://ocw.mit.edu/terms.

### Formal Languages and Automata Theory - Regular Expressions and Finite Automata -

Formal Languages and Automata Theory - Regular Expressions and Finite Automata - Samarjit Chakraborty Computer Engineering and Networks Laboratory Swiss Federal Institute of Technology (ETH) Zürich March

### 13 Infinite Sets. 13.1 Injections, Surjections, and Bijections. mcs-ftl 2010/9/8 0:40 page 379 #385

mcs-ftl 2010/9/8 0:40 page 379 #385 13 Infinite Sets So you might be wondering how much is there to say about an infinite set other than, well, it has an infinite number of elements. Of course, an infinite

### The Halting Problem is Undecidable

185 Corollary G = { M, w w L(M) } is not Turing-recognizable. Proof. = ERR, where ERR is the easy to decide language: ERR = { x { 0, 1 }* x does not have a prefix that is a valid code for a Turing machine

### THE TURING DEGREES AND THEIR LACK OF LINEAR ORDER

THE TURING DEGREES AND THEIR LACK OF LINEAR ORDER JASPER DEANTONIO Abstract. This paper is a study of the Turing Degrees, which are levels of incomputability naturally arising from sets of natural numbers.

### CAs and Turing Machines. The Basis for Universal Computation

CAs and Turing Machines The Basis for Universal Computation What We Mean By Universal When we claim universal computation we mean that the CA is capable of calculating anything that could possibly be calculated*.

### (Refer Slide Time: 1:41)

Discrete Mathematical Structures Dr. Kamala Krithivasan Department of Computer Science and Engineering Indian Institute of Technology, Madras Lecture # 10 Sets Today we shall learn about sets. You must

### CS 341 Homework 9 Languages That Are and Are Not Regular

CS 341 Homework 9 Languages That Are and Are Not Regular 1. Show that the following are not regular. (a) L = {ww R : w {a, b}*} (b) L = {ww : w {a, b}*} (c) L = {ww' : w {a, b}*}, where w' stands for w

### Turing Machine and the Conceptual Problems of Computational Theory

Research Inventy: International Journal of Engineering And Science Vol.4, Issue 4 (April 204), PP 53-60 Issn (e): 2278-472, Issn (p):239-6483, www.researchinventy.com Turing Machine and the Conceptual

### 24 Uses of Turing Machines

Formal Language and Automata Theory: CS2004 24 Uses of Turing Machines 24 Introduction We have previously covered the application of Turing Machine as a recognizer and decider In this lecture we will discuss

### Turing Machines, Part I

Turing Machines, Part I Languages The \$64,000 Question What is a language? What is a class of languages? Computer Science Theory 2 1 Now our picture looks like Context Free Languages Deterministic Context

### SETS, RELATIONS, AND FUNCTIONS

September 27, 2009 and notations Common Universal Subset and Power Set Cardinality Operations A set is a collection or group of objects or elements or members (Cantor 1895). the collection of the four

### Automata and Formal Languages

Automata and Formal Languages Winter 2009-2010 Yacov Hel-Or 1 What this course is all about This course is about mathematical models of computation We ll study different machine models (finite automata,

### 6.045: Automata, Computability, and Complexity Or, Great Ideas in Theoretical Computer Science Spring, 2010. Class 4 Nancy Lynch

6.045: Automata, Computability, and Complexity Or, Great Ideas in Theoretical Computer Science Spring, 2010 Class 4 Nancy Lynch Today Two more models of computation: Nondeterministic Finite Automata (NFAs)

### Reading 13 : Finite State Automata and Regular Expressions

CS/Math 24: Introduction to Discrete Mathematics Fall 25 Reading 3 : Finite State Automata and Regular Expressions Instructors: Beck Hasti, Gautam Prakriya In this reading we study a mathematical model

### Automata and Languages

Automata and Languages Computational Models: An idealized mathematical model of a computer. A computational model may be accurate in some ways but not in others. We shall be defining increasingly powerful

### Regular Languages and Finite Automata

Regular Languages and Finite Automata 1 Introduction Hing Leung Department of Computer Science New Mexico State University Sep 16, 2010 In 1943, McCulloch and Pitts [4] published a pioneering work on a

### A Formalization of the Turing Test Evgeny Chutchev

A Formalization of the Turing Test Evgeny Chutchev 1. Introduction The Turing test was described by A. Turing in his paper [4] as follows: An interrogator questions both Turing machine and second participant

### MAT2400 Analysis I. A brief introduction to proofs, sets, and functions

MAT2400 Analysis I A brief introduction to proofs, sets, and functions In Analysis I there is a lot of manipulations with sets and functions. It is probably also the first course where you have to take

### the lemma. Keep in mind the following facts about regular languages:

CPS 2: Discrete Mathematics Instructor: Bruce Maggs Assignment Due: Wednesday September 2, 27 A Tool for Proving Irregularity (25 points) When proving that a language isn t regular, a tool that is often

### Georg Cantor (1845-1918):

Georg Cantor (845-98): The man who tamed infinity lecture by Eric Schechter Associate Professor of Mathematics Vanderbilt University http://www.math.vanderbilt.edu/ schectex/ In papers of 873 and 874,

### Chapter 3. Cartesian Products and Relations. 3.1 Cartesian Products

Chapter 3 Cartesian Products and Relations The material in this chapter is the first real encounter with abstraction. Relations are very general thing they are a special type of subset. After introducing

### Clicker Question. Theorems/Proofs and Computational Problems/Algorithms MC215: MATHEMATICAL REASONING AND DISCRETE STRUCTURES

MC215: MATHEMATICAL REASONING AND DISCRETE STRUCTURES Tuesday, 1/21/14 General course Information Sets Reading: [J] 1.1 Optional: [H] 1.1-1.7 Exercises: Do before next class; not to hand in [J] pp. 12-14:

### Sets and functions. {x R : x > 0}.

Sets and functions 1 Sets The language of sets and functions pervades mathematics, and most of the important operations in mathematics turn out to be functions or to be expressible in terms of functions.

Some Definitions about Sets Definition: Two sets are equal if they contain the same elements. I.e., sets A and B are equal if x[x A x B]. Notation: A = B. Recall: Sets are unordered and we do not distinguish

### Structural properties of oracle classes

Structural properties of oracle classes Stanislav Živný Computing Laboratory, University of Oxford, Wolfson Building, Parks Road, Oxford, OX1 3QD, UK Abstract Denote by C the class of oracles relative

### 4.6 The Primitive Recursive Functions

4.6. THE PRIMITIVE RECURSIVE FUNCTIONS 309 4.6 The Primitive Recursive Functions The class of primitive recursive functions is defined in terms of base functions and closure operations. Definition 4.6.1

### Topology and Convergence by: Daniel Glasscock, May 2012

Topology and Convergence by: Daniel Glasscock, May 2012 These notes grew out of a talk I gave at The Ohio State University. The primary reference is [1]. A possible error in the proof of Theorem 1 in [1]

### A set is a Many that allows itself to be thought of as a One. (Georg Cantor)

Chapter 4 Set Theory A set is a Many that allows itself to be thought of as a One. (Georg Cantor) In the previous chapters, we have often encountered sets, for example, prime numbers form a set, domains

### Finite Sets. Theorem 5.1. Two non-empty finite sets have the same cardinality if and only if they are equivalent.

MATH 337 Cardinality Dr. Neal, WKU We now shall prove that the rational numbers are a countable set while R is uncountable. This result shows that there are two different magnitudes of infinity. But we

### Finite Automata and Formal Languages

Finite Automata and Formal Languages TMV026/DIT321 LP4 2011 Lecture 14 May 19th 2011 Overview of today s lecture: Turing Machines Push-down Automata Overview of the Course Undecidable and Intractable Problems

### Chapter 1. Logic and Proof

Chapter 1. Logic and Proof 1.1 Remark: A little over 100 years ago, it was found that some mathematical proofs contained paradoxes, and these paradoxes could be used to prove statements that were known

### Logic & Discrete Math in Software Engineering (CAS 701) Dr. Borzoo Bonakdarpour

Logic & Discrete Math in Software Engineering (CAS 701) Background Dr. Borzoo Bonakdarpour Department of Computing and Software McMaster University Dr. Borzoo Bonakdarpour Logic & Discrete Math in SE (CAS

### Theory of Computation Chapter 2: Turing Machines

Theory of Computation Chapter 2: Turing Machines Guan-Shieng Huang Feb. 24, 2003 Feb. 19, 2006 0-0 Turing Machine δ K 0111000a 01bb 1 Definition of TMs A Turing Machine is a quadruple M = (K, Σ, δ, s),

### Introduction to Theory of Computation

Introduction to Theory of Computation Prof. (Dr.) K.R. Chowdhary Email: kr.chowdhary@iitj.ac.in Formerly at department of Computer Science and Engineering MBM Engineering College, Jodhpur Tuesday 28 th

### 6.080 / 6.089 Great Ideas in Theoretical Computer Science Spring 2008

MIT OpenCourseWare http://ocw.mit.edu 6.080 / 6.089 Great Ideas in Theoretical Computer Science Spring 008 For information about citing these materials or our Terms of Use, visit: http://ocw.mit.edu/terms.

### Introduction to computer science

Introduction to computer science Michael A. Nielsen University of Queensland Goals: 1. Introduce the notion of the computational complexity of a problem, and define the major computational complexity classes.

### GROUPS SUBGROUPS. Definition 1: An operation on a set G is a function : G G G.

Definition 1: GROUPS An operation on a set G is a function : G G G. Definition 2: A group is a set G which is equipped with an operation and a special element e G, called the identity, such that (i) the

### What computers can't do

1997 2009, Millennium Mathematics Project, University of Cambridge. Permission is granted to print and copy this page on paper for non commercial use. For other uses, including electronic redistribution,

### Applications of Methods of Proof

CHAPTER 4 Applications of Methods of Proof 1. Set Operations 1.1. Set Operations. The set-theoretic operations, intersection, union, and complementation, defined in Chapter 1.1 Introduction to Sets are

### Models of Sequential Computation

Models of Sequential Computation 13 C H A P T E R Programming is often considered as an art, but it raises mostly practical questions like which language should I choose, which algorithm is adequate, and

### CS_226 Computability Theory

Examples CS_226 Computability Theory http://www.cs.swan.ac.uk/ csetzer/lectures/computability/ 08/index.html Course Notes, Michaelmas Term 2008 Anton Setzer (Dept. of Computer Science, Swansea) http://www.cs.swan.ac.uk/

### Sets and Cardinality Notes for C. F. Miller

Sets and Cardinality Notes for 620-111 C. F. Miller Semester 1, 2000 Abstract These lecture notes were compiled in the Department of Mathematics and Statistics in the University of Melbourne for the use

### Notes. Sets. Notes. Introduction II. Notes. Definition. Definition. Slides by Christopher M. Bourke Instructor: Berthe Y. Choueiry.

Sets Slides by Christopher M. Bourke Instructor: Berthe Y. Choueiry Spring 2006 Computer Science & Engineering 235 Introduction to Discrete Mathematics Sections 1.6 1.7 of Rosen cse235@cse.unl.edu Introduction

### Set Theory Basic Concepts and Definitions

Set Theory Basic Concepts and Definitions The Importance of Set Theory One striking feature of humans is their inherent need and ability to group objects according to specific criteria. Our prehistoric

### Deterministic Finite Automata

1 Deterministic Finite Automata Definition: A deterministic finite automaton (DFA) consists of 1. a finite set of states (often denoted Q) 2. a finite set Σ of symbols (alphabet) 3. a transition function

### Theory of Computation Lecture Notes

Theory of Computation Lecture Notes Abhijat Vichare August 2005 Contents 1 Introduction 2 What is Computation? 3 The λ Calculus 3.1 Conversions: 3.2 The calculus in use 3.3 Few Important Theorems 3.4 Worked

### CARDINALITY, COUNTABLE AND UNCOUNTABLE SETS PART ONE

CARDINALITY, COUNTABLE AND UNCOUNTABLE SETS PART ONE With the notion of bijection at hand, it is easy to formalize the idea that two finite sets have the same number of elements: we just need to verify

### Classical Information and Bits

p. 1/24 Classical Information and Bits The simplest variable that can carry information is the bit, which can take only two values, 0 or 1. Any ensemble, description, or set of discrete values can be quantified

### Mathematical Logic. Giuseppe Peano ( ) Core Logic 2005/06-1ab p. 2/4

Mathematical Logic. From the XIXth century to the 1960s, logic was essentially mathematical. Development of first-order logic (1879-1928): Frege, Hilbert, Bernays, Ackermann. Development of the fundamental

### On the Structure of Turing Universe: The Non-Linear Ordering of Turing Degrees

On the Structure of Turing Universe: The Non-Linear Ordering of Turing Degrees Yazan Boshmaf November 22, 2010 Abstract Turing Universe: the final frontier. These are the voyages of five mathematicians.

### Turing Machines and Understanding Computational Complexity

Turing Machines and Understanding Computational Complexity Paul M.B.Vitányi CWI, Science Park 123, 1098XG Amsterdam The Netherlands 1. Introduction A Turing machine refers to a hypothetical machine proposed

### Alan Turing and the Unsolvable Problem To Halt or Not to Halt That Is the Question

Alan Turing and the Unsolvable Problem To Halt or Not to Halt That Is the Question Cristian S. Calude 26 April 2012 Alan Turing Alan Mathison Turing was born in a nursing home in Paddington, London, now

### This chapter is all about cardinality of sets. At first this looks like a

CHAPTER Cardinality of Sets This chapter is all about cardinality of sets At first this looks like a very simple concept To find the cardinality of a set, just count its elements If A = { a, b, c, d },

### This asserts two sets are equal iff they have the same elements, that is, a set is determined by its elements.

3. Axioms of Set theory Before presenting the axioms of set theory, we first make a few basic comments about the relevant first order logic. We will give a somewhat more detailed discussion later, but

### Basic Concepts of Set Theory, Functions and Relations

March 1, 2006 p. 1 Basic Concepts of Set Theory, Functions and Relations 1. Basic Concepts of Set Theory...1 1.1. Sets and elements...1 1.2. Specification of sets...2 1.3. Identity and cardinality...3

### Descriptive Set Theory

Martin Goldstern Institute of Discrete Mathematics and Geometry Vienna University of Technology Ljubljana, August 2011 Polish spaces Polish space = complete metric separable. Examples N = ω = {0, 1, 2,...}.

### Practice Problems for Final Exam: Solutions CS 341: Foundations of Computer Science II Prof. Marvin K. Nakayama

Practice Problems for Final Exam: Solutions CS 341: Foundations of Computer Science II Prof. Marvin K. Nakayama 1. Short answers: (a) Define the following terms and concepts: i. Union, intersection, set

### Proof: A logical argument establishing the truth of the theorem given the truth of the axioms and any previously proven theorems.

Math 232 - Discrete Math 2.1 Direct Proofs and Counterexamples Notes Axiom: Proposition that is assumed to be true. Proof: A logical argument establishing the truth of the theorem given the truth of the

### Introduction to Automata Theory. Reading: Chapter 1

Introduction to Automata Theory Reading: Chapter 1 1 What is Automata Theory? Study of abstract computing devices, or machines Automaton = an abstract computing device Note: A device need not even be a

### Georg Cantor and Set Theory

Georg Cantor and Set Theory. Life Father, Georg Waldemar Cantor, born in Denmark, successful merchant, and stock broker in St Petersburg. Mother, Maria Anna Böhm, was Russian. In 856, because of father

### It is not immediately obvious that this should even give an integer. Since 1 < 1 5

Math 163 - Introductory Seminar Lehigh University Spring 8 Notes on Fibonacci numbers, binomial coefficients and mathematical induction These are mostly notes from a previous class and thus include some

### Direct Proofs. CS 19: Discrete Mathematics. Direct Proof: Example. Indirect Proof: Example. Proofs by Contradiction and by Mathematical Induction

Direct Proofs CS 19: Discrete Mathematics Amit Chakrabarti Proofs by Contradiction and by Mathematical Induction At this point, we have seen a few examples of mathematical proofs. These have the following

### 8 Primes and Modular Arithmetic

8 Primes and Modular Arithmetic 8.1 Primes and Factors Over two millennia ago already, people all over the world were considering the properties of numbers. One of the simplest concepts is prime numbers.

### Fun With Nonstandard Models

Fun With Nonstandard Models A self-contained sequel to: 2500 Years of very Small Numbers David A. Ross Department of Mathematics University of Hawai i Outline of Talk: Slides 1..3 Random Blather Slides

### MATH10040 Chapter 2: Prime and relatively prime numbers

MATH10040 Chapter 2: Prime and relatively prime numbers Recall the basic definition: 1. Prime numbers Definition 1.1. Recall that a positive integer is said to be prime if it has precisely two positive

### NP-Completeness and Cook s Theorem

NP-Completeness and Cook s Theorem Lecture notes for COM3412 Logic and Computation 15th January 2002 1 NP decision problems The decision problem D L for a formal language L Σ is the computational task:

### Universality in the theory of algorithms and computer science

Universality in the theory of algorithms and computer science Alexander Shen Computational models The notion of computable function was introduced in 1930ies. Simplifying (a rather interesting and puzzling)

### 1. Prove that the empty set is a subset of every set.

1. Prove that the empty set is a subset of every set. Basic Topology Written by Men-Gen Tsai email: b89902089@ntu.edu.tw Proof: For any element x of the empty set, x is also an element of every set since

### Structure of Measurable Sets

Structure of Measurable Sets In these notes we discuss the structure of Lebesgue measurable subsets of R from several different points of view. Along the way, we will see several alternative characterizations

### Discrete Mathematics and Probability Theory Fall 2009 Satish Rao, David Tse Note 2

CS 70 Discrete Mathematics and Probability Theory Fall 2009 Satish Rao, David Tse Note 2 Proofs Intuitively, the concept of proof should already be familiar We all like to assert things, and few of us

### Consistency, completeness of undecidable preposition of Principia Mathematica. Tanmay Jaipurkar

Consistency, completeness of undecidable preposition of Principia Mathematica Tanmay Jaipurkar October 21, 2013 Abstract The fallowing paper discusses the inconsistency and undecidable preposition of Principia

### In mathematics you don t understand things. You just get used to them. (Attributed to John von Neumann)

Chapter 1 Sets and Functions We understand a set to be any collection M of certain distinct objects of our thought or intuition (called the elements of M) into a whole. (Georg Cantor, 1895) In mathematics

### Inf1A: Deterministic Finite State Machines

Lecture 2 InfA: Deterministic Finite State Machines 2. Introduction In this lecture we will focus a little more on deterministic Finite State Machines. Also, we will be mostly concerned with Finite State

### CANTOR S DIAGONAL ARGUMENT: PROOF AND PARADOX

CANTOR S DIAGONAL ARGUMENT: PROOF AND PARADOX Cantor s diagonal method is elegant, powerful, and simple. It has been the source of fundamental and fruitful theorems as well as devastating, and ultimately,