Deterministic Finite Automata
Lecture 4
1
Deterministic Finite Automata Lecture 4 1 Input Accepted by a DFA - - PowerPoint PPT Presentation
Deterministic Finite Automata Lecture 4 1 Input Accepted by a DFA We say that M accepts w * if M , on input w , starting from the start state s , reaches a final state i.e., * ( s,w ) F L ( M ) is the set of all strings accepted by
1
CS 374
2
CS 374
3
CS 374
4
CS 374 Reject state
1 0,1 1 1 2 abbreviation B 1 A 2 B B B A 4 A 3 A B A
A AB ABB ABBA
1 3 1 2 1 1 1
0*11* (A+B)*ABBA
5
6
CS 374
7
CS 374
8
s a
CS 374
9
1
s a
CS 374
10
1 1
s a
CS 374
11
1 1
b s a
CS 374
12
1 1
b s a 0,1
CS 374
13
1 1 b s a 0,1
CS 374
14
CS 374
15
CS 374
16
1 1 b s a 0,1
CS 374
17
1 1 b’ s’ a’ 0,1
CS 374
18
1 1 00 s
CS 374
19
1 1 00 s
CS 374
20
1 1 00 s 1 00,1
CS 374
21
1 1 00 s 1 00,1
CS 374
22
1 1 00 s 1 1 00,11 00,1
CS 374
23
1 1 00 s 1 1 00,11 00,1
CS 374
24
1 1 00 s 1 1 00,11 0,1 00,1
CS 374
25
1 1 00 s 1 1 00,11 0,1 00,1
CS 374
26
1 1 00 s 1 1 00,11 0,1 00,1
CS 374
27
1 1 00 s 1 1 00,11 0,1 00,1
CS 374
28
1 1 00 s 1 1 00,11 0,1 00,1
CS 374
29
1 1 00 s 1 1 00,11 0,1 00,1
CS 374
1 1 b s a 0, 1 1 b’ s’ a’ 0,
contains two zeroes in a row AND two ones in a row.
for machine 1 AND on the accept state for machine 2, then I accept.
CS 374
L(M1) contains 00 L(M2) :contains 11
31
1 1 b s a 0, 1 1 b’ s’ a’ 0,
CS 374
L(M1) contains 00 L(M2) :contains 11
32
1 1 b s a 0, 1 1 b’ s’ a’ 0,
CS 374
L(M1) contains 00 L(M2) :contains 11
33
1 1 b s a 0, 1 1 b’ s’ a’ 0,
CS 374
L(M1) contains 00 L(M2) :contains 11
34
1 1 b s a 0, 1 1 b’ s’ a’ 0, 1
CS 374
L(M1) contains 00 L(M2) :contains 11
35
1 1 b s a 0, 1 1 b’ s’ a’ 0, 1
CS 374
L(M1) contains 00 L(M2) :contains 11
36
1 1 b s a 0, 1 1 b’ s’ a’ 0, 1
CS 374
L(M1) contains 00 L(M2) :contains 11
37
1 1 b s a 0, 1 1 b’ s’ a’ 0, 1 1
CS 374
L(M1) contains 00 L(M2) :contains 11
38
1 1 b s a 0, 1 1 b’ s’ a’ 0, 1 1
CS 374
L(M1) contains 00 L(M2) :contains 11
39
1 1 b s a 0, 1 1 b’ s’ a’ 0, 1 1
CS 374
L(M1) contains 00 L(M2) :contains 11
40
1 1 b s a 0, 1 1 b’ s’ a’ 0, 1 1 1 1 1 0,1 1 1 1
CS 374
L(M1) contains 00 L(M2) :contains 11
41
1 1 b s a 0, 1 1 b’ s’ a’ 0, 1 1 1 1 1 0,1 1 1 1
CS 374
Where M1 accepts L1 M2 accepts L2
42
CS 374
Where M1 accepts L1 M2 accepts L2
43
CS 374
44
1 1 b s a 0, 1 1 b’ s’ a’ 0, 1 1 1 1 0,1 1 1 1
CS 374
45
1 1 1 1 0,1 1 1
1 1 b s a 0, 1 1 b’ s’ a’ 0, 1
CS 374
46
1 1 1 1 0,1 1 1
1 1 b s a 0, 1 1 b’ s’ a’ 0, 1
CS 374
Where M1 accepts L1 M2 accepts L2
47
CS 374
Where M1 accepts L1 M2 accepts L2
48
CS 374
Where M1 accepts L1 M2 accepts L2
49
CS 374
Where M1 accepts L1 M2 accepts L2
50
CS 374
product
expressions
expressions
DFA’s
51