Lecture 12: Mapping Reductions

Similar documents
CS5371 Theory of Computation. Lecture 15: Computability VI (Post s Problem, Reducibility)

CSE 105 THEORY OF COMPUTATION

Reducability. Sipser, pages

Computation Histories

Computability and Complexity

6.045: Automata, Computability, and Complexity Or, Great Ideas in Theoretical Computer Science Spring, Class 8 Nancy Lynch

Undecidable Problems and Reducibility

Non-emptiness Testing for TMs

Mapping Reducibility. Human-aware Robotics. 2017/11/16 Chapter 5.3 in Sipser Ø Announcement:

1 Reducability. CSCC63 Worksheet Reducability. For your reference, A T M is defined to be the language { M, w M accepts w}. Theorem 5.

CS5371 Theory of Computation. Lecture 14: Computability V (Prove by Reduction)

Lecture Notes: The Halting Problem; Reductions

problem X reduces to Problem Y solving X would be easy, if we knew how to solve Y

CSCE 551 Final Exam, Spring 2004 Answer Key

6.045J/18.400J: Automata, Computability and Complexity. Quiz 2. March 30, Please write your name in the upper corner of each page.

CSE 105 THEORY OF COMPUTATION

CSE 105 THEORY OF COMPUTATION

CS154, Lecture 10: Rice s Theorem, Oracle Machines

Chapter 3: The Church-Turing Thesis

CS5371 Theory of Computation. Lecture 10: Computability Theory I (Turing Machine)

CpSc 421 Homework 9 Solution

Further discussion of Turing machines

1 Showing Recognizability

CSE 105 THEORY OF COMPUTATION

CS5371 Theory of Computation. Lecture 10: Computability Theory I (Turing Machine)

Theory of Computation

Equivalence of TMs and Multitape TMs. Theorem 3.13 and Corollary 3.15 By: Joseph Lauman

CSCE 551: Chin-Tser Huang. University of South Carolina

CS 301. Lecture 18 Decidable languages. Stephen Checkoway. April 2, 2018

CS5371 Theory of Computation. Lecture 12: Computability III (Decidable Languages relating to DFA, NFA, and CFG)

1 Unrestricted Computation

Undecidability. We are not so much concerned if you are slow as when you come to a halt. (Chinese Proverb)

The Turing Machine. Computability. The Church-Turing Thesis (1936) Theory Hall of Fame. Theory Hall of Fame. Undecidability

CS3719 Theory of Computation and Algorithms

Turing Machines, diagonalization, the halting problem, reducibility

Harvard CS 121 and CSCI E-121 Lecture 14: Turing Machines and the Church Turing Thesis

CS21 Decidability and Tractability

Turing Machines A Turing Machine is a 7-tuple, (Q, Σ, Γ, δ, q0, qaccept, qreject), where Q, Σ, Γ are all finite

CS6901: review of Theory of Computation and Algorithms

Decidability. Linz 6 th, Chapter 12: Limits of Algorithmic Computation, page 309ff

V Honors Theory of Computation

FORMAL LANGUAGES, AUTOMATA AND COMPUTATION

Griffith University 3130CIT Theory of Computation (Based on slides by Harald Søndergaard of The University of Melbourne) Turing Machines 9-0

Turing Machines. Lecture 8

A non-turing-recognizable language

Lecture 23: Rice Theorem and Turing machine behavior properties 21 April 2009

Computability Theory

Introduction to Turing Machines

Advanced Undecidability Proofs

Computability Theory. CS215, Lecture 6,

} Some languages are Turing-decidable A Turing Machine will halt on all inputs (either accepting or rejecting). No infinite loops.

CSE355 SUMMER 2018 LECTURES TURING MACHINES AND (UN)DECIDABILITY

6.045: Automata, Computability, and Complexity Or, Great Ideas in Theoretical Computer Science Spring, Class 10 Nancy Lynch

Exam Computability and Complexity

The Power of One-State Turing Machines

ECS 120 Lesson 20 The Post Correspondence Problem

CSCC63 Worksheet Turing Machines

More Turing Machines. CS154 Chris Pollett Mar 15, 2006.

CSE 105 Theory of Computation

Decidability and Undecidability

Decidable Languages - relationship with other classes.

CS 525 Proof of Theorems 3.13 and 3.15

What languages are Turing-decidable? What languages are not Turing-decidable? Is there a language that isn t even Turingrecognizable?

Decidability: Reduction Proofs

Homework Assignment 6 Answers

Decidable and undecidable languages

Outline 1 PCP. 2 Decision problems about CFGs. M.Mitra (ISI) Post s Correspondence Problem 1 / 10

4.2 The Halting Problem

Mapping Reductions. Mapping Reductions. Introduction to Computability. Theory. Mapping Reductions. Lecture13: Mapping. Reductions

Turing s thesis: (1930) Any computation carried out by mechanical means can be performed by a Turing Machine

