cs373 fa10 hw7sol - Solutions for Problem Set 7 CS 373:...

Info iconThis preview shows pages 1–2. Sign up to view the full content.

View Full Document Right Arrow Icon

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: Solutions for Problem Set 7 CS 373: Theory of Computation Assigned: October 19, 2010 Due on: October 26, 2010 at 10am Homework Problems Problem 1 . [Category: Proof] Solve problem 3.19. Hint: Use the result of problem 3.18, which was solved in discussion 9. Solution: Let L be an infinite recursively enumerable language. Since L is recursively enumerable, L has an enumerator M such that E ( M ) = L . Problem 3.18 (and the discussion section problem) provide a characterization of decidable languages in terms of enumeration: L 1 is decidable iff there is an enumerator M 1 that enumerates the strings of L 1 in lexicographic order. We will use this result to identify an infinite, decidable subset of L . Consider the following enumerator M 1 last-string = Run M Whenever M outputs a string (say) w if ((last-string = ) or ( w > last-string) then output w last-string = w In the above algorithm, the check w > last-string means that w is after last-string in the lexicographic ordering. Observe that, by construction, any string output by M...
View Full Document

Page1 / 3

cs373 fa10 hw7sol - Solutions for Problem Set 7 CS 373:...

This preview shows document pages 1 - 2. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online