Alc-Cycle 2 Part - A
Alc-Cycle 2 Part - A
N.Rajeswari
18TD0662
Cse - A
Roll no :31
UNIT-1
1.Finite automata:
Finite automaton is a mathematical model of a system with discrete inputs and outputs. The
system can be in any one of the finite number of states. The state of the system summaries the
information concerning past inputs that is needed to determine the behavior of the systems on
subsequent inputs. A finite automaton consists of a finite set of states and set of transitions from state
to state that occur on input symbols chosen from an alphabet ∑.
2.Formal language:
Language is a set of valid strings from some alphabet. The set may be empty, finite or infinite. L(M) is
the language defined by machine M and L(G) is the language defined by context free grammar. The two
notations for specifying formal languages are:
3. Head pointer:
The head examines only one square at a time and can move one square either to the left or to
the right but we restrict the movement of the reading head pointer only to the right-side.
Finite control:
The finite control contains the routines that instruct the reading head pointer to move from one state
to the next state by recognizing each symbol or alphabet.
DFA
For each and every state and for each and every input symbol there exist atmost one transition. The
transition mapping for DFA is Q×∑→Q.
NFA
For each and every state and for each and every input symbol there exist more than one transition.
The transition mapping for NFA is Q × (∑ U { }) →
i. Transition Diagram.
Transition Diagram:
The transition diagram consists of finite set of states, symbols, initial state and final state. It is a
Directed graph which shows the transition from one state to another.
Transition Table:
The transition table is the tabular representation of the transition function “delta (∂)” with the rows
denoting states and columns denoting input symbol.
6. Language:
An alphabet is a finite set of symbols. A language is a set of strings of symbols from someone
alphabet.
7. Transition:
Transition is the process of moving from one state to another state on reading an input symbol. It
can be represented as ∂ (q , a).
The language accepted by finite automata is described by a simple expression called as regular
expression. The language accepted by regular expression is called as regular language.
The deterministic finite automata as a control unit that reads a tape moving one square right at each
moved. We needed non-determinism to the model which allowed many “copies” of the control unit to
exist and scan the tape simultaneously . Next we added €- transitions, which allowed change of state
without reading the input symbol or moving the tape head. Next interesting extension is to allow the
tape head with the ability to move left as well as right, such a finite automaton is called two way finite
automata.
10.The “” is a character used to indicate the null string (i.e) the string which is used simply for transition
from one state to the other without any input. The NFA with € transition function can be extended to ∂’
as ∂’=Q×∑*→
Let ‘r’ be the regular expression then there exists a NFA with-transition that accepts L(r)
(i.e.) L(M)=L(r). Where the regular expression “r” belonging to a language “L” can be accepted by
automata.
14. The rules that define the regular expression over alphabet ∑ are as follows,
If r and s are regular expression denoting language R and S respectively then (r+s), rs and (r*)
are regular expression that denote the set RUS, RS, R* respectively.
15.DFA
NFA
For each and every state and For each and every input Symbol there exist atmost one Transition.
For each and every state and for Each and every input symbol. There exist more than one
Transition.
UNIT-2
1.BNF:
Bnf – Backus – naur form is a notation technique for context free Grammer, offen used to describe
the syntax of languages used in computing
The pumping lemma is a powerful tool providing and proving certain language is regular or not.
It is also useful in the development of algorithms to answer certain question concerning finite
3.Homomorphisms:
A string homomorphism is a function on strings that works by substituting a particular string for
Each symbol.
Example: The function h given by h(0) = abb and h(1) = ba is a homomorphism which replaces
4.Inverse homomorphisms:
Homomorphisms can also applied in reverse and in this mode they also preserve regular
language.That is, suppose h is a homomorphism from some alphabet ∑ to strings in another (possibly
the same) alphabet T -1 . Let L be a language over alphabet T. Then h -1 is the set of strings w in ∑* such
that h(w) is in L.
6.The first closure properties are the three Boolean operations: Union, Intersection, and
Complementation:
i. Let L and M be language over alphabet ∑. Then LUM is the language that contains all
ii. Let L and M be language over alphabet ∑. Then L∩M is the language that contains all
iii. Let L be a language over alphabet ∑. Then , the complement of L, is the set of strings in
7.Reversal:
The reversal of a string a 1 a 2 ...a n is the string written backwards, that is, a n a n-1 …a 1 . We use w
R for the reversal of string w. Thus, 0010 R is 0100, and Є R = Є. The reversal of language L, written L R ,
is the language consisting of the reversals of all its strings. For instances, if L ={001, 10, 111}, then L
R={100,01,111}.
8.Minimization of DFA:
For each DFA we can find an equivalent DFA that has a few states as any DFA accepting the same
language. Moreover, except for our ability to call the states by whatever names we choose, this
minimum-state DFA is unique for the language. The algorithm is as follows:
a. First, eliminate any state that cannot be reached from the start state.
b. Then, partition the remaining states into blocks, so that all states in the same block are equivalent,
We all may think that the same state-partition technique that minimizes the states of a DFA could
also be used to find a minimum-state NFA equivalent to a given NFA or DFA. We can do it, by a process
of exhaustive enumeration, find an NFA with as few states as possible accepting a given regular
language,we cannot simply group the states of some given NFA for the language.
10. To verify this we use pumping lemma. If L pal is a regular language, let n be the associated
constant,and consider the palindrome w =0 n 10 n . If L pal is regular, then we can break w into w = xyz,
such that y consist of one or more 0’s from the first group. Thus, xz, which would also have to be L pal if
L pal were regular, would have fewer 0’s to the left of the lone 1 than there are to the right of the 1.
Therefore xz cannot be a palindrome. So we have now contradicted the assumption that L pal is a
regular language.