Prof. Busch - LSU1 Reductions. Prof. Busch - LSU2 Problem is reduced to problem If we can solve problem then we can solve problem.

Slides:



Advertisements
Similar presentations
Fall 2006Costas Busch - RPI1 Reductions. Fall 2006Costas Busch - RPI2 Problem is reduced to problem If we can solve problem then we can solve problem.
Advertisements

David Evans cs302: Theory of Computation University of Virginia Computer Science Lecture 17: ProvingUndecidability.
Lecture 3 Universal TM. Code of a DTM Consider a one-tape DTM M = (Q, Σ, Γ, δ, s). It can be encoded as follows: First, encode each state, each direction,
Lecture 16 Deterministic Turing Machine (DTM) Finite Control tape head.
Variants of Turing machines
CSCI 4325 / 6339 Theory of Computation Zhixiang Chen Department of Computer Science University of Texas-Pan American.
Reducibility Sipser 5.1 (pages ). CS 311 Fall Reducibility.
Reducibility Sipser 5.1 (pages ).
Fall 2004COMP 3351 Undecidable problems for Recursively enumerable languages continued…
Prof. Busch - LSU1 Decidable Languages. Prof. Busch - LSU2 Recall that: A language is Turing-Acceptable if there is a Turing machine that accepts Also.
Fall 2004COMP 3351 Recursively Enumerable and Recursive Languages.
Costas Busch - RPI1 Undecidable problems for Recursively enumerable languages continued…
Fall 2003Costas Busch - RPI1 Decidability. Fall 2003Costas Busch - RPI2 Recall: A language is decidable (recursive), if there is a Turing machine (decider)
Recursively Enumerable and Recursive Languages
1 The Chomsky Hierarchy. 2 Unrestricted Grammars: Rules have form String of variables and terminals String of variables and terminals.
1 Uncountable Sets continued Theorem: Let be an infinite countable set. The powerset of is uncountable.
Fall 2006Costas Busch - RPI1 The Post Correspondence Problem.
Fall 2004COMP 3351 The Chomsky Hierarchy. Fall 2004COMP 3352 Non-recursively enumerable Recursively-enumerable Recursive Context-sensitive Context-free.
Fall 2004COMP 3351 Reducibility. Fall 2004COMP 3352 Problem is reduced to problem If we can solve problem then we can solve problem.
Linear Bounded Automata LBAs
1 Decidability continued. 2 Undecidable Problems Halting Problem: Does machine halt on input ? State-entry Problem: Does machine enter state halt on input.
Automata & Formal Languages, Feodor F. Dragan, Kent State University 1 CHAPTER 5 Reducibility Contents Undecidable Problems from Language Theory.
Fall 2006Costas Busch - RPI1 Non-Deterministic Finite Automata.
Fall 2005Costas Busch - RPI1 Recursively Enumerable and Recursive Languages.
Courtesy Costas Busch - RPI1 Reducibility. Courtesy Costas Busch - RPI2 Problem is reduced to problem If we can solve problem then we can solve problem.
Costas Busch - LSU1 Non-Deterministic Finite Automata.
Fall 2006Costas Busch - RPI1 Undecidable Problems (unsolvable problems)
Prof. Busch - LSU1 Undecidable Problems (unsolvable problems)
Prof. Busch - LSU1 Turing Machines. Prof. Busch - LSU2 The Language Hierarchy Regular Languages Context-Free Languages ? ?
1 Reducibility. 2 Problem is reduced to problem If we can solve problem then we can solve problem.
Prof. Busch - LSU1 NFAs accept the Regular Languages.
A Universal Turing Machine
1 Turing’s Thesis. 2 Turing’s thesis: Any computation carried out by mechanical means can be performed by a Turing Machine (1930)
 2005 SDU Lecture13 Reducibility — A methodology for proving un- decidability.
