3

Design a FA to accept L, where L = {Strings in which ‘a’ always appears tripled} over the input set Σ = {a, b}.

This is my solution (A is start state):

DFA

From what I understand the question doesn't say it should always contain "a", it should also accept strings like {b,bb,bbb}. Is this correct?

  • 3
    Welcome to SO! This looks correct to me, assuming [A] is marked as a start state. However, it does reject strings like `"aaaa"` which could be valid depending on the interpretation of the question. In this example, `"a"` is quadrupled, but you could interpret that as two overlapping triples. I think your interpretation is more reasonable, but you might want to get clarification to resolve the ambiguity. Same for `"bababa"`, in which a "triple" of `"a"`s appear, but they're not adjacent. Again, probably not the intent, but good to clarify that. – ggorlen Feb 19 '20 at 16:31
  • 1
    A couple of links that might be relevant on a quick search: [1](http://courses.washington.edu/css448/zander/Notes/reg343ans.txt) and [2](https://www.slideshare.net/hadiha12/automata-theory-76299839) – ggorlen Feb 19 '20 at 16:37

1 Answers1

1

Your solution appears right to me! It really depends on the interpretation of the question. I also interpreted that a's could also be separated, as long as they were always tripled.

abbabbbab should be accepted as a's are tripled always, come in threes.

You should make sure of that! I also did this FA in the case above, but my generic understanding of the question would be your interpretation which looks fine!

FA automata tripled a's

M.K
  • 1,464
  • 2
  • 24
  • 46