
Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
Prepare for your exams
Study with the several resources on Docsity
Earn points to download
Earn points by helping other students or get them with a premium plan
This is assignment for Theory of Automata course. It was given at AMET University by Dr. Inayat Hussain. It includes: Automata, Set, Theory, Relations, Languages, Alphabet, Context, Free, Grammar, DFA, Regular, Expression, Deterministic, Finite
Typology: Exercises
1 / 1
This page cannot be seen from the preview
Don't miss anything!

(Units: 1–4)
Note: All questions are compulsory. All questions carry equal marks.
Q. 1 (a) Explain the following terms: i) Automata ii) Set theory (b) For the following relations between sets A and B mention if they are one to one and/or onto: A = {a, b, c} B = {1, 2, 3} i) {(a, 1), (b, 1), (c, 1)} ii) {(a, 2), (b, 2), (c, 2)} iii) {(a, 1), (a, 2), (b, 2), (c, 3)} iv) {(a, 2), (b, 1), (c, 2)}
Q. 2 (a) Consider the language S*, where S= {aa b}. How many words does this language have of length 4? Of length 5? What can be said in general? (b) Construct a regular expression defining each of the following languages over the alphabet ∑ = {a b}: i) All words in which a appears tripled, if at all. This means that every clump of a’s contains 3 or 6 or 9 or 12… a’s. ii) All strings that have exactly one double letter in them. iii) All words that contain exactly two b’s or exactly three b’s, not more.
Q. 3 (a) What is the relationship between regular languages and context free grammars? Discuss them? Construct a language that can be generated by CFG. (b) Consider the Context Free Grammar S a X X a x | b X | Λ Y b b b (a +b) * b b b (a + b) *
Q. 4 (a) Construct an example DFA? Write down the steps to convert FA into DFA. (b) Construct DFA for the following regular expression: (a / b) * a b *.
Q. 5 Define and explain the following terms. (a) Context Free Grammar (b) Regular Expression (c) Context Free Language (d) Deterministic Finite Automata