computation theory - What is the context free grammar for the complement of the double word over 0,1? -
l = {ww | What is the complimentary complimentary CFG {0,1} *}? L1 = {w1w | W {0,1} *}, L0 = {w0w | W {0,1} *}
These languages can be defined by the following CFGs: S0 / 1 - & gt; | 0 S 1 S1 0 S1 | 1 s <
Now see L3: L3 = (L1) U (L2) U (L1 L2) U (L2L1)
This context is free from the close of union and closing
Let's prove that L3 is the language for which we are searching. First of all we have seen that it is related to all the possible heterogeneous length words. Even for the word of the length, if they are in the language, there is a pair of terminals, at least, which is different from both sides of the word. Call this pair A and B. Each word can also be divided into this way:
(x_1 ^ m) (a) (x_2 ^ m) (y_1 ^ n) (b) (y_2 ^ N)
And it is absolutely fine (L1L2) U (L2L1) U (L2L1)
This means that CFG language Are not closed under the supplement.
Comments
Post a Comment