Question
A linear grammar is a context-free grammar in which no production body has more than one occurrence of one variable. For example, A 0B1 or
A linear grammar is a context-free grammar in which no production body has more than one occurrence of one variable. For example, A 0B1 or A 001 could be productions of a linear grammar, but A BB or A A0B could not. A linear language is a language that has at least one linear grammar.
The following statement is false: "The concatenation of two linear languages is a linear language." To prove it we use a counterexample: We give two linear languages L1 and L2 and show that their concatenation is not a linear language.Which of the following can serve as a counterexample?
a) L1 ={w|w=(aaa)n(ab)n, where n is a positive integer}
L2={w|w=(ab)n, where n is a positive integer}
b) L1 ={w|w=aaacn-1(ab) , where n is a positive integer}
L2={w|w=c(aaa)n, where n is a positive integer}
c) L1 ={w|w=anbn, where n is a positive integer}
L2={w|w=(abb)n(ab)n, where n is a positive integer}
d) L1 ={w|w=(ab)nanbn, where n is a positive integer}
L2={w|w=c(aaa)n(aa)n(ab) n, where n is a positive integer}
Would you plz explain me the solution?
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started