Prove or disprove the following statement:

If [tex]L_1[/tex] and [tex]L_2[/tex] are non-regular languages, then [tex]L_1 \cup L_2[/tex] is also non-regular.

Answer :

The statement is disproven as it is possible for L₁ U L₂ to be regular while L₁ and L₂ are non-regular languages.

A regular language can be recognized by a finite automaton, whereas a non-regular language cannot. To prove the given statement, consider the following:

  • It is possible for the union of two non-regular languages to be regular. For instance, let L₁ = {aⁿbⁿ | n ≥ 0} and L₂ = {bⁿaⁿ | n ≥ 0}. Both L₁ and L₂ are non-regular as they cannot be recognized by finite automata.

  • However, L₁ U L₂ = {aⁿbⁿ | n ≥ 0} U {bⁿaⁿ | n ≥ 0} can be regular if n = 1, since the finite automaton can distinguish between strings 'ab' and 'ba'.

  • More importantly, there are specific constructions where the union remains non-regular, highlighting that the regularity of the union is not guaranteed simply by the non-regularity of component languages.

Thus, the statement is disproven as it is possible for L₁ U L₂ to be regular even if L₁ and L₂ are non-regular.