NFSA Simulation with Deque - PowerPoint PPT Presentation

1 / 25
About This Presentation
Title:

NFSA Simulation with Deque

Description:

bottom. state. label. Deque. a. a. a. a. a. a. a. a. a. a. a -1. a. a. a. 2. NFSA Simulation with Deque ... a. Input Text. top. bottom. 3. state. label. Deque ... – PowerPoint PPT presentation

Number of Views:24
Avg rating:3.0/5.0
Slides: 26
Provided by: kevin59
Category:

less

Transcript and Presenter's Notes

Title: NFSA Simulation with Deque


1
NFSA Simulation with Deque
Deque
Input Text
a
a
b
d
a
a
a
a
a
a
a
a
a
a
a
a
-1
a
a
a
top
bottom
state
label
a
?
c
6
7
8
9
?
?
?
d
10
11
?
12
13
start
accept
?
a
?
b
?
1
2
3
4
5
?
2
NFSA Simulation with Deque
Deque
Input Text
a
a
b
d
a
a
a
a
a
a
a
a
a
a
a
a
-1
a
a
a
3
6
top
bottom
Push 3 and 6 since label ?
10
state
?
label
a
?
c
6
7
8
9
?
?
?
d
10
11
?
12
13
start
accept
?
a
?
b
?
1
2
3
4
5
?
3
NFSA Simulation with Deque
Deque
Input Text
a
a
b
d
a
a
a
a
a
a
a
a
a
a
a
a
-1
3
a
a
7
top
bottom
Enqueue 7 since label matches
6
state
a
label
a
?
c
6
7
8
9
?
?
?
d
10
11
?
12
13
start
accept
?
a
?
b
?
1
2
3
4
5
?
4
NFSA Simulation with Deque
Deque
Input Text
a
a
b
d
a
a
a
a
a
a
a
a
a
a
a
7
-1
3
a
a
1
4
top
bottom
Push 1 and 4 since label ?
3
state
?
label
a
?
c
6
7
8
9
?
?
?
d
10
11
?
12
13
start
accept
?
a
?
b
?
1
2
3
4
5
?
5
NFSA Simulation with Deque
Deque
Input Text
a
a
b
d
a
a
a
a
a
a
a
a
a
a
a
7
-1
1
a
a
top
bottom
Do nothing since label mismatches
4
state
b
label
a
?
c
6
7
8
9
?
?
?
d
10
11
?
12
13
start
accept
?
a
?
b
?
1
2
3
4
5
?
6
NFSA Simulation with Deque
Deque
Input Text
a
a
b
d
a
a
a
a
a
a
a
a
a
a
a
7
-1
1
a
a
2
top
bottom
Enqueue 2 since label matches
1
state
a
label
a
?
c
6
7
8
9
?
?
?
d
10
11
?
12
13
start
accept
?
a
?
b
?
1
2
3
4
5
?
7
NFSA Simulation with Deque
Deque
Input Text
a
a
b
d
a
a
a
a
a
a
a
a
a
a
2
7
-1
1
a
a
-1
top
bottom
Enqueue -1 and advance input
-1
state
label
a
?
c
6
7
8
9
?
?
?
d
10
11
?
12
13
start
accept
?
a
?
b
?
1
2
3
4
5
?
8
NFSA Simulation with Deque
Deque
Input Text
a
a
b
d
a
a
a
a
a
a
a
a
a
-1
2
7
-1
1
a
a
top
bottom
Enqueue -1 and advance input
-1
state
label
a
?
c
6
7
8
9
?
?
?
d
10
11
?
12
13
start
accept
?
a
?
b
?
1
2
3
4
5
?
9
NFSA Simulation with Deque
Deque
Input Text
a
a
b
d
a
a
a
a
a
a
a
a
a
-1
2
7
-1
1
a
a
8
top
bottom
Push 8 since label ?
7
state
?
label
a
?
c
6
7
8
9
?
?
?
d
10
11
?
12
13
start
accept
?
a
?
b
?
1
2
3
4
5
?
10
NFSA Simulation with Deque
Deque
Input Text
a
a
b
d
a
a
a
a
a
a
a
a
a
-1
2
7
-1
1
a
a
top
bottom
Do nothing since label mismatches
8
state
c
label
a
?
c
6
7
8
9
?
?
?
d
10
11
?
12
13
start
accept
?
a
?
b
?
1
2
3
4
5
?
11
NFSA Simulation with Deque
Deque
Input Text
a
a
b
d
a
a
a
a
a
a
a
a
a
-1
2
7
-1
1
a
a
3
top
bottom
Push 3 since label ?
2
state
?
label
a
?
c
6
7
8
9
?
?
?
d
10
11
?
12
13
start
accept
?
a
?
b
?
1
2
3
4
5
?
12
NFSA Simulation with Deque
Deque
Input Text
a
a
b
d
a
a
a
a
a
a
a
a
a
-1
2
7
-1
1
a
a
1
4
top
bottom
Push 1 and 4 since label ?
3
state
?
label
a
?
c
6
7
8
9
?
?
?
d
10
11
?
12
13
start
accept
?
a
?
b
?
1
2
3
4
5
?
13
NFSA Simulation with Deque
Deque
Input Text
a
a
b
d
a
a
a
a
a
a
a
a
a
-1
1
7
-1
1
a
a
top
bottom
Do nothing since label mismatches
4
state
b
label
a
?
c
6
7
8
9
?
?
?
d
10
11
?
12
13
start
accept
?
a
?
b
?
1
2
3
4
5
?
14
NFSA Simulation with Deque
Deque
Input Text
a
a
b
d
a
a
a
a
a
a
a
a
a
-1
1
7
-1
1
a
a
2
top
bottom
Enqueue 2 since label matches
1
state
a
label
a
?
c
6
7
8
9
?
?
?
d
10
11
?
12
13
start
accept
?
a
?
b
?
1
2
3
4
5
?
15
NFSA Simulation with Deque
Deque
Input Text
a
a
b
d
a
a
a
a
a
a
a
a
2
-1
1
7
-1
1
a
a
-1
top
bottom
Enqueue -1 and advance input
-1
state
label
a
?
c
6
7
8
9
?
?
?
d
10
11
?
12
13
start
accept
?
a
?
b
?
1
2
3
4
5
?
16
NFSA Simulation with Deque
Deque
Input Text
a
a
b
d
a
a
a
a
a
a
a
-1
2
-1
1
7
-1
1
a
a
3
top
bottom
Push 3 since label ?
2
state
?
label
a
?
c
6
7
8
9
?
?
?
d
10
11
?
12
13
start
accept
?
a
?
b
?
1
2
3
4
5
?
17
NFSA Simulation with Deque
Deque
Input Text
a
a
b
d
a
a
a
a
a
a
a
-1
2
-1
1
7
-1
1
a
a
1
4
top
bottom
Push 1 and 4 since label ?
3
state
?
label
a
?
c
6
7
8
9
?
?
?
d
10
11
?
12
13
start
accept
?
a
?
b
?
1
2
3
4
5
?
18
NFSA Simulation with Deque
Deque
Input Text
a
a
b
d
a
a
a
a
a
a
a
-1
1
-1
1
7
-1
1
a
a
5
top
bottom
Enqueue 5 since label matches
4
state
?
label
a
?
c
6
7
8
9
?
?
?
d
10
11
?
12
13
start
accept
?
a
?
b
?
1
2
3
4
5
?
19
NFSA Simulation with Deque
Deque
Input Text
a
a
b
d
a
a
a
a
a
a
5
-1
1
-1
1
7
-1
1
a
a
top
bottom
Do nothing since label mismatches
1
state
a
label
a
?
c
6
7
8
9
?
?
?
d
10
11
?
12
13
start
accept
?
a
?
b
?
1
2
3
4
5
?
20
NFSA Simulation with Deque
Deque
Input Text
a
a
b
d
a
a
a
a
a
a
5
-1
1
-1
1
7
-1
1
a
a
-1
top
bottom
Enqueue -1 and advance input
-1
state
label
a
?
c
6
7
8
9
?
?
?
d
10
11
?
12
13
start
accept
?
a
?
b
?
1
2
3
4
5
?
21
NFSA Simulation with Deque
Deque
Input Text
a
a
b
d
a
a
a
a
a
-1
5
-1
1
-1
1
7
-1
1
a
a
11
top
bottom
Push 11 since label ?
5
state
?
label
a
?
c
6
7
8
9
?
?
?
d
10
11
?
12
13
start
accept
?
a
?
b
?
1
2
3
4
5
?
22
NFSA Simulation with Deque
Deque
Input Text
a
a
b
d
a
a
a
a
a
-1
5
-1
1
-1
1
7
-1
1
a
a
12
top
bottom
Push 12 since label ?
11
state
?
label
a
?
c
6
7
8
9
?
?
?
d
10
11
?
12
13
start
accept
?
a
?
b
?
1
2
3
4
5
?
23
NFSA Simulation with Deque
Deque
Input Text
a
a
b
d
a
a
a
a
a
-1
5
-1
1
-1
1
7
-1
1
a
a
13
top
bottom
Enqueue 13 since label matches
12
state
d
label
a
?
c
6
7
8
9
?
?
?
d
10
11
?
12
13
start
accept
?
a
?
b
?
1
2
3
4
5
?
24
NFSA Simulation with Deque
Deque
Input Text
a
a
b
d
a
a
a
a
13
-1
5
-1
1
-1
1
7
-1
1
a
a
-1
top
bottom
Enqueue -1 and advance input
-1
state
label
a
?
c
6
7
8
9
?
?
?
d
10
11
?
12
13
start
accept
?
a
?
b
?
1
2
3
4
5
?
25
NFSA Simulation with Deque
Deque
Input Text
a
a
b
d
a
a
a
-1
-1
5
-1
1
-1
1
7
-1
1
a
a
top
bottom
STOP match found
13
state
label
a
?
c
6
7
8
9
?
?
?
d
10
11
?
12
13
start
accept
?
a
?
b
?
1
2
3
4
5
?
Write a Comment
User Comments (0)
About PowerShow.com