×
Listen to your teachers when they tell you WHAT to do. But more importantly, think about it later and ask yourself WHY they told you to do it.
--Your friends at LectureNotes
Close

Note for FORMAL LANGUAGES AND AUTOMATA THEORY - FLAT By JNTU Heroes

  • FORMAL LANGUAGES AND AUTOMATA THEORY - FLAT
  • Note
  • Jawaharlal Nehru Technological University Anantapur (JNTU) College of Engineering (CEP), Pulivendula, Pulivendula, Andhra Pradesh, India - JNTUACEP
  • 5 Topics
  • 5642 Views
  • 206 Offline Downloads
  • Uploaded 1 year ago
Jntu Heroes
Jntu Heroes
0 User(s)
Download PDFOrder Printed Copy

Share it with your friends

Leave your Comments

Text from page-2

Contents 1 Mathematical Preliminaries 3 2 Formal Languages 2.1 Strings . . . . . . . . . . . . 2.2 Languages . . . . . . . . . . 2.3 Properties . . . . . . . . . . 2.4 Finite Representation . . . . 2.4.1 Regular Expressions 3 Grammars 3.1 Context-Free Grammars 3.2 Derivation Trees . . . . . 3.2.1 Ambiguity . . . . 3.3 Regular Grammars . . . 3.4 Digraph Representation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4 Finite Automata 4.1 Deterministic Finite Automata . . . . . . . . . . . 4.2 Nondeterministic Finite Automata . . . . . . . . . 4.3 Equivalence of NFA and DFA . . . . . . . . . . . . 4.3.1 Heuristics to Convert NFA to DFA . . . . . 4.4 Minimization of DFA . . . . . . . . . . . . . . . . . 4.4.1 Myhill-Nerode Theorem . . . . . . . . . . . 4.4.2 Algorithmic Procedure for Minimization . . 4.5 Regular Languages . . . . . . . . . . . . . . . . . . 4.5.1 Equivalence of Finite Automata and Regular 4.5.2 Equivalence of Finite Automata and Regular 4.6 Variants of Finite Automata . . . . . . . . . . . . . 4.6.1 Two-way Finite Automaton . . . . . . . . . 4.6.2 Mealy Machines . . . . . . . . . . . . . . . . 1 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4 . 5 . 6 . 10 . 13 . 13 . . . . . 18 19 26 31 32 36 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . Languages Grammars . . . . . . . . . . . . . . . . . . 38 39 49 54 58 61 61 65 72 72 84 89 89 91

Text from page-3

5 Properties of Regular Languages 5.1 Closure Properties . . . . . . . 5.1.1 Set Theoretic Properties 5.1.2 Other Properties . . . . 5.2 Pumping Lemma . . . . . . . . 2 . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 94 94 94 97 104

Text from page-4

Chapter 1 Mathematical Preliminaries 3

Text from page-5

Chapter 2 Formal Languages A language can be seen as a system suitable for expression of certain ideas, facts and concepts. For formalizing the notion of a language one must cover all the varieties of languages such as natural (human) languages and programming languages. Let us look at some common features across the languages. One may broadly see that a language is a collection of sentences; a sentence is a sequence of words; and a word is a combination of syllables. If one considers a language that has a script, then it can be observed that a word is a sequence of symbols of its underlying alphabet. It is observed that a formal learning of a language has the following three steps. 1. Learning its alphabet - the symbols that are used in the language. 2. Its words - as various sequences of symbols of its alphabet. 3. Formation of sentences - sequence of various words that follow certain rules of the language. In this learning, step 3 is the most difficult part. Let us postpone to discuss construction of sentences and concentrate on steps 1 and 2. For the time being instead of completely ignoring about sentences one may look at the common features of a word and a sentence to agree upon both are just sequence of some symbols of the underlying alphabet. For example, the English sentence "The English articles - a, an and the - are categorized into two types: indefinite and definite." may be treated as a sequence of symbols from the Roman alphabet along with enough punctuation marks such as comma, full-stop, colon and further one more special symbol, namely blank-space which is used to separate two words. Thus, abstractly, a sentence or a word may be interchangeably used 4

Lecture Notes