Title: Regular Expressions and Non-regular Languages
1Regular Expressions and Non-regular Languages
- http//cis.k.hosei.ac.jp/yukita/
2Expressions and their values
3Definition 1.26
4The values of atomic expressions
5Example 1.27
6Units for the binary operations
7Theorem 1.28
- A language is regular if and only if some regular
expression describes it. - We break down this theorem as follows.
- Lemma 1.29
- If a language is described by a regular
expression, then it is regular. - Lemma 1.32
- If a langulage is regular, then it is described
by a regular expression.
8Proof of Lemma 1.29
a
Next three slides
9Case 4 Let N1, N2, and N correspond to R1, R2,
and R, respectively.
N
N1
e
e
N2
10Case 5 Let N1, N2, and N correspond to R1, R2,
and R, respectively.
N
e
e
11Case 6 Let N1 and N correspond to R1 and R,
respectively.
N
e
e
e
12Generalized Nondeterministic Finite Automaton
- is roughly a NFA in which the transition arrows
may have regular expressions as labels. - We assume the following standard form for
convenience, which can always be attained with an
easy modification. - There is only one accept state and different from
the start state. - The start state has transition arrows going to
every other state but no arrows coming in from
any other state. - There is only a single accept state, and it has
arrows coming in from any other state but no
arrows going to any other state. - Except for the start and accept states, one arrow
goes from every state to every other state and
also from each state to itself.
13Standard Form of GNFA
...
14Standard Form of GNFA
15Equivalent GNFA with one fewer state
R4
qi
qj
qi
qj
R1
R3
qrip
R2
16Definition 1.33
17Computation with GNFA
18Converting GNFA
19Claim 1.34 For any GNFA G, Convert(G) is
equivalent to G.
20Proof continued
21Non-regularity
22Theorem 1.37 Pumping Lemma
23Proof of Th 1.37
24Example 1.38
25Example 1.39
26Alternative proof of 1.39
27Example 1.40
28Example 1.41 Unary Language
29Example 1.42 Pumping Down
30Problem 1.41 Differential Encoding
0
1
1
0xx1
0xx0
0
0
qstart
0
1xx0
1xx1
1
1
1
0