If we were to have a trap state in a DFA and we are converting it to a regular expression, how exactly would I incorporate that into the regex? Let's say our language only accepts a*, and my DFA has a start state/final state with a a loop, and once I get a b it goes into a trap. Would the regex simply be a* meaning we ignore the b?
1 Answer
$\begingroup$
$\endgroup$
Yes, since the automaton can never accept after reading a $b$.