[6 points] Let L = { ai bj ck | i, j, k ³ 0, i + k = j }. Prove that L is not regular by using the pumping lemma for regular languages.
[4 points] Using the closure properties of regular languages (regularity-preserving operators) to show that L is not regular.
[10 points] Give context-free grammars generating the following languages.
Notes: No conversion from pushdown automaton to context-free grammar is accepted. For each grammar, give a brief and precise interpretation of each variable (that is, the set of strings derived from the variable).
[5 points] L1, the set of all non-palindromes over alphabet { a, b }. (A palindrome over an alphabet S is a string over S that reads the same backward and forward; what is a non-palindrome?)
[5 points] L2 = { am bn cp dq | m, n, p, q ³ 0, m + n = p + q }. Note that the condition m + n = p + q does not
necessarily imply that m = q and/or n = p.
[10 points] Consider the following language:
L = { z Î { a, b }* | z isoftheform x y x forsome x and y with |x| ³ 1 }.
For examples: The strings aaa (with x = a and y = a) and abababa (with x = a and y = babab, or x = aba and y = b) are in L, but the string aaab is not in L.
Decide if L is regular. Prove your answer.
[10 points] Give the 6-tuple definition of a pushdown automaton for the language:
L = { a, b }* - { w w | w Î { a, b }* }.
Note: A direct construction of a pushdown automaton is required. Give a brief and precise interpretation of the states and transitions of your machine.
File translated from
TEX
by
TTH,
version 3.35. On 20 Apr 2009, 13:17.