# Formal Languages and Automata Theory [duplicate]

How can I show that $L = \{a^m b^n \mid (m > n \text{ or } m < n) \text{ and } m, n ≥ 1\}$ is not a regular language.

• What have you tried? What is stopping you? What techniques have you learned for doing such a proof? Regarding style, it is nicer to ask for help rather than using a sentence that looks like an order, for example "How do I show ...., I tried this and that but I am stuck because ...". Also, -please use LaTeX for writing math. – babou Jun 5 '15 at 21:41

## 1 Answer

Use the fact that compliment of a regular grammar is regular. So assume this language is regular. Then its complement is also regular that is $$\{{a^{m}b^{m}}\}$$ Now using pumping lemma you can show that this is not a regular language.

• Thanks for restricting to a hint, since this looks a lot like a homework question. However, you're missing a step: the complement of the language in the question isn't the one you give. – David Richerby Jun 5 '15 at 19:20
• I deliberately left it incomplete and gave away the major step – iLoveCamelCase Jun 5 '15 at 19:27