THEORY OF AUTOMATA & FINITE LANGUAGE

advertisement
1.Informal description
An automaton is supposed to run on some given sequence of inputs in discrete time steps. An automaton
gets one input every time step that is picked up from a set of symbolsor letters, which is called an alphabet.
At any time, the symbols so far fed to the automaton as input form a finite sequence of symbols, which is
called a word. An automaton contains a finite set of states. At each instance in time of some run, the
automaton is in one of its states. At each time step when the automaton reads a symbol, it jumps or
transitions to another state that is decided by a function that takes the current state and symbol as
parameters. This function is called the transition function. The automaton reads the symbols of the input
word one after another and transitions from state to state according to the transition function, until the word
is read completely. Once the input word has been read, the automaton is said to have stopped and the
state at which automaton has stopped is called the final state. Depending on the final state, it's said that the
automaton either accepts or rejects an input word. There is a subset of states of the automaton, which is
defined as the set of accepting states. If the final state is an accepting state, then the
automaton accepts the word. Otherwise, the word is rejected. The set of all the words accepted by an
automaton is called the language recognized by the automaton.
In short, an automaton is a mathematical object that takes a word as input and decides either to accept it or
reject it. Since all computational problems are reducible into the accept/reject question on words (all
problem instances can be represented in a finite length of symbols)[citation needed], automata theory plays a
crucial role in computational theory.
2.Connection to Category theory
One can define several distinct categories of automata[2] following the automata classification into different
types described in the previous section. The mathematical category of deterministic automata, sequential
machines or sequential automata, and Turing machines with automata homomorphisms defining the
arrows between automata is aCartesian closed category,[3][4] it has both categorical limits and colimits. An
automata homomorphism maps a quintuple of an automaton Ai onto the quintuple of another
automaton Aj.[5] Automata homomorphisms can also be considered as automata transformations or as
semigroup homomorphisms, when the state space,S, of the automaton is defined as a
semigroup Sg. Monoids are also considered as a suitable setting for automata in monoidal categories.[6][7][8]
Categories of variable automata
One could also define a variable automaton, in the sense of Norbert Wiener in his book on "Human Use of
Human Beings" via the endomorphisms
. Then, one can show that such variable automata
homomorphisms form a mathematical group. In the case of non-deterministic, or other complex kinds of
automata, the latter set of endomorphisms may become, however, a variable automaton groupoid.
Therefore, in the most general case, categories of variable automata of any kind are categories of
groupoids[9] or groupoid categories. Moreover, the category of reversible automata is then a 2-category,
and also a subcategory of the 2-category of groupoids, or the groupoid category
3.Acceptance condition

Acceptance of finite words: Same as described in the informal definition above.

Acceptance of infinite words: an omega automaton cannot have final states, as infinite words never
terminate. Rather, acceptance of the word is decided by looking at the infinite sequence of visited
states during the run.

Probabilistic acceptance: An automaton need not strictly accept or reject an input. It may accept the
input with some probability between zero and one. For example, quantum finite automaton, geometric
automaton and metric automaton have probabilistic acceptance.
Different combinations of the above variations produce many classes of automaton.
Automata theory is a subject matter that studies properties of various types of automata. For example, the
following questions are studied about a given type of automata.

Which class of formal languages is recognizable by some type of automata? (Recognizable
languages)

Are certain automata closed under union, intersection, or complementation of formal languages?
(Closure properties)

How much is a type of automata expressive in terms of recognizing a class of formal languages? And,
their relative expressive power? (Language Hierarchy)
Automata theory also studies if there exist any effective algorithm or not to solve problems similar to the
following list.

Does an automaton accept any input word? (emptiness checking)

Is it possible to transform a given non-deterministic automaton into deterministic automaton without
changing the recognizable language? (Determinization)

For a given formal language, what is the smallest automaton that recognizes it? (Minimization).
2O MARKS
.
1.Transducers
Transducers generate output based on a given input and/or a state using actions. They are used for control
applications and in the field of computational linguistics.
In control applications, two types are distinguished:
Moore machine
The FSM uses only entry actions, i.e., output depends only on the state. The advantage of the
Moore model is a simplification of the behaviour. Consider an elevator door. The state machine
recognizes two commands: "command_open" and "command_close" which trigger state changes.
The entry action (E:) in state "Opening" starts a motor opening the door, the entry action in state
"Closing" starts a motor in the other direction closing the door. States "Opened" and "Closed" stop
the motor when fully opened or closed. They signal to the outside world (e.g., to other state
machines) the situation: "door is open" or "door is closed".
Fig. 7 Transducer FSM: Mealy model example
Mealy machine
The FSM uses only input actions, i.e., output depends on input and state. The use of a Mealy FSM
leads often to a reduction of the number of states. The example in figure 7 shows a Mealy FSM
implementing the same behaviour as in the Moore example (the behaviour depends on the
implemented FSM execution model and will work, e.g., for virtual FSM but not for event driven
FSM). There are two input actions (I:): "start motor to close the door if command_close arrives"
and "start motor in the other direction to open the door if command_open arrives". The "opening"
and "closing" intermediate states are not shown.
In practice[of what?] mixed models are often used.[citation needed]
More details about the differences and usage of Moore and Mealy models, including an
executable example, can be found in the external technical note "Moore or Mealy model?"
2.Mathematical model
In accordance with the general classification, the following formal definitions are found:

A deterministic finite state machine or acceptor deterministic finite state machine is
a quintuple
, where:

is the input alphabet (a finite, non-empty set of symbols).

is a finite, non-empty set of states.


is an initial state, an element of
.
is the state-transition function:
would be

(in a nondeterministic finite automaton it
, i.e.,
would return a set of states).
is the set of final states, a (possibly empty) subset of
.
For both deterministic and non-deterministic FSMs, it is conventional to allow
i.e.
does not have to be defined for every combination of
is in a state
, the next symbol is
and
is not defined, then
to be a partial function,
and
. If an FSM
can announce an error (i.e.
reject the input). This is useful in definitions of general state machines, but less useful when transforming
the machine. Some algorithms in their default form may require total functions.
A finite-state machine is a restricted Turing machine where the head can only perform "read" operations,
and always moves from left to right.[9]

A finite state transducer is a sextuple
, where:

is the input alphabet (a finite non empty set of symbols).

is the output alphabet (a finite, non-empty set of symbols).

is a finite, non-empty set of states.

is the initial state, an element of
. In a nondeterministic finite automaton,
is a set of initial
states.

is the state-transition function:

is the output function.
.
If the output function is a function of a state and input alphabet (
) that definition
corresponds to the Mealy model, and can be modelled as a Mealy machine. If the output function depends
only on a state (
) that definition corresponds to the Moore model, and can be modelled as
a Moore machine. A finite-state machine with no output function at all is known as
a semiautomaton or transition system.
If we disregard the first output symbol of a Moore machine,
, then it can be readily converted to an
output-equivalent Mealy machine by setting the output function of every Mealy transition (i.e. labeling every
edge) with the output symbol given of the destination Moore state. The converse transformation is less
straightforward because a Mealy machine state may have different output labels on its incoming transitions
(edges). Every such state needs to be split in multiple Moore machine states, one for every incident output
symbol.[10]
3.Decision table
Decision tables are a precise yet compact way to model complicated logic.[1]
Decision tables, like flowcharts and if-then-else and switch-case statements, associate conditions with
actions to perform, but in many cases do so in a more elegant way.
In the 1960s and 1970s a range of "decision table based" languages such as Filetab were popular for
business programming.
Contents
[hide]
Structure[edit]
The four quadrants
Conditions Condition alternatives
Actions
Action entries
Each decision corresponds to a variable, relation or predicate whose possible values are listed among the
condition alternatives. Each action is a procedure or operation to perform, and the entries specify whether
(or in what order) the action is to be performed for the set of condition alternatives the entry corresponds to.
Many decision tables include in their condition alternatives the don't care symbol, a hyphen. Using don't
cares can simplify decision tables, especially when a given condition has little influence on the actions to be
performed. In some cases, entire conditions thought to be important initially are found to be irrelevant when
none of the conditions influence which actions are performed.
Aside from the basic four quadrant structure, decision tables vary widely in the way the condition
alternatives and action entries are representedSome decision tables use simple true/false values to
represent the alternatives to a condition (akin to if-then-else), other tables may use numbered alternatives
(akin to switch-case), and some tables even use fuzzy logic or probabilistic representations for condition
alternatives.[4] In a similar way, action entries can simply represent whether an action is to be performed
(check the actions to perform), or in more advanced decision tables, the sequencing of actions to perform
(number the actions to perform).
Example
The limited-entry decision table is the simplest to describe. The condition alternatives are simple Boolean
values, and the action entries are check-marks, representing which of the actions in a given column are to
be performed.
A technical support company writes a decision table to diagnose printer problems based upon symptoms
described to them over the phone from their clients.
The following is a balanced decision table (created by Systems Made Simple).
Printer troubleshooter
Rules
Printer does not print
Y Y Y Y N N N N
Conditions A red light is flashing
Y Y N N Y Y N N
Printer is unrecognized
Y N Y N Y N Y N
Check the power cable
Actions
Check the printer-computer cable
X
X
X
Ensure printer software is installed X
X
X
X
Check/replace ink
Check for paper jam
X X
X
X X
X
Of course, this is just a simple example (and it does not necessarily correspond to the reality of printer
troubleshooting), but even so, it demonstrates how decision tables can scale to several conditions with
many possibilities
4.Closure properties
The set of Büchi automata is closed under the following operations.
Let A=(QA,Σ,ΔA,IA,FA) and B=(QB,Σ,ΔB,IB,FB) be Büchi automata and C=(QC,Σ,ΔC,IC,FC) be a finite
automaton.

Union: There is a Büchi automaton that recognizes the language L(A)∪L(B).
Proof: If we assume, w.l.o.g., QA∩QB is empty then L(A)∪L(B) is recognized by the Büchi
automaton (QA∪QB, Σ, ΔA∪ΔB, IA∪IB, FA∪FB).

Intersection: There is a Büchi automaton that recognizes the language L(A)∩L(B).
Proof: The Büchi automaton A'=(Q',Σ,Δ',I',F') recognizes L(A)∩L(B), where

 Q' = QA × QB × {1,2}
 Δ' = Δ1 ∪ Δ2

Δ1 = {( (qA,qB,1), a, (q'A,q'B,i) ) | (qA,a,q'A)∈ΔA and (qB,a,q'B)∈ΔB and if qA∈FA then i=2
else i=1 }

Δ2 = {( (qA,qB,2), a, (q'A,q'B,i) ) | (qA,a,q'A)∈ΔA and (qB,a,q'B)∈ΔB and if qB∈FB then i=1
else i=2 }
 I' = IA × IB × {1}
 F' = { (qA,qB,2) | qB∈FB }
By construction, r'=(qA0,qB0,i0),(qA1,qB1,i1),... is a run of automaton A' on input word w iff rA=qA0,qA1,...
is run of A on w and rB=qB0,qB1,... is run of B on w. rA is accepting and rB is accepting iff r' is
concatenation of an infinite series of finite segments of 1-states(states with third component 1) and
2-states(states with third component 2) alternatively. There is such a series of segments of r' iff r' is
accepted by A'.

Concatenation: There is a Büchi automaton that recognizes the language L(C)⋅L(A).
Proof: If we assume, w.l.o.g., QC∩QA is empty then the Büchi automaton A'=(QC∪QA,Σ,Δ',I',FA)
recognizes L(C)⋅L(A), where



Δ' = ΔA ∪ ΔC ∪ { (q,a,q') | q'∈IA and ∃f∈FC. (q,a,f)∈ΔC }

if IC∩FC is empty then I' = IC otherwise I' = IC ∪ IA
ω-closure: If L(C) does not contain empty word then there is a Büchi automaton
that recognizes the language L(C)ω.
Proof: The Büchi automaton that recognizes L(C)ω is constructed in two stages. First, we
construct a finite automaton A' such that A' also recognizes L(C) but there are no incoming
transitions to initial states of A'. So, A'=(QC ∪ {qnew},Σ,Δ',{qnew},FC), where
Δ' = ΔC ∪ { (qnew,a,q') | ∃q∈IC. (q,a,q')∈ΔC}. Note that L(C)=L(A') because L(C) does not contain the
empty string. Second, we will construct the Büchi automaton A" that recognize L(C)ω by adding a
loop back to the initial state of A'. So, A"=(QC ∪ {qnew},Σ,Δ",{qnew},{qnew}), where
Δ" = Δ' ∪ { (q,a,qnew) | ∃q'∈FC. (q,a,q')∈Δ'}.

Complementation:There is a Büchi automaton that recognizes the language
Σ*/L(A).
Proof: The proof is presented here.
Download