Is this language regular ? [automata]

94 Views Asked by At

Is this a regular language :

$$L = \{w : w \in \{a,b\}^*\text{ and }abw = wba\}$$

Does my automata only need to start with $a$ and $b$, then loop on $a,b$ and finish with $b\to a$, or do I don't understand the language?

1

There are 1 best solutions below

2
On BEST ANSWER

HINT: Prove that $L$ is generated by the regular expression $(ab)^*a$. If $L_0$ is the language generated by $(ab)^*a$, it’s not hard to prove that $L_0\subseteq L$. To prove that $L\subseteq L_0$, I suggest assuming that $L_0\setminus L\ne\varnothing$, letting $w$ be a word of minimal length in $L_0\setminus L$, and getting a contradiction. (If you get stuck finding the contradiction, feel free to leave a comment.)