Question

In: Computer Science

L = {a r b s | r, s ≥ 0 and s = r 2}....

L = {a r b s | r, s ≥ 0 and s = r 2}. Show that L is not regular using the pumping lemma

Solutions

Expert Solution

Here r, s 0

In order to achieve this language we need to keep count of how many 'a' do we have then only we can count the number of 'b', but we know that final state machine cannot keep count of anything, so this cannot be designed using final state machines and all languages that cannot be designed using final state machines are said to be non-regular.

LET US PROVE THIS USING PUMPING LEMMA

CONDITIONS MUST BE TRUE TO PROVE REGULAR

1. for every i0

2. |Y|>0

3.

Assume that language L is regular

let pumping length = P

therefore, String =

let p = 3

therefore string is = aaabbbbbbbbb

let's divide the string into three parts X, Y and Z

(I've divided the string using different colours)

and then we will check whether or not by considering all ways to divide string into X, Y and Z, if it will not follow this then due to contradiction, the language will not be regular.

to check this we are going to assume i =2.

case 1: The Y is in the 'a' part

a a abbbbbbbbb

=>

a aa abbbbbbbbb

we know that , according to that, , but here a=4 and b = 9

therefore, , this does not lie in our language

case 2: The Y is in the 'b' part

aaabb bbbb bbb

=>

aaabb bbbbbbbb bbb

we know that , according to that, , but here a=3 and b = 13

therefore, , this also does not lie in our language

case 3: The Y is in the 'a' and 'b' part

aa abbb bbbbbb

=>

aa abbbabbb bbbbbb

this is not following the pattern

therefore this also does not lie in our language


So we have showed that none of these can satisfy all the 3 pumping conditions at the same time

let us consider the third condition

In case 1, |XY| = 2 (i.e length of XY is 2) and p is 3, therefore |XY| < P (CONDITION SATISFIED)

In case 2, |XY| = 9, and p is 3, therefore |XY| > P (CONDITION NOT SATISFIED)

In case 3, |XY| = 6, and p is 3, therefore |XY| > P (CONDITION NOT SATISFIED)

SO LANGUAGE L CANNOT BE PUMPED, AS IT CONTRADICTED OUR ASSUMPTION THAT LANGUAGE L IS REGULAR.

Hence, we have proved that language L is not regular using pumping lemma.


Related Solutions

Let L = {0 r | r = s 2 , s a positive integer}. Give...
Let L = {0 r | r = s 2 , s a positive integer}. Give the simplest proof you can that L is not regular using the pumping lemma.
Let L = {x = a r b s c t | r + s =...
Let L = {x = a r b s c t | r + s = t, r, s, t ≥ 0}. Give the simplest proof you can that L is not regular using the pumping lemma.
# O W L S f(O,W,L,S) 0 0 0 0 0 0 1 0 0 0...
# O W L S f(O,W,L,S) 0 0 0 0 0 0 1 0 0 0 1 0 2 0 0 1 0 1 3 0 0 1 1 1 4 0 1 0 0 0 5 0 1 0 1 1 6 0 1 1 0 1 7 0 1 1 1 X 8 1 0 0 0 0 9 1 0 0 1 0 10 1 0 1 0 0 11 1 0 1 1 1 12 1...
Let L = {x = a^rb^s | r + s = 1mod2}, I.e, r + s...
Let L = {x = a^rb^s | r + s = 1mod2}, I.e, r + s is an odd number. Is L regular or not? Give a proof that your answer is correct.
For each pair a, b with a ∈ R − {0} and b ∈ R, define...
For each pair a, b with a ∈ R − {0} and b ∈ R, define a function fa,b : R → R by fa,b(x) = ax + b for each x ∈ R. (a) Prove that for each a ∈ R − {0} and each b ∈ R, the function fa,b is a bijection. (b) Let F = {fa,b | a ∈ R − {0}, b ∈ R}. Prove that the set F with the operation of composition of...
Player 1 chooses T, M, or B. Player 2 chooses L, C, or R. L C...
Player 1 chooses T, M, or B. Player 2 chooses L, C, or R. L C R T 0, 1 -1, 1 1, 0 M 1, 3 0, 1 2, 2 B 0, 1 0, 1 3, 1 (a) Find all strictly dominated strategies for Player 1. You should state what strategy strictly dominates them. (b) Find all weakly dominated strategies for Player 2.  You should state what strategy weakly dominates them. (c) Is there any weakly dominant strategy for player...
a.)Find the length of the spiral r=θ for 0 ≤ θ ≤ 2 b.)Find the exact...
a.)Find the length of the spiral r=θ for 0 ≤ θ ≤ 2 b.)Find the exact length of the polar curve r=3sin(θ), 0 ≤ θ ≤ π/3 c.)Write each equation in polar coordinates. Express as a function of t. Assume that r>0. - y=(−9) r= - x^2+y^2=8 r= - x^2 + y^2 − 6x=0 r= -    x^2(x^2+y^2)=2y^2 r=
Given the differential equation y''+y'+2y=0,  y(0)=−1,  y'(0)=2y′′+y′+2y=0,  y(0)=-1,  y′(0)=2 Apply the Laplace Transform and solve for Y(s)=L{y}Y(s)=L{y}. You do not...
Given the differential equation y''+y'+2y=0,  y(0)=−1,  y'(0)=2y′′+y′+2y=0,  y(0)=-1,  y′(0)=2 Apply the Laplace Transform and solve for Y(s)=L{y}Y(s)=L{y}. You do not need to actually find the solution to the differential equation.
for square matrices A and B show that [A,B]=0 then [A^2,B]=0
for square matrices A and B show that [A,B]=0 then [A^2,B]=0
Consider the following model of interacting species: R' = R(2 + 3R − S) S' =...
Consider the following model of interacting species: R' = R(2 + 3R − S) S' = S(1 − S + 4R) (a) Find all the equilibrium points, and determine the type of those points which are in the first quadrant (including those on the axes) (b) Plot the phase portrait of the system. (c) If the initial conditions are R(0) = 1 and S(0) = 1, what will be the population size of each species when t → ∞?
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT