SlideShare uma empresa Scribd logo
1 de 5
Baixar para ler offline
www.firstranker.com



      Code :9A05407                                                                                                   1
                         II B.Tech II Semester(R09) Regular Examinations, April/May 2011
                                FORMAL LANGUAGES & AUTOMATA THEORY
                                             (Computer Science & Engineering)
      Time: 3 hours                                                                                     Max Marks: 70
                                               Answer any FIVE questions
                                              All questions carry equal marks
                                                          ⋆⋆⋆⋆⋆

         1. (a) Define an NFA. Draw the transition graph of NFA that accepts the language generated by the regular
                expression (10+01)*1(0+1). Process the string 100111 on the machine.
            (b) Define DFA. Draw the transion graph of the DFA that accepts the language generated by the regular
                expression (a+b)*ba. Process the string abba.
         2. (a) Define NFA-∈. Convert the following NFA-∈ into it’s equivalent NFA.




                Process fue string 101010 on both the machines.



                                                                                               E R
            (b) Define Moore and Melay machines. Convert the following Moore machine into its equivalent Melay machine.




                                                                                N K
                Process the string 111001.

                                                                R A
         3. (a) Construct an NFA-∈ that recognizes the language generated by the regular expression (11+01)*10(0+1)*.

            (b) State pumping lemma for regular languages. Prove that the language of palindromes over the alphabet {a,
                b} is not regular.



                                                  S T
         4. (a) Define a regular grammar. Find the FA that recognizes the language generated by the following right linear
                grammar.
                S → OA/1B/1C



                                  IR
                A → 1A/OC
                B → 1B/O/1
                C → OC/O/1A

                                F
            (b) Define leftmost and right most derivations. Find out the leftmost, right most derivations and draw the
                corresponding derivation trees for the string (a+a)*a in the following grammar.
                E → E + T /T
                T → T ∗ F/F
                F → (E)/a
         5. (a) Eliminate ∈-productions from the following CFG.
                S → ABBAC
                A → AB/a/B
                B → A/CB/AC/b/ ∈
                C→d
            (b) Convert the following CFG into CNF
                S → ABC/BaB
                A → Aa/BaC/a
                B → bBb/a
                C → aC/bC/c
         6. When do you say that a language is recognized or accepted by a PDA? Design a PDA for L = {a1 bj ck /j >= i + k
            and ijk>0}. Process the string aaabbbbbbcc using instantaneous description.
         7. Design a TM for recognizing L = {xx/x ∈ {a, b}∗ }. Show the moves of the TM for the string abaaba and abaabb.
         8. Write short notes on the following:
            (i) NP hard and NP complete problems. (ii) Posts correspondence problem. (iii) Linear Bounded Automata.

                                                            ⋆⋆⋆⋆⋆


                                                      www.firstranker.com
www.firstranker.com



      Code :9A05407                                                                                                       2
                          II B.Tech II Semester(R09) Regular Examinations, April/May 2011
                                 FORMAL LANGUAGES & AUTOMATA THEORY
                                               (Computer Science & Engineering)
      Time: 3 hours                                                                                         Max Marks: 70
                                                   Answer any FIVE questions
                                                  All questions carry equal marks
                                                              ⋆⋆⋆⋆⋆

         1. (a) Define DFA. Draw the transition graph on transition table for the DFA which recognizes L = {x ∈ {a, b}∗ /x
                ends with ba } Process the string bbab.
            (b) Define NFA. Draw the transition graph and transition table of NFA which can recognize (0+11)*0(11+00).
         2. (a) Convert the following NFA into its equivalent DFA. Process the string 0101 on both the machines.




                                                                                                     R
            (b) Define Moore and Melay machines. Convert the following Melay machine into equivalent Moore machine.




                                                                                     K             E
                Process the string 10110 on the FA.

                                                                     A             N
         3. (a) Construct an FA which can recognize the language generated by the regular expression (00+10)*11(0+1).

            (b) Write any eight identify roles for regular expression and any four closure properties of regular sets ( regular
                languages ).




                                                       T           R
         4. (a) Find an FA which can recognize the language generated by the following regular grammar.
                S → 00A/11B



                                                     S
                B → 01/10
                A → 0B/1A/1




                                   IR
                Check the acceptability of 00010.
            (b) Design a CFG that generates strings over the alphabet {a,b} that contain unequal number of a’s and b’s.



                                 F
         5. (a) How do you a eliminate the unit productions from a given CFG? Eliminate the unit productions from the
                following CFG.
                 E → E + T /T
                 T → T ∗ F/F
                 F → (E)/a
            (b) Define CNF for CFGs. Convert the following CFG into its equivalent CNF.
                 S → abA/bB/aba
                 A → b/aB/bA
                 B → aB/aA
         6. (a) Design a PDA for recognizing the language of palindromes over {0,1}. Process the string 00100.
            (b) How do you find out PDA that recognizes the language generated by a CFG? Find the PDA which recognizes
                the language generated by the following CFG.
                S → 01A/1B
                A → 00A/11B/0/1
                B → 1A/0B/0
         7. (a) What are computable functions? Design a TM for computing the multiplication of two given integers.
            (b) Discuss about Church’s hypothesis.
         8. Write brief notes on the following:
            (a) Context Sensitive Languages.
            (b) Universal Tuning Machine.
            (c) Posts correspondence problem.

                                                              ⋆⋆⋆⋆⋆


                                                         www.firstranker.com
www.firstranker.com



      Code :9A05407                                                                                           3
                      II B.Tech II Semester(R09) Regular Examinations, April/May 2011
                             FORMAL LANGUAGES & AUTOMATA THEORY
                                         (Computer Science & Engineering)
      Time: 3 hours                                                                             Max Marks: 70
                                          Answer any FIVE questions
                                         All questions carry equal marks
                                                     ⋆⋆⋆⋆⋆

         1. (a) Draw the transition graph and transition table of an NFA for accepting the strings generated by
                the regular expression (00+11)*10. Process the string 001110.
            (b) Design a DFA for accepting the language of strings over {0,1} that do not contain 10 as substring.
                Process the string 0011.
         2. (a) Find the NFA equivalent to the following NFA-E. Process the string 0112 on both the machines.




            (b) Check the equality of the following FA’S.

                                                                                         E R
                                                                           N K
                                                            R A
                                               S T
                                IR
         3. (a) Find the regular expression for the language recognized by the following FA.




                              F
            (b) State the pumping lemma for regular languages. Prove that the language of all strings over {a,
                b} that contain equal no. of a’s and b’s is not a regular language.
         4. (a) Define a CFG. Find a CFG which generate the strings over the alphabet {0,1} and does not
                contain equal number of 0’s and 1’s. Find the left most derivation, rightmost derivation and
                derivation tree for the string 01100.
            (b) Find a right linear grammar generating the language recognized by the following FA.




                                                  www.firstranker.com
www.firstranker.com




         5. Convert the following CFG into Greibach Normal form
            E → E + T /T
            T → T ∗ F/F
            F → lE/a
         6. (a) Define a PDA. Design a PDA for recognizing
                L = {x ∈ {0, 1}∗ /x = 0i ij ok and j = i + k, i, j, k > 0} Process the string 011100 on the PDA.
            (b) Write the procedure for finding a CFG equivalent to a given PDA.




                                                                                            R
         7. Write brief notes on the following:
            (i) Church’s hypothesis (ii) Counter machines (iii) Computable functions.
         8. Write brief notes on the following:

                                                                                          E
            (i) Linear bounded automata. (ii) Universal tuning machine. (iii) Posts correspondence problem.


                                                                              K
                                                                            N
                                                        ⋆⋆⋆⋆⋆




                                                             R A
                                                S T
                               F IR




                                                   www.firstranker.com
www.firstranker.com



      Code :9A05407                                                                                           4
                      II B.Tech II Semester(R09) Regular Examinations, April/May 2011
                             FORMAL LANGUAGES & AUTOMATA THEORY
                                         (Computer Science & Engineering)
      Time: 3 hours                                                                            Max Marks: 70
                                          Answer any FIVE questions
                                         All questions carry equal marks
                                                     ⋆⋆⋆⋆⋆


         1. (a) What are various operations that can be performed on languages ? Explain with examples.
            (b) Design a DFA that accepts (recognizes) strings containing even no of a’s and odd no of b’s.
                Draw it’s transition diagram and transition tables. Process the string ababb.

         2. (a) Convert the following NFA into DFA.




                                                                                        E R
                 Process the string 0010 on both the machines.



                                                                          N K
            (b) Draw a Moore machine for calculating mod 3 of a given binary number. Find it’s equivalent
                Mealy machine.




                                                            R A
         3. (a) Write any 8 identify rules for regular expressions.
            (b) Write any 4 closure properties of regular sets.



                                                 T
             (c) Prove that the language of palindromes over {a,b} is not a regular language using pumping lemma.




                                               S
         4. (a) Find a right linear grammar for the language (0+1)*10.Draw the transition diagram of the FA
                from the grammar designed.



                                 IR
            (b) Design a CFG for the language of non-palindromes over {a,b}. Find the derivations for the strings
                abad and ababaa.


                               F
         5. (a) What is meant by ambiguous CFG? Prove that the grammar E → E + E/E ∗ E/a is ambiguous.
            (b) Write the procedure for converting a CFG into its equivalent CNF. Convert the following CFG
                into CNF.
                 E → E + T /T
                 T → T ∗ F/F
                 F → (E)/a

         6. (a) Design a PDA for accepting the language of palindromes over {a,b}. Process the string ababa.
            (b) Design a PDA for accepting the language generated by the following CFG.
                S → ab/aA/aB
                 A → aA/a
                 B → bB/b

         7. Design a TM for accepting the strings of language L = {x ∈ {a, b}∗ /x = yy for some y ∈ {a, b}∗ }
            Process the string abab.

         8. (a) Write about Chomsky hierarchy of languages.
            (b) Write a brief note of NP hard and NP complete problems.


                                                        ⋆⋆⋆⋆⋆



                                                   www.firstranker.com

