Download as pdf or txt
Download as pdf or txt
You are on page 1of 6

IIMT COLLEGE OF ENGINEERING, GREATER NOIDA

B TECH
MODEL PAPER-1
THEORY OF AUTOMATA AND FORMAL LANGUAGE (BCS-402)
----------------------------------------------------------------------------------------------------------------------------------
Note: Attempt all Sections. If require any missing data; then choose suitably.

SECTION-A
1. Attempt all questions in brief. 2 x 10 = 20
Q no. Question Marks CO
a. What are the different representational techniques of finite automata? 2 1
b. What do you understand by grammar? 2 1
c. Differentiate between DFA and NFA. 2 2
d. What do you mean by ε-Closure in FA? 2 2
e. What do you understand Ambiguity in CFG? 2 3
f. State Arden’s Theorem. 2 4
g. Discuss Turing thesis. 2 5

SECTION-B
2. Attempt any three of the following: 10 x 3 = 30
Q no. Question Marks CO
a. Construct a DFA for ternary number divisible by 4 7 1

b. Write the regular expression for the following language: 7 2


i) L= {abnw : n≥3,w€(a,b)+}
ii) L= { anbm : (n+m) is even}
c. Determine the FA accepted by the language described by the regular expression: 7 3
(0+1)*0(0+1)*0(0+1)* over the alphabet {0,1} and also mention the accepted language ?
d. Construct a PDA accepting the set of all strings over {a,b} with equal number of 7 4
a’s and b’s.
e. Design a PDA for the language L= {WWT | W= (a+b)* } 7 5

SECTION C
3. Attempt any one part of the following: 10 x 1 = 10
a. Construct a Moore machine which is equivalent to the Mealy machine M given 7 1
below:

Present State Next State


a=0 a=1
State Output State Output
→q1 q1 1 q2 0
q2 q4 1 q4 1
q3 q2 1 q3 1
q4 q3 0 q1 1
b. Construct a minimum state automata equivalent to a DFA whose transition table is as 7 1
follows where q3 and q4 are final state.

4. Attempt any one part of the following: 10 x 1 = 10

Q no. Question Marks CO


a. Find the regular expression corresponding to the finite automata given below: 7 2

b. Give regular expression for the following languages on { a,b,c} 7 2


All the strings containing exactly one “a”
All the strings containing no more than three a’s

5. Attempt any one part of the following: 10 x 1 = 10

Q no. Question Marks CO


a Explain Closure properties of regular language. 7 3
b. What do you mean by ambiguity in a grammar? Show that the grammar given 7 3
below is ambiguous. S→a| abSb | aAb, A→bS | aAAb.

6. Attempt any one part of the following: 10 x 1 = 10


Q no. Question Marks CO
a. Generate CFG for the given PDA M is defined as 7 4
M = ({q0, q1}, {0,1} {x, z0}, δ, q0, z0, q1) where δ is given as follows:
δ (q0,1, z0) = (q0, xz0)
δ (q0,1, x) = (q0, xx)
δ (q0,0, x) = (q0, x)
δ (q0, ε, x) = (q1, ε)
δ (q1, ε, x) = (q1, ε)
δ (q1,0, x) = (q1, xx)
δ (q1,0, z0) = ( q1, ε)
b. Construct a PDA equivalent to the following CFG: S→0BB, B→0S | 1S | 0. Test 7 4
whether 0104 is in N (A).

7. Attempt any one part of the following: 10 x 1 = 10


Q no. Question Marks CO
a. Explain the basic model of a turing machine and design the turing machine that 7 5
can accept the following language.
L = {anb2n | n ≥1}
b. Design a Turing Machine for the language: 7 5
L={an bncn | n>=1}
IIMT COLLEGE OF ENGINEERING, GREATER NOIDA
B TECH
MODEL PAPER-2
THEORY OF AUTOMATA AND FORMAL LANGUAGE (BCS-402)
----------------------------------------------------------------------------------------------------------------------------------
Note: Attempt all Sections. If require any missing data; then choose suitably.

SECTION-A
1. Attempt all questions in brief. 2 x 10 = 20
Q no. Question Marks CO
a. Derive the CFG for (a+b)* 2 1
b. Give the formal definition of Moore machine. 2 1
c. Explain Chomsky Hierarchy. 2 2
d. What is regular Expression? Write various applications of regular expression. 2 2
e. Explain pumping lemma for context free language. 2 3
f. Write down the Closure properties of CFL. 2 4
g. Draw the graphical representation for PDA. 2 5

SECTION-B
2. Attempt any three of the following: 10 x 3 = 30
Q no. Question Marks CO
a. i) Design a FA which accepts set of strings containing exactly four 1’s in every 7 1
string over alphabet ∑= {0, 1}

b. ii) Define
Write short Finite Automata (FA).
notes on: 7 2
i) Church’s Thesis
ii) Recursive and Recursive Enumerable Language
c. i) Reduce the following grammar to CNF, S→abSb | a | aAb, A→bS | aAAb . 7 3
ii) Explain Chomasky classification of grammar.
d. Design a PDA for the language L= {WWT | W= (a+b)* } 7 4
e. Construct a turing machine that enumerates {xnynzn | n≥1}. 7 5

SECTION C
3. Attempt any one part of the following: 10 x 1 = 10
a. Construct a DFA equivalent to the NFA 7 1

b. Construct a minimum state automaton equivalent to the DFA given in the picture. 7 1

4. Attempt any one part of the following: 10 x 1 = 10

Q no. Question Marks CO


i i
a. Show that L= { 0 1 | i≥1}is not a regular. 7 2
b. State pumping lemma for regular language. Prove that the language L= {a p | p is 7 2
prime} is not regular.

5. Attempt any one part of the following: 10 x 1 = 10

Q no. Question Marks CO


a Describe about the derivation tree and draw the derivation tree for the 7 3
production rules given as follows –
E=E+E
E=E*E
E=a|b|c
b. A context free grammar G is given by the following productions: 7 3
E→E+E|E-E|E∗E|E^E|N N→0|1|2|3|4|5|6|7|8|9
Determine whether the grammar G is ambiguous or not.If ambiguous then construct an
unambiguous grammar equivalent to G.

6. Attempt any one part of the following: 10 x 1 = 10


Q no. Question Marks CO
n 2n
a. Give a deterministic PDA for the language L= { a cb : n≥1} over the alphabet 7 4
∑={a,b,c}. Specify the acceptance state.
b. Design a two stack PDA for the language L={a n bncn | n>=1} 7 4
7. Attempt any one part of the following: 10 x 1 = 10
Q no. Question Marks CO
a. Write short notes on: 7 5
(i) Variants of Turing Machine
(ii) Post Correspondence problem
(iii) Universal Turing Machine
b. State and prove that post correspondence problem (PCP) is decidable. 7 5

You might also like