Chapter Seven:

Regular Expressions

Docsity.com

The first time a young student sees the mathematical constant , it

looks like just one more school artifact: one more arbitrary symbol

whose definition to memorize for the next test. Later, if he or she

persists, this perception changes. In many branches of mathematics

and with many practical applications, keeps on turning up. "There

it is again!" says the student, thus joining the ranks of

mathematicians for whom mathematics seems less like an artifact

invented and more like a natural phenomenon discovered.

So it is with regular languages. We have seen that DFAs and

NFAs have equal definitional power. It turns out that regular

expressions also have exactly that same definitional power: they can

be used to define all the regular languages, and only the regular

languages. There it is again!

Docsity.com

Outline

•7.1 Regular Expressions, Formally Defined

•7.2 Regular Expression Examples

•7.3 For Every Regular Expression, a Regular

Language

•7.4 Regular Expressions and Structural

Induction

•7.5 For Every Regular Language, a Regular

Expression

Docsity.com

Concatenation of Languages

•The concatenation of two languages L1 and

L2 is L1L2 = {xy | x ∈ L1 and y ∈ L2}

•The set of all strings that can be constructed

by concatenating a string from the first

language with a string from the second

•For example, if L1 = {a, b} and L2 = {c, d} then

L1L2 = {ac, ad, bc, bd}

Docsity.com