Use pumping lemma to prove that the language {anb2n| n>0, and w is in {a, b}* } is not a regular language.
Given Language - {anb2n| n>0, and w is in {a, b}* }
Pumping Lemma states that
For any language L, there exists an integer n, such that for all
x ∈ L with |x| ≥ n, there exists u,v, w ∈ Σ*, such that x = uvw,
and
(1) |uv| ≤ n
(2) |v| ≥ 1
(3) for all i ≥ 0: uv^iw ∈ L
To prove that the language is not regular we have show that there exist alteast one string such that it is not in the language (i.e it has to fail pumping lemma Test)
let X=ab2 (n=1) where pumping length = 3
u= ,v = a and w = b2
and on pumping 'a'(i.e v) once, we get a2b2 which doesn't belong to the given language
so the given is not regular language
Get Answers For Free
Most questions answered within 1 hours.