






Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!







b
b b
b
a^
a^
a
a
b
b b
b
a^
a^
a
a
-^ Intuition behind the construction– Every time you get a problem “strings such that
-^ In the previous example, S
→^ S4 is the “core”
-^ In the previous example, once you have checked it for 3 consecutive a’s, youare “trapped” in the
rejecting
state S4. That is subsequent a’s and b’s will
cause you to remain in S4 and you cannot ever go to the accepting statefrom S4• Mark all the other states as accepting state
In the previous example, assume we had a sub-sequence “aab”. Uponencountering the “b”, we start over by going back to state S
-^ Note– If you construct a DFA “D” for checking
-^ Intuition behind the construction– Every time you get a problem “strings such that
-^ In the previous example, S
→^ S3 is the “core”
In the previous example, once you have checked it for twoconsecutive b’s, you are “trapped” in the accepting state S3. That is,subsequent a’s, b’s and c’s will cause you to remain in theaccepting state
In the previous example, assume we had a sub-sequence “ba”.Upon encountering the “b”, we start over by going back to state S
condition x
and add
transitions to states of the DFA that checks for condition y
and vice-versa