30577507 Lec 1 Automata Theory

16
 Lecture One:  Automata Theor y  Automata Theor y , Lecture 1, slide 1  Amjad Ali

Transcript of 30577507 Lec 1 Automata Theory

5/11/2018 30577507 Lec 1 Automata Theory - slidepdf.com

http://slidepdf.com/reader/full/30577507-lec-1-automata-theory 1/16

 

Lecture One:

 Automata Theory

 Automata Theory, Lecture 1, slide 1

 Amjad Ali

5/11/2018 30577507 Lec 1 Automata Theory - slidepdf.com

http://slidepdf.com/reader/full/30577507-lec-1-automata-theory 2/16

 

 Automata Theory, Lecture 1, slide 2

 Automata theory The word “Automata“ is the plural of “automaton"

which simply means any machine.

automata theory is the study of abstract machines and problems they are able to solve.

 Automata theory is closely related to formal languagetheory as the automata are often classified by theclass of formal languages they are able to recognize.

5/11/2018 30577507 Lec 1 Automata Theory - slidepdf.com

http://slidepdf.com/reader/full/30577507-lec-1-automata-theory 3/16

 

 Automata Theory, Lecture 1, slide 3

 Abstract Machine  An abstract machine, also called an abstract computer,

is a theoretical model of a computer hardware or software

system used in Automata theory.

 Abstraction of computing processes is used in both thecomputer science and computer engineering disciplines andusually assumes discrete time paradigm.

abstract machines are often used in thought experiments regarding computability or to analyze the complexity of algorithms

5/11/2018 30577507 Lec 1 Automata Theory - slidepdf.com

http://slidepdf.com/reader/full/30577507-lec-1-automata-theory 4/16

 

What do we do here? We construct abstract models of computers and

computations

These models possess the important featuresthat are common to both hardware and software

These features are essential to many of the

special and complex constructs we encounterwhile working with computers

 Automata Theory, Lecture 1, slide 4

5/11/2018 30577507 Lec 1 Automata Theory - slidepdf.com

http://slidepdf.com/reader/full/30577507-lec-1-automata-theory 5/16

 

Models 

The construction of models is one of the

essentials of any scientific discipline. The usefulness of a discipline is often

dependent on the existence of simple,

yet powerful, theories and laws.

 Automata Theory, Lecture 1, slide 5

5/11/2018 30577507 Lec 1 Automata Theory - slidepdf.com

http://slidepdf.com/reader/full/30577507-lec-1-automata-theory 6/16

 

 Automaton  An automaton is an abstract model of a digital

computer

It has a mechanism to read input (string over agiven alphabet, e.g. strings of 0’s and 1’s on S = {0,1}) written on an input file.

 A finite automaton has a set of states

Its control moves from state to state inresponse to external “inputs” 

 Automata Theory, Lecture 1, slide 6

5/11/2018 30577507 Lec 1 Automata Theory - slidepdf.com

http://slidepdf.com/reader/full/30577507-lec-1-automata-theory 7/16

 Automaton With every automaton, a transition function is

associated which gives the next state in terms

of the current state  An automaton can be represented by a graph in

which the vertices give the internal states andthe edges transitions

The labels on the edges show what happens (interms of input and output) during thetransitions

 An automaton operates in discrete time frame Automata Theory, Lecture 1, slide 7 

5/11/2018 30577507 Lec 1 Automata Theory - slidepdf.com

http://slidepdf.com/reader/full/30577507-lec-1-automata-theory 8/16

Components of an automaton Input file : Contains strings of input

symbols

Storage unit: consists of an unlimitednumber of cells, each capable of holdinga single symbol from an alphabet

Control unit : can be in any one of a finitenumber of internal states and can changestates in defined manner 

 Automata Theory, Lecture 1, slide 8

 

5/11/2018 30577507 Lec 1 Automata Theory - slidepdf.com

http://slidepdf.com/reader/full/30577507-lec-1-automata-theory 9/16

