You are on page 1of 22

AUTOMATA THEORY

Reference: Introduction to Automata Theory Languages and Computation


Hopcraft, Ullman and Motwani
Automata Theory
Automata theory is the study of abstract computing device or machine.

The word automaton itself, closely related to the word "automation", denotes automatic processes
carrying out the production of specific processes.

A moving mechanical device made in imitation of a human being.

A machine that performs a function according to a predetermined set of coded instructions.

Automatons are abstract models of machines that perform computations on an input by moving


through a series of states.

At each state of the computation, a transition function determines the next configuration on the
basis of a finite portion of the present configuration.

The major objective of automata theory is to develop methods by which computer scientists


can describe and analyze the dynamic behavior of discrete systems, in which signals are sampled
periodically.
• Automata Theory deals with definitions and properties of different types
of “computation models”. Examples of such models are:
 Finite Automata. These are used in text processing, compilers, and
hardware design.
 Context-Free Grammars. These are used to define programming
languages and in Artificial Intelligence
 Turing Machines. These form a simple abstract model of a “real”
computer, such as your PC at home.
• Finite instruction machine with finite memory (Finite State Automata)

• Finite instruction machine with unbounded memory (Turing machine)


Why Study Automata Theory?

 There are several reasons why the study of automata


and complexity is an important part of the core of
Computer science.
Why Study Automata Theory?
Some of the most important kinds :
1. Software for designing and checking the behavior
of digital circuits.

2. The “lexical analyzer” of a typical compiler, that is,


the compiler component that breaks the input text
into logical units, such as identifiers, keywords and
punctuations.
Why Study Automata Theory?
3. Software for scanning large bodies of text, such as
collections of web pages, to find occurrences of
words, phrases, or other patterns.

4. Software for verifying systems of all types that have


a finite number of distinct states, such as
communications protocols or protocols for secure
exchange of information.
A finite automata modeling on/off
switch
push
start off on
push

The devices remember whether it is in the “on” state or


“off” state and it allows the user to press a button whose
effect is different.
A finite automata modeling on/off
switch
• The states are represented by circles, In this example two
states “on” and “off”.
• One of the states is designated by the start states.

• It is often necessary to indicate one or more states as


“final” or “accepting” states.
A finite Automation modeling
recognition of then
start
t h e n
the then
t th

• This figure shows finite automation that could be


part of a lexical analyzer. The job of this automation
is to recognize the keyword then.
Introduction to Finite Automata
• A finite Automation has a set of states and its control
moves from one state to another in response to
external inputs.
• One of the crucial distinction among classes of finite
automata is whether that control is “deterministic”
meaning that the automation cannot be in more than
one state at one time or “nondeterministic” meaning
that it may be in several states at one.
Structural Representations
• There are 2 important notations that are not
automation like, but play an important rule in
Automata and their applications:
---- Grammar
– processing data with a recursive structure
– E.g., grammatical rule E  E + E for generating arithmetic expressions

---- Regular Expressions


– describing text strings
– E.g., UNIX-style regular expression
’[A-Z][a-z]*[ ][A-Z][A-Z]’ describes Ithaca NY, Lafayette IN…
• A set is a collection of objects, e.g.
– A = {a, b, c, d} and B = {b, d}
– Empty set Ø = {}
– N = {0,2; 3; : : :g and Z = f: : : ; -2; -1; 0; 1; 2; : : :g
– Q is the set of rational number
– R is the set of real numbers
– a 2 A: elements of a set, belongs to, or contains,
– subset of A ⊆ N, proper subset of A ⊂ N
– Notion of union, intersection, difference, and disjoint
– Power set 2A of a set A is the set of subsets of A
– Partition of a set
Central Concepts of Automata Theory

• Three basic concepts

– Alphabet --- a set of symbols


– Strings --- a sequence of symbols from an alphabet
– Language --- a set of strings from the same
alphabet
Central Concepts of Automata Theory
• Alphabets :
finite, nonempty set of symbols.
Conventional notation --- 
Ex: 1. ∑ = {0,1} the binary alphabet,
2. ∑ = {a, b, c, . . . z}
3. The set of all ASCII characters
• Strings:
Boroi ajgubi
finite sequences of symbols chosen from some
alphabet
Ex: 01101 is string from the binary alphabet ∑ =
{0,1} .
– Empty string --- a string with zero occurrences of
symbols
– Length |w| of string w --- the number of positions for
symbols in w
• Examples --- |0111|=4, ||=0, …
Central Concepts of Automata Theory
• Powers of an Alphabets:

∑º={€}
∑1={0,1}
∑2={00,01,10,11}
∑3={000,001,010,011,100,101,110,111}

• ∑+ = ∑1 + ∑2 + ∑3+ …..
• ∑* = ∑+ Ü {€}
Central Concepts of Automata Theory
• Language:
A language is set of strings all of which chosen
from ∑* .

Example:
1. The language of all strings consisting of n 0’s
followed by n 1’s:

{€,01,0011,000111,…..}
Central Concepts of Automata Theory
2. The set of strings of 0’s and 1’s with an equal
number each:
{€,01,10,0011,0101,1001…..}

3. The set of binary number whose value is


prime:
{10,11,101,111,1011,…..}
• End of Class

You might also like