Recursively Enumerable and Recursive Languages
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.
Donghyun (David) Kim Department of Mathematics and Computer Science North Carolina Central University 1 Chapter 4 Decidability Some slides are in courtesy.
NP-complete Languages
1 The Chomsky Hierarchy. 2 Unrestricted Grammars: Productions String of variables and terminals String of variables and terminals.
Costas Busch - LSU1 The Post Correspondence Problem.
Costas Busch - RPI1 Decidability. Costas Busch - RPI2 Consider problems with answer YES or NO Examples: Does Machine have three states ? Is string a binary.
Costas Busch - RPI1 Decidability. Costas Busch - RPI2 Another famous undecidable problem: The halting problem.
1 Recursively Enumerable and Recursive Languages.
Recursively Enumerable and Recursive Languages. Definition: A language is recursively enumerable if some Turing machine accepts it.
Decidability.
NP-Completeness A problem is NP-complete if: It is in NP
A Universal Turing Machine
Recursively Enumerable Languages
Recursively Enumerable and Recursive Languages
Busch Complexity Lectures: Turing Machines
Busch Complexity Lectures: Reductions
Linear Bounded Automata LBAs
Reductions.
Undecidable Problems Costas Busch - LSU.
Reductions Costas Busch - LSU.
Busch Complexity Lectures: Undecidable Problems (unsolvable problems)
Undecidable Problems (unsolvable problems)
Turing acceptable languages and Enumerators
Non-Deterministic Finite Automata
Non-Deterministic Finite Automata
Decidable Languages Costas Busch - LSU.
The Off-Line Machine Input File read-only (once) Input string
Turing acceptable languages and Enumerators
Undecidable problems:
Computability and Complexity
Proposed in Turing’s 1936 paper
Theory of Computability
Theory of Computability
Decidability continued….
More Undecidable Problems
Presentation transcript:

Prof. Busch - LSU1 Reductions

Prof. Busch - LSU2 Problem is reduced to problem If we can solve problem then we can solve problem

Prof. Busch - LSU3 Language is reduced to language There is a computable function (reduction) such that: Definition:

Prof. Busch - LSU4 Computable function : which for any string computes There is a deterministic Turing machine Recall:

Prof. Busch - LSU5 If: a: Language is reduced to b: Language is decidable Then: is decidable Theorem: Proof: Basic idea: Build the decider for using the decider for

Prof. Busch - LSU6 Decider for Decider for compute accept reject accept reject (halt) Input string END OF PROOF Reduction YES NO

Prof. Busch - LSU7 Example: is reduced to:

Prof. Busch - LSU8 Turing Machine for reduction DFA We only need to construct:

Prof. Busch - LSU9 Let be the language of DFA construct DFA by combining and so that: DFA Turing Machine for reduction

Prof. Busch - LSU10

Prof. Busch - LSU11 Decider Decider for compute Input string YES NO Reduction

Prof. Busch - LSU12 If: a: Language is reduced to b: Language is undecidable Then: is undecidable Theorem (version 1): (this is the negation of the previous theorem) Proof: Using the decider for build the decider for Suppose is decidable Contradiction!

Prof. Busch - LSU13 Decider for Decider for compute accept reject accept reject (halt) Input string Reduction END OF PROOF If is decidable then we can build: CONTRADICTION! YES NO

Prof. Busch - LSU14 Observation: In order to prove that some language is undecidable we only need to reduce a known undecidable language to

Prof. Busch - LSU15 State-entry problem Input: Turing Machine State Question:Does String enter state while processing input string ? Corresponding language:

Prof. Busch - LSU16 Theorem: (state-entry problem is unsolvable) Proof: Reduce (halting problem) to (state-entry problem) is undecidable

Prof. Busch - LSU17 Decider for YES NO state-entry problem decider DeciderCompute Reduction YES NO Given the reduction, if is decidable, then is decidable A contradiction! since is undecidable Halting Problem Decider

Prof. Busch - LSU18 Compute Reduction We only need to build the reduction: So that:

Prof. Busch - LSU19 halting states special halt state Construct from : A transition for every unused tape symbol of

Prof. Busch - LSU20 halts on statehalts halting states special halt state

Prof. Busch - LSU21 halts on state on input halts on inputTherefore: Equivalently: END OF PROOF

Prof. Busch - LSU22 Blank-tape halting problem Input:Turing Machine Question:Doeshalt when started with a blank tape? Corresponding language:

Prof. Busch - LSU23 Theorem: (blank-tape halting problem is unsolvable) Proof: Reduce (halting problem) to (blank-tape problem) is undecidable

Prof. Busch - LSU24 Decider for YES NO blank-tape problem decider DeciderCompute Reduction YES NO Given the reduction, If is decidable, then is decidable A contradiction! since is undecidable Halting Problem Decider

Prof. Busch - LSU25 Compute Reduction We only need to build the reduction: So that:

Prof. Busch - LSU26 no yes Write on tape Tape is blank? Run with input Construct from : If halts then halt Accept and halt

Prof. Busch - LSU27 halts when started on blank tape halts on input no yes Write on tape Tape is blank? Run with input Accept and halt

Prof. Busch - LSU28 END OF PROOF halts when started on blank tape halts on input Equivalently:

Prof. Busch - LSU29 If: a: Language is reduced to b: Language is undecidable Then: is undecidable Theorem (version 2): Proof: Using the decider for build the decider for Suppose is decidable Contradiction! Then is decidable

Prof. Busch - LSU30 Suppose is decidable Decider for accept reject (halt)

Prof. Busch - LSU31 Suppose is decidable Decider for accept reject (halt) Then is decidable (we have proven this in previous class) reject accept (halt) Decider for NO YES NO

Prof. Busch - LSU32 Decider for Decider for compute accept reject accept reject (halt) Input string Reduction If is decidable then we can build: CONTRADICTION! YES NO

Prof. Busch - LSU33 Decider for Decider for compute accept reject accept reject (halt) Input string Reduction END OF PROOF CONTRADICTION! Alternatively: NO YES NO

Prof. Busch - LSU34 Observation: In order to prove that some language is undecidable we only need to reduce some known undecidable language to or to (theorem version 1) (theorem version 2)

Prof. Busch - LSU35 Undecidable Problems for Turing Recognizable languages is empty? is regular? has size 2? Let be a Turing-acceptable language All these are undecidable problems

Prof. Busch - LSU36 is empty? is regular? has size 2? Let be a Turing-acceptable language

Prof. Busch - LSU37 Empty language problem Input: Turing Machine Question:Isempty? Corresponding language:

Prof. Busch - LSU38 Theorem: (empty-language problem is unsolvable) is undecidable Proof: Reduce (membership problem) to (empty language problem)

Prof. Busch - LSU39 Decider for YES NO empty problem decider DeciderCompute Reduction YES NO Given the reduction, if is decidable, then is decidable membership problem decider A contradiction! since is undecidable

Prof. Busch - LSU40 Compute Reduction We only need to build the reduction: So that:

Prof. Busch - LSU41 Write on tape, and Simulate on input Tape of input string accepts ? Construct from : yes Turing Machine Accept yes

Prof. Busch - LSU42 The only possible accepted string Louisiana Prof. Busch - LSU42Prof. Busch - LSU42 Write on tape, and Simulate on input accepts ? yes Turing Machine Accept yes

Prof. Busch - LSU43 accepts does not accept Prof. Busch - LSU43Prof. Busch - LSU43Prof. Busch - LSU43 Write on tape, and Simulate on input accepts ? yes Turing Machine Accept yes

Prof. Busch - LSU44 Therefore: accepts Equivalently: END OF PROOF

Prof. Busch - LSU45 is empty? is regular? has size 2? Let be a Turing-acceptable language

Prof. Busch - LSU46 Regular language problem Input: Turing Machine Question:Isa regular language? Corresponding language:

Prof. Busch - LSU47 Theorem: (regular language problem is unsolvable) is undecidable Proof: Reduce (membership problem) to (regular language problem)

Prof. Busch - LSU48 Decider for YES NO regular problem decider DeciderCompute Reduction YES NO Given the reduction, If is decidable, then is decidable membership problem decider A contradiction! since is undecidable

Prof. Busch - LSU49 Compute Reduction We only need to build the reduction: So that:

Prof. Busch - LSU50 Tape of input string Construct from : Prof. Busch - LSU50Prof. Busch - LSU50Prof. Busch - LSU50Prof. Busch - LSU50 Write on tape, and Simulate on input Accept accepts ? yes Turing Machine

Prof. Busch - LSU51 accepts does not accept not regular regular Prof. Busch - LSU51Prof. Busch - LSU51Prof. Busch - LSU51Prof. Busch - LSU51Prof. Busch - LSU51 Write on tape, and Simulate on input Accept accepts ? yes Turing Machine

Prof. Busch - LSU52 Therefore: accepts Equivalently: END OF PROOF is not regular

Prof. Busch - LSU53 is empty? is regular? has size 2? Let be a Turing-acceptable language

Prof. Busch - LSU54 Does have size 2 (two strings)? Size2 language problem Input: Turing Machine Question: Corresponding language:

