JNTU

JNTU B.Tech III FORMAL LANGUAGES AND AUTOMATA THEORY Previous Question Paper (February - 2022 - R18)

B.Tech | III | I | R18 | February - 2022

Answer PaperPaper Code: 155BKMaximum Marks: 75Time: 3 hours

Answer any five questions. All questions carry equal marks.

Main

115 marks
a

Design a FA for the Language which accepts odd number of 0’s and odd number of 1’s over input alphabet Σ = {0,1}.

7 marks

Answer

To accept strings with an odd number of 0s and an odd number of 1s over Σ = {0, 1}, we define a DFA with four states representing the parity of 0s and 1s: q0 (even 0s, even 1s), q1 (odd 0s, even 1s), q2 (even 0s, odd 1s), and q3 (odd 0s, odd 1s).

  1. Start state: q0.
  2. Accepting state: q3.
  3. Transitions:
    • δ(q0, 0) = q1, δ(q0, 1) = q2
    • δ(q1, 0) = q0, δ(q1, 1) = q3
    • δ(q2, 0) = q3, δ(q2, 1) = q0
    • δ(q3, 0) = q2, δ(q3, 1) = q1
b

Convert the following NFA into equivalent DFA (figure 1).

8 marks

Answer

To convert an NFA to a DFA, we use the subset construction method. Let the NFA states be Q = {A, B, C} with transitions: δ(A, 0) = {A, B}, δ(A, 1) = {A}, δ(B, 1) = {C}, δ(C, 0) = {B}.

  1. Start state of DFA is {A}.
  2. For state {A}: δ({A}, 0) = {A, B}, δ({A}, 1) = {A}.
  3. For state {A, B}: δ({A, B}, 0) = {A, B}, δ({A, B}, 1) = {A, C}.
  4. For state {A, C}: δ({A, C}, 0) = {A, B}, δ({A, C}, 1) = {A}.
  5. The DFA states are {A}, {A, B}, and {A, C}. If C is the accepting state in the NFA, then any subset containing C (i.e., {A, C}) is an accepting state in the DFA.
215 marks
a

Convert the following NFA with ε into equivalent NFA without ε (figure 2).

7 marks

Answer

Sign in to view the complete answer paper.

b

Design a Moore machine to count number of b’s in a given input string with a’s and b’s.

8 marks

Answer

Sign in to view the complete answer paper.

315 marks
a

Construct the Finite Automation to accept the regular expression

1*01(0+11)*
.

7 marks

Answer

Sign in to view the complete answer paper.

b

Find the minimum state automata for the following DFA (figure 3).

8 marks

Answer

Sign in to view the complete answer paper.

415 marks
a

Obtain a regular expression for the following FA (figure 4).

7 marks

Answer

Sign in to view the complete answer paper.

b

Check whether the following two FSM’s are equivalent or not (figure 5).

8 marks

Answer

Sign in to view the complete answer paper.

515 marks
a

Construct the Context Free Grammar for the Language

L= { 02n1m | n≥0, m≥0}
.

7 marks

Answer

Sign in to view the complete answer paper.

b

Construct the CFG for the PDA M given by the transition function δ.

8 marks

Answer

Sign in to view the complete answer paper.

615 marks
a

Design Non deterministic PDA for the language

L= { wwR | w ∈ (0+1)* }
by empty stack.

7 marks

Answer

Sign in to view the complete answer paper.

b

Show that the following grammar is ambiguous or not:

S → AB | aaB, A→a | Aa, B→b

8 marks

Answer

Sign in to view the complete answer paper.

715 marks
a

Find the GNF equivalent to the following:

S → AA | 0, A → SS | 1

7 marks

Answer

Sign in to view the complete answer paper.

b

Show that

L={anbncn | n≥0}
is not a context free language.

8 marks

Answer

Sign in to view the complete answer paper.

815 marks
a

Give an overview of recursively enumerable language.

7 marks

Answer

Sign in to view the complete answer paper.

b

Obtain the solution for the following post’s correspondence problem:

A= { 100, 0, 1 }, B = { 1, 100, 00 }

8 marks

Answer

Sign in to view the complete answer paper.

About this paper

This page contains the question paper of FORMAL LANGUAGES AND AUTOMATA THEORY from JNTU for B.Tech CSE III I, February - 2022, R18.

For the solved question paper with answers, switch to the Answer Paper tab.

Other papers in FORMAL LANGUAGES AND AUTOMATA THEORY

Loading Question Papers

Fetching data from database...