CS F-15 Undecidiability 1

Size: px
Start display at page:

Download "CS F-15 Undecidiability 1"

Transcription

1 CS F-15 Undecidiability : Univeral TM Turing Machine are Hard Wired Addition machine only add 0 n 1 n 2 n machine only determine if a tring i in the language0 n 1 n 2 n Have een one Programmable TM Random Acce Computer TM 15-1: Univeral TM We can create a Univeral Turing Machine Take a input a decription of a Turing Machine, and the input tring for the Turing Machine Simulate running the machine on the input tring Turing Machine Interpreter Writing a Java Interpreter in Java, for intance, i not all that trange eentially what we are doing with Turing Machine 15-2: Encoding a Turing Machine Our Univeral Turing Machine need to have a pecific, finite alphabet of tape ymbol We need to be able to imulate any Turing Machine with any tape alphabet Ue an encoding cheme 15-3: Encoding a Turing Machine Tape alphabet Σ for Univeral Turing Machine: q a 01,() Encoded tate: q001,q010,q011,q100, Encoded Tape ymbol a001,a010,a011,a100, 15-4: Encoding a Turing Machine Turing Machine that change all a tob, and allb toa 15-5: Encoding a Turing Machine b a R b ye a

2 CS F-15 Undecidiability 2 a b q 0 (q 2, ) (q 1,b) (q 1,a) q 1 (q 0, ) (q 0, ) (q 0, ) q : Encoding a Turing Machine a b q 0 (q 2, ) (q 1,b) (q 1,a) q 1 (q 0, ) (q 0, ) (q 0, ) q 3 Symbol Encoding a000 a001 ( alway ymbol 1, alway ymbol 10 a010 2) a a011 b a100 (q00, a000, q10, a000)(q00, a011, q01, a100)(q00, a100, q01, a011)(q01, a000, q00, a010)(q01, a011, q00, a100)(q01, a100, q00, a100) 15-7: Encoding a Turing Machine Halting tate can be coded implicitly No outgoing edge = halting tate If we want a ye and no tate Firt halting tate i ye Second halting tate i no 15-8: Encoding a Turing Machine Given any Turing MachineM, we can create an encoding of the machine,e(m) Some machine will require more digit to repreent tate & ymbol Why uedq andaeparator We can actually encode any Turing Machine (and any tape) uing jut 0 and 1 (more on thi in a minute) 15-9: Univeral Turing Machine Take a input an encoding of a Turing Machinee(M), and an encoding of the input tapee(w) Simulate running M on w 3-Tape Machine: Simulated Tape Current State Tape Tranition Function Tape 15-10: Univeral Turing Machine Input Tape a a a a a a a State Tape q 0 0 Tranition Function Tape ( q 0 0, a 0 0 0, q 1 0 a ) ( q 0 0, a 0 1 1, q 0 1, a ) ( q 0 0, a 1 0 0

3 CS F-15 Undecidiability : Encoding a Turing Machine Encoding a Turing Machine uing jut 0 and 1 : If we knew how many tate there were, and how many ymbol in the input alphabet, we wouldn t need the eparator aq(), Each encoding tart with the # of digit ued for tate, and the # of digit ued for alphabet ymbol, in unary. (q00, a000, q10, a000)(q00, a011, q01, a100)(q00, a100, q01, a011),(q01, a000, q00, a010)(q01, a011, q00, a100) (q01, a100, q00, a100) : Halting Problem Halting Machine take a input an encoding of a Turing Machinee(M) and an encoding of an input tringe(w), and return ye ifm halt onw, and no if M doe not halt onw. Like writing a Java program that pare a Java function, and determine if that function halt on a pecific input e(m) e(w) Halting Machine ye no 15-13: Language v. Problem Brief Interlude We will ue Language and Problem interchangeably Any Problem can be converted to a Language, and vice-vera Problem: Multiply two numberx andy Language: L = {x;y;z : z = x y} 15-14: Language v. Problem Brief Interlude We will ue Language and Problem interchangeably Any Problem can be converted to a Language, and vice-vera Problem: Determine if a number i prime Language: L = {p : p i prime} 15-15: Language v. Problem Brief Interlude We will ue Language and Problem interchangeably Any Problem can be converted to a Language, and vice-vera Problem: Determine if a Turing MachineM halt on an input tringw Language: L = {e(m),e(w) : M halt onw}

4 CS F-15 Undecidiability : Halting Problem Halting Machine take a input an encoding of a Turing Machinee(M) and an encoding of an input tringe(w), and return ye ifm halt onw, and no if M doe not halt onw. Like writing a Java program that pare a Java function, and determine if that function halt on a pecific input How might the Java verion work? 15-17: Halting Problem Halting Machine take a input an encoding of a Turing Machinee(M) and an encoding of an input tringe(w), and return ye ifm halt onw, and no if M doe not halt onw. Like writing a Java program that pare a Java function, and determine if that function halt on a pecific input How might the Java verion work? Check for loop while (<tet) <body Ue program verification technique to ee if tet can ever be fale, etc : Halting Problem The Halting Problem i Undecidable There exit no Turing Machine that decide it There i no Turing Machine that halt on all input, and alway ay ye if M halt on w, and alway ay no if M doe not halt onw Prove Halting Problem i Undecidable by Contradiction: 15-19: Halting Problem Prove Halting Problem i Undecidable by Contradiction: e(m) e(w) e(m) Aume that there i ome Turing Machine that olve the halting problem. Halting Machine ye no We can ue thi machine to create a new machineq: Q e(m) e(m) Halting Machine ye no ye run forever 15-20: Halting Problem

5 CS F-15 Undecidiability 5 e(m) Q e(m) e(m) Halting Machine ye no ye run forever ye R M DUPLICATE M HALT 15-21: Halting Problem no ye MachineQtake a input a Turing MachineM, and either halt, or run forever. What happen if we runqone(q)? IfM HALT ayqhould run forever one(q),qhalt IfM HALT ayqhould halt one(q), Q run forever Q mut not exit butqi eay to build ifm HALT exit, om HALT mut not exit 15-22: Halting Problem (Java) Quick ideline: Prove that there can be no Java program that take a input two tring, one containig ource code for a Java program, and one containing an input, and determine if that program will halt when run on the given input. boolean Halt(String SourceCode, String Input); 15-23: Halting Problem (Java) boolean Halt(String SourceCode, String Input); void Contrarian(String SourceCode) { if (Halt(SourceCode, SourceCode)) while (true); ele return; } 15-24: Halting Problem (Java) boolean Halt(String SourceCode, String Input); void Contrarian(String SourceCode) {

6 CS F-15 Undecidiability 6 if (Halt(SourceCode, SourceCode)) while (true); ele return; } Contrarian("void Contrarian(String SourceCode { \ if (Halt(SourceCode, SourceCode)) \ } "); What happen? 15-25: Halting Problem II What if we retrict the input language, to prohibit running machine on it own encoding? Blank-Tape Halting Problem Given a Turing MachineM, doem halt when run on the empty tape? 15-26: Halting Problem II What if we retrict the input language, to prohibit running machine on it own encoding? Blank-Tape Halting Problem Given a Turing MachineM, doem halt when run on the empty tape? Thi problem i alo undecidable Prove uing a reduction 15-27: Reduction Reduce Problem A to Problem B 15-28: Reduction Convert intance of Problem A to an intance of Problem B Problem A: Power x y Problem B: Multiplication x y If we can olve Problem B, we can olve Problem A If we can multiply two number, we can calculate the powerx y If we can reduce Problem A to Problem B, and Problem A i undecidable, then: Problem B mut alo be undecidable 15-29: Reduction Becaue, if we could olve B, we could olve A To prove a problem B i undecidable: Start with a an intance of a known undecidable problem (like the Halting Problem)

7 CS F-15 Undecidiability 7 Create an intance of Problem B, uch that the anwer to the intance of Problem B give the anwer to the undecidable problem If we could olve Problem B, we could olve the halting problem thu Problem B mut be undecidable 15-30: Halting Problem II Show that the Blank-Tape Halting Problem i undecidable, by reducing the Halting Problem to the Blank-Tape Halting Problem Given any machine/input pairm,w, create a machinem uch thatm halt on the empty tape if and only if M halt onw 15-31: Halting Problem II Given any machine/input pair M,w, create a machine M uch that M halt on the empty tape if and only if M halt onw MachineM : Erae input tape (ignore input) Write M,w on input tape Run Univeral Turing Machine No matter what the input to M i, the input i ignored, andm imulate runningm onw M halt on the empty tape iffm halt onw If we could olve the Empty-Tape Halting Problem, we could olve the tandard Halting Problem 15-32: Halting Problem II input M (ignored) e(m) e(w) Univeral Turing Machine 15-33: Halting Problem II (Java) boolean MPrime(String Input) { String code = " (any java ource)" String input = " (any tring)" jvm(javac(code), input); } 15-34: More Reduction

8 CS F-15 Undecidiability 8 What do we know about Problem A if we reduce it to the Halting Problem? That i, given an intance of Problem A, create an intance of the halting problem, uch that olution to the intance of the halting problem i the ame a the olution to the intance of Problem A 15-35: More Reduction What do we know about Problem A if we reduce it to the Halting Problem? That i, given an intance of Problem A, create an intance of the halting problem, uch that olution to the intance of the halting problem i the ame a the olution to the intance of Problem A We know that the Halting Problem i at leat a hard a Problem A If we could decide the Halting Problem, we could decide Problem A 15-36: More Reduction What do we know about Problem A if we reduce it to the Halting Problem? That i, given an intance of Problem A, create an intance of the halting problem, uch that olution to the intance of the halting problem i the ame a the olution to the intance of Problem A We know that the Halting Problem i at leat a hard a Problem A If we could decide the Halting Problem, we could decide Problem A Which tell u nothing about Problem A! 15-37: More Reduction Given two Turing MachineM 1,M 2, i L[M 1 ] = L[M 2 ]? 15-38: More Reduction Given two Turing MachineM 1,M 2, i L[M 1 ] = L[M 2 ]? Start with an intancem,w of the halting problem Create M 1, which accept everything Create M 2, which ignore it input, and run M,w through the Univeral Turing Machine. Accept if M halt onw. IfM halt onw, thenl[m 2 ] = Σ, andl[m 1 ] = L[M 2 ] IfM doe not halt onw, thenl[m 2 ] = {}, andl[m 1 ] L[M 2 ] 15-39: More Reduction Given two Turing MachineM 1,M 2, i L[M 1 ] = L[M 2 ]? input M 2 M 1 input (ignored) e(m) e(w) Univeral Turing Machine (ignored) ye 15-40: More Reduction

9 CS F-15 Undecidiability 9 If we had a machine M ame that took a input the encoding of two machine M 1 and M 2, and determined if L[M 1 ] = L[M 2 ], we could olve the halting problem for any pairm,w: Create a Machine that accept everything (eay!). Encode thi machine. Create a Machine that firt erae it input, then write e(m),e(w) on input, then run Univeral TM. Encode thi machine Feed encoded machine intom ame. IfM ame ay ye, thenm halt onw, otherwiem doe not halt onw 15-41: More Reduction I the language decribed by a TMM regular? Thi problem i alo undecidable Ue a reduction 15-42: More Reduction Recall: to how a problemp i undecidable: Pick a known undecidable problemp UND Create an intance ofp, uch that if we could olvep, we could olvep UND SinceP UND i known to be undecidable,p mut be undecidable, too : More Reduction I the language decribed by a TMM regular? Let M,w be an intance of the halting problem Create a new machine M, that firt run M on w. If that proce halt, the input tring i run though a machine that accept the languagea n b n 15-44: More Reduction input M e(m) e(w) Univeral Turing Machine an bn After M halt on w What il[m ]? 15-45: More Reduction

10 CS F-15 Undecidiability 10 input M e(m) e(w) Univeral Turing Machine an bn After M halt on w What il[m ]? IfM halt onw, thenl[m ] = a n b n, which i not regular IfM doe not halt onw, thenl[m ] = {}, which i regular 15-46: More Reduction So, if we have a machinem REG, that took a input a Turing machinem 1, and decided ifl[m 1 ] i regular, then: For any Turing machinem and tringw, we can decide ifm halt onw Create M fromm andw FeedM throughm REG IfM REG ay ye, thenm doe not halt onw. IfM REG ay no, thenm doe halt onw 15-47: More Reduction Given a Turing Machine M, i L[M] 0? That i, are there any tring accepted by M? 15-48: More Reduction Given a Turing Machine M, i L[M] 0? That i, are there any tring accepted by M? Undecidable, by reduction from the halting problem. Given any TMM and tringw, we create a TM M uch that: L[M ] = Σ ifm halt onw L[M ] = {} otherwie 15-49: More Reduction Given a Turing Machine M, i L[M] 0? That i, are there any tring accepted by M? ConiderM : Erae input Simulate running M on w Accept 15-50: Quetion about Grammar The following quetion about unretricted grammar are all undecidable:

11 CS F-15 Undecidiability 11 Given a GrammarGand tringw, iw L[G]? Given a GrammarG, iǫ L[G]? Given GrammarG 1 andg 2, il[g 1 ] = L[G 2 ]? Given a GrammarG, il[g] = {} 15-51: Quetion about Grammar The following quetion about unretricted grammar are all undecidable: Given a GrammarGand tringw, iw L[G]? By reduction from the Halting Problem: Given any MachineM, we can contruct an unretricted GrammarG, uch thatl[g] = L[M] w L[M] iffw L[G] 15-52: Quetion about Grammar The following quetion about Context-Free Grammar are decidable: Given a GrammarGand tringw, iw L[G]? Compiler would be hard to write, otherwie Given a GrammarG, iǫ L[G]? Thi i a pecial cae of determining if w L[G] 15-53: Quetion about Grammar However, there are ome problem about CFG that are not decidable: Given any CFG G, il[g] = Σ Given any two CFG G 1 andg 2, il[g 1 ] = L[G 2 ] Given two PDAM 1 andm 2, il[m 1 ] = L[M 2 ] Given a PDA M, find an equivalent PDA with the mallet poible number of tate 15-54: Quetion about Grammar Given any CFG G, il[g] = Σ? Prove thi problem i undecidable by reduction from the problem Given an unretricted grammar G, i L[G] = {} That i, given any unretricted grammarg, we will create a CFG G : L[G ] = Σ iffl[g] = {} 15-55: Quetion about Grammar Given any unretricted grammarg, we will create a CFG G, uch thatl[g ] = Σ iffl[g] = {} Firt, we will modifyg, to create an equivalent grammar S absc S X Ba ab BX Xb ax a 15-56: Quetion about Grammar

12 CS F-15 Undecidiability 12 Given any unretricted grammarg, we will create a CFG G, uch thatl[g ] = Σ iffl[g] = {} Firt, we will modifyg, to create an equivalent grammar S A 1 S A 2 Ba A 3 BX A 4 ax A 5 A 1 absc A 2 X A 3 ab A 4 Xb A 5 a 15-57: Quetion about Grammar A tandard derivation in thi new grammar i one in which each odd tep applie of rule of the formu i A i, and every even tep applie a rule of the forma i v i S A 1 absc aba 2 c abxc aa 4 c axbc A 5 bc abc S A 1 A 1 absc S A 2 A 2 X Ba A 3 A 3 ab BX A 4 A 4 Xb ax A 5 A 5 a 15-58: Quetion about Grammar Each tandard derivation of a tring generated from G can be conidered a tring over the alphabet V { } (recallv containσ a well a non-terminal) We can define a new langauged G, the et of all valid tandard derivation of tring generated byg. S A 1 absc aba 2 c abxc aa 4 c axbc A 5 bc abc D G S A 1 absc aba 1 c ababscc ababa 2 cc ababxcc aa 3 BXcc aabbxcc aaba 4 cc aabxbcc aaa 4 bcc aaxbbcc aa 5 bbcc aabbcc D G 15-59: Quetion about Grammar A boutrophedon verion of a derivation i one in which the odd numbered element of the derivation are revered: S x R 1 x 2 x R 3 xr n 1 x n Derivation S A 1 absc aba 2 c abxc aa 4 c axbc A 5 bc abc Boutrophedon verion of the derivation S A 1 absc ca 2 Ba abxc ca 4 a axbc cba 5 abc 15-60: Quetion about Grammar D G i the language of all tandard derivation of tring inl[g] BD G i the language of all boutrophedon verion of tandard derivation of tring inl[g]

13 CS F-15 Undecidiability 13 S A 1 absc ca 2 Ba abxc ca 4 a axbc cba 5 abc BD G 15-61: Quetion about Grammar Given any Unretricted Grammar G: L[G] i the et of all tring generated byg D G i the et of all tring that repreent tandard derivation of tring generated byg BD G i the et of all tring that repreent boutrophedon verion of tandard derivation of tring in L[G] BD G i the et of all tring that do not repreent boutrophedon verion of tandard derivation of tring in L[G]. w BD G if w repreent only a partial derivation, or an incorrect derivation, or a mal-formed derivation 15-62: Quetion about Grammar What doe it mean ifbd G = Σ? 15-63: Quetion about Grammar What doe it mean ifbd G = Σ? BD G = {} D G = {} L[G] = {} So, if we could build a CFG that generate BD G, for any unretricted grammar G, and we could determine if L[G ] = Σ for any CFG G 15-64: Quetion about Grammar What doe it mean ifbd G = Σ? BD G = {} D G = {} L[G] = {} So, if we could build a CFG that generate BD G, for any unretricted grammar G, and we could determine if L[G ] = Σ for any CFG G We could determine if L[G] = {} for any unretricted grammar G which mean we could olve the halting problem (why?) 15-65: Building a CFG forbd G When iw BD G? w doe not tart with S w doe not end with v,v Σ w contain an odd # of w i of the formu y v, oru y

14 CS F-15 Undecidiability 14 u contain an even number of y contain exactly one y i not of the formy = y 1 A i y 2 y R 2 β iy R 1 for omei R,y 1,y 2 V, whereβ i i the right-hand ide of theith rule ing (there more) 15-66: Building a CFG forbd G When iw BD G? w i of the formu y v u contain an odd number of y contain exactly one y i not of the formy = y 1 α i y 2 y R 2 A iy R 1 for omei R,y 1,y 2 V, whereα i i the right-hand ide of theith rule ing 15-67: Building a CFG forbd G w doe not tart with S We can create a CFG for all tringw (V ) that do not tart with S Thi language i regular, we could even creatre a DFA or regular expreion for it : Building a CFG forbd G w doe not end with v, v Σ We can create a CFG for all tringw (V ) that do not end with v, v Σ Thi language i regular, we could even create a DFA or regular expreion for it : Building a CFG forbd G w doe contain an odd # of We can create a CFG for all tringw (V ) that contain an odd # of Thi language i regular, we could even create a DFA or regular expreion for it : Building a CFG forbd G w i of the formu y v, oru y u contain an even number of y contain exactly one y i not of the form y = y 1 A i y 2 y R 2 β i y R 1 for ome i R, y 1,y 2 V, where β i i the right-hand ide of theith rule ing We can create a PDA which accept tringw of thi form 15-71: Building a CFG forbd G We can create a PDA which can accept all tringw of thi form

15 CS F-15 Undecidiability 15 Firt, check that the firt part of the tring i of the form: V ( V V ) Non-determinitically decide when to top Puh Symbol on tack until a Check the input againt the tack, making ure there i at leat one mimatch Jut like the PDA for non-palindrome 15-72: Building a CFG forbd G A 3 ABc (V,ε,ε) (V,ε,ε) (V,ε,ε) (a,ε,a) (b,ε,b) (c,ε,c) (A,ε,A) (A,A ε) 3 (B,ε,ε) (A,A ε) 3 (B,ε,ε) (c,ε,ε) (V,ε,ε) (ε,γ,ε) 15-73: Building a CFG forbd G w i of the formu y v u contain an odd number of y contain exactly one y i not of the form y = y 1 α i y 2 y R 2 A iy R 1 for ome i R, y 1,y 2 V, where α i i the right-hand ide of theith rule ing We can create a PDA which accept all tringwof thi form : Quetion about Grammar If we could determine, for any CFG G, ifl[g] = Σ, we could olve the halting problem Given any TM M and tring w: Create a new TM M, that acceptσ if M halt onw, and{} otherwie Create an Unretricted Grammar, uch thatl[g] = L[M ] Create a CFG G forbd G L[G ] = Σ if and only if L[G] = {},L[M ] = {}, andm doe not halt onw 15-75: Quetion about Grammar Undecidable problem about CFG Given any CFG G, il[g] = Σ

16 CS F-15 Undecidiability 16 Jut proved Given any two CFG G 1 andg 2, il[g 1 ] = L[G 2 ] Given two PDAM 1 andm 2, il[m 1 ] = L[M 2 ] Given a PDA M, find an equivalent PDA with the mallet poible number of tate 15-76: Quetion about Grammar Given any two CFGG 1 andg 2, il[g 1 ] = L[G 2 ] We can eaily create a CFG G 2 which generateσ How? Note that the preceding proof did not ay we cannot decide if L[G] = Σ for any grammar G, but intead, we cannot decide if L[G] = Σ for every grammarg. For any CFG G 1, L[G 1 ] = L[G 2 ] if and only ifl[g 1 ] = Σ 15-77: Quetion about Grammar Given two PDA M 1 andm 2, il[m 1 ] = L[M 2 ] We can convert a CFG to an equivalent PDA If we could determine if two PDA are equivalent: We could determine if two CFG are equivalent We could determine if a CFG acceptedσ We could determine if an Unretricted Grammar generated any tring We could determine if a Turing Machine accepted any tring We could olve the halting problem 15-78: Quetion about PDA Given a PDAM, find an equivalent PDA with the mallet poible number of tate Firt, prove that it i decidable whether a PDA with one tate acceptσ 15-79: Quetion about PDA It i decidable whether a PDA with a ingle tate acceptσ A PDA that acceptσ mut acceptσ. We can tet whether a PDA acceptσ Iw L[M] for a PDA M i decidable Tet each of the Σ tring equentially We can decide if a PDA M acceptσ 15-80: Quetion about PDA If a Single State PDA M acceptσ, thenm acceptσ. Why? 15-81: Quetion about PDA

17 CS F-15 Undecidiability 17 If a Single State PDA M acceptσ, thenm acceptσ. Start in the initial tate (which i alo a final tate) with an empty tack After reading a ingle character, tack i empty, and we re (till!) in the initial (and final!) tate accept the tring We are in exactly the ame poition after reading one ymbol a we were before reading in anything After reading the next ymbol, we will be in a final tate with an empty tack accept the tring 15-82: Quetion about PDA Given a PDAM, find an equivalent PDA with the mallet poible number of tate It i decidable whether a PDA with one tate acceptσ So 15-83: Quetion about PDA Given a PDAM, find an equivalent PDA with the mallet poible number of tate It i decidable whether a PDA with one tate acceptσ If we could minimize the number of tate in a PDA, we could decide if a PDA acceptedσ Minimize the number of tate. PDA acceptσ iff minimized PDA ha a ingle tate, and minimized PDA acceptσ 15-84: Tiling Quetion There are ome problem which eem to have no relation to Turing Machine at all, which turn out to be undecidable Tiling Problem: Set of tile (infinite # of copie of each tile) Rule for which tile can be placed next to which other tile (think puzzle piece) Can we tile the entire plane? 15-85: Tiling Quetion origin tile 15-86: Tiling Quetion

18 CS F-15 Undecidiability 18 Tiling Sytem D = (D,d 0,H,V) D i a et of tile d D i the origin tile H D D lit of pair of which tile can be next to each other V D D lit of pair of which tile can be on top of each other 15-87: Tiling Quetion Tiling functionf : N N D Specifie which tile goe where f(0,0) = d 0 (f(m,n),f(m+1,n)) H (f(m,n),f(m,n+1)) V 15-88: Tiling Quetion Problem: Given a tiling ytem D = (D,d 0,H,V), doe a tiling exit? That i, i there a completely defined tiling functionf that atifie the requirement: f(0,0) = d 0 (f(m,n),f(m+1,n)) H (f(m,n),f(m,n+1)) V Thi problem i undecidable! 15-89: Tiling Quetion Tiling Problem i undecidable Proof by reduction from the empty tape halting problem Given any Turing Machine M Create a tiling ytem D A tiling will exit fordif and only if M doe not halt when run on the empty tape 15-90: Tiling Quetion Given any Turing MachineM, create a tiling ytem D Baic Idea: Each row of the tiling repreent a TM configuration Infinite row, infinite tape Create rule o that ucceive row i and j are only legal if TM can tranition form configuration i to configuration j in one tep Can tile the entire plane if and only if TM doe not halt 15-91: Tiling Quetion

19 CS F-15 Undecidiability 19 Label the edge of each tile Two tile can only be adjacent if the edge match Jut like a tandard jigaw puzzle 15-92: Tiling Quetion We will modify the Turing MachineM lightly to get M (make creating the tiling ytem a little eaier) Add a new ymbolto the tape ymbol ofm Add a new tart tate Add a tranition((,),(, )) M halt on empty tape if and only if M halt on the tape containing 15-93: Tiling Quetion Tile: For each ymbola that can appear on the tape of Turing MachineM, add the tile: a a Top and bottom edge labeled witha, left and right edge labeled withǫ 15-94: Tiling Quetion Tile: For each tranition((q,a),(p,b)) inδ M add the tile: (p,b) (q,a) 15-95: Tiling Quetion Tile: For each tranition((q,a),(p, )) in δ M add the tile: a (p,b) p p (q,a) b Add a copy of right-hand tile for every ymbolb

20 CS F-15 Undecidiability : Tiling Quetion Tile: For each tranition((q,a),(p, )) in δ M add the tile: (p,b) a p p b (q,a) Add a copy of left-hand tile for every ymbolb 15-97: Tiling Quetion Initial Tile: (,) 15-98: Tiling Quetion One final tile: 15-99: Tiling Quetion Thi tiling ytem ha a tiling if and only if M doe not halt on the empty tape. Example: (, ) (, ) : Tiling Quetion (, ) (, )

21 CS F-15 Undecidiability 21 (, ) (, ) (,) (, ) (,) (,) : Tiling Quetion (, ) (, ) (, ) (, ) (, ) (,) (,) : Tiling Quetion Example II: (, ) (p, ) p (, ) : Tiling Quetion

22 CS F-15 Undecidiability 22 (,) (, ) (,) (,) (p, ) (p,) p p p (, ) (, ) (,) (p, ) : Tiling Quetion (p, ) p p (, ) (, ) (p, ) (p, ) p p (, ) (, ) (,) (,) : Tiling Quetion Example III: (, ) (, ) : Tiling Quetion

23 CS F-15 Undecidiability 23 (,) (,) (, ) (,) (, ) (,) (, ) : Tiling Quetion (, ) (, ) (, ) (, ) (, ) (,) (,) (, ) (, ) : Tiling Quetion Example IV: a (, ) (p, ) p (, ) : Tiling Quetion

24 CS F-15 Undecidiability 24 a (,) a (,) (, ) (,) (,a) a (p, ) (p,) p p p (, ) a (, ) (,) (p,a) : Tiling Quetion (p,a) p a (,a) a Can t Place Any tile here (p, ) p p (, ) (, ) (,) (,)

Automata Theory CS S-FR2 Final Review

Automata Theory CS S-FR2 Final Review Automata Theory CS411-2015S-FR2 Final Review David Galles Department of Computer Science University of San Francisco FR2-0: Halting Problem e(m) e(w) Halting Machine takes as input an encoding of a Turing

More information

The machines in the exercise work as follows:

The machines in the exercise work as follows: Tik-79.148 Spring 2001 Introduction to Theoretical Computer Science Tutorial 9 Solution to Demontration Exercie 4. Contructing a complex Turing machine can be very laboriou. With the help of machine chema

More information

Problem Set 8 Solutions

Problem Set 8 Solutions Deign and Analyi of Algorithm April 29, 2015 Maachuett Intitute of Technology 6.046J/18.410J Prof. Erik Demaine, Srini Devada, and Nancy Lynch Problem Set 8 Solution Problem Set 8 Solution Thi problem

More information

Turing Machines Part III

Turing Machines Part III Turing Machines Part III Announcements Problem Set 6 due now. Problem Set 7 out, due Monday, March 4. Play around with Turing machines, their powers, and their limits. Some problems require Wednesday's

More information

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

CS 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 information

Theory of Computation

Theory 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 information

6.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, 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 information

CS 170: Midterm Exam II University of California at Berkeley Department of Electrical Engineering and Computer Sciences Computer Science Division

CS 170: Midterm Exam II University of California at Berkeley Department of Electrical Engineering and Computer Sciences Computer Science Division 1 1 April 000 Demmel / Shewchuk CS 170: Midterm Exam II Univerity of California at Berkeley Department of Electrical Engineering and Computer Science Computer Science Diviion hi i a cloed book, cloed calculator,

More information

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

CS5371 Theory of Computation. Lecture 14: Computability V (Prove by Reduction) CS5371 Theory of Computation Lecture 14: Computability V (Prove by Reduction) Objectives This lecture shows more undecidable languages Our proof is not based on diagonalization Instead, we reduce the problem

More information

Chapter 4. The Laplace Transform Method

Chapter 4. The Laplace Transform Method Chapter 4. The Laplace Tranform Method The Laplace Tranform i a tranformation, meaning that it change a function into a new function. Actually, it i a linear tranformation, becaue it convert a linear combination

More information

Reducability. Sipser, pages

Reducability. 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 information

CS20a: Turing Machines (Oct 29, 2002)

CS20a: Turing Machines (Oct 29, 2002) CS20a: Turing Machines (Oct 29, 2002) So far: DFA = regular languages PDA = context-free languages Today: Computability 1 Church s thesis The computable functions are the same as the partial recursive

More information

7.2 INVERSE TRANSFORMS AND TRANSFORMS OF DERIVATIVES 281

7.2 INVERSE TRANSFORMS AND TRANSFORMS OF DERIVATIVES 281 72 INVERSE TRANSFORMS AND TRANSFORMS OF DERIVATIVES 28 and i 2 Show how Euler formula (page 33) can then be ued to deduce the reult a ( a) 2 b 2 {e at co bt} {e at in bt} b ( a) 2 b 2 5 Under what condition

More information

Undecidable Problems and Reducibility

Undecidable 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 information

cse303 ELEMENTS OF THE THEORY OF COMPUTATION Professor Anita Wasilewska

cse303 ELEMENTS OF THE THEORY OF COMPUTATION Professor Anita Wasilewska cse303 ELEMENTS OF THE THEORY OF COMPUTATION Professor Anita Wasilewska LECTURE 14 SMALL REVIEW FOR FINAL SOME Y/N QUESTIONS Q1 Given Σ =, there is L over Σ Yes: = {e} and L = {e} Σ Q2 There are uncountably

More information

Laplace Transformation

Laplace Transformation Univerity of Technology Electromechanical Department Energy Branch Advance Mathematic Laplace Tranformation nd Cla Lecture 6 Page of 7 Laplace Tranformation Definition Suppoe that f(t) i a piecewie continuou

More information

CPSC 421: Tutorial #1

CPSC 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 information

Advanced Undecidability Proofs

Advanced Undecidability Proofs 17 Advanced Undecidability Proofs In this chapter, we will discuss Rice s Theorem in Section 17.1, and the computational history method in Section 17.3. As discussed in Chapter 16, these are two additional

More information

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

Lecture 23: Rice Theorem and Turing machine behavior properties 21 April 2009 CS 373: Theory of Computation Sariel Har-Peled and Madhusudan Parthasarathy Lecture 23: Rice Theorem and Turing machine behavior properties 21 April 2009 This lecture covers Rice s theorem, as well as

More information

Theory of Computation Turing Machine and Pushdown Automata

Theory of Computation Turing Machine and Pushdown Automata Theory of Computation Turing Machine and Pushdown Automata 1. What is a Turing Machine? A Turing Machine is an accepting device which accepts the languages (recursively enumerable set) generated by type

More information

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

Turing s thesis: (1930) Any computation carried out by mechanical means can be performed by a Turing Machine Turing s thesis: (1930) Any computation carried out by mechanical means can be performed by a Turing Machine There is no known model of computation more powerful than Turing Machines Definition of Algorithm:

More information

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

CSCE 551: Chin-Tser Huang. University of South Carolina CSCE 551: Theory of Computation Chin-Tser Huang huangct@cse.sc.edu University of South Carolina Computation History A computation history of a TM M is a sequence of its configurations C 1, C 2,, C l such

More information

Section 14.1 Computability then else

Section 14.1 Computability then else Section 14.1 Computability Some problems cannot be solved by any machine/algorithm. To prove such statements we need to effectively describe all possible algorithms. Example (Turing machines). Associate

More information

Decidability. Overview. Preliminaries to Halting Problem. Decidable Problems of Regular Languages. Decidable Problems of Context-Free Languages

Decidability. Overview. Preliminaries to Halting Problem. Decidable Problems of Regular Languages. Decidable Problems of Context-Free Languages CS533 Class 04a: 1 c P. Heeman, 2017 Introduction: Decidability Overview Decidable Problems of Regular Languages Decidable Problems of Context-Free Languages Preliminaries to Halting Problem CS533 Class

More information

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

The Turing Machine. Computability. The Church-Turing Thesis (1936) Theory Hall of Fame. Theory Hall of Fame. Undecidability The Turing Machine Computability Motivating idea Build a theoretical a human computer Likened to a human with a paper and pencil that can solve problems in an algorithmic way The theoretical provides a

More information

Feedback Control Systems (FCS)

Feedback Control Systems (FCS) Feedback Control Sytem (FCS) Lecture19-20 Routh-Herwitz Stability Criterion Dr. Imtiaz Huain email: imtiaz.huain@faculty.muet.edu.pk URL :http://imtiazhuainkalwar.weebly.com/ Stability of Higher Order

More information

FORMAL LANGUAGES, AUTOMATA AND COMPUTABILITY

FORMAL 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 information

A non-turing-recognizable language

A non-turing-recognizable language CS 360: Introduction to the Theory of Computing John Watrous, University of Waterloo A non-turing-recognizable language 1 OVERVIEW Thus far in the course we have seen many examples of decidable languages

More information

THEORY OF COMPUTATION (AUBER) EXAM CRIB SHEET

THEORY 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

Math 273 Solutions to Review Problems for Exam 1

Math 273 Solutions to Review Problems for Exam 1 Math 7 Solution to Review Problem for Exam True or Fale? Circle ONE anwer for each Hint: For effective tudy, explain why if true and give a counterexample if fale (a) T or F : If a b and b c, then a c

More information

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

Decidability. 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 information

Decision 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. 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 information

Undecidability COMS Ashley Montanaro 4 April Department of Computer Science, University of Bristol Bristol, UK

Undecidability 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 information

CSE 105 THEORY OF COMPUTATION

CSE 105 THEORY OF COMPUTATION CSE 105 THEORY OF COMPUTATION "Winter" 2018 http://cseweb.ucsd.edu/classes/wi18/cse105-ab/ Today's learning goals Sipser Section 4.1 Explain what it means for a problem to be decidable. Justify the use

More information

Social Studies 201 Notes for November 14, 2003

Social Studies 201 Notes for November 14, 2003 1 Social Studie 201 Note for November 14, 2003 Etimation of a mean, mall ample ize Section 8.4, p. 501. When a reearcher ha only a mall ample ize available, the central limit theorem doe not apply to the

More information

Lecture Notes: The Halting Problem; Reductions

Lecture 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 information

Turing Machine Recap

Turing 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 information

The Unsolvability of the Halting Problem. Chapter 19

The 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 information

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

Chap. 4,5 Review. Algorithms created in proofs from prior chapters Chap. 4,5 Review Algorithms created in proofs from prior chapters (p. 55) Theorem 1.39: NFA to DFA (p. 67) Lemma 1.55: Regex to NFA (p. 69) Lemma 1.60: DFA to regex (through GNFA) (p. 112) Lemma 2.21:

More information

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

CS5371 Theory of Computation. Lecture 12: Computability III (Decidable Languages relating to DFA, NFA, and CFG) CS5371 Theory of Computation Lecture 12: Computability III (Decidable Languages relating to DFA, NFA, and CFG) Objectives Recall that decidable languages are languages that can be decided by TM (that means,

More information

Correction for Simple System Example and Notes on Laplace Transforms / Deviation Variables ECHE 550 Fall 2002

Correction for Simple System Example and Notes on Laplace Transforms / Deviation Variables ECHE 550 Fall 2002 Correction for Simple Sytem Example and Note on Laplace Tranform / Deviation Variable ECHE 55 Fall 22 Conider a tank draining from an initial height of h o at time t =. With no flow into the tank (F in

More information

Logic, Automata and Games

Logic, Automata and Games Logic, Automata and Game Jacque Duparc EJCIM 27 EJCIM, 23-27 January 27 J. Duparc ( & ) Logic, Automata and Game Lyon, 23-27 January 27 / 97 Reference [] K. R. Apt and E. Grädel. Lecture in game theory

More information

CS 21 Decidability and Tractability Winter Solution Set 3

CS 21 Decidability and Tractability Winter Solution Set 3 CS 21 Decidability and Tractability Winter 2018 Posted: January 31 Solution Set 3 If you have not yet turned in the Problem Set, you should not consult these solutions. 1. (a) A 2-NPDA is a 7-tuple (Q,,

More information

Convex Hulls of Curves Sam Burton

Convex Hulls of Curves Sam Burton Convex Hull of Curve Sam Burton 1 Introduction Thi paper will primarily be concerned with determining the face of convex hull of curve of the form C = {(t, t a, t b ) t [ 1, 1]}, a < b N in R 3. We hall

More information

ACS2: Decidability Decidability

ACS2: 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

AC68 FINITE AUTOMATA & FORMULA LANGUAGES DEC 2013

AC68 FINITE AUTOMATA & FORMULA LANGUAGES DEC 2013 Q.2 a. Prove by mathematical induction n 4 4n 2 is divisible by 3 for n 0. Basic step: For n = 0, n 3 n = 0 which is divisible by 3. Induction hypothesis: Let p(n) = n 3 n is divisible by 3. Induction

More information

Physics 741 Graduate Quantum Mechanics 1 Solutions to Final Exam, Fall 2014

Physics 741 Graduate Quantum Mechanics 1 Solutions to Final Exam, Fall 2014 Phyic 7 Graduate Quantum Mechanic Solution to inal Eam all 0 Each quetion i worth 5 point with point for each part marked eparately Some poibly ueful formula appear at the end of the tet In four dimenion

More information

FORMAL LANGUAGES, AUTOMATA AND COMPUTATION

FORMAL 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 information

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

Midterm Exam 2 CS 341: Foundations of Computer Science II Fall 2018, face-to-face day section Prof. Marvin K. Nakayama Midterm Exam 2 CS 341: Foundations of Computer Science II Fall 2018, face-to-face day section Prof. Marvin K. Nakayama Print family (or last) name: Print given (or first) name: I have read and understand

More information

Lecture 9: Shor s Algorithm

Lecture 9: Shor s Algorithm Quantum Computation (CMU 8-859BB, Fall 05) Lecture 9: Shor Algorithm October 7, 05 Lecturer: Ryan O Donnell Scribe: Sidhanth Mohanty Overview Let u recall the period finding problem that wa et up a a function

More information

p. (The electron is a point particle with radius r = 0.)

p. (The electron is a point particle with radius r = 0.) - pin ½ Recall that in the H-atom olution, we howed that the fact that the wavefunction Ψ(r) i ingle-valued require that the angular momentum quantum nbr be integer: l = 0,,.. However, operator algebra

More information

Theory of Computation - Module 4

Theory of Computation - Module 4 Theory of Computation - Module 4 Syllabus Turing Machines Formal definition Language acceptability by TM TM as acceptors, Transducers - designing of TM- Two way infinite TM- Multi tape TM - Universal Turing

More information

Social Studies 201 Notes for March 18, 2005

Social Studies 201 Notes for March 18, 2005 1 Social Studie 201 Note for March 18, 2005 Etimation of a mean, mall ample ize Section 8.4, p. 501. When a reearcher ha only a mall ample ize available, the central limit theorem doe not apply to the

More information

Codes Correcting Two Deletions

Codes Correcting Two Deletions 1 Code Correcting Two Deletion Ryan Gabry and Frederic Sala Spawar Sytem Center Univerity of California, Lo Angele ryan.gabry@navy.mil fredala@ucla.edu Abtract In thi work, we invetigate the problem of

More information

Introduction to Languages and Computation

Introduction 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 information

Uniform Acceleration Problems Chapter 2: Linear Motion

Uniform Acceleration Problems Chapter 2: Linear Motion Name Date Period Uniform Acceleration Problem Chapter 2: Linear Motion INSTRUCTIONS: For thi homework, you will be drawing a coordinate axi (in math lingo: an x-y board ) to olve kinematic (motion) problem.

More information

Decidability and Undecidability

Decidability and Undecidability Decidability and Undecidability Major Ideas from Last Time Every TM can be converted into a string representation of itself. The encoding of M is denoted M. The universal Turing machine U TM accepts an

More information

Turing Machines. Lecture 8

Turing Machines. Lecture 8 Turing Machines Lecture 8 1 Course Trajectory We will see algorithms, what can be done. But what cannot be done? 2 Computation Problem: To compute a function F that maps each input (a string) to an output

More information

CSE 105 THEORY OF COMPUTATION

CSE 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 information

Lecture 12: Mapping Reductions

Lecture 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 information

Bogoliubov Transformation in Classical Mechanics

Bogoliubov Transformation in Classical Mechanics Bogoliubov Tranformation in Claical Mechanic Canonical Tranformation Suppoe we have a et of complex canonical variable, {a j }, and would like to conider another et of variable, {b }, b b ({a j }). How

More information

MAE140 Linear Circuits Fall 2012 Final, December 13th

MAE140 Linear Circuits Fall 2012 Final, December 13th MAE40 Linear Circuit Fall 202 Final, December 3th Intruction. Thi exam i open book. You may ue whatever written material you chooe, including your cla note and textbook. You may ue a hand calculator with

More information

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

CS5371 Theory of Computation. Lecture 10: Computability Theory I (Turing Machine) CS537 Theory of Computation Lecture : Computability Theory I (Turing Machine) Objectives Introduce the Turing Machine (TM)? Proposed by Alan Turing in 936 finite-state control + infinitely long tape A

More information

On Rice s theorem. Hans Hüttel. October 2001

On Rice s theorem. Hans Hüttel. October 2001 On Rice s theorem Hans Hüttel October 2001 We have seen that there exist languages that are Turing-acceptable but not Turing-decidable. An important example of such a language was the language of the Halting

More information

4.2 The Halting Problem

4.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 information

into a discrete time function. Recall that the table of Laplace/z-transforms is constructed by (i) selecting to get

into a discrete time function. Recall that the table of Laplace/z-transforms is constructed by (i) selecting to get Lecture 25 Introduction to Some Matlab c2d Code in Relation to Sampled Sytem here are many way to convert a continuou time function, { h( t) ; t [0, )} into a dicrete time function { h ( k) ; k {0,,, }}

More information

DIFFERENTIAL EQUATIONS

DIFFERENTIAL EQUATIONS DIFFERENTIAL EQUATIONS Laplace Tranform Paul Dawkin Table of Content Preface... Laplace Tranform... Introduction... The Definition... 5 Laplace Tranform... 9 Invere Laplace Tranform... Step Function...4

More information

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

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

More information

Main Goal I basic concepts of automata and process theory regular languages

Main Goal I basic concepts of automata and process theory regular languages Cure verview Main Gal I baic cncept f autmata and prce thery regular language determinitic finite autmatn DFA nn-determinitic finite autmatn NFA regular exprein finite memry cntext-free language puh-dwn

More information

A Study on Simulating Convolutional Codes and Turbo Codes

A Study on Simulating Convolutional Codes and Turbo Codes A Study on Simulating Convolutional Code and Turbo Code Final Report By Daniel Chang July 27, 2001 Advior: Dr. P. Kinman Executive Summary Thi project include the deign of imulation of everal convolutional

More information

CSE 355 Homework Two Solutions

CSE 355 Homework Two Solutions CSE 355 Homework Two Solution Due 2 Octoer 23, tart o cla Pleae note that there i more than one way to anwer mot o thee quetion. The ollowing only repreent a ample olution. () Let M e the DFA with tranition

More information

Automata Theory CS F-13 Unrestricted Grammars

Automata Theory CS F-13 Unrestricted Grammars Automata Theory CS411-2015F-13 Unrestricted Grammars David Galles Department of Computer Science University of San Francisco 13-0: Language Hierarchy Regular Languaes Regular Expressions Finite Automata

More information

MA/CSSE 474 Theory of Computation

MA/CSSE 474 Theory of Computation MA/CSSE 474 Theory of Computation CFL Hierarchy CFL Decision Problems Your Questions? Previous class days' material Reading Assignments HW 12 or 13 problems Anything else I have included some slides online

More information

Introduction to Turing Machines. Reading: Chapters 8 & 9

Introduction 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 information

FORMAL LANGUAGES, AUTOMATA AND COMPUTABILITY

FORMAL 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 information

March 18, 2014 Academic Year 2013/14

March 18, 2014 Academic Year 2013/14 POLITONG - SHANGHAI BASIC AUTOMATIC CONTROL Exam grade March 8, 4 Academic Year 3/4 NAME (Pinyin/Italian)... STUDENT ID Ue only thee page (including the back) for anwer. Do not ue additional heet. Ue of

More information

ECS 120 Lesson 20 The Post Correspondence Problem

ECS 120 Lesson 20 The Post Correspondence Problem ECS 120 Lesson 20 The Post Correspondence Problem Oliver Kreylos Wednesday, May 16th, 2001 Today we will continue yesterday s discussion of reduction techniques by looking at another common strategy, reduction

More information

TURING MAHINES

TURING 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 information

Lecture 8: Period Finding: Simon s Problem over Z N

Lecture 8: Period Finding: Simon s Problem over Z N Quantum Computation (CMU 8-859BB, Fall 205) Lecture 8: Period Finding: Simon Problem over Z October 5, 205 Lecturer: John Wright Scribe: icola Rech Problem A mentioned previouly, period finding i a rephraing

More information

CSE 105 THEORY OF COMPUTATION

CSE 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 information

1 Unrestricted Computation

1 Unrestricted Computation 1 Unrestricted Computation General Computing Machines Machines so far: DFAs, NFAs, PDAs Limitations on how much memory they can use: fixed amount of memory plus (for PDAs) a stack Limitations on what they

More information

Computational Models Lecture 8 1

Computational 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 information

1 Showing Recognizability

1 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 information

Frames of Reference and Relative Velocity

Frames of Reference and Relative Velocity 1.5 frame of reference coordinate ytem relative to which motion i oberved Frame of Reference and Relative Velocity Air how provide element of both excitement and danger. When high-peed airplane fly in

More information

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

CS5371 Theory of Computation. Lecture 10: Computability Theory I (Turing Machine) CS537 Theory of Computation Lecture : Computability Theory I (Turing Machine) Objectives Introduce the Turing Machine (TM) Proposed by Alan Turing in 936 finite-state control + infinitely long tape A stronger

More information

Section 1 (closed-book) Total points 30

Section 1 (closed-book) Total points 30 CS 454 Theory of Computation Fall 2011 Section 1 (closed-book) Total points 30 1. Which of the following are true? (a) a PDA can always be converted to an equivalent PDA that at each step pops or pushes

More information

DIFFERENTIAL EQUATIONS Laplace Transforms. Paul Dawkins

DIFFERENTIAL EQUATIONS Laplace Transforms. Paul Dawkins DIFFERENTIAL EQUATIONS Laplace Tranform Paul Dawkin Table of Content Preface... Laplace Tranform... Introduction... The Definition... 5 Laplace Tranform... 9 Invere Laplace Tranform... Step Function...

More information

CSE 105 THEORY OF COMPUTATION

CSE 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 4.2 Trace high-level descriptions of algorithms for computational problems. Use

More information

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

Midterm Exam 2 CS 341: Foundations of Computer Science II Fall 2016, face-to-face day section Prof. Marvin K. Nakayama Midterm Exam 2 CS 341: Foundations of Computer Science II Fall 2016, face-to-face day section Prof. Marvin K. Nakayama Print family (or last) name: Print given (or first) name: I have read and understand

More information

Decidability: Reduction Proofs

Decidability: Reduction Proofs Decidability: Reduction Proofs Basic technique for proving a language is (semi)decidable is reduction Based on the following principle: Have problem A that needs to be solved If there exists a problem

More information

Decidability (What, stuff is unsolvable?)

Decidability (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 information

SD & Turing Enumerable. Lecture 33: Reductions and Undecidability. Lexicographically Enumerable. SD & Turing Enumerable

SD & Turing Enumerable. Lecture 33: Reductions and Undecidability. Lexicographically Enumerable. SD & Turing Enumerable SD & Turing Lecture 33: Reductions and Undecidability CSCI 81 Spring, 2012 Kim Bruce Theorem: A language is SD iff it is Turing enumerable. Proof: Spose L is Turing enumerable. Show L is SD. Let w be input.

More information

Theory of Computation (Classroom Practice Booklet Solutions)

Theory of Computation (Classroom Practice Booklet Solutions) Theory of Computation (Classroom Practice Booklet Solutions) 1. Finite Automata & Regular Sets 01. Ans: (a) & (c) Sol: (a) The reversal of a regular set is regular as the reversal of a regular expression

More information

Finite Automata Theory and Formal Languages TMV026/TMV027/DIT321 Responsible: Ana Bove

Finite Automata Theory and Formal Languages TMV026/TMV027/DIT321 Responsible: Ana Bove Finite Automata Theory and Formal Languages TMV026/TMV027/DIT321 Responsible: Ana Bove Tuesday 28 of May 2013 Total: 60 points TMV027/DIT321 registration VT13 TMV026/DIT321 registration before VT13 Exam

More information

Decidable and undecidable languages

Decidable 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 information

CS154 Final Examination

CS154 Final Examination CS154 Final Examination June 7, 2010, 7-10PM Directions: CS154 students: answer all 13 questions on this paper. Those taking CS154N should answer only questions 8-13. The total number of points on this

More information

Automata and Computability. Solutions to Exercises

Automata and Computability. Solutions to Exercises Automata and Computability Solutions to Exercises Spring 27 Alexis Maciel Department of Computer Science Clarkson University Copyright c 27 Alexis Maciel ii Contents Preface vii Introduction 2 Finite Automata

More information

Solving Radical Equations

Solving Radical Equations 10. Solving Radical Equation Eential Quetion How can you olve an equation that contain quare root? Analyzing a Free-Falling Object MODELING WITH MATHEMATICS To be proficient in math, you need to routinely

More information

Hybrid Control and Switched Systems. Lecture #6 Reachability

Hybrid Control and Switched Systems. Lecture #6 Reachability Hbrid Control and Switched Stem Lecture #6 Reachabilit João P. Hepanha Univerit of California at Santa Barbara Summar Review of previou lecture Reachabilit tranition tem reachabilit algorithm backward

More information

Solutions to Old Final Exams (For Fall 2007)

Solutions to Old Final Exams (For Fall 2007) Solutions to Old Final Exams (For Fall 2007) CS 381 (Fall 2002, Fall 2004, Fall 2005, Fall 2006) Yogi Sharma Disclaimer: I, Yogi Sharma, do not claim these solution to be complete, or even to be absolutely

More information