Differences
This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision | ||
lfa:2022:lab05-mindfa [2022/11/09 09:19] pdmatei |
lfa:2022:lab05-mindfa [2022/11/12 20:49] (current) alexandra.udrescu01 |
||
---|---|---|---|
Line 12: | Line 12: | ||
5.1.1. Identify a pair of states which are **indistinguishable**. (Solve the exercise for the 2 given DFAs.) | 5.1.1. Identify a pair of states which are **indistinguishable**. (Solve the exercise for the 2 given DFAs.) | ||
- | /* | ||
<hidden DFA 1> | <hidden DFA 1> | ||
Line 34: | Line 33: | ||
</hidden> | </hidden> | ||
- | */ | ||
5.1.2. Identify a pair of final or non-final states which are **distinguishable**. The pair must be distinguished by a word different from the empty word. (Solve the exercise for the 2 given DFAs.) | 5.1.2. Identify a pair of final or non-final states which are **distinguishable**. The pair must be distinguished by a word different from the empty word. (Solve the exercise for the 2 given DFAs.) | ||
- | /* | ||
<hidden DFA 1> | <hidden DFA 1> | ||
Line 52: | Line 49: | ||
</hidden> | </hidden> | ||
- | */ | ||
5.1.3. Compute the table of indistinguishable states for the DFA. (Solve the exercise for the 2 given DFAs.) | 5.1.3. Compute the table of indistinguishable states for the DFA. (Solve the exercise for the 2 given DFAs.) | ||
- | /* | ||
<hidden DFA 1><note tip> | <hidden DFA 1><note tip> | ||
Line 205: | Line 200: | ||
</hidden> | </hidden> | ||
- | */ | ||
===== 5.2. Minimisation ====== | ===== 5.2. Minimisation ====== | ||
Line 211: | Line 205: | ||
5.2.1. Minimise the DFA. (Solve the exercise for the 2 given DFAs.) | 5.2.1. Minimise the DFA. (Solve the exercise for the 2 given DFAs.) | ||
- | /* | ||
<hidden DFA 1> | <hidden DFA 1> | ||
Line 225: | Line 218: | ||
</hidden> | </hidden> | ||
- | */ | ||
5.2.2. How can we algorithmically determine if two minimal DFAs accept the same language? | 5.2.2. How can we algorithmically determine if two minimal DFAs accept the same language? | ||
- | /* | ||
<hidden><note tip> | <hidden><note tip> | ||
Line 242: | Line 233: | ||
</note></hidden> | </note></hidden> | ||
- | */ | ||
5.2.3. Determine if the following regexes are **equivalent**: $math[(1\cup\epsilon)(00^*1)^*0^*] and $math[(10\cup 0)^*(01 \cup 1)^*(0 \cup \epsilon)] | 5.2.3. Determine if the following regexes are **equivalent**: $math[(1\cup\epsilon)(00^*1)^*0^*] and $math[(10\cup 0)^*(01 \cup 1)^*(0 \cup \epsilon)] | ||
- | /* | ||
<hidden> | <hidden> | ||
Line 252: | Line 241: | ||
</hidden> | </hidden> | ||
- | */ | ||
5.2.4. Remember exercise 3.3.4 from Lab3. Show that the two regexes are equivalent: $ E1 = ((ab^*a)^+b)^* $ and $ E2 = (a(b\mid aa)^*ab)^* $ | 5.2.4. Remember exercise 3.3.4 from Lab3. Show that the two regexes are equivalent: $ E1 = ((ab^*a)^+b)^* $ and $ E2 = (a(b\mid aa)^*ab)^* $ | ||
- | /* | ||
<hidden> | <hidden> | ||
Line 348: | Line 335: | ||
</note></hidden> | </note></hidden> | ||
- | */ | ||
5.2.5. (extra) Apply the **Brzozowski** minimisation algorithm on DFA 1. | 5.2.5. (extra) Apply the **Brzozowski** minimisation algorithm on DFA 1. | ||
Line 356: | Line 342: | ||
<note important>Brzozowski minimisation: **minDfa(A) = toDfa(reverse(toDfa(reverse(A))))**</note> | <note important>Brzozowski minimisation: **minDfa(A) = toDfa(reverse(toDfa(reverse(A))))**</note> | ||
- | /* | ||
<hidden> | <hidden> | ||
Line 397: | Line 382: | ||
</hidden> | </hidden> | ||
- | */ | ||
===== Conclusion ===== | ===== Conclusion ===== | ||
Line 408: | Line 392: | ||
* DFA -> minDfa | * DFA -> minDfa | ||
- | **We advise you to include minDfa conversion in your project.** | + | **To get a better performance, include minDfa conversion in your project.** |
</note> | </note> | ||