Computability and Complexity 5-1 Classifying Problems Computability and Complexity Andrei Bulatov.

Slides:



Advertisements
Similar presentations
Formal Models of Computation Part III Computability & Complexity
Advertisements

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,
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.
Turing -Recognizable vs. -Decidable
CSCI 4325 / 6339 Theory of Computation Zhixiang Chen Department of Computer Science University of Texas-Pan American.
1 COMP 382: Reasoning about algorithms Unit 9: Undecidability [Slides adapted from Amos Israeli’s]
1 CSC3130 Formal Languages and Automata Theory Tutorial 9 Undecidable Problem KN Hung SHB 1026.
Complexity 7-1 Complexity Andrei Bulatov Complexity of Problems.
Complexity 11-1 Complexity Andrei Bulatov Space Complexity.
Computability and Complexity 13-1 Computability and Complexity Andrei Bulatov The Class NP.
1 Introduction to Computability Theory Lecture12: Decidable Languages Prof. Amos Israeli.
1 Introduction to Computability Theory Lecture15: Reductions Prof. Amos Israeli.
1 Introduction to Computability Theory Lecture12: Reductions Prof. Amos Israeli.
Reducibility Sipser 5.1 (pages ). CS 311 Fall Reducibility.
The Halting Problem Sipser 4.2 (pages ). CS 311 Mount Holyoke College 2 Taking stock All languages Turing-recognizable Turing-decidable Context-free.
The Halting Problem Sipser 4.2 (pages ).
1 Introduction to Computability Theory Lecture13: Mapping Reductions Prof. Amos Israeli.
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.
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)
Complexity 5-1 Complexity Andrei Bulatov Complexity of Problems.
1 Undecidability Andreas Klappenecker [based on slides by Prof. Welch]
Computability and Complexity 7-1 Computability and Complexity Andrei Bulatov Recursion Theorem.
1 The Chomsky Hierarchy. 2 Unrestricted Grammars: Rules have form String of variables and terminals String of variables and terminals.
Fall 2004COMP 3351 The Chomsky Hierarchy. Fall 2004COMP 3352 Non-recursively enumerable Recursively-enumerable Recursive Context-sensitive Context-free.
CHAPTER 4 Decidability Contents Decidable Languages
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.
Courtesy Costas Busch - RPI1 Reducibility. Courtesy Costas Busch - RPI2 Problem is reduced to problem If we can solve problem then we can solve problem.
Theory of Computing Lecture 20 MAS 714 Hartmut Klauck.
CS21 Decidability and Tractability
Fall 2006Costas Busch - RPI1 Undecidable Problems (unsolvable problems)
Prof. Busch - LSU1 Undecidable Problems (unsolvable problems)
Prof. Busch - LSU1 Reductions. Prof. Busch - LSU2 Problem is reduced to problem If we can solve problem then we can solve problem.
1 Reducibility. 2 Problem is reduced to problem If we can solve problem then we can solve problem.
ATM, Halting Problem, P vs. NP Chapter 4, 5 & 7. Russel’s Paradox An Index is a book that lists other books in.
CS 3813: Introduction to Formal Languages and Automata Chapter 12 Limits of Algorithmic Computation These class notes are based on material from our textbook,
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.
1Computer Sciences Department. Book: INTRODUCTION TO THE THEORY OF COMPUTATION, SECOND EDITION, by: MICHAEL SIPSER Reference 3Computer Sciences Department.
CS Master – Introduction to the Theory of Computation Jan Maluszynski - HT Lecture 7 Undecidability cont. Jan Maluszynski, IDA, 2007
Turing -Recognizable vs. -Decidable
C SC 573 Theory of Computation Theory of Computation Lecture 05 Reduction.
CSCI 2670 Introduction to Theory of Computing October 13, 2005.
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.
Overview of the theory of computation Episode 3 0 Turing machines The traditional concepts of computability, decidability and recursive enumerability.
Donghyun (David) Kim Department of Mathematics and Computer Science North Carolina Central University 1 Chapter 4 Decidability Some slides are in courtesy.
Decidability Decidable/Undecidable problems. Jaruloj Chongstitvatana Decidability2 Accepting: Definition Let T = (Q, , , , s) be a TM. T accepts.
1 The Chomsky Hierarchy. 2 Unrestricted Grammars: Productions String of variables and terminals String of variables and terminals.
Donghyun (David) Kim Department of Mathematics and Computer Science North Carolina Central University 1 Chapter 5 Reducibility Some slides are in courtesy.
Undecidability and The Halting 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.
Recursively Enumerable and Recursive Languages. Definition: A language is recursively enumerable if some Turing machine accepts it.
Decidability.
Chapters 11 and 12 Decision Problems and Undecidability.
Recursively Enumerable and Recursive Languages
Busch Complexity Lectures: Reductions
Linear Bounded Automata LBAs
Undecidable Problems Costas Busch - LSU.
Reductions Costas Busch - LSU.
Automata, Grammars and Languages
Busch Complexity Lectures: Undecidable Problems (unsolvable problems)
Decidable Languages Costas Busch - LSU.
Computability and Complexity
Decidability continued….
Theory of Computability
More Undecidable Problems
Presentation transcript:

Computability and Complexity 5-1 Classifying Problems Computability and Complexity Andrei Bulatov

Computability and Complexity 5-2 Problems and Languages We have seen that every decision problem  has an associated language L ( , e ) (via a suitable encoding e ) Hence, to classify decision problems we will develop methods to classify languages

Computability and Complexity 5-3 Decidable Languages Definition A language L is decidableª if there exists a TM T, with 2 final states and, such that If x  L then T(x) halts in state If x  L then T(x) halts in state ªalso known as recursive T is said to decide the language L — it gives a yes or no answer for each possible string from  *

Computability and Complexity 5-4 Examples The following languages are decidable:  *  {x| |x| = 20} {x | x is prime } {x | x encodes a graph G, and a Hamilton circuit of G} {x | x is a valid encoding of a TM}

Computability and Complexity 5-5 Examples All languages accepted by finite automata, or generated by context-free grammars are decidable All Languages Decidable Languages Context-free Languages Regular Languages (for finite automata see Discrete Mathematics course or Sipser) (for context-free grammars see Compilers course or Sipser)

Computability and Complexity 5-6 Acceptable Languages Definition A language L is acceptableª if there exists a TM T, with 2 final states and, such that If x  L then T(x) halts in state If x  L then T(x) halts in state or infinite ªalso known as Turing-acceptable or Turing-recognizable T is said to accept the language L — it gives a yes answer for each string in L, in all other cases it gives a no answer or fails to halt

Computability and Complexity 5-7 Acceptable vs. Decidable If a language is decidable, then it is acceptable. If a language, L, is acceptable, and its complement is also acceptable, the it is decidable. (Proof: run the two acceptor machines alternately until one halts) So, to show that there are languages that are not decidable, we must find a language that is not acceptable …

Computability and Complexity 5-8 The Halting Problem Instance: A Turing Machine T and an input string x. Question: Does T(x) halt? Halting Once we choose an encoding for Turing machines, the corresponding language is: is acceptable - use a universal TM U to simulate T on x and modify it so that that if it halts then it moves to “Accept” state is not decidable - see next slide

Computability and Complexity 5-9 Assume, for contradiction, that there is a TM that decides Construct a new T from so that for input x, T simulates but - if accepts “ x ; x ” then T goes into an infinite loop, - if rejects “ x ; x ” then T accepts x.

Computability and Complexity 5-10 INPUT A? R? T

I NPUTINPUT ; Computability and Complexity 5-11 INPUT A? R? T A?R?

Computability and Complexity 5-12 Consider the computation T(T) - if T(T) halts this implies that rejects “ T;T ”, implying that T(T) does not halt! - if T(T) does not halt this implies that accepts “ T;T ”, implying that T(T) halts! Hence cannot exist, so is undecidable.

Computability and Complexity 5-13 Consequences There is no Turing machine that can give correct answers to the Halting problem on all inputs. The language is not acceptable. Hence, by Turing’s Thesis: The Halting problem cannot be solved by any algorithm! This result was first announced in Turing’s 1936 paper

Computability and Complexity 5-14 Reducibility A major tool in analysing and classifying problems is the idea of “reducing one problem to another” Informally, a problem  is reducible to a problem  if we can somehow use methods that solve  in order to solve 

Computability and Complexity 5-15 Many-One Reducibility Definition A language A is many-one reducible (or m-reducible, or mapping reducible) to a language B if there exists a total and computable function f such that for all We can use a machine that decides B (plus a machine that reduces A ) So, in a sense, A is “no harder than” B We denote this by writing

Computability and Complexity 5-16 Properties of Many-One Reducibility If and is decidable, then so is (Just build a machine that computes f(x) and then behaves like the machine that decides ) is reflexive and transitive If is any language (apart from  and  *) and is decidable, then The first property can be used when trying to prove that a language is decidable (or undecidable). The last property implies that many-one reducibility is too weak to distinguish between decidable languages — they are pretty much All reducible to each other!

Computability and Complexity 5-17 Other Undecidable Problems Instance: A Turing Machine (acceptor) T and an input string x. Question: Does T accept x ? ACCEPTANCE The corresponding language is: Theorem is undecidable. Proof see next slide

Computability and Complexity 5-18 We show that For every input “ T;x ” of, we do: Add to T two new states and (to guarantee that they are not in T already we may need to rename the states of T ) Change the transition function by adding transition from every final state to Denote the obtained machine T’ Note that T’ accepts x if and only if T halts on x Therefore, the function which maps “ T;x ” to “ T’;x ” is computable and provides a mapping reduction from to

Computability and Complexity 5-19 Instance: A Turing Machine T. Question: Can T be simulated by a finite automaton? Regularity Instance: A context-free grammar G. Question: Is G ambiguous? Ambiguous Grammars

Computability and Complexity 5-20 Instance: A multivariate polynomial equation such as Question: Does this equation have an integer-valued solution? Diophantine Equations See “Hilbert’s Tenth Problem is Unsolvable” M.Davis, American Mathematical Monthly 80 (1973) pp