12.07.2015 Views

Closure properties of regular languages

Closure properties of regular languages

Closure properties of regular languages

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

36 45§ 4*¢¦)©2$§£% /-¦0/¨.$"¤"¦1$§ ++££§ £)£ ¨ )¨¨¨ *§ ¦*¨.¨ ¦¤$¢¢¤¤££5 6 43* § 4©) ¦¨+¨+¥¥¨¨ExamplesProve the following <strong>languages</strong> to be non-<strong>regular</strong>:For anyIN, take%, then pump.For anyIN, takein the splitis prime 7 " 87 ¨for a prime£. Then pump tois not prime.such that+.02140 Languages and Parsing, MF, Fall 2004 – p.7/8<strong>Closure</strong> <strong>properties</strong> <strong>of</strong> <strong>regular</strong> <strong>languages</strong>The <strong>regular</strong> <strong>languages</strong> are closed underunion — i.e., the union <strong>of</strong> two <strong>regular</strong> <strong>languages</strong> is <strong>regular</strong>,intersection — i.e., the intersection <strong>of</strong> two reg. lang.s is <strong>regular</strong>,complement — i.e., the complement <strong>of</strong> a reg. lang. is <strong>regular</strong>,difference — i.e., the difference <strong>of</strong> two reg. lang.s is <strong>regular</strong>,reversal — i.e., the language containing the reversals <strong>of</strong> thewords <strong>of</strong> a reg. lang. is <strong>regular</strong>,closure (Kleene star) — i.e., the closure <strong>of</strong> a reg. lang. is <strong>regular</strong>,concatenation — i.e., the catenation <strong>of</strong> two reg. lang.s is <strong>regular</strong>,homomorphism — i.e., the image <strong>of</strong> a reg. lang. under ahomomorphism is <strong>regular</strong>,inverse homomorphism — i.e., the pre-image <strong>of</strong> a reg. lang.under a homomorphism is <strong>regular</strong>.02140 Languages and Parsing, MF, Fall 2004 – p.8/8

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!