Professional Documents
Culture Documents
Let us assume
p that
p L is regular. Let p be the length specified by the pumping lemma.
Let s be the string a bba . s is a member of L and |w| p. Therefore, the pumping
lemma
k
states that s can be subdivided, s = xyz, such that |xy| p, |y| 1, and xy z L for all k
0.
p
2.
Soln.
Let LR be the regular language.
Now, we know that a language having finite length is always regular.
So, the finite number of words that are to be added will also
form a regular language, LF(say).
Since, regular languages are closed under union operation, therefore, LR LF is also regular.
= {q0, q1,
q2} ({q0, q1}, 1) =
{ q0, q2} {q0, q1, q2},
0) = {q0, q1, q2} {q0,
q1, q2}, 1) = {q0, q2}
{{q0, q2}, 0) = {q0,
q1} {{q0, q2}, 1) =
{q0}
Let q0 = q0, q1 = {q0, q1}, q2 = {q0, q1, q2}, q3 = {q0, q2}.
Then the equivalent DFA is:
II.
I = {q0,
II = {q2,
q1};
q3}
(q0, =
(q0, 1) =
0)
q1 = I
q0
(q1, = =
(q1, =
0)
q2 II
1)
q3
(q2, = =
(q2, =
0)
q2 II
1)
q3
(q3, =
(q3, =
0)
q1 = I
1)
q0
=
I
=
II
=
II
=
I
q0
q3
0, 1,
, 1, .*00 .*00
10, 0,
.*01
q
1
q
, 0, .*1