dfa - How can I prove if this language is regular or not? -


how can prove if language regular or not?

l = {an bn: n≥1} union {an bn+2: n≥1}

i'll give approach , sketch of prove, there might holes in believe can fill yourself.

the idea use nerode's theorem - show there infinte number of equivalence groups rl - , theorem can derive language irregular.

define 2 types of sets:

  1. g_j = {anb k | n-k = j , k≥1} each j in [-2,-1,0,1,...]
  2. h_j = {aj } each j in [0,1,...]
  3. g_illegal = {0,1}* / (g_j u h_j) [for each j in specified range]

it easy see each x in g_illegal, , each z in {a,b}*: xz not in l.

so, every x,y in g_illegal , each z in {a,b}*: xz in l <-> yz in l.

also, each z in {a,b}* - , each x,y in g_j [same j both]:

  • if z contains a, both xz , yz not in l
  • if z = bj, xz = an bk bj, , since k+j = n - xz in l. same applies y, yz in l.
  • if z = bj+2, xz = an bk bj+2, , since k+j+2 = n+2 - xz in l. same applies y, yz in l.
  • otherwise, x bi such i≠j , i≠j+2, , both xz , yz not in l.

so, every j , every x,y in g_j , each z in {a,b}*: xz in l <-> yz in l.

prove same every h_j using same approach.

also, easy show each x g_j u h_j, , each y in g_illegal - z = bj, xz in l , yz not in l.
for x in g_j, , y in h_i, z = abj+1 - easy see xz not in l , yz in l.
it easy see x,y in g_j , g_i respectively or x, y in h_j, h_i - z = bj: xz in l while yz not.

we proved sets created equivalence relations rl nerode's theorem, , since have infinite number of these sets, each equivalence relation rl [we have h_j , g_j every j] - we can derive nerode's theorem language l irregular.


Comments

Popular posts from this blog

delphi - How to convert bitmaps to video? -

jasper reports - Fixed header in Excel using JasperReports -

python - ('The SQL contains 0 parameter markers, but 50 parameters were supplied', 'HY000') or TypeError: 'tuple' object is not callable -