ACS2: Decidability Decidability

Post s Correspondence Problem (PCP) Is Undecidable. Presented By Bharath Bhushan Reddy Goulla

CSE 105 THEORY OF COMPUTATION

Computability and Complexity

Midterm Exam 2 CS 341: Foundations of Computer Science II Fall 2018, face-to-face day section Prof. Marvin K. Nakayama

Computability Theory

FORMAL LANGUAGES, AUTOMATA AND COMPUTABILITY

Theory of Computation

Theory of Computation

CSE 105 Theory of Computation

Lecture 24: Randomized Complexity, Course Summary

A Note on Turing Machine Design

Decision Problems with TM s. Lecture 31: Halting Problem. Universe of discourse. Semi-decidable. Look at following sets: CSCI 81 Spring, 2012

CSCI3390-Assignment 2 Solutions

Computational Models Lecture 8 1

CS 361 Meeting 26 11/10/17

Week 3: Reductions and Completeness

Reductions in Computability Theory

CS 125 Section #10 (Un)decidability and Probability November 1, 2016

Lecture 14: Recursive Languages

Chap. 4,5 Review. Algorithms created in proofs from prior chapters

Intro to Theory of Computation

CpSc 421 Final Exam December 15, 2006

Computational Models Lecture 8 1

Computational Models Lecture 8 1

Intro to Theory of Computation

CS151 Complexity Theory. Lecture 1 April 3, 2017

Decidability (What, stuff is unsolvable?)

UNRESTRICTED GRAMMARS

CS154, Lecture 17: conp, Oracles again, Space Complexity

Transcription:

Lecture 12: Mapping Reductions October 18, 2016 CS 1010 Theory of Computation Topics Covered 1. The Language EQ T M 2. Mapping Reducibility 3. The Post Correspondence Problem 1 The Language EQ T M The language EQ T M = { M 1, M 2 M 1 and M 2 are TMs such that L(M 1 ) = L(M 2 )} is undecidable, which we can prove by a reduction from A T M. Proof that EQ T M is Undecidable Suppose that EQ T M were decidable and let D be its decider. Consider the following decider D for A T M : D, on input M, w: 1. Find descriptions of TMs M 1 and M 2 such that L(M 1 ) = L(M 2 ) if and only if M accepts w. 2. Run D on input M 1, M 2. Accept if D rejects. Reject if D rejects. How do we accomplish step 1? Let M 1 be the TM that always accepts its input x. Let M 2 be a machine with the description, On input x, run M on w. If M accepts, accept. Else, reject. To show that D is a decider for A T M, first suppose M, w is in A T M. Then M 1, M 2 is in EQ T M, so D accepts and D accepts. If M, w is not in A T M, then L(M 1 ) = Σ and L(M 2 ) =. It follows that M 1, M 2 is not in EQ T M, so D rejects and D rejects. Because we know that D cannot exist, EQ T M must be undecidable. Lecture 12: Mapping Reductions Page 1 / 5

2 Mapping Reducibility Consider step 1 in the construction of D above: we find a pair M 1, M 2 such that M 1, M 2 EQ T M if and only if M, w A T M. If we let the function f represent this step, we say that f is a mapping reduction. We can illustrate f with the following mapping: In general, let f Σ Σ be a function. Let A and B be languages. f is computable if there exists a TM M such that for all x Σ, M halts on input x such that once it halts, the content of its tape is f(x). A m B if there exists a computable function f such that x A if and only if f(x) B. We say that A is mapping-reducible to B. For example, let f be step 1 of D, as illustrated above. Then A T M m EQ T M. Theorem Suppose A m B and B is decidable. Then A is decidable. Proof Let D be a decider for B. Then consider D, a decider for A: D, on input w: 1. Computer f(w) = y. 2. Run D on input y. Accept if D accepts. Otherwise, reject. D decides A. If w A, then y = f(w) B, so D accepts y and D accepts. If w A, then y = f(w) B, so D rejects y and D rejects. Thus, D is a decider for A. Lecture 12: Mapping Reductions Page 2 / 5