Mais conteúdo relacionado

Mais procurados

Assembly Language Programming By Ytha Yu, Charles Marut Chap 7 (Logic, Shift,...
Assembly Language Programming By Ytha Yu, Charles Marut Chap 7 (Logic, Shift,...Assembly Language Programming By Ytha Yu, Charles Marut Chap 7 (Logic, Shift,...
Assembly Language Programming By Ytha Yu, Charles Marut Chap 7 (Logic, Shift,...Bilal Amjad
 
Arithmetic & logical operations in 8051
Arithmetic & logical operations in 8051Arithmetic & logical operations in 8051
Arithmetic & logical operations in 8051Jay Patel
 
N_Asm Assembly arithmetic instructions (sol)
N_Asm Assembly arithmetic instructions (sol)N_Asm Assembly arithmetic instructions (sol)
N_Asm Assembly arithmetic instructions (sol)Selomon birhane
 
Chap 8 The stack and introduction to procedures & Chapter 9 multiplication an...
Chap 8 The stack and introduction to procedures & Chapter 9 multiplication an...Chap 8 The stack and introduction to procedures & Chapter 9 multiplication an...
Chap 8 The stack and introduction to procedures & Chapter 9 multiplication an...warda aziz
 
Assembly language 8086
Assembly language 8086Assembly language 8086
Assembly language 8086John Cutajar
 
chapter 7 Logic, shift and rotate instructions
chapter 7 Logic, shift and rotate instructionschapter 7 Logic, shift and rotate instructions
chapter 7 Logic, shift and rotate instructionswarda aziz
 
Cs6660 compiler design may june 2016 Answer Key
Cs6660 compiler design may june 2016 Answer KeyCs6660 compiler design may june 2016 Answer Key
Cs6660 compiler design may june 2016 Answer Keyappasami
 
Stack in microprocessor 8085(presantation)
Stack in microprocessor 8085(presantation)Stack in microprocessor 8085(presantation)
Stack in microprocessor 8085(presantation)Safin Biswas
 
Unit 2 assembly language programming
Unit 2   assembly language programmingUnit 2   assembly language programming
Unit 2 assembly language programmingKartik Sharma
 
Assembly language 8086 intermediate
Assembly language 8086 intermediateAssembly language 8086 intermediate
Assembly language 8086 intermediateJohn Cutajar
 
Chapter 6 Flow control Instructions
Chapter 6 Flow control InstructionsChapter 6 Flow control Instructions
Chapter 6 Flow control Instructionswarda aziz
 
Assembly Language Programming By Ytha Yu, Charles Marut Chap 6 (Flow Control ...
Assembly Language Programming By Ytha Yu, Charles Marut Chap 6 (Flow Control ...Assembly Language Programming By Ytha Yu, Charles Marut Chap 6 (Flow Control ...
Assembly Language Programming By Ytha Yu, Charles Marut Chap 6 (Flow Control ...Bilal Amjad
 
assembly language programming and organization of IBM PC" by YTHA YU
assembly language programming and organization of IBM PC" by YTHA YUassembly language programming and organization of IBM PC" by YTHA YU
assembly language programming and organization of IBM PC" by YTHA YUEducation
 
Intermediate code- generation
Intermediate code- generationIntermediate code- generation
Intermediate code- generationrawan_z
 
C the basic concepts
C the basic conceptsC the basic concepts
C the basic conceptsAbhinav Vatsa
 
Multiplication & division instructions microprocessor 8086
Multiplication & division instructions microprocessor 8086Multiplication & division instructions microprocessor 8086
Multiplication & division instructions microprocessor 8086University of Gujrat, Pakistan
 

Mais procurados (19)

Assembly Language Programming By Ytha Yu, Charles Marut Chap 7 (Logic, Shift,...
Assembly Language Programming By Ytha Yu, Charles Marut Chap 7 (Logic, Shift,...Assembly Language Programming By Ytha Yu, Charles Marut Chap 7 (Logic, Shift,...
Assembly Language Programming By Ytha Yu, Charles Marut Chap 7 (Logic, Shift,...
 
Arithmetic & logical operations in 8051
Arithmetic & logical operations in 8051Arithmetic & logical operations in 8051
Arithmetic & logical operations in 8051
 
N_Asm Assembly arithmetic instructions (sol)
N_Asm Assembly arithmetic instructions (sol)N_Asm Assembly arithmetic instructions (sol)
N_Asm Assembly arithmetic instructions (sol)
 
Chap 8 The stack and introduction to procedures & Chapter 9 multiplication an...
Chap 8 The stack and introduction to procedures & Chapter 9 multiplication an...Chap 8 The stack and introduction to procedures & Chapter 9 multiplication an...
Chap 8 The stack and introduction to procedures & Chapter 9 multiplication an...
 
Assembly language 8086
Assembly language 8086Assembly language 8086
Assembly language 8086
 
chapter 7 Logic, shift and rotate instructions
chapter 7 Logic, shift and rotate instructionschapter 7 Logic, shift and rotate instructions
chapter 7 Logic, shift and rotate instructions
 
Cs6660 compiler design may june 2016 Answer Key
Cs6660 compiler design may june 2016 Answer KeyCs6660 compiler design may june 2016 Answer Key
Cs6660 compiler design may june 2016 Answer Key
 
Stack in microprocessor 8085(presantation)
Stack in microprocessor 8085(presantation)Stack in microprocessor 8085(presantation)
Stack in microprocessor 8085(presantation)
 
Chapt 06
Chapt 06Chapt 06
Chapt 06
 
Unit 2 assembly language programming
Unit 2   assembly language programmingUnit 2   assembly language programming
Unit 2 assembly language programming
 
7th semester Computer Science and Information Science Engg (2013 December) Qu...
7th semester Computer Science and Information Science Engg (2013 December) Qu...7th semester Computer Science and Information Science Engg (2013 December) Qu...
7th semester Computer Science and Information Science Engg (2013 December) Qu...
 
Assembly language 8086 intermediate
Assembly language 8086 intermediateAssembly language 8086 intermediate
Assembly language 8086 intermediate
 
Chapter 6 Flow control Instructions
Chapter 6 Flow control InstructionsChapter 6 Flow control Instructions
Chapter 6 Flow control Instructions
 
Assembly Language Programming By Ytha Yu, Charles Marut Chap 6 (Flow Control ...
Assembly Language Programming By Ytha Yu, Charles Marut Chap 6 (Flow Control ...Assembly Language Programming By Ytha Yu, Charles Marut Chap 6 (Flow Control ...
Assembly Language Programming By Ytha Yu, Charles Marut Chap 6 (Flow Control ...
 
Introduction to C programming
Introduction to C programmingIntroduction to C programming
Introduction to C programming
 
assembly language programming and organization of IBM PC" by YTHA YU
assembly language programming and organization of IBM PC" by YTHA YUassembly language programming and organization of IBM PC" by YTHA YU
assembly language programming and organization of IBM PC" by YTHA YU
 
Intermediate code- generation
Intermediate code- generationIntermediate code- generation
Intermediate code- generation
 
C the basic concepts
C the basic conceptsC the basic concepts
C the basic concepts
 
Multiplication & division instructions microprocessor 8086
Multiplication & division instructions microprocessor 8086Multiplication & division instructions microprocessor 8086
Multiplication & division instructions microprocessor 8086
 

Destaque

Undecidable Problem
Undecidable ProblemUndecidable Problem
Undecidable ProblemMGoodhew
 
Decidability of Finiteness of a Context Free Grammer
Decidability of Finiteness of a Context Free GrammerDecidability of Finiteness of a Context Free Grammer
Decidability of Finiteness of a Context Free GrammerZeeshan Masood S
 
Push down automata
Push down automataPush down automata
Push down automataSomya Bagai
 
Chomsky & Greibach Normal Forms
Chomsky & Greibach Normal FormsChomsky & Greibach Normal Forms
Chomsky & Greibach Normal FormsRajendran
 
Normal forms cfg
Normal forms   cfgNormal forms   cfg
Normal forms cfgRajendran
 
Chomsky by zeeshan khan and Raheel Khan
Chomsky by zeeshan khan and Raheel KhanChomsky by zeeshan khan and Raheel Khan
Chomsky by zeeshan khan and Raheel KhanM Khan
 
Simplifiaction of grammar
Simplifiaction of grammarSimplifiaction of grammar
Simplifiaction of grammarlavishka_anuj
 
CNF & Leftmost Derivation - Theory of Computation
CNF & Leftmost Derivation - Theory of ComputationCNF & Leftmost Derivation - Theory of Computation
CNF & Leftmost Derivation - Theory of ComputationDrishti Bhalla
 
Context free grammars
Context free grammarsContext free grammars
Context free grammarsShiraz316
 
Deciability (automata presentation)
Deciability (automata presentation)Deciability (automata presentation)
Deciability (automata presentation)Sagar Kumar
 
PUSH DOWN AUTOMATA VS TURING MACHINE
PUSH DOWN AUTOMATA VS TURING MACHINEPUSH DOWN AUTOMATA VS TURING MACHINE
PUSH DOWN AUTOMATA VS TURING MACHINEAbhishek Shivhare
 
Context free languages
Context free languagesContext free languages
Context free languagesJahurul Islam
 
Cs6503 theory of computation may june 2016 be cse anna university question paper
Cs6503 theory of computation may june 2016 be cse anna university question paperCs6503 theory of computation may june 2016 be cse anna university question paper
Cs6503 theory of computation may june 2016 be cse anna university question paperappasami
 
Context free grammars
Context free grammarsContext free grammars
Context free grammarsRonak Thakkar
 

Destaque (19)

Undecidable Problem
Undecidable ProblemUndecidable Problem
Undecidable Problem
 
Decidability of Finiteness of a Context Free Grammer
Decidability of Finiteness of a Context Free GrammerDecidability of Finiteness of a Context Free Grammer
Decidability of Finiteness of a Context Free Grammer
 
Pumping lemma (1)
Pumping lemma (1)Pumping lemma (1)
Pumping lemma (1)
 
Push down automata
Push down automataPush down automata
Push down automata
 
Chomsky & Greibach Normal Forms
Chomsky & Greibach Normal FormsChomsky & Greibach Normal Forms
Chomsky & Greibach Normal Forms
 
Normal forms cfg
Normal forms   cfgNormal forms   cfg
Normal forms cfg
 
pushdown automata
pushdown automatapushdown automata
pushdown automata
 
Chomsky by zeeshan khan and Raheel Khan
Chomsky by zeeshan khan and Raheel KhanChomsky by zeeshan khan and Raheel Khan
Chomsky by zeeshan khan and Raheel Khan
 
Theory of computation / Post’s Correspondence Problems (PCP)
Theory of computation / Post’s Correspondence Problems (PCP)Theory of computation / Post’s Correspondence Problems (PCP)
Theory of computation / Post’s Correspondence Problems (PCP)
 
Properties of cfg
Properties of cfgProperties of cfg
Properties of cfg
 
Simplifiaction of grammar
Simplifiaction of grammarSimplifiaction of grammar
Simplifiaction of grammar
 
CNF & Leftmost Derivation - Theory of Computation
CNF & Leftmost Derivation - Theory of ComputationCNF & Leftmost Derivation - Theory of Computation
CNF & Leftmost Derivation - Theory of Computation
 
Context free grammars
Context free grammarsContext free grammars
Context free grammars
 
Deciability (automata presentation)
Deciability (automata presentation)Deciability (automata presentation)
Deciability (automata presentation)
 
PUSH DOWN AUTOMATA VS TURING MACHINE
PUSH DOWN AUTOMATA VS TURING MACHINEPUSH DOWN AUTOMATA VS TURING MACHINE
PUSH DOWN AUTOMATA VS TURING MACHINE
 
Context free languages
Context free languagesContext free languages
Context free languages
 
Cs6503 theory of computation may june 2016 be cse anna university question paper
Cs6503 theory of computation may june 2016 be cse anna university question paperCs6503 theory of computation may june 2016 be cse anna university question paper
Cs6503 theory of computation may june 2016 be cse anna university question paper
 
Context free grammars
Context free grammarsContext free grammars
Context free grammars
 
Turing machines
Turing machinesTuring machines
Turing machines
 

Semelhante a 9 a05407 formal_languages_automata_theor_yfr_2029

V cse cs6503 model qb1 1
V  cse cs6503  model qb1 1V  cse cs6503  model qb1 1
V cse cs6503 model qb1 1Ezhumalai p
 
Problem set2 | Theory of Computation | Akash Anand | MTH 401A | IIT Kanpur
Problem set2 | Theory of Computation | Akash Anand | MTH 401A | IIT KanpurProblem set2 | Theory of Computation | Akash Anand | MTH 401A | IIT Kanpur
Problem set2 | Theory of Computation | Akash Anand | MTH 401A | IIT KanpurVivekananda Samiti
 
Automata And Compiler Design
Automata And Compiler DesignAutomata And Compiler Design
Automata And Compiler Designguestac67362
 
Cs2303 theory of computation all anna University question papers
Cs2303 theory of computation all anna University question papersCs2303 theory of computation all anna University question papers
Cs2303 theory of computation all anna University question papersappasami
 
TOC Solutions-Adi.pdf
TOC Solutions-Adi.pdfTOC Solutions-Adi.pdf
TOC Solutions-Adi.pdfAdiseshaK
 
TOC_Solutions-Adi.pdf
TOC_Solutions-Adi.pdfTOC_Solutions-Adi.pdf
TOC_Solutions-Adi.pdfAdiseshaK
 
Cs2303 theory of computation may june 2016
Cs2303 theory of computation may june 2016Cs2303 theory of computation may june 2016
Cs2303 theory of computation may june 2016appasami
 
Cs6503 theory of computation november december 2016
Cs6503 theory of computation november december 2016Cs6503 theory of computation november december 2016
Cs6503 theory of computation november december 2016appasami
 
Cs2303 theory of computation november december 2015
Cs2303 theory of computation november december 2015Cs2303 theory of computation november december 2015
Cs2303 theory of computation november december 2015appasami
 
Problem set1 | Theory of Computation | Akash Anand | MTH 401A | IIT Kanpur
Problem set1 | Theory of Computation | Akash Anand | MTH 401A | IIT KanpurProblem set1 | Theory of Computation | Akash Anand | MTH 401A | IIT Kanpur
Problem set1 | Theory of Computation | Akash Anand | MTH 401A | IIT KanpurVivekananda Samiti
 
Assembly language solution
Assembly language  solutionAssembly language  solution
Assembly language solutionAhsan Riaz
 
CS2303 Theory of computation April may 2015
CS2303 Theory of computation April may  2015CS2303 Theory of computation April may  2015
CS2303 Theory of computation April may 2015appasami
 
Expected questions tc
Expected questions tcExpected questions tc
Expected questions tcSANTOSH RATH
 
Expected questions tc
Expected questions tcExpected questions tc
Expected questions tcSANTOSH RATH
 

Semelhante a 9 a05407 formal_languages_automata_theor_yfr_2029 (20)

V cse cs6503 model qb1 1
V  cse cs6503  model qb1 1V  cse cs6503  model qb1 1
V cse cs6503 model qb1 1
 
Problem set2 | Theory of Computation | Akash Anand | MTH 401A | IIT Kanpur
Problem set2 | Theory of Computation | Akash Anand | MTH 401A | IIT KanpurProblem set2 | Theory of Computation | Akash Anand | MTH 401A | IIT Kanpur
Problem set2 | Theory of Computation | Akash Anand | MTH 401A | IIT Kanpur
 
Model toc
Model tocModel toc
Model toc
 
TOC question bank.pdf
TOC question bank.pdfTOC question bank.pdf
TOC question bank.pdf
 
Question bank toafl
Question bank toaflQuestion bank toafl
Question bank toafl
 
Automata And Compiler Design
Automata And Compiler DesignAutomata And Compiler Design
Automata And Compiler Design
 
Cs2303 theory of computation all anna University question papers
Cs2303 theory of computation all anna University question papersCs2303 theory of computation all anna University question papers
Cs2303 theory of computation all anna University question papers
 
TOC_Solutions-Adi.pdf
TOC_Solutions-Adi.pdfTOC_Solutions-Adi.pdf
TOC_Solutions-Adi.pdf
 
TOC Solutions-Adi.pdf
TOC Solutions-Adi.pdfTOC Solutions-Adi.pdf
TOC Solutions-Adi.pdf
 
TOC_Solutions-Adi.pdf
TOC_Solutions-Adi.pdfTOC_Solutions-Adi.pdf
TOC_Solutions-Adi.pdf
 
Cs 73
Cs 73Cs 73
Cs 73
 
Cs2303 theory of computation may june 2016
Cs2303 theory of computation may june 2016Cs2303 theory of computation may june 2016
Cs2303 theory of computation may june 2016
 
Cs6503 theory of computation november december 2016
Cs6503 theory of computation november december 2016Cs6503 theory of computation november december 2016
Cs6503 theory of computation november december 2016
 
Cs2303 theory of computation november december 2015
Cs2303 theory of computation november december 2015Cs2303 theory of computation november december 2015
Cs2303 theory of computation november december 2015
 
UNIT 2.pdf
UNIT 2.pdfUNIT 2.pdf
UNIT 2.pdf
 
Problem set1 | Theory of Computation | Akash Anand | MTH 401A | IIT Kanpur
Problem set1 | Theory of Computation | Akash Anand | MTH 401A | IIT KanpurProblem set1 | Theory of Computation | Akash Anand | MTH 401A | IIT Kanpur
Problem set1 | Theory of Computation | Akash Anand | MTH 401A | IIT Kanpur
 
Assembly language solution
Assembly language  solutionAssembly language  solution
Assembly language solution
 
CS2303 Theory of computation April may 2015
CS2303 Theory of computation April may  2015CS2303 Theory of computation April may  2015
CS2303 Theory of computation April may 2015
 
Expected questions tc
Expected questions tcExpected questions tc
Expected questions tc
 
Expected questions tc
Expected questions tcExpected questions tc
Expected questions tc
 

Mais de Rajesh Yaramadi

Mais de Rajesh Yaramadi (8)

O2
O2O2
O2
 
Flat [ www.uandi star.org]
Flat [ www.uandi star.org]Flat [ www.uandi star.org]
Flat [ www.uandi star.org]
 
Finite automata
Finite automataFinite automata
Finite automata
 
Dbms[uandi star.org]
Dbms[uandi star.org]Dbms[uandi star.org]
Dbms[uandi star.org]
 
Compute1 dfa
Compute1 dfaCompute1 dfa
Compute1 dfa
 
Co [uandi star.org]
Co [uandi star.org]Co [uandi star.org]
Co [uandi star.org]
 
Chapter2
Chapter2Chapter2
Chapter2
 
07 a0123 sustainable development briefing note
07 a0123 sustainable development briefing note07 a0123 sustainable development briefing note
07 a0123 sustainable development briefing note
 

Último

Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobeapidays
 
A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?Igalia
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024The Digital Insurer
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfsudhanshuwaghmare1
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...Neo4j
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUK Journal
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...apidays
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...DianaGray10
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024The Digital Insurer
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsMaria Levchenko
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoffsammart93
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...apidays
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Drew Madelung
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProduct Anonymous
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CVKhem
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...Martijn de Jong
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024The Digital Insurer
 

Último (20)

Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
 
A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...Workshop - Best of Both Worlds_ Combine  KG and Vector search for  enhanced R...
Workshop - Best of Both Worlds_ Combine KG and Vector search for enhanced R...
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CV
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 

9 a05407 formal_languages_automata_theor_yfr_2029

  • 1. www.firstranker.com Code :9A05407 1 II B.Tech II Semester(R09) Regular Examinations, April/May 2011 FORMAL LANGUAGES & AUTOMATA THEORY (Computer Science & Engineering) Time: 3 hours Max Marks: 70 Answer any FIVE questions All questions carry equal marks ⋆⋆⋆⋆⋆ 1. (a) Define an NFA. Draw the transition graph of NFA that accepts the language generated by the regular expression (10+01)*1(0+1). Process the string 100111 on the machine. (b) Define DFA. Draw the transion graph of the DFA that accepts the language generated by the regular expression (a+b)*ba. Process the string abba. 2. (a) Define NFA-∈. Convert the following NFA-∈ into it’s equivalent NFA. Process fue string 101010 on both the machines. E R (b) Define Moore and Melay machines. Convert the following Moore machine into its equivalent Melay machine. N K Process the string 111001. R A 3. (a) Construct an NFA-∈ that recognizes the language generated by the regular expression (11+01)*10(0+1)*. (b) State pumping lemma for regular languages. Prove that the language of palindromes over the alphabet {a, b} is not regular. S T 4. (a) Define a regular grammar. Find the FA that recognizes the language generated by the following right linear grammar. S → OA/1B/1C IR A → 1A/OC B → 1B/O/1 C → OC/O/1A F (b) Define leftmost and right most derivations. Find out the leftmost, right most derivations and draw the corresponding derivation trees for the string (a+a)*a in the following grammar. E → E + T /T T → T ∗ F/F F → (E)/a 5. (a) Eliminate ∈-productions from the following CFG. S → ABBAC A → AB/a/B B → A/CB/AC/b/ ∈ C→d (b) Convert the following CFG into CNF S → ABC/BaB A → Aa/BaC/a B → bBb/a C → aC/bC/c 6. When do you say that a language is recognized or accepted by a PDA? Design a PDA for L = {a1 bj ck /j >= i + k and ijk>0}. Process the string aaabbbbbbcc using instantaneous description. 7. Design a TM for recognizing L = {xx/x ∈ {a, b}∗ }. Show the moves of the TM for the string abaaba and abaabb. 8. Write short notes on the following: (i) NP hard and NP complete problems. (ii) Posts correspondence problem. (iii) Linear Bounded Automata. ⋆⋆⋆⋆⋆ www.firstranker.com
  • 2. www.firstranker.com Code :9A05407 2 II B.Tech II Semester(R09) Regular Examinations, April/May 2011 FORMAL LANGUAGES & AUTOMATA THEORY (Computer Science & Engineering) Time: 3 hours Max Marks: 70 Answer any FIVE questions All questions carry equal marks ⋆⋆⋆⋆⋆ 1. (a) Define DFA. Draw the transition graph on transition table for the DFA which recognizes L = {x ∈ {a, b}∗ /x ends with ba } Process the string bbab. (b) Define NFA. Draw the transition graph and transition table of NFA which can recognize (0+11)*0(11+00). 2. (a) Convert the following NFA into its equivalent DFA. Process the string 0101 on both the machines. R (b) Define Moore and Melay machines. Convert the following Melay machine into equivalent Moore machine. K E Process the string 10110 on the FA. A N 3. (a) Construct an FA which can recognize the language generated by the regular expression (00+10)*11(0+1). (b) Write any eight identify roles for regular expression and any four closure properties of regular sets ( regular languages ). T R 4. (a) Find an FA which can recognize the language generated by the following regular grammar. S → 00A/11B S B → 01/10 A → 0B/1A/1 IR Check the acceptability of 00010. (b) Design a CFG that generates strings over the alphabet {a,b} that contain unequal number of a’s and b’s. F 5. (a) How do you a eliminate the unit productions from a given CFG? Eliminate the unit productions from the following CFG. E → E + T /T T → T ∗ F/F F → (E)/a (b) Define CNF for CFGs. Convert the following CFG into its equivalent CNF. S → abA/bB/aba A → b/aB/bA B → aB/aA 6. (a) Design a PDA for recognizing the language of palindromes over {0,1}. Process the string 00100. (b) How do you find out PDA that recognizes the language generated by a CFG? Find the PDA which recognizes the language generated by the following CFG. S → 01A/1B A → 00A/11B/0/1 B → 1A/0B/0 7. (a) What are computable functions? Design a TM for computing the multiplication of two given integers. (b) Discuss about Church’s hypothesis. 8. Write brief notes on the following: (a) Context Sensitive Languages. (b) Universal Tuning Machine. (c) Posts correspondence problem. ⋆⋆⋆⋆⋆ www.firstranker.com
  • 3. www.firstranker.com Code :9A05407 3 II B.Tech II Semester(R09) Regular Examinations, April/May 2011 FORMAL LANGUAGES & AUTOMATA THEORY (Computer Science & Engineering) Time: 3 hours Max Marks: 70 Answer any FIVE questions All questions carry equal marks ⋆⋆⋆⋆⋆ 1. (a) Draw the transition graph and transition table of an NFA for accepting the strings generated by the regular expression (00+11)*10. Process the string 001110. (b) Design a DFA for accepting the language of strings over {0,1} that do not contain 10 as substring. Process the string 0011. 2. (a) Find the NFA equivalent to the following NFA-E. Process the string 0112 on both the machines. (b) Check the equality of the following FA’S. E R N K R A S T IR 3. (a) Find the regular expression for the language recognized by the following FA. F (b) State the pumping lemma for regular languages. Prove that the language of all strings over {a, b} that contain equal no. of a’s and b’s is not a regular language. 4. (a) Define a CFG. Find a CFG which generate the strings over the alphabet {0,1} and does not contain equal number of 0’s and 1’s. Find the left most derivation, rightmost derivation and derivation tree for the string 01100. (b) Find a right linear grammar generating the language recognized by the following FA. www.firstranker.com
  • 4. www.firstranker.com 5. Convert the following CFG into Greibach Normal form E → E + T /T T → T ∗ F/F F → lE/a 6. (a) Define a PDA. Design a PDA for recognizing L = {x ∈ {0, 1}∗ /x = 0i ij ok and j = i + k, i, j, k > 0} Process the string 011100 on the PDA. (b) Write the procedure for finding a CFG equivalent to a given PDA. R 7. Write brief notes on the following: (i) Church’s hypothesis (ii) Counter machines (iii) Computable functions. 8. Write brief notes on the following: E (i) Linear bounded automata. (ii) Universal tuning machine. (iii) Posts correspondence problem. K N ⋆⋆⋆⋆⋆ R A S T F IR www.firstranker.com
  • 5. www.firstranker.com Code :9A05407 4 II B.Tech II Semester(R09) Regular Examinations, April/May 2011 FORMAL LANGUAGES & AUTOMATA THEORY (Computer Science & Engineering) Time: 3 hours Max Marks: 70 Answer any FIVE questions All questions carry equal marks ⋆⋆⋆⋆⋆ 1. (a) What are various operations that can be performed on languages ? Explain with examples. (b) Design a DFA that accepts (recognizes) strings containing even no of a’s and odd no of b’s. Draw it’s transition diagram and transition tables. Process the string ababb. 2. (a) Convert the following NFA into DFA. E R Process the string 0010 on both the machines. N K (b) Draw a Moore machine for calculating mod 3 of a given binary number. Find it’s equivalent Mealy machine. R A 3. (a) Write any 8 identify rules for regular expressions. (b) Write any 4 closure properties of regular sets. T (c) Prove that the language of palindromes over {a,b} is not a regular language using pumping lemma. S 4. (a) Find a right linear grammar for the language (0+1)*10.Draw the transition diagram of the FA from the grammar designed. IR (b) Design a CFG for the language of non-palindromes over {a,b}. Find the derivations for the strings abad and ababaa. F 5. (a) What is meant by ambiguous CFG? Prove that the grammar E → E + E/E ∗ E/a is ambiguous. (b) Write the procedure for converting a CFG into its equivalent CNF. Convert the following CFG into CNF. E → E + T /T T → T ∗ F/F F → (E)/a 6. (a) Design a PDA for accepting the language of palindromes over {a,b}. Process the string ababa. (b) Design a PDA for accepting the language generated by the following CFG. S → ab/aA/aB A → aA/a B → bB/b 7. Design a TM for accepting the strings of language L = {x ∈ {a, b}∗ /x = yy for some y ∈ {a, b}∗ } Process the string abab. 8. (a) Write about Chomsky hierarchy of languages. (b) Write a brief note of NP hard and NP complete problems. ⋆⋆⋆⋆⋆ www.firstranker.com