MHB Creating DFA's for $\Sigma=\{0,1\}$ Languages

  • Thread starter Thread starter mathmari
  • Start date Start date
AI Thread Summary
The discussion focuses on creating Deterministic Finite Automata (DFA) for various languages over the alphabet $\Sigma=\{0, 1\}$. Participants are seeking validation of their DFA designs for specific language criteria, such as strings starting with 1 and ending with 0, containing at least three 1s, or having a length of at least 3 with the third symbol being 0. There is a particular emphasis on ensuring that the DFA correctly accepts or rejects specific strings, like 1010 for the first language. Additionally, hints are requested for constructing DFAs for the last three languages mentioned. The conversation highlights collaborative problem-solving in automata theory.
mathmari
Gold Member
MHB
Messages
4,984
Reaction score
7
Hey! :o

I have to draw the DFA's for the following languages:
$\Sigma=\{0, 1\}$

  1. $$\{w \mid w \text{ starts with } 1 \text{ and ends with } 0 \}$$
  2. $$\{w \mid w \text{ contains at least 3 } 1\}$$
  3. $$\{w \mid w \text{ contains the substring } 0101\}$$
  4. $$\{w \mid w \text{ has length at least } 3 \text{ and the third symbol is } 0\}$$
  5. $$\{w \mid w \text{ starts with } 0 \text{ and has an odd length, or with } 1 \text{ and has an even length} \}$$
  6. $$\{w \mid w \text{ doesn't contain the substring } 110\}$$
  7. $$\{w \mid \text{ the length of } w \text{ is smaller than or equal to } 5\}$$
  8. $$\{w \mid w \text{ is any string besides } 11 \text{ and } 111\}$$
  9. $$\{w \mid \text{ in each odd position of } w \text{ there is a } 1\}$$
  10. $$\{w \mid w \text{ contains at least two } 0 \text{ and at most one } 1\}$$
  11. $$\{\epsilon , 0\}$$
  12. $$\{w \mid w \text{ contains an even number of } 0, \text{ or exactly two } 1\}$$
  13. the empty set
  14. all strings besides the empty one.
I have done the following:

View attachment 4142

Could you tell me if it is correct?? (Wondering)

Could you give me some hints how we could find the DFA of the last three languages ?? (Wondering)
 

Attachments

  • DFA's.png
    DFA's.png
    30.5 KB · Views: 95
Last edited by a moderator:
Physics news on Phys.org
Hey mathmari! (Wave)

I'll just pick up number 1 for now: w starts with 1 and ends with 0.
Hmm... so 1010 would be part of the language wouldn't it? (Thinking)
Does your DFA accept 1010? (Wondering)
 
I like Serena said:
I'll just pick up number 1 for now: w starts with 1 and ends with 0.
Hmm... so 1010 would be part of the language wouldn't it? (Thinking)
Does your DFA accept 1010? (Wondering)

It doesn't accept 1010... (Headbang)

Should it be maybe as followed?? (Wondering)

View attachment 4151
 

Attachments

  • DFA_1.png
    DFA_1.png
    3.1 KB · Views: 104
Or have I done something wrong?? (Wondering)
 
mathmari said:
It doesn't accept 1010... (Headbang)

Should it be maybe as followed?? (Wondering)

mathmari said:
Or have I done something wrong?? (Wondering)

No worries. That's it. (Nod)

Number 2 looks fine to me. (Happy)

So let me randomly pick up number 10.
Logically we have to build up a tree that starts as a binary tree where we either accept a 0 to the left and a 1 to the right.
That is, until we can decide what is acceptable or not. (Thinking)
 

Similar threads

Back
Top