Transitions from start state to

end state•There are 4 objectsCabbage, Man, Wolf and

Goat on one bank and thereis a boat

• All 4 have to cross the riverso that (C,G) or (W,G) arenot left at one place

•Man rows the boat andtakes one at a time

Present state

M,C,G,W = f 

final state

f = M,C,G,W

transition

 Automata Theory, Lecture 1, slide 9

 

5/11/2018 30577507 Lec 1 Automata Theory - slidepdf.com

http://slidepdf.com/reader/full/30577507-lec-1-automata-theory 10/16

Intermediate states

Class assignment 

(M,C,G,W=f) =………..= (f =M,C,G,W) 

 Automata Theory, Lecture 1, slide 10

 

5/11/2018 30577507 Lec 1 Automata Theory - slidepdf.com

http://slidepdf.com/reader/full/30577507-lec-1-automata-theory 11/16

 Applications of Automata  A variety of properties concerning the models,grammars, and languages will be proven.

The existence or non-existence of algorithms forprocessing languages and language processors will be

proven. These algorithms form the basis of tools for processing

languages, e.g., parsers, compilers, assemblers, etc. Other algorithms will form the basis of tools that

automatically construct language processors, e.g.,

yacc, lex, etc. Note that our perspective will be similar to, yet different from

a compiler class.

 Additionally, some things will be proven to be non-computable, e.g., the enhanced compiler.

 Automata Theory, Lecture 1, slide 11 

5/11/2018 30577507 Lec 1 Automata Theory - slidepdf.com

http://slidepdf.com/reader/full/30577507-lec-1-automata-theory 12/16

Different kinds of automata This was only one example of a computational

device, and there are others

We will look at different devices, and look at thesekinds of questions:

What kinds of problems can a given type of devicesolve?

What things are impossible for this kind of device?

Is one type of device more powerful than another?

 Automata Theory, Lecture 1, slide 12

 

5/11/2018 30577507 Lec 1 Automata Theory - slidepdf.com

http://slidepdf.com/reader/full/30577507-lec-1-automata-theory 13/16

Some devices we will see

finite automata Devices with a finite amount of memory. Used to

model “small” computers. 

push-downautomata

Devices with infinite memory that can be accessedin a restricted way.

Used to model parsers, etc.

Turing Machines Devices with infinite memory. Used to model any

computer.

time-bounded

Turing Machines

Infinite memory, but bounded running time.

Used to model any computer program that runs in a

“reasonable” amount of time. 

Automata Theory, Lecture 1, slide 13 

5/11/2018 30577507 Lec 1 Automata Theory - slidepdf.com

http://slidepdf.com/reader/full/30577507-lec-1-automata-theory 14/16

Some highlights of the course Finite automata

We will understand what kinds of things a device

with finite memory can do, and what it cannot do Introduce simulation: the ability of one device to

 “imitate” another device 

Introduce nondeterminism: the ability of a device to

make arbitrary choices Push-down automata

These devices are related to grammars, whichdescribe the structure of programming (and natural)

languages Automata Theory, Lecture 1, slide 14

 

5/11/2018 30577507 Lec 1 Automata Theory - slidepdf.com

http://slidepdf.com/reader/full/30577507-lec-1-automata-theory 15/16

Some highlights of the course

Turing Machines This is a general model of a computer, capturing

anything we could ever hope to compute

But there are many things that computers cannotdo:

 Automata Theory, Lecture 1, slide 15

 

5/11/2018 30577507 Lec 1 Automata Theory - slidepdf.com

http://slidepdf.com/reader/full/30577507-lec-1-automata-theory 16/16

Some highlights of the course

Time-bounded Turing Machines

Many problems are possible to solve on a

computer in principle, but take too muchtime in practice

Traveling salesman: Given a list of cities,

find the shortest way to visit them andcome back home

 Automata Theory, Lecture 1, slide 16