56 PS7 Solutions

56 PS7 Solutions - Handout #56 May 25, 2010 CS103 Robert...

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

View Full Document Right Arrow Icon
Handout #56 CS103 May 25, 2010 Robert Plummer Problem Set #7 Solutions All problems except #4 are from Sipser. 1. Exercise 1.31, p. 88, part a. Suppose that M is a DFA that recognizes A. Construct an NFA M' that recognizes A R as follows: Keep all the states of M and reverse the direction of all the arrows. The accept state of M' is the start state of M. Add a new state to M' as the start state, and add an - transition to every accept state of M. The construction of this NFA shows that AR is regular by Corollary 1.40. 2. Exercise 2.2, p. 128, part a. This grammar generates A: This grammar generates B: S R T S TR R aR | T aTb | T bTc | R cR | Both A and B are CFG's, and A B = {a n b n c n | n 0). We know this language is not context-free, so the class of context-free languages is not closed under intersection. 3. Exercise 2.4, p. 128, parts b, c. (c)
Background image of page 1

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

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

This document was uploaded on 02/08/2011.

Page1 / 2

56 PS7 Solutions - Handout #56 May 25, 2010 CS103 Robert...

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