Download presentation
Presentation is loading. Please wait.
Published byJessie Berry Modified over 9 years ago
1
C SC 573 Theory of Computation Theory of Computation Lecture 05 Reduction
2
C SC 573 Theory of Computation 2 Reducibility Language is (many-one) reducible to language iff there is some total computable function (algorithm) f such that: Notation Full name: “many-one reducible” ( other kinds e.g. ) If an algorithm for deciding then one for since f has an algorithm: x
3
C SC 573 Theory of Computation 3 Reducibility (cont.) Lemma 3.2: Let. Then decidable decidable [decidability inherited down] undecidable undecidable [undecidability inherited up] c.e. c.e. [acceptability inherited down] If you want to show a problem P is easier than problem Q then reduce P to Q If you want to show a problem P is harder than problem Q then reduce Q to P easinesshardness ? Q P: ?P Q:
4
C SC 573 Theory of Computation 4 Unsolvability via Reductions: HALTING HALTING PROBLEM UNIVERSAL LANGUAGE In the Homer & Selman text, these two problems are treated as identical. They are actually different, but equivalent in the sense that Theorem 3.6: is undecidable. Proof: Since the mapping is total computable, then From which we conclude is undecidable. Corollary: is c.e. but undecidable.
5
C SC 573 Theory of Computation 5 Unsolvability via Reductions (cont.) Theorem 3.6: The HALTING problem is c.e. but not decidable. Proof: It is c.e. because the UTM U given e and w will halt just in case halts on w. To show undecidable, we show that by constructing a decider for assuming one for Consider a “compiler” c that takes a TM and converts it to a TM such that if halts and accepts, then so does but if halts and rejects, then will diverge. (This can be done simply by arranging that transitions to are replaced by transitions to a loop.) Then Since c is totally computable,
6
C SC 573 Theory of Computation 6 Unsolvability via Reductions (cont.) Visual proof that the universal language is reducible to the HALTING problem: Proof: Consider a “compiler” c that given e constructs index c(e) for a TM as follows: Reduction yes no yes loop
7
C SC 573 Theory of Computation 7 Unsolvability via Reductions: Examples Theorem: The EMPTY-TAPE-ACCEPTANCE problem is c.e. but not decidable: Proof: An acceptor is easy to construct: submit (e,0) to the UTM. We will show that. Consider a “compiler” c that given ( e,w) constructs TM c(e,w) as follows: Reduction no yes no yes no
8
C SC 573 Theory of Computation 8 Unsolvability via Reductions [alternate] Theorem: The EMPTY-TAPE-ACCEPTANCE problem is c.e. but not decidable: Proof: An acceptor is easy to construct: submit ( e,0) to the UTM. We will show that. Consider a “compiler” c that given ( e,w) constructs TM c(e,w): Reduction yes no yes no { M (w) }
9
C SC 573 Theory of Computation 9 Reductions Properties of reduction relation Reduction: major method for showing unsolvability or non- enumerability: Goal: to show is not c.e. Known:is not c.e. Strategy: reduce to Method: build total computable “translator” f to accept f yes w
10
C SC 573 Theory of Computation 10 Non-CE via Reductions Theorem: The EMPTY-SET-ACCEPTANCE problem is not c.e.: Proof: Show Consider a “compiler” c that given e,w constructs TM encoding Reduction: c is total recursive (an algorithm) yes x
11
C SC 573 Theory of Computation 11 Undecidable via Reductions Theorem: The NONEMPTY-SET-ACCEPTANCE problem is c.e. but not decidable: Proof: It is easy to see that since So it cannot be decidable. An acceptor for is the following nondeterministic ‡ TM yes _____________________________________ †what if w is not a syntactically valid TM encoding? Which set is it in? ‡ a good illustration of the power of nondeterminism to describe processes
12
C SC 573 Theory of Computation 12 Non-RE via Reductions Exercise: The FINITE-SET-ACCEPTANCE problem is not c.e.: Proof: Show that Exercise: The INFINITE-SET-ACCEPTANCE problem is not c.e.: Proof: Show that _____________________________________ †what if e is not a syntactically valid TM encoding? Which set is it in?
13
C SC 573 Theory of Computation 13 Equivalence and Completeness Definition: Let C be a class of sets. A set A is many-one complete ( -complete ) in C iff Remark: “ A is complete” says A is a “hardest problem in C ” A is many-one equivalent to B iff Fact: all complete sets in C are many-one equivalent Exercise:
14
C SC 573 Theory of Computation 14 Completeness Theorem: is complete in CE. Proof: is accepted by U, so is in CE. To show completeness, let B be any c.e. set and suppose for TM that. Define the total recursive function Then Exercise: Show the Halting Problem is complete in CE
15
C SC 573 Theory of Computation 15 Arithmetic Hierarchy DEC=CE co-CE For every class C, a class co-C C } Ladder of complexity CE co-CE DEC=Decidable Sets
16
C SC 573 Theory of Computation 16 Arithmetic Hierarchy Fact: CE Corollary: CE co-CE CE co-CE Proof: Know that CE. If co-CE, then CE, which is a contradiction. A similar argument holds for
Similar presentations
© 2024 SlidePlayer.com. Inc.
All rights reserved.