1 / 10

Regular Languages are closed under the regular operations

Regular Languages are closed under the regular operations. Regular Languages. The regular languages are the languages that DFA accept. Since DFA are equivalent with NFA ε , in order to show that L is regular it suffices to construct an NFA ε that recognizes L. Regular Operations.

laszlo
Download Presentation

Regular Languages are closed under the regular operations

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Regular Languages are closed under the regular operations

  2. Regular Languages • The regular languages are the languages that DFA accept. • Since DFA are equivalent with NFAε, in order to show that L is regular it suffices to construct an NFAεthat recognizes L.

  3. Regular Operations The regular operations are the following: • Union (U) • Concatenation (o) • Star (*)

  4. Regular Languages are closed under the Regular Operations • We already showed that the class of regular languages is closed under U. • This proof becomes much easier is we use NFAεinstead of DFA. • We can also show that the set of regular languages is closed under o and *.

  5. Regular Languages are closed under union. • We should prove that if L1 and L2 are regular then L = L1 UL2 is also regular. • Since L1 and L2 are regular there exist DFAs M1 and M2 that accept them. • It suffices to show that there exists an NFAε that accepts L.

  6. An NFAε thataccepts L1 U L2 Suppose M1 and M2 are shown in the first figure. Add an new start state and ε-moves from this to the initial start states of M1 and M2 ε ε

  7. Regular Languages are closed under concatenation • Suppose that L1 and L2 are two regular languages. Then there exist two DFA M1 and M2 that recognize L1 and L2. • We construct an NFAεthat accepts their concatenation L.

  8. An NFAε thataccepts L1o L2 Suppose M1 and M2 are shown in the first figure. Add ε-moves from the accept states of M1 to the start state of M2 and make them non-accepting ε ε

  9. Regular Languages are closed under star operation • Suppose that L is a regular language. Then there exists DFA M that recognizes L. • We construct an NFAεthat accepts L*.

  10. An NFAε thataccepts L1o L2 Suppose M is shown in the first figure. Add a new accept start state. Add ε-moves from the accept states to the previous start state. ε ε ε

More Related