Prof. Busch - LSU55 Theorem: (size2 language problem is unsolvable) is undecidable Proof: Reduce (membership problem) to (size 2 language problem)

Prof. Busch - LSU56 Decider for YES NO size2 problem decider DeciderCompute Reduction YES NO Given the reduction, If is decidable, then is decidable membership problem decider A contradiction! since is undecidable

Prof. Busch - LSU57 Compute Reduction We only need to build the reduction: So that:

Prof. Busch - LSU58 Tape of input string Construct from : Prof. Busch - LSU58Prof. Busch - LSU58Prof. Busch - LSU58Prof. Busch - LSU58Prof. Busch - LSU58 Write on tape, and Simulate on input Accept accepts ? yes Turing Machine

Prof. Busch - LSU59 accepts does not accept 2 strings 0 strings Prof. Busch - LSU59Prof. Busch - LSU59Prof. Busch - LSU59Prof. Busch - LSU59Prof. Busch - LSU59Prof. Busch - LSU59 Write on tape, and Simulate on input Accept accepts ? yes Turing Machine

Prof. Busch - LSU60 Therefore: accepts Equivalently: END OF PROOF has size 2

Prof. Busch - LSU61 RICE’s Theorem is empty? is regular? has size 2? Undecidable problems: This can be generalized to all non-trivial properties of Turing-acceptable languages

Prof. Busch - LSU62 Non-trivial property: A property possessed by some Turing-acceptable languages but not all : is empty? Example: YES NO

Prof. Busch - LSU63 : is regular? More examples of non-trivial properties: YES NO YES : has size 2? NO YES NO

Prof. Busch - LSU64 Trivial property: A property possessed by ALL Turing-acceptable languages : has size at least 0?Examples: True for all languages : is accepted by some Turing machine? True for all Turing-acceptable languages

Prof. Busch - LSU65 We can describe a property as the set of languages that possess the property : is empty? Example: YES NO If language has property then

Prof. Busch - LSU66 : has size 1? NO YES Example:Suppose alphabet is NO

Prof. Busch - LSU67 Non-trivial property problem Does have the non-trivial property ? Input: Turing Machine Question: Corresponding language:

Prof. Busch - LSU68 Rice’s Theorem: is undecidable (the non-trivial property problem is unsolvable) Proof: Reduce (membership problem) to or

Prof. Busch - LSU69 We examine two cases: Case 1: Case 2: Examples: : is empty? : is regular? : has size 2? Example:

Prof. Busch - LSU70 Let be the Turing machine that accepts Case 1: Since is non-trivial, there is a Turing-acceptable language such that:

Prof. Busch - LSU71 Reduce (membership problem) to

Prof. Busch - LSU72 Decider for YES NO Non-trivial property problem decider DeciderCompute Reduction YES NO Given the reduction, if is decidable, then is decidable membership problem decider A contradiction! since is undecidable

Prof. Busch - LSU73 Compute Reduction We only need to build the reduction: So that:

Prof. Busch - LSU74 Tape of input string Construct from : Write on tape, and Simulate on input Accept accepts ? yes Turing Machine

Prof. Busch - LSU75 For this we can run machine, that accepts language, with input string Write on tape, and Simulate on input Accept accepts ? yes Turing Machine

Prof. Busch - LSU76 accepts does not accept Prof. Busch - LSU76 Write on tape, and Simulate on input Accept accepts ? yes Turing Machine

Prof. Busch - LSU77 Therefore: accepts Equivalently:

Prof. Busch - LSU78 Let be the Turing machine that accepts Case 2: Since is non-trivial, there is a Turing-acceptable language such that:

Prof. Busch - LSU79 Reduce (membership problem) to

Prof. Busch - LSU80 Decider for YES NO Non-trivial property problem decider DeciderCompute Reduction YES NO Given the reduction, if is decidable, then is decidable membership problem decider A contradiction! since is undecidable

Prof. Busch - LSU81 Compute Reduction We only need to build the reduction: So that:

Prof. Busch - LSU82 Tape of input string Construct from : Write on tape, and Simulate on input Accept accepts ? yes Turing Machine

Prof. Busch - LSU83 accepts does not accept Write on tape, and Simulate on input Accept accepts ? yes Turing Machine

Prof. Busch - LSU84 Therefore: accepts Equivalently: END OF PROOF