q FORMAL LANGUAGES, AUTOMATA AND COMPUTABILITY. FLAC (15-453) Spring L. Blum. REVIEW for Midterm 2 TURING MACHINE
|
|
- Byron Mills
- 5 years ago
- Views:
Transcription
1 FLAC (15-45) Spring L. Blum THURSDAY APRIL REVIEW or Midterm 2 FORMAL LANGUAGES, AUTOMATA AND COMPUTABILITY TUESDAY April 8 Deinition: A Turing Machine is a 7-tuple T = (Q, Σ, Γ,, q, q accept, q reject ), where: Q is a inite set o states Σ is the input alphabet, where Σ Γ is the tape alphabet, where Γ and Σ Γ : Q Γ Q Γ {L,R} q Q is the start state q accept Q is the accept state q reject Q is the reject state, and q reject q accept TURING MACHINE FINITE STATE q CONTROL I N P U T INFINITE TAPE CONFIGURATIONS 111q 7 11 q COMPUTATION HISTORIES An accepting computation history is a sequence o conigurations C 1,C 2,,C k, where 1. C 1 is the start coniguration, C 1 =q w 2. C k is an accepting coniguration, C k =uq accept v. Each C i ollows rom C i-1 via the transition unction A rejecting computation history is a sequence o conigurations C 1,C 2,,C k, where 1. C 1 is the start coniguration, 2. C k is a rejecting coniguration, C k =uq reject v. Each C i ollows rom C i-1 1
2 FLAC (15-45) Spring L. Blum We can encode a TM as a string o s and 1s M accepts w i and only i there is an accepting computation history that starts with C 1 =q w n states n 1 m 1 k 1 s 1 t 1 r 1 u 1 m tape symbols (irst k are input symbols) start state accept state reject state blank symbol ( (p,a), (q,b,l) ) = p 1 a 1 q 1 b 1 NB. We assume a given convention o describing TMs by strings in Σ*. We may assume that any string in Σ* describes some TM: Either the string describes a TM by the convention, or i the string is gibberish at some point then the machine just halts i/when a computation gets to that point. A language is called Turing-recognizable or semi-decidable or recursively enumerable (r.e.) i some TM recognizes it A language is called decidable or recursive i some TM decides it Languages over {,1} semi-decidable (r.e.) decidable (recursive) is undecidable: (proo by contradiction) Assume machine H decides H( (M,w) ) = Accept Reject i M accepts w i M does not accept w Construct a new TM D as ollows: on input M, run H on (M,M) and output the opposite o H is undecidable: (proo by contradiction) Assume machine H decides H( (M,w) ) = Accept Reject i M accepts w i M does not accept w Construct a new TM D as ollows: on input M, run H on (M,M) and output the opposite o H D( M ) = Reject Accept i M accepts M i.e. i H(M,M) accepts i M does not accept M i.e. i H(M,M) rejects D( M D ) = Reject Accept i MD accepts DM i MD does not accept DM 2
3 FLAC (15-45) Spring L. Blum is undecidable: (constructive proo & subtle) Assume machine H SEMI-DECIDES H( (M,w) ) = Accept i M accepts w Rejects or Loops otherwise Construct a new TM as ollows: on input M, run H on (M,M) and output the opposite o H whenever possible. ( M ) = Reject i M accepts M (i.e. i H( M, M ) = Accept) Accept i M rejects M (i.e. i H( M, M ) = Reject) Loops i M loops on M (i.e. i H( M, M ) loops) Note: There is no contradiction here! loops on We can eectively construct an instance which does not belong to (namely, (, ) ) but H ails to tell us that. THE RECURSION THEOREM Theorem: Let T be a Turing machine that computes a unction t : Σ* Σ* Σ*. There is a Turing machine R that computes a unction r : Σ* Σ*, where or every w Given T: THEN R: (a,b) w r(w) = t(r, w) T R t(a,b) t(r,w) Recursion Theorem: A Turing machine can obtain its own description, and compute with it We can use the operation: Obtain your own description in pseudocode! Given a computable t, we can get a computable r such that r(w) = t(<r>,w) where <R> is a description o r INSIGHT: T (or t) is really R (or r) A NOTE ON SELF REFERENCE Suppose in general we want to design a program that prints its own description. How? Print this sentence. Print two copies o the ollowing (the stu inside quotes), and put the second copy in quotes: Print two copies o the ollowing (the stu inside quotes), and put the second copy in quotes: = B = P <B> THAT PRINTS <itself> Theorem: There is a computable unction q : Σ* Σ*, where or any string w, q(w) is the description o a TM P w that on any input, prints out w and then accepts w Q <P w > TM Q computes q s P w w
4 FLAC (15-45) Spring L. Blum THAT PRINTS <itself> Theorem: is undecidable Proo (using the recursion theorem): Inormally <M> B w P <M> M Assume to the contrary, D decides Construct machine R such that On input w: 1. Obtains, via the recursion theorem, its own description R w P <B> <B> B w P <B> B 2. Runs D on (R,w) and lips the output Running R on input w does the opposite o what D says it should! Theorem: is undecidable Proo (using the recursion theorem) Formally 1. Assume to the contrary that D decides 2. Let T(M, w) = opposite o D(M, w). Obtain by the Recursion Theorem, machine R so that R(w) = T(R, w) Then, R(w) accepts T(R, w) accepts D(R, w) rejects by by 2 R(w) does not accept by 1 MIN TM = {<M> M is a minimal TM, wrt <M> } Theorem: MIN TM is not RE. Proo (using the Recursion Theorem): Inormally Assume E enumerates MIN TM Construct machine R such that on input w: 1. Obtains its own description <R> 2. Runs E until a machine D appears with a longer description than o R. Simulate D on w Contradiction. Why? MIN TM = {<M> M is a minimal TM, wrt <M> } Theorem: MIN TM is not RE. Proo (using the Recursion Theorem): Formally Assume E enumerates MIN TM Let T E (x, w) = D(w) where <D> is irst in E s enumeration s.t. <D> > x By the Recursion Theorem, there is a TM R such that: R(w) = T E (<R>, w) = D(w) where <D> is irst in E s enumeration s.t. <D> > <R> Contradiction. Why? Let : Σ* Σ* be a computable unction such that w A (w) B Σ* A B Σ* A m B Say: A is Mapping Reducible to B Write: A m B (also, A m B (why?) ) 4
5 FLAC (15-45) Spring L. Blum Let : Σ* Σ* be a computable unction such that w A (w) B Σ* A B Σ* HALT TM = { (M,w) M is a TM that halts on string w } Σ* Σ* A m B A m HALT TM TM HALT TM So, i B is (semi) decidable, then so is A (And i B is (semi) decidable, then so is A) : (M,w) (M, w) where M (s) = M(s) i M(s) accepts, Loops otherwise So, (M, w) (M, w) HALT TM s Σ* E TM = { M M is a TM and L(M) = } REG TM = { M M is a TM and L(M) is regular} Σ* Σ* Σ* Σ* m REG TM m E TM E TM REG TM : (M,w) M w where M w (s) = M(w) i s = w, Loops otherwise So, (M, w) M w E TM s Σ* s Σ* : (M,w) M w where M w (s) = accept i s = n 1 n, M(w) otherwise So, (M, w) M w REG TM E TM = { M M is a TM and L(M) = } EQ TM = {( M, N) M, N are TMs and L(M) =L(N)} ALL PDA = { P P is a PDA and L(P) = Σ* } Σ* Σ* Σ* Σ* E TM E TM m EQ TM EQ TM A m ALL PDA TM ALL PDA s Σ* : M (M, M ) where M (s) = Loops So, M E TM (M, M ) EQ TM : (M,w) PDA P w where s Σ* P w (s) = accept i s is NOT an accepting computation o M(w) So, (M, w ) P w ALL PDA 5
6 FLAC (15-45) Spring L. Blum FPCP = { P P is a set o dominos with a match starting with the irst domino } Σ* Σ* PCP = { P P is a set o dominos with a match } Σ* Σ* m FPCP FPCP m PCP PCP Construct : (M,w) P (M,w) such that Construct : (M,w) P (M,w) such that (M, w ) P (M,w) FPCP (M, w ) P (M,w) PCP HALT TM = { (M,w) M is a TM that halts on string w } E TM = { M M is a TM and L(M) = } REG TM = { M M is a TM and L(M) is regular} EQ TM = {(M, N) M, N are TMs and L(M) =L(N)} ALL PDA = { P P is a PDA and L(P) = Σ* } PCP = { P P is a set o dominos with a match } ALL UNDECIDABLE Use Reductions to Prove HALT TM = { (M,w) M is a TM that halts on string w } E TM = { M M is a TM and L(M) = } E TM REG TM = { M M is a TM and L(M) is regular} EQ TM = {(M, N) M, N are TMs and L(M) =L(N)} EQ TM ALL PDA = { P P is a PDA and L(P) = Σ* } ALL PDA PCP = { P P is a set o dominos with a match } ALL UNDECIDABLE Use Reductions to Prove Which are SEMI-DECIDABLE? Then L is undecidable RICE S THEOREM Let L be a language over Turing machines. Assume that L satisies the ollowing properties: 1. For any TMs M 1 and M 2, where L(M 1 ) = L(M 2 ), M 1 L i and only i M 2 L 2. There are TMs M 1 and M 2, where M 1 L and M 2 L EXTREMELY POWERFUL! Then L is undecidable RICE S THEOREM Let L be a language over Turing machines. Assume that L satisies the ollowing properties: 1. For any TMs M 1 and M 2, where L(M 1 ) = L(M 2 ), M 1 L i and only i M 2 L 2. There are TMs M 1 and M 2, where M 1 L and M 2 L FIN TM = { M M is a TM and L(M) is E TM = { M M is inite} a TM and L(M) = } REG TM = { M M is a TM and L(M) is regular} 6
7 FLAC (15-45) Spring L. Blum Proo: Show L is undecidable Show: is mapping reducible to L Proo: Show L is undecidable Show: is mapping reducible to L Σ* L Σ* Σ* L Σ* (M,w) (M,w) M 1 (M,w) (M,w) M 2 Proo: RICE S THEOREM Deine M to be a TM that never halts Assume, WLOG, that M L Why? Let M 1 L (such M 1 exists, by assumption) Show is mapping reducible to L : Map (M, w) M w where M w (s) = accepts i both M(w) and M 1 (s) accept loops otherwise What is the language o M w? is mapping reducible to L Σ* L Σ* (M,w) (M,w) M w M 1 M w M QED Corollary: The ollowing are undecidable. E TM = { M M is a TM and L(M) = } REG TM = {M M is TM and L(M) is regular} FINITE STATE q YES? CONTROL ORACLE TMs Is (M,w) in? YES FIN TM = {M M is a TM and L(M) is inite} DEC TM = {M M is a TM and L(M) is decidable} I N P U T INFINITE TAPE 7
8 FLAC (15-45) Spring L. Blum A Turing Reduces to B We say A is decidable in B i there is an oracle TM M with oracle B that decides A A T B T VERSUS m Theorem: I A m B then A T B But in general, the converse doesn t hold! Proo: I A m B then there is a computable unction : Σ* Σ*, where or every w, w A (w) B We can thus use an oracle or B to decide A T is transitive Theorem: HALT TM T HALT TM Theorem: HALT TM m HALT TM WHY? THE ARITHMETIC HIERARCHY = { decidable sets } (sets = ) = { semi-decidable sets } n+1 = { sets semi-decidable in some B } n n+1 n = { sets decidable in some B } n = { complements o sets in n } Deinition: A decidable predicate R(x,y) is some proposition about x and y 1, where there is a TM M such that or all x, y, R(x,y) is TRUE M(x,y) accepts R(x,y) is FALSE M(x,y) rejects We say M decides the predicate R. Semidecidable Languages = Decidable Languages Co-semidecidable Languages EXAMPLES: R(x,y) = x + y is less than 1 R(<N>,y) = N halts on y in at most 1 steps Kleene s T predicate, T(<M>, x, y): M accepts x in y steps. 1. x, y are positive integers or elements o * 8
9 FLAC (15-45) Spring L. Blum Theorem: A language A is semi-decidable i and only i there is a decidable predicate R(x, y) such that:a = { x y R(x,y) } Proo: (1) I A = { x y R(x,y) } then A is semi-decidable Because we can enumerate over all y s (2) I A is semi-decidable, then A = { x y R(x,y) } Let M semi-decide A and Let R <M> (x,y) be the Kleene T- predicate: T(<M>, x, y): TM M accepts x in y steps (y interpreted as an integer) R <M> is a decidable predicate (why?) So x A i and only i y R <M> (x,y) is true. Theorem = { semi-decidable sets } = o the orm { x y R(x,y) } = { complements o semi-decidable sets } = o the orm { x y R(x,y) } = { decidable sets } 1 = Where R is a decidable predicate Theorem = { sets semi-decidable in some semi-dec. B } = o the orm { x y 1 y 2 R(x,y 1,y 2 ) } = { complements o sets} = o the orm { x y 1 y 2 R(x,y 1,y 2 ) } = Theorem n = { x y1 y 2 y Qy n R(x,y 1,,y n ) } n = { x y 1 y 2 y Qy n R(x,y 1,,y n ) } n = n n Where R is a decidable predicate Where R is a decidable predicate Example = o the orm { x y R(x,y) } We know that is in Decidable predicate Why? Show it can be described in this orm: = { <(M,w)> t [M accepts w in t steps] } decidable predicate = { <(M,w)> t T (<M>, w, t )} = { <(M,w)> v (v is an accepting computation history o M on w} Semidecidable = Decidable Co-semidecidable 9
10 FLAC (15-45) Spring L. Blum Example Example = o the orm { x y R(x,y) } Show that EMPTY (ie, E TM ) = { M L(M) = } is in EMPTY = { M wt [M doesn t accept w in t steps] } = o the orm { x y R(x,y) } Show that EMPTY (ie, E TM ) = { M L(M) = } is in EMPTY = { M wt [ T(<M>, w, t) ] } two quantiiers?? decidable predicate two quantiiers?? decidable predicate THE PAIRING FUNCTION Theorem. There is a 1-1 and onto computable unction <, >: Σ* x Σ* Σ* and computable unctions and : Σ* Σ* such that z = <w, t> (z) = w and (z) = t EMPTY EMPTY = { M wt [M doesn t accept w in t steps] = } 2 EMPTY = { M z[m doesn t accept (z) in (z) steps]} 1 Semidecidable EMPTY = { M z[ T(<M>, (z), (z) ) ] } Co-semidecidable Decidable Example = o the orm { x yz R(x,y,z) } Show that TOTAL = { M M halts on all inputs } is in TOTAL = { M w t [M halts on w in t steps] } Example = o the orm { x yz R(x,y,z) } Show that TOTAL = { M M halts on all inputs } is in TOTAL = { M w t [ T(<M>, w, t) ] } decidable predicate decidable predicate 1
11 FLAC (15-45) Spring L. Blum TOTAL Example = o the orm { x yz R(x,y,z) } 2 Show that FIN = { M L(M) is inite } is in Semidecidable = EMPTY Decidable Co-semidecidable FIN = { M nwt [Either w < n, or M doesn t accept w in t steps] } FIN = { M nwt ( w < n T(<M>,w, t) )} decidable predicate COF FIN TOTAL FIN TOTAL Semidecidable = EMPTY Co-semidecidable Semidecidable = EMPTY Co-semidecidable Decidable Decidable REG DEC FIN TOTAL FIN TOTAL Semidecidable = EMPTY Co-semidecidable Semidecidable = EMPTY Co-semidecidable Decidable Decidable 11
12 FLAC (15-45) Spring L. Blum CFL FIN TOTAL Each is m-complete or its level in hierachy and cannot go lower (by next Theorem, which shows the hierarchy does not collapse). Semidecidable = EMPTY Co-semidecidable Decidable ORACLES not all powerul The ollowing problem cannot be decided, even by a TM with an oracle or the Halting Problem: SUPERHALT = { (M,x) M, with an oracle or the Halting Problem, halts on x} Can use diagonalization here! Suppose H decides SUPERHALT (with oracle) Deine D(X) = i H(X,X) accepts (with oracle) then LOOP, else ACCEPT. D(D) halts H(D,D) accepts D(D) loops ORACLES not all powerul Theorem: The arithmetic hierarchy is strict. That is, the nth level contains a language that isn t in any o the levels below n. Proo IDEA: Same idea as the previous slide. SUPERHALT = HALT = { (M,x) M halts on x}. SUPERHALT 1 = { (M,x) M, with an oracle or the Halting Problem, halts on x} SUPERHALT n = { (M,x) M, with an oracle or SUPERHALT n-1, halts on x} Theorem: 1. The hierarchy is strict 2. Each o the is m-complete or its class. Proo Idea. 1. Let,1 =, n+1 = {(M,x) M is an oracle machine with oracle and M accepts x} Then, n n - n Theorem: 1. The hierarchy is strict 2. Each o the is m-complete or its class. Proo. 2. Eg to show FIN is m-complete or Need to show FIN = { M n x t ( x <n or a) FIN M does not accept x in t 2 steps)} b) For A then A m FIN 12
13 FLAC (15-45) Spring L. Blum For A, A={ x yz R(x,y,z)} FIN = { M L(M) is inite } Σ* Σ* For A, A={ x yz R(x,y,z)} FIN = { M L(M) is inite } Σ* Σ* A FIN A FIN : x M x Given input w: For each y o length w or less, look or z such that R(x,y,z)}. I ound or all such y, Accept. Otherwise keep on running. I x A, then yz R(x,y,z)}, so when w > y, M x keeps on running, so M x FIN. I x A, then yz R(x,y,z)}, so M x recognizes Σ* CAN WE QUANTIFY HOW MUCH INFORMATION IS IN A STRING? A = B = Idea: The more we can compress a string, the less inormation it contains. KOLMOGOROV COMPLEXITY Deinition: Let x in {,1}*. The shortest description o x, denoted as d(x), is the lexicographically shortest string <M,w> s.t. M(w) halts with x on tape. Use pairing unction to code <M,w> Deinition: The Kolmogorov complexity o x, denoted as K(x), is d(x). KOLMOGOROV COMPLEXITY Theorem: There is a ixed c so that or all x in {,1}*, K(x) x + c The amount o inormation in x isn t much more than x Proo: Deine M = On w, halt. On any string x, M(x) halts with x on its tape! This implies K(x) <M,x> M + x + 1 c + x (Note: M is ixed or all x. So M is constant) REPETITIVE STRINGS Theorem: There is a ixed c so that or all x in {,1}*, K(xx) K(x) + c The inormation in xx isn t much more than that in x Proo: Let N = On <M,w>, let s=m(w). Print ss. Let <M,w > be the shortest description o x. Then <N,<M,w >> is a description o xx Thereore K(xx) <N,<M,w >> N + K(x) + 1 c + K(x) 1
14 FLAC (15-45) Spring L. Blum REPETITIVE STRINGS Corollary: There is a ixed c so that or all n, and all x {,1}*, K(x n ) K(x) + c log 2 n The inormation in x n isn t much more than that in x Proo: An intuitive way to see this: Deine M: On <x, n>, print x or n times. Now take <M,<x,n>> as a description o x n. In binary, n takes O(log n) bits to write down, so we have K(x) + O(log n) as an upper bound on K(x n ). REPETITIVE STRINGS Corollary: There is a ixed c so that or all n, and all x {,1}*, K(x n ) K(x) + c log 2 n The inormation in x n isn t much more than that in x Recall: A = For w = (1) n, K(w) K(1) + c log 2 n CONCATENATION o STRINGS Theorem: There is a ixed c so that or all x, y in {,1}*, K(xy) K(x) + K(y) + c Better: K(xy) logk(x) +K(x) + K(y) + c INCOMPRESSIBLE STRINGS Theorem: For all n, there is an x {,1} n such that K(x) n There are incompressible strings o every length Proo: (Number o binary strings o length n) = 2 n (Number o descriptions o length < n) (Number o binary strings o length < n) = 2 n 1. Thereore: there s at least one n-bit string that doesn t have a description o length < n INCOMPRESSIBLE STRINGS Theorem: For all n and c, Pr x {,1}^n [ K(x) n-c ] 1/2 c Most strings are airly incompressible Proo: (Number o binary strings o length n) = 2 n (Number o descriptions o length < n-c) (Number o binary strings o length < n-c) = 2 n-c 1. So the probability that a random x has K(x) < n-c is at most (2 n-c 1)/2 n < 1/2 c. DETERMINING COMPRESSIBILITY Can an algorithm help us compress strings? Can an algorithm tell us when a string is compressible? COMPRESS = {(x,c) K(x) c} Theorem: COMPRESS is undecidable! Berry Paradox: The irst string whose shortest description cannot be written in less than iteen words. 14
15 FLAC (15-45) Spring L. Blum DETERMINING COMPRESSIBILITY COMPRESS = {(x,n) K(x) n} Theorem: COMPRESS is undecidable! Proo: M = On input x {,1}*, Interpret x as integer n. ( x log n) Find irst y {,1}* in lexicographical order, s.t. (y,n) COMPRESS, then print y and halt. M(x) prints the irst string y* with K(y*) > n. Thus <M,x> describes y*, and <M,x> c + log n So n < K(y*) c + log n. CONTRADICTION! DETERMINING COMPRESSIBILITY Theorem: K is not computable Proo: M = On input x {,1}*, Interpret x as integer n. ( x log n) Find irst y {,1}* in lexicographical order, s. t. K(y) >n, then print y and halt. M(x) prints the irst string y* with K(y*) > n. Thus <M,x> describes y*, and <M,x> c + log n So n < K(y*) c + log n. CONTRADICTION! DETERMINING COMPRESSIBILITY What about other measures o compressibility? For example: the smallest DFA that recognizes {x} the shortest grammar in Chomsky normal orm that generates the language {x} SO WHAT CAN YOU DO WITH THIS? Many results in mathematics can be proved very simply using incompressibility. Theorem: There are ininitely many primes. IDEA: Finitely many primes can compress everything! Proo: Suppose not. Let p 1,, p k be the primes. Let x be incompressible. Think o n = x as integer. Then there are e i s.t. n = p 1 e1 p k ek For all i, e i log n, so e i log log n Can describe n (and x) with k log log n + c bits! But x was incompressible CONTRADICTION! Deinition: Let M be a TM that halts on all inputs. The running time or time complexity o M is a unction : N N, where (n) is the maximum number o steps that M uses on any input o length n. Deinition: TIME(t(n)) = { L L is a language decided by a O(t(n)) time Turing Machine } P = TIME(n k ) k N Deinition: A Non-Deterministic TM is a 7-tuple T = (Q, Σ, Γ,, q, q accept, q reject ), where: Q is a inite set o states Σ is the input alphabet, where Σ Γ is the tape alphabet, where Γ and Σ Γ : Q Γ 2 (Q Γ {L,R}) q Q is the start state q accept Q is the accept state q reject Q is the reject state, and q reject q accept 15
16 FLAC (15-45) Spring L. Blum Theorem: L NP i there exists a poly-time Turing machine V with L = { x y [ y = poly( x ) and V(x,y) accepts ] } Deinition: NTIME(t(n)) = { L L is decided by a O(t(n))-time non-deterministic Turing machine } TIME(t(n)) NTIME(t(n)) NP = NTIME(n k ) k N Proo: (1) I L = { x y y = poly( x ) and V(x,y) accepts } then L NP Non-deterministically guess y and then run V(x,y) (2) I L NP then L = { x y y = poly( x ) and V(x,y) accepts } Let N be a non-deterministic poly-time TM that decides L, deine V(x,y) to accept i y is an accepting computation history o N on x A language is in NP i and only i there exist polynomial-length proos or membership to the language P = the problems that can be eiciently solved NP = the problems where proposed solutions can be eiciently veriied P = NP? Can Problem Solving Be Automated? $$$ A Clay Institute Millennium Problem POLY-TIME REDUCIBILITY : Σ* Σ* is a polynomial time computable unction i some poly-time Turing machine M, on every input w, halts with just (w) on its tape Language A is polynomial time reducible to language B, written A P B, i there is a polytime computable unction : Σ* Σ* such that: w A (w) B is called a polynomial time reduction o A to B Theorem: I A P B and B P, then A P SAT = { (y)[ y is a satisying assignment to and is a boolean ormula ] } SAT = { (y)[y is a satisying assignment to and is in cn ] } Theorem (Cook-Levin): SAT and -SAT are NP-complete 1. SAT NP: A satisying assignment is a proo that a ormula is satisiable! 2. SAT is NP-hard: Every language in NP can be polytime reduced to SAT (complex ormula) Corollary: SAT P i and only i P = NP 16
17 FLAC (15-45) Spring L. Blum Assume a reasonable encoding o graphs (example: the adjacency matrix is reasonable) (x 1 x 1 x 2 ) (x 1 x 2 x 2 ) (x 1 x 2 x 2 ) x 1 x 2 x 2 CLIQUE = { (G,k) G is an undirected graph with a k-clique } Theorem: CLIQUE is NP-Complete (1) CLIQUE NP (2) SAT P CLIQUE c l a u s e x 1 x 1 x 1 x 2 x 2 x 2 #nodes = (# clauses) k = #clauses (x 1 x 1 x 2 ) (x 1 x 2 x 2 ) (x 1 x 2 x 2 ) Variables and negations o variables VERTEX-COVER = { (G,k) G is an undirected graph with a k-node vertex cover } x 1 x 1 x 2 x 2 Theorem: VERTEX-COVER is NP-Complete (1) VERTEX-COVER NP (2) SAT P VERTEX-COVER x 1 clauses x 1 x 1 x 1 x 2 x 2 x 2 x 2 x 2 k = 2(#clauses) + (#variables) HAMPATH = { (G,s,t) G is an directed graph with a Hamilton path rom s to t} Theorem: HAMPATH is NP-Complete (1) HAMPATH NP (2) SAT P HAMPATH Proo is in Sipser, Chapter
18 FLAC (15-45) Spring L. Blum UHAMPATH = { (G,s,t) G is an undirected graph with a Hamilton path rom s to t} Theorem: UHAMPATH is NP-Complete (1) UHAMPATH NP (2) HAMPATH P UHAMPATH SUBSETSUM = { (S, t) S is multiset o integers and or some Y S, we have y Y y = t } Theorem: SUBSETSUM is NP-Complete (1) SUBSETSUM NP (2) SAT P SUBSETSUM HW Let G denote a graph, and s and t denote nodes. SHORTEST PATH = {(G, s, t, k) G has a simple path o length < k rom s to t } LONGEST PATH = {(G, s, t, k) G has a simple path o length > k rom s to t } Good Luck on Midterm 2! WHICH IS EASY? WHICH IS HARD? Justiy (see Sipser 7.21) 18
FORMAL LANGUAGES, AUTOMATA AND COMPUTABILITY
15-453 FORMAL LANGUAGES, AUTOMATA AND COMPUTABILITY THURSDAY APRIL 3 REVIEW for Midterm TUESDAY April 8 Definition: A Turing Machine is a 7-tuple T = (Q, Σ, Γ, δ, q, q accept, q reject ), where: Q is a
More informationFORMAL LANGUAGES, AUTOMATA AND COMPUTABILITY
15-453 FORMAL LANGUAGES, AUTOMATA AND COMPUTABILITY KOLMOGOROV-CHAITIN (descriptive) COMPLEXITY TUESDAY, MAR 18 CAN WE QUANTIFY HOW MUCH INFORMATION IS IN A STRING? A = 01010101010101010101010101010101
More informationFORMAL LANGUAGES, AUTOMATA AND COMPUTABILITY. FLAC (15-453) Spring l. Blum TIME COMPLEXITY AND POLYNOMIAL TIME;
15-453 TIME COMPLEXITY AND POLYNOMIAL TIME; FORMAL LANGUAGES, AUTOMATA AND COMPUTABILITY NON DETERMINISTIC TURING MACHINES AND NP THURSDAY Mar 20 COMPLEXITY THEORY Studies what can and can t be computed
More informationFinish K-Complexity, Start Time Complexity
6.045 Finish K-Complexity, Start Time Complexity 1 Kolmogorov Complexity Definition: The shortest description of x, denoted as d(x), is the lexicographically shortest string such that M(w) halts
More informationCS154, Lecture 10: Rice s Theorem, Oracle Machines
CS154, Lecture 10: Rice s Theorem, Oracle Machines Moral: Analyzing Programs is Really, Really Hard But can we more easily tell when some program analysis problem is undecidable? Problem 1 Undecidable
More informationLecture 13: Foundations of Math and Kolmogorov Complexity
6.045 Lecture 13: Foundations of Math and Kolmogorov Complexity 1 Self-Reference and the Recursion Theorem 2 Lemma: There is a computable function q : Σ* Σ* such that for every string w, q(w) is the description
More informationCS154, Lecture 13: P vs NP
CS154, Lecture 13: P vs NP The EXTENDED Church-Turing Thesis Everyone s Intuitive Notion of Efficient Algorithms Polynomial-Time Turing Machines More generally: TM can simulate every reasonable model of
More informationLecture 16: Time Complexity and P vs NP
6.045 Lecture 16: Time Complexity and P vs NP 1 Time-Bounded Complexity Classes Definition: TIME(t(n)) = { L there is a Turing machine M with time complexity O(t(n)) so that L = L(M) } = { L L is a language
More informationCS154, Lecture 13: P vs NP
CS154, Lecture 13: P vs NP The EXTENDED Church-Turing Thesis Everyone s Intuitive Notion of Efficient Algorithms Polynomial-Time Turing Machines More generally: TM can simulate every reasonable model of
More informationCS154, Lecture 12: Kolmogorov Complexity: A Universal Theory of Data Compression
CS154, Lecture 12: Kolmogorov Complexity: A Universal Theory of Data Compression Rosencrantz & Guildenstern Are Dead (Tom Stoppard) Rigged Lottery? And the winning numbers are: 1, 2, 3, 4, 5, 6 But is
More informationCS 361 Meeting 28 11/14/18
CS 361 Meeting 28 11/14/18 Announcements 1. Homework 9 due Friday Computation Histories 1. Some very interesting proos o undecidability rely on the technique o constructing a language that describes the
More informationIntroduction to Languages and Computation
Introduction to Languages and Computation George Voutsadakis 1 1 Mathematics and Computer Science Lake Superior State University LSSU Math 400 George Voutsadakis (LSSU) Languages and Computation July 2014
More informationMidterm II : Formal Languages, Automata, and Computability
Midterm II 15-453: Formal Languages, Automata, and Computability Lenore Blum, Asa Frank, Aashish Jindia, and Andrew Smith April 8, 2014 Instructions: 1. Once the exam begins, write your name on each sheet.
More informationTURING MAHINES
15-453 TURING MAHINES TURING MACHINE FINITE STATE q 10 CONTROL AI N P U T INFINITE TAPE read write move 0 0, R, R q accept, R q reject 0 0, R 0 0, R, L read write move 0 0, R, R q accept, R 0 0, R 0 0,
More informationFinal exam study sheet for CS3719 Turing machines and decidability.
Final exam study sheet for CS3719 Turing machines and decidability. A Turing machine is a finite automaton with an infinite memory (tape). Formally, a Turing machine is a 6-tuple M = (Q, Σ, Γ, δ, q 0,
More informationTIME COMPLEXITY AND POLYNOMIAL TIME; NON DETERMINISTIC TURING MACHINES AND NP. THURSDAY Mar 20
TIME COMPLEXITY AND POLYNOMIAL TIME; NON DETERMINISTIC TURING MACHINES AND NP THURSDAY Mar 20 COMPLEXITY THEORY Studies what can and can t be computed under limited resources such as time, space, etc Today:
More informationCS154, Lecture 17: conp, Oracles again, Space Complexity
CS154, Lecture 17: conp, Oracles again, Space Complexity Definition: conp = { L L NP } What does a conp computation look like? In NP algorithms, we can use a guess instruction in pseudocode: Guess string
More informationChapter 7: Time Complexity
Chapter 7: Time Complexity 1 Time complexity Let M be a deterministic Turing machine that halts on all inputs. The running time or time complexity of M is the function f: N N, where f(n) is the maximum
More informationTime Complexity. CS60001: Foundations of Computing Science
Time Complexity CS60001: Foundations of Computing Science Professor, Dept. of Computer Sc. & Engg., Measuring Complexity Definition Let M be a deterministic Turing machine that halts on all inputs. The
More informationComplexity Theory VU , SS The Polynomial Hierarchy. Reinhard Pichler
Complexity Theory Complexity Theory VU 181.142, SS 2018 6. The Polynomial Hierarchy Reinhard Pichler Institut für Informationssysteme Arbeitsbereich DBAI Technische Universität Wien 15 May, 2018 Reinhard
More informationOutline. Complexity Theory EXACT TSP. The Class DP. Definition. Problem EXACT TSP. Complexity of EXACT TSP. Proposition VU 181.
Complexity Theory Complexity Theory Outline Complexity Theory VU 181.142, SS 2018 6. The Polynomial Hierarchy Reinhard Pichler Institut für Informationssysteme Arbeitsbereich DBAI Technische Universität
More informationCSCE 551 Final Exam, Spring 2004 Answer Key
CSCE 551 Final Exam, Spring 2004 Answer Key 1. (10 points) Using any method you like (including intuition), give the unique minimal DFA equivalent to the following NFA: 0 1 2 0 5 1 3 4 If your answer is
More informationComputability Theory
Computability Theory Cristian S. Calude May 2012 Computability Theory 1 / 1 Bibliography M. Sipser. Introduction to the Theory of Computation, PWS 1997. (textbook) Computability Theory 2 / 1 Supplementary
More informationFORMAL LANGUAGES, AUTOMATA AND COMPUTABILITY
15-453 FORMAL LANGUAGES, AUTOMATA AND COMPUTABILITY REVIEW for MIDTERM 1 THURSDAY Feb 6 Midterm 1 will cover everything we have seen so far The PROBLEMS will be from Sipser, Chapters 1, 2, 3 It will be
More informationCSE 105 THEORY OF COMPUTATION
CSE 105 THEORY OF COMPUTATION Spring 2018 http://cseweb.ucsd.edu/classes/sp18/cse105-ab/ Today's learning goals Sipser Ch 5.1, 5.3 Define and explain core examples of computational problems, including
More informationTime Complexity (1) CSCI Spring Original Slides were written by Dr. Frederick W Maier. CSCI 2670 Time Complexity (1)
Time Complexity (1) CSCI 2670 Original Slides were written by Dr. Frederick W Maier Spring 2014 Time Complexity So far we ve dealt with determining whether or not a problem is decidable. But even if it
More informationFunctions on languages:
MA/CSSE 474 Final Exam Notation and Formulas page Name (turn this in with your exam) Unless specified otherwise, r,s,t,u,v,w,x,y,z are strings over alphabet Σ; while a, b, c, d are individual alphabet
More informationTheory of Computation Time Complexity
Theory of Computation Time Complexity Bow-Yaw Wang Academia Sinica Spring 2012 Bow-Yaw Wang (Academia Sinica) Time Complexity Spring 2012 1 / 59 Time for Deciding a Language Let us consider A = {0 n 1
More information6.045: Automata, Computability, and Complexity Or, Great Ideas in Theoretical Computer Science Spring, Class 8 Nancy Lynch
6.045: Automata, Computability, and Complexity Or, Great Ideas in Theoretical Computer Science Spring, 2010 Class 8 Nancy Lynch Today More undecidable problems: About Turing machines: Emptiness, etc. About
More informationCSE 105 THEORY OF COMPUTATION
CSE 105 THEORY OF COMPUTATION Fall 2016 http://cseweb.ucsd.edu/classes/fa16/cse105-abc/ Logistics HW7 due tonight Thursday's class: REVIEW Final exam on Thursday Dec 8, 8am-11am, LEDDN AUD Note card allowed
More informationUNIT-VIII COMPUTABILITY THEORY
CONTEXT SENSITIVE LANGUAGE UNIT-VIII COMPUTABILITY THEORY A Context Sensitive Grammar is a 4-tuple, G = (N, Σ P, S) where: N Set of non terminal symbols Σ Set of terminal symbols S Start symbol of the
More informationFORMAL LANGUAGES, AUTOMATA AND COMPUTATION
FORMAL LANGUAGES, AUTOMATA AND COMPUTATION DECIDABILITY ( LECTURE 15) SLIDES FOR 15-453 SPRING 2011 1 / 34 TURING MACHINES-SYNOPSIS The most general model of computation Computations of a TM are described
More informationUndecidable Problems and Reducibility
University of Georgia Fall 2014 Reducibility We show a problem decidable/undecidable by reducing it to another problem. One type of reduction: mapping reduction. Definition Let A, B be languages over Σ.
More informationLecture 19: Finish NP-Completeness, conp and Friends
6.045 Lecture 19: Finish NP-Completeness, conp and Friends 1 Polynomial Time Reducibility f : Σ* Σ* is a polynomial time computable function if there is a poly-time Turing machine M that on every input
More informationDM17. Beregnelighed. Jacob Aae Mikkelsen
DM17 Beregnelighed Jacob Aae Mikkelsen January 12, 2007 CONTENTS Contents 1 Introduction 2 1.1 Operations with languages...................... 2 2 Finite Automata 3 2.1 Regular expressions/languages....................
More information1 Showing Recognizability
CSCC63 Worksheet Recognizability and Decidability 1 1 Showing Recognizability 1.1 An Example - take 1 Let Σ be an alphabet. L = { M M is a T M and L(M) }, i.e., that M accepts some string from Σ. Prove
More informationCSE 105 THEORY OF COMPUTATION
CSE 105 THEORY OF COMPUTATION Spring 2016 http://cseweb.ucsd.edu/classes/sp16/cse105-ab/ Today's learning goals Sipser Ch 4.1, 5.1 Define reductions from one problem to another. Use reductions to prove
More informationLecture Notes: The Halting Problem; Reductions
Lecture Notes: The Halting Problem; Reductions COMS W3261 Columbia University 20 Mar 2012 1 Review Key point. Turing machines can be encoded as strings, and other Turing machines can read those strings
More informationFORMAL LANGUAGES, AUTOMATA AND COMPUTABILITY
15-453 FORMAL LANGUAGES, AUTOMATA AND COMPUTABILITY Chomsky Normal Form and TURING MACHINES TUESDAY Feb 4 CHOMSKY NORMAL FORM A context-free grammar is in Chomsky normal form if every rule is of the form:
More informationCS 301. Lecture 18 Decidable languages. Stephen Checkoway. April 2, 2018
CS 301 Lecture 18 Decidable languages Stephen Checkoway April 2, 2018 1 / 26 Decidable language Recall, a language A is decidable if there is some TM M that 1 recognizes A (i.e., L(M) = A), and 2 halts
More informationCS151 Complexity Theory. Lecture 1 April 3, 2017
CS151 Complexity Theory Lecture 1 April 3, 2017 Complexity Theory Classify problems according to the computational resources required running time storage space parallelism randomness rounds of interaction,
More informationComputability Theory
CS:4330 Theory of Computation Spring 2018 Computability Theory The class NP Haniel Barbosa Readings for this lecture Chapter 7 of [Sipser 1996], 3rd edition. Section 7.3. Question Why are we unsuccessful
More informationLecture 12: Mapping Reductions
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
More informationDecision Problems with TM s. Lecture 31: Halting Problem. Universe of discourse. Semi-decidable. Look at following sets: CSCI 81 Spring, 2012
Decision Problems with TM s Look at following sets: Lecture 31: Halting Problem CSCI 81 Spring, 2012 Kim Bruce A TM = { M,w M is a TM and w L(M)} H TM = { M,w M is a TM which halts on input w} TOTAL TM
More informationCS6901: review of Theory of Computation and Algorithms
CS6901: review of Theory of Computation and Algorithms Any mechanically (automatically) discretely computation of problem solving contains at least three components: - problem description - computational
More informationHomework 8. a b b a b a b. two-way, read/write
Homework 8 309 Homework 8 1. Describe a TM that accepts the set {a n n is a power of 2}. Your description should be at the level of the descriptions in Lecture 29 of the TM that accepts {ww w Σ } and the
More informationNotes for Lecture Notes 2
Stanford University CS254: Computational Complexity Notes 2 Luca Trevisan January 11, 2012 Notes for Lecture Notes 2 In this lecture we define NP, we state the P versus NP problem, we prove that its formulation
More informationCSE 105 THEORY OF COMPUTATION. Spring 2018 review class
CSE 105 THEORY OF COMPUTATION Spring 2018 review class Today's learning goals Summarize key concepts, ideas, themes from CSE 105. Approach your final exam studying with confidence. Identify areas to focus
More informationCSE 105 THEORY OF COMPUTATION
CSE 105 THEORY OF COMPUTATION Spring 2017 http://cseweb.ucsd.edu/classes/sp17/cse105-ab/ Today's learning goals Summarize key concepts, ideas, themes from CSE 105. Approach your final exam studying with
More informationDecidability: Church-Turing Thesis
Decidability: Church-Turing Thesis While there are a countably infinite number of languages that are described by TMs over some alphabet Σ, there are an uncountably infinite number that are not Are there
More informationReducability. Sipser, pages
Reducability Sipser, pages 187-214 Reduction Reduction encodes (transforms) one problem as a second problem. A solution to the second, can be transformed into a solution to the first. We expect both transformations
More informationChomsky Normal Form and TURING MACHINES. TUESDAY Feb 4
Chomsky Normal Form and TURING MACHINES TUESDAY Feb 4 CHOMSKY NORMAL FORM A context-free grammar is in Chomsky normal form if every rule is of the form: A BC A a S ε B and C aren t start variables a is
More informationDecidability (What, stuff is unsolvable?)
University of Georgia Fall 2014 Outline Decidability Decidable Problems for Regular Languages Decidable Problems for Context Free Languages The Halting Problem Countable and Uncountable Sets Diagonalization
More informationComputability and Complexity
Computability and Complexity Decidability, Undecidability and Reducibility; Codes, Algorithms and Languages CAS 705 Ryszard Janicki Department of Computing and Software McMaster University Hamilton, Ontario,
More informationCSE 555 Homework Three Sample Solutions
CSE 555 Homework Three Sample Solutions Question 1 Let Σ be a fixed alphabet. A PDA M with n states and stack alphabet of size σ may recognize the empty language; if its language is non-empty then denote
More information6.045 Final Exam Solutions
6.045J/18.400J: Automata, Computability and Complexity Prof. Nancy Lynch, Nati Srebro 6.045 Final Exam Solutions May 18, 2004 Susan Hohenberger Name: Please write your name on each page. This exam is open
More informationTHEORY OF COMPUTATION (AUBER) EXAM CRIB SHEET
THEORY OF COMPUTATION (AUBER) EXAM CRIB SHEET Regular Languages and FA A language is a set of strings over a finite alphabet Σ. All languages are finite or countably infinite. The set of all languages
More information,
Kolmogorov Complexity Carleton College, CS 254, Fall 2013, Prof. Joshua R. Davis based on Sipser, Introduction to the Theory of Computation 1. Introduction Kolmogorov complexity is a theory of lossless
More informationCSE 105 THEORY OF COMPUTATION
CSE 105 THEORY OF COMPUTATION Spring 2016 http://cseweb.ucsd.edu/classes/sp16/cse105-ab/ Today's learning goals Sipser Ch 7.2, 7.3 Distinguish between polynomial and exponential DTIME Define nondeterministic
More informationWhat languages are Turing-decidable? What languages are not Turing-decidable? Is there a language that isn t even Turingrecognizable?
} We ll now take a look at Turing Machines at a high level and consider what types of problems can be solved algorithmically and what types can t: What languages are Turing-decidable? What languages are
More informationCS5371 Theory of Computation. Lecture 19: Complexity IV (More on NP, NP-Complete)
CS5371 Theory of Computation Lecture 19: Complexity IV (More on NP, NP-Complete) Objectives More discussion on the class NP Cook-Levin Theorem The Class NP revisited Recall that NP is the class of language
More informationCPSC 421: Tutorial #1
CPSC 421: Tutorial #1 October 14, 2016 Set Theory. 1. Let A be an arbitrary set, and let B = {x A : x / x}. That is, B contains all sets in A that do not contain themselves: For all y, ( ) y B if and only
More information1 Non-deterministic Turing Machine
1 Non-deterministic Turing Machine A nondeterministic Turing machine is a generalization of the standard TM for which every configuration may yield none, or one or more than one next configurations. In
More informationCS3719 Theory of Computation and Algorithms
CS3719 Theory of Computation and Algorithms Any mechanically (automatically) discretely computation of problem solving contains at least three components: - problem description - computational tool - analysis
More informationDefinition: conp = { L L NP } What does a conp computation look like?
Space Complexity 28 Definition: conp = { L L NP } What does a conp computation look like? In NP algorithms, we can use a guess instruction in pseudocode: Guess string y of x k length and the machine accepts
More informationAdvanced topic: Space complexity
Advanced topic: Space complexity CSCI 3130 Formal Languages and Automata Theory Siu On CHAN Chinese University of Hong Kong Fall 2016 1/28 Review: time complexity We have looked at how long it takes to
More informationUndecidability COMS Ashley Montanaro 4 April Department of Computer Science, University of Bristol Bristol, UK
COMS11700 Undecidability Department of Computer Science, University of Bristol Bristol, UK 4 April 2014 COMS11700: Undecidability Slide 1/29 Decidability We are particularly interested in Turing machines
More informationconp, Oracles, Space Complexity
conp, Oracles, Space Complexity 1 What s next? A few possibilities CS161 Design and Analysis of Algorithms CS254 Complexity Theory (next year) CS354 Topics in Circuit Complexity For your favorite course
More informationCSE 105 Theory of Computation
CSE 105 Theory of Computation http://www.jflap.org/jflaptmp/ Professor Jeanne Ferrante 1 Today s Agenda P and NP (7.2, 7.3) Next class: Review Reminders and announcements: CAPE & TA evals are open: Please
More informationV Honors Theory of Computation
V22.0453-001 Honors Theory of Computation Problem Set 3 Solutions Problem 1 Solution: The class of languages recognized by these machines is the exactly the class of regular languages, thus this TM variant
More informationCSCE 551 Final Exam, April 28, 2016 Answer Key
CSCE 551 Final Exam, April 28, 2016 Answer Key 1. (15 points) Fix any alphabet Σ containing the symbol a. For any language L Σ, define the language a\l := {w Σ wa L}. Show that if L is regular, then a\l
More information1 Computational Problems
Stanford University CS254: Computational Complexity Handout 2 Luca Trevisan March 31, 2010 Last revised 4/29/2010 In this lecture we define NP, we state the P versus NP problem, we prove that its formulation
More informationComplexity (Pre Lecture)
Complexity (Pre Lecture) Dr. Neil T. Dantam CSCI-561, Colorado School of Mines Fall 2018 Dantam (Mines CSCI-561) Complexity (Pre Lecture) Fall 2018 1 / 70 Why? What can we always compute efficiently? What
More informationCSE 105 THEORY OF COMPUTATION
CSE 105 THEORY OF COMPUTATION "Winter" 2018 http://cseweb.ucsd.edu/classes/wi18/cse105-ab/ Today's learning goals Sipser Ch 7 Distinguish between computability and complexity Articulate motivation questions
More informationCSE 105 THEORY OF COMPUTATION
CSE 105 THEORY OF COMPUTATION Spring 2016 http://cseweb.ucsd.edu/classes/sp16/cse105-ab/ Today's learning goals Sipser Ch 3.3, 4.1 State and use the Church-Turing thesis. Give examples of decidable problems.
More information6.045: Automata, Computability, and Complexity Or, Great Ideas in Theoretical Computer Science Spring, Class 10 Nancy Lynch
6.045: Automata, Computability, and Complexity Or, Great Ideas in Theoretical Computer Science Spring, 2010 Class 10 Nancy Lynch Today Final topic in computability theory: Self-Reference and the Recursion
More informationLecture 20: conp and Friends, Oracles in Complexity Theory
6.045 Lecture 20: conp and Friends, Oracles in Complexity Theory 1 Definition: conp = { L L NP } What does a conp computation look like? In NP algorithms, we can use a guess instruction in pseudocode:
More informationDecidability. Linz 6 th, Chapter 12: Limits of Algorithmic Computation, page 309ff
Decidability Linz 6 th, Chapter 12: Limits of Algorithmic Computation, page 309ff 1 A property P of strings is said to be decidable if the set of all strings having property P is a recursive set; that
More informationTheory of Computation
Theory of Computation Lecture #10 Sarmad Abbasi Virtual University Sarmad Abbasi (Virtual University) Theory of Computation 1 / 43 Lecture 10: Overview Linear Bounded Automata Acceptance Problem for LBAs
More informationComputational complexity
COMS11700 Computational complexity Department of Computer Science, University of Bristol Bristol, UK 2 May 2014 COMS11700: Computational complexity Slide 1/23 Introduction If we can prove that a language
More informationComputational Models Lecture 8 1
Computational Models Lecture 8 1 Handout Mode Ronitt Rubinfeld and Iftach Haitner. Tel Aviv University. May 11/13, 2015 1 Based on frames by Benny Chor, Tel Aviv University, modifying frames by Maurice
More informationCP405 Theory of Computation
CP405 Theory of Computation BB(3) q 0 q 1 q 2 0 q 1 1R q 2 0R q 2 1L 1 H1R q 1 1R q 0 1L Growing Fast BB(3) = 6 BB(4) = 13 BB(5) = 4098 BB(6) = 3.515 x 10 18267 (known) (known) (possible) (possible) Language:
More information4.2 The Halting Problem
172 4.2 The Halting Problem The technique of diagonalization was discovered in 1873 by Georg Cantor who was concerned with the problem of measuring the sizes of infinite sets For finite sets we can simply
More informationP is the class of problems for which there are algorithms that solve the problem in time O(n k ) for some constant k.
Complexity Theory Problems are divided into complexity classes. Informally: So far in this course, almost all algorithms had polynomial running time, i.e., on inputs of size n, worst-case running time
More informationTuring Machine Recap
Turing Machine Recap DFA with (infinite) tape. One move: read, write, move, change state. High-level Points Church-Turing thesis: TMs are the most general computing devices. So far no counter example Every
More informationCSCE 551: Chin-Tser Huang. University of South Carolina
CSCE 551: Theory of Computation Chin-Tser Huang huangct@cse.sc.edu University of South Carolina Church-Turing Thesis The definition of the algorithm came in the 1936 papers of Alonzo Church h and Alan
More informationComputational Models Lecture 8 1
Computational Models Lecture 8 1 Handout Mode Nachum Dershowitz & Yishay Mansour. Tel Aviv University. May 17 22, 2017 1 Based on frames by Benny Chor, Tel Aviv University, modifying frames by Maurice
More informationBBM402-Lecture 11: The Class NP
BBM402-Lecture 11: The Class NP Lecturer: Lale Özkahya Resources for the presentation: http://ocw.mit.edu/courses/electrical-engineering-andcomputer-science/6-045j-automata-computability-andcomplexity-spring-2011/syllabus/
More informationNon-emptiness Testing for TMs
180 5. Reducibility The proof of unsolvability of the halting problem is an example of a reduction: a way of converting problem A to problem B in such a way that a solution to problem B can be used to
More informationThe Unsolvability of the Halting Problem. Chapter 19
The Unsolvability of the Halting Problem Chapter 19 Languages and Machines SD D Context-Free Languages Regular Languages reg exps FSMs cfgs PDAs unrestricted grammars Turing Machines D and SD A TM M with
More informationCS154, Lecture 15: Cook-Levin Theorem SAT, 3SAT
CS154, Lecture 15: Cook-Levin Theorem SAT, 3SAT Definition: A language B is NP-complete if: 1. B NP 2. Every A in NP is poly-time reducible to B That is, A P B When this is true, we say B is NP-hard On
More informationLecture 21: Space Complexity (The Final Exam Frontier?)
6.045 Lecture 21: Space Complexity (The Final Exam Frontier?) 1 conp NP MIN-FORMULA conp P NP FIRST-SAT TAUT P FACTORING SAT NP NP NP 2 VOTE VOTE VOTE For your favorite course on automata and complexity
More informationComputational Models Lecture 8 1
Computational Models Lecture 8 1 Handout Mode Ronitt Rubinfeld and Iftach Haitner. Tel Aviv University. April 18/ May 2, 2016 1 Based on frames by Benny Chor, Tel Aviv University, modifying frames by Maurice
More informationTheory of Computation CS3102 Spring 2014 A tale of computers, math, problem solving, life, love and tragic death
Theory of Computation CS3102 Spring 2014 A tale of computers, math, problem solving, life, love and tragic death Nathan Brunelle Department of Computer Science University of Virginia www.cs.virginia.edu/~njb2b/theory
More informationTheory of Computation CS3102 Spring 2015 A tale of computers, math, problem solving, life, love and tragic death
Theory of Computation CS3102 Spring 2015 A tale of computers, math, problem solving, life, love and tragic death Robbie Hott www.cs.virginia.edu/~jh2jf Department of Computer Science University of Virginia
More informationComputation Histories
208 Computation Histories The computation history for a Turing machine on an input is simply the sequence of configurations that the machine goes through as it processes the input. An accepting computation
More informationComputability and Complexity
Computability and Complexity Lecture 10 More examples of problems in P Closure properties of the class P The class NP given by Jiri Srba Lecture 10 Computability and Complexity 1/12 Example: Relatively
More informationIntroduction to Turing Machines. Reading: Chapters 8 & 9
Introduction to Turing Machines Reading: Chapters 8 & 9 1 Turing Machines (TM) Generalize the class of CFLs: Recursively Enumerable Languages Recursive Languages Context-Free Languages Regular Languages
More informationDecidable and undecidable languages
The Chinese University of Hong Kong Fall 2011 CSCI 3130: Formal languages and automata theory Decidable and undecidable languages Andrej Bogdanov http://www.cse.cuhk.edu.hk/~andrejb/csc3130 Problems about
More informationACS2: Decidability Decidability
Decidability Bernhard Nebel and Christian Becker-Asano 1 Overview An investigation into the solvable/decidable Decidable languages The halting problem (undecidable) 2 Decidable problems? Acceptance problem
More information