Corollary If A m B and A is undecidable, then B is undecidable. This follows from the previous theorem; if B were decidable, A would be decidable a contradiction. Proof that EQ T M is Undecidable Now consider proving that EQ T M is undecidable via mapping-reducibility. To show that A T M m EQ T M, we construct a TM for f. On input M, w, the TM computes M 1, M 2 as before. In particular, M 2 always accepts and M 2 has description, On input x, run M on w. If M accepts, accept. Else, reject. In our analysis of f, we first need to show that f is correct. If M, w A T M, then M 1, M 2 EQ T M, and if M, w A T M, then M 1, M 2 EQ T M. The reasoning is the same as in the previous proof. Next, we argue that f is computable. All that f does is construct M 1 and M 2. We have described an algorithm to do this (i.e. there is a Turing machine that can compute it), so f is computable. Therefore A T M m EQ T M, and A T M is undecidable. By the corollary, EQ T M is undecidable. Theorem Suppose A m B and B is Turing-recognizable. Then A is Turing-recognizable. Proof Let R be a recognizer for B. Then consider R, which recognizes A: R, on input w: 1. Compute f(w) = y. 2. Run R on input y. Accept if it accepts. Otherwise, reject. R recognizes A because if w A, then f(w) B, so R accepts and R accepts. If w A, then f(w) B, so R does not accept (it will reject or loop), so R does not accept. Corollary If A m B and A is not Turing-recognizable, then B is not Turing-recognizable. Like the previous corollary, this is proved by contradiction. If B were Turing-recognizable, then A would be as well, a contradiction. Theorem If A m B, then A C m B C. Proof As seen in the earlier illustration of a mapping-reduction, the same function f works for the complements of languages. Let f be the mapping-reduction from A to B. Then w A if and only if f(w) B. Thus w A C if and only if f(w) B C. Using the same f, we have A C m B C. Lecture 12: Mapping Reductions Page 3 / 5

We ve seen that A T M m EQ T M. This theorem implies that A C T M m EQ C T M. We can also show that A T M m EQ C T M, which implies that AC T M m EQ T M. Since A C T M is not Turing-recognizable, it follows that EQ T M and EQ C T M are also not Turing-recognizable. Proof that A T M m EQ C T M We want a function f such that f( M, w ) = M 1, M 2 such that L(M 1 ) L(M 2 ) if and only if M accepts w. Let M 1 have description, On input x, reject. Let M 2 have description, On input x, if x w, reject. Else, run M on w and do as M does. First, consider the correctness of f. If M, w A T M, then L(M 1 ) L(M 2 ) because M 1 rejects w but M 2 accepts w. That is, L(M 1 ) = and L(M 2 ) = {w}, so M 1, M 2 EQ T M. Alternatively, if M, w A T M, then L(M 1 ) = and L(M 2 ) =. Then M 1, M 2 EQ T M. The function f is also computable. We can describe an algorithm for constructing M 1 and M 2 (although we don t go into the details). As a result of this proof, we conclude that EQ T M and EQ C T M are not Turing-recognizable. 3 The Post Correspondence Problem In the Post correspondence problem, we consider a set of dominoes over an alphabet Σ. Acceptance in the language of the Post correspondence problem (PCP) corresponds to the existence of a sequence of dominoes such that the top and bottom strings are equal. For a concrete example, let Σ = {a, n}, and suppose we have the following dominoes: d 1 = [ a nn ], d aa 2 = [ annaa ], d 3 = [ ann a ] Then consider the ordering of dominoes d 3, d 1, d 3, d 2 : [ ann a ][ a nn ][ann a ][ aa annaa ] Note that the top and bottom strings are both annaannaa. Then d 3, d 1, d 3, d 2 is called a match and proves that the collection of dominoes d 1, d 2, d 3 is in PCP. Formally, let PCP = { d 1,..., d k each d i is a domino over Σ and there exists a match i 1,..., i n such that d i1,..., d in has matching top and bottom strings}. Rather than prove that PCP is undecidable, we consider a slightly modified language MPCP = { d 1,..., d k there exists a match starting with d 1 }. Proof that MPCP is Undecidable Our proof is a reduction from A T M. Given M, w, we want to choose d 1,..., d k such that M accepts w if and only if there exists a match Lecture 12: Mapping Reductions Page 4 / 5

using d 1,..., d k that starts with d 1. Note that M accepts w if and only if M s computation history on w is accepting. To map an instance M, w to a set of dominoes, we will build a collection of dominoes such that the only possible matching string is an accepting computation history of M on w. There are several steps in this transformation (which are also described in Sipser section 5.2). 1. First, add the domino d 1, which contains the starting configuration of M s computation history on w: # d 1 = [ #q 0 w 1 w 2... w n # ] 2. Next, suppose M has a transition from state q to state r, where the head overwrites a with b and moves right. For each of these transitions, we add a corresponding domino: [ qa br ] 3. For every transition from state q to r where the head overwrites a with b and moves left, and for every c Γ, add the domino: [ cqa rcb ] 4. For every a Γ, add the domino: [ a a ] 5. Add the following two dominoes to denote separations between configurations, possibly with infinitely many blanks to the right side of the tape: [ # # ], [ # # ] 6. Add two dominoes to ensure that if M accepts, then we include the rest of the tape in the string. We can think of the tape head as eating the extra symbols to the left and right of q accept : [ aq accept ], [ q accepta ] q accept q accept 7. Finally, we add a domino to complete the matching strings: [ q accept## ] # The idea behind this construction is that if M accepts w, then the dominoes have a match corresponding the the accepting computation history of M on w. Alternatively, if there exists a match, then there is an accepting computation history. Lecture 12: Mapping Reductions Page 5 / 5