{[ promptMessage ]}

Bookmark it

{[ promptMessage ]}

MoreCFL

# MoreCFL - Harvard CS 121 and CSCI E-207 Lecture 11 CFL...

This preview shows pages 1–5. Sign up to view the full content.

Harvard CS 121 and CSCI E-207 Lecture 11: CFL Closure Properties and Non-Context-Free Languages Harry Lewis October 8, 2009 Reading: Sipser, pp. 119-128.

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

View Full Document
Harvard CS 121 & CSCI E-207 October 8, 2008 Closure Properties of CFLs Thm (last time): The CFLs are the languages accepted by PDAs Thm: The CFLs are closed under Union Concatenation Kleene * Intersection with a regular set 1
Harvard CS 121 & CSCI E-207 October 8, 2008 The intersection of a CFL and a regular set is a CFL Pf sketch: Let L 1 be CF and L 2 be regular L 1 = L ( M 1 ) , M 1 a PDA L 2 = L ( M 2 ) , M 2 a DFA Q 1 = state set of M 1 Q 2 = state set of M 2 Construct a PDA with state set Q 1 × Q 2 which keeps track of computation of both M 1 and M 2 on input. 2

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

View Full Document
Harvard CS 121 & CSCI E-207 October 8, 2008 Q: Why doesn’t this argument work if M 1 and M 2 are both PDAs? In fact, the intersection of two CFLs is not necessarily CF. And the complement of a CFL is not necessarily CF (PS4). Q: How to prove that languages are not context free?
This is the end of the preview. Sign up to access the rest of the document.

{[ snackBarMessage ]}