Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                

Flat PQP

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

Code: 20A05503 R20

B.Tech IlYear I Semester (R20) Regular Examinations January 2023


FORMAL LANGUAGE & AUTOMATA THEORY
(Common to IT &CSE)
Time: 3 hours Max. Marks: 70
PART - A
(Compulsory Question)
1 Answer the following: (10 X 02 = 20 Marks)
(a) Show that (0*1")' = (0+1)". 2M
(b) Define Moore machine. 2M
(c) What is Arden's Theorem? 2M
(d) What is the closure property of regular sets? 2M
(e) What is linear grammar? 2M
() What is the differentiate between CFG and Regular Language? 2M
(g) Define push down automata. 2M
(h) What is the informal definition of PDA? 2M
() List the types of Turing machine. 2M
() Define linear bounded automaton. 2M

PART- B
(Answer all the questions: 05 X 10 = 50 Marks)
2 Define DFA and regular expression. DFA accepts all Strings corresponding to the expression 10M
1"01(0+11)". Also explain how to convert a regular expression to DFA.
OR
3 (a) Discuss Chomsky's Hierarchy of formal languages. 5M
(b) Explain briefly about DFA and NFA. 5M

4 Prove that the language L= {a" b" |n>=1) is not regular using pumping lemma with procedure. 10M
OR
5 (a) Construct a DFA for the regular expression consisting of any number of a's and b's. 5M
(b) Explain about the identity rules of regular expression. 5M

6 Simplify the following context free grammar. (Here, Astands for epsilon (¬)). S’TUJV 10M
T’ aTblA
U’cU| A
V’aVcW
OR
7 (a) What is linear grammar? Explain in detail with example. 4M
(b) Explain the closure properties of context free languages. 6M

8 Explain Deterministic Push down Automata with example. 10M


OR
9 Construct PDA from the following Grammar. 10M
S’ aB
B-’bA/b
A>ba

10 Explain the various types of Turing machine with examples. 10M


OR
11 Explain what undecidable problem is and post correspondence problem. 10M
Code: 20A05503 R20
B.Tech lI Year I Semester (R20) Supplementary Examinations August 2023
FORMAL LANGUAGES AND AUTOMATA THEORY
(Common to IT &CSE)
Time: 3 hours Max. Marks: 70
PART -A
(Compulsory Question)

Answer the following: (10 X 02 = 20 Marks)


(a) Define NDFA with Null moves. 2M
(b) Design a DFA to accept 0's and 1's such that string having a substring 01. 2M
(c) Define Pumping Lemma. 2M
(d) Give an English description of the following regular expressionr= a(a+b)*ab. 2M
(e) State pumping lemma theorem for Context-Free Languages. 2M
() Under, what circumstances you can say that the grammar symbol is useless. 2M
(g) The acceptance of a string using Push-Down Automata (PDA) can be described through the 2M
instantaneous description. Define it.
(h) Define Deterministic PDA. 2M
(() The set of languages that one can recognize on Turing machines is much bigger than that of 2M
PDA and FA. Justify with an example.
() Define Recursively Enumerable language. 2M

PART- B
(Answer all the questions: 05 X 10 = 50 Marks)
2 (a) Explain the procedure for conversion of NFA to DFA. 4M
(b) Prove That for every NFA there exists an equivalent DFA which accepts the same language. 6M
OR
3 (a) Construct NFA without [ for a given NFA with E where g0 and g2 are the initial and final states 5M
respectively.
C

q0 q0 q1
q1 q1 q2

q2 e q2

(b) Construct a Moore machine to determine the residue modulo 3 of the input treated as a binary 5M
number.
4 (a) Convert ((01)+. (0 + 1"))" into Finite Automata. 5M
(b) State and Prove Ardens Theorem. 5M
OR
5 (a) State and Prove Pumping Lemma for Regular Sets. 5M
(b) Obtain a CFG to obtain the balanced set of parentheses (i.e. every left parenthesis should 5M
match with the corresponding right parentheses) using the symbols ('and ).
6 (a) Define Chomosky's classification of grammar. 5M
(b) Explain Normal Forms and convert the following grammar into GNF S>(S)/SoS/-S/p/q. 5M
OR
Contd. in Page 2

Page 1 of 2
www.android,previousquestionpapers.com / www.previousquestionpapers.com | https:/helegram.me/jntua

www.android.universityupdates.in/ www.niversityupdates. in | htps:/telegram.me/jntua

Code: 20A05503 R20

7 (a) Define CNF and convert the following Grammar into CNF 6M
S >aAB / Aba
A ’aA la/Ba
B’ ab /bc.
(b) Write the procedure for conversion of CNF to GNF. 4M

8 Find the corresponding PDAs for the following CFGs:


(a) S0SO|1S1 |AA’ 2B3B’23 |31. 5M
(b) S’ bX| aYX ’bXX|aSlaY’ aÝ Y| bS|b. 5M
OR
9 (a) Design a PDA to accept odd no of 0's and even no of 1's. 5M
(b) Explain procedure for conversion of grammar to PDA. 5M

10 (a) Design a Turing Machine for (m" n). 6M


(b) Explain about Halting problem. 4M
OR
11 (a) Explain about Post Correspondence Problem. 5M
(b) Define Halting Problem. 5M
8aHN5 ASol
Code: 20A05503
R20

B.Tech llI Year ISemester (R20) Regular &Supplementary Examinations January 2024
FORMAL LANGUAGES AND AUTOMATA THEORY
(Common to Information Technology and Computer Soence &Engineering)
Max. Marks. 70
Time: 3 hours
PART-A
(Compulsory Question)

Answer the following (10 X02 = 20 Marks)


(a) Write applications of finite automata 2M
(b) Compare DFA and NFA 2M
(c) Simplify regular expression aab ab)' " bab ab). 2M
2M
(4) Write short notes on "Homomophism cosue property of regular language. 2M
(e) Define Left recursion wth an eumple
0 Construca Contest Fre Grammar (CFG) (ar alanguage containa even length palindrome over 2M
Z=(0. 1)
(gy What is mean by Instantaneous Descripton of pushdown Autoata? 2M
(h) Mention merits of two stacks POA over sing'e stack POA 2M
2M
0) Define undecidabie problem
2M
0) Compare recursive and recursvely enumer abie languages
PART- 8
(Angwer al the questons 05 X 10 = 50 Atarks)
SM
2 (a) Design a DFA for accaptng of language nat contains subatring as aba over alphabet
E (a, b).
(b) Construct equivalent DFA for the foloirgNFA 5M
8

(Q Q:)
OR
3 (a) Design a Moore Machine to count number of substrings 101 in a given string over alphabet 5M
E(0, 1).
(b) Let Lbe a set accepted by a NFA show that there exists a DFA hat accepts L. 5M

4 (a) Discuss the identity rules of Regular Expressions. 5M


5M
(b) Apply pumping lemma for the language L={a]nis prime) and prove that it is not regular.
OR
5 Find regular expression for the followng automata. 10M

0 1

q &
Q, are final stales.

Contd. In Page 2
Page 1 of 2
Code: 20A05503 R20
from
(a) Define Chomsky Nornal Form (CNF)? Write procedure to construct equivalent CNF
5M
6
grammar.
5M
(b) Convert the following grammar to Chomsky Normal Form (CNF).
S ABA
A’ aA|¬
B’ bB|¬.
OR
5M
7 (a) Define ambiguous grammar? Show that the following grammar is ambiguous?
S’ aSbS| a | bSaS | b|e
(b) Write the closure properties of context free languages with an example. 5M

8 (a) Design a PDA to recognize the language L =(ww*|Win (0+1)"). 5M


(b) Compare Deterministic PDA and NPDA. 5M
OR
9 Construct equivalent PDA for the following grammar. 10M
S aAB |a
A’ aA | bB | bA | aB |¬
B bA|aB |¬

10 Design a TM for the language L= (a' b" c|m, n, >= 1). Write the acceptance for the input 10M
string aaabbbbbccc.
OR
11 (a) Discuss in brief about types of Turing Machines (TM). 5M
(b) llustrate post correspondence problem with an example. 5M

Page 2 of 2

You might also like