Docsity
Docsity

Prepare for your exams
Prepare for your exams

Study with the several resources on Docsity


Earn points to download
Earn points to download

Earn points by helping other students or get them with a premium plan


Guidelines and tips
Guidelines and tips

New format for FAs - Theory of Automata - Lecture Slides, Slides of Theory of Automata

New format for FAs, CFG to CNF converting, Null productions, Removing the unit productions, Introducing the new productions, Class of machines, Regular language are the key points and terms you can learn in this lecture. Other related concepts are also explained in this course.

Typology: Slides

2011/2012

Uploaded on 11/06/2012

parasad
parasad 🇮🇳

4.5

(56)

131 documents

1 / 32

Toggle sidebar

This page cannot be seen from the preview

Don't miss anything!

bg1
ReCap
Chomsky Normal Form, Theorem regarding
CNF, examples of converting CFG to be in
CNF, Example of an FA corresponding to
Regular CFG, Left most and Right most
Docsity.com
pf3
pf4
pf5
pf8
pf9
pfa
pfd
pfe
pff
pf12
pf13
pf14
pf15
pf16
pf17
pf18
pf19
pf1a
pf1b
pf1c
pf1d
pf1e
pf1f
pf20

Partial preview of the text

Download New format for FAs - Theory of Automata - Lecture Slides and more Slides Theory of Automata in PDF only on Docsity!

ReCap

  • Chomsky Normal Form, Theorem regarding

CNF, examples of converting CFG to be in

CNF, Example of an FA corresponding to

Regular CFG, Left most and Right most

Solution of the Task

Convert the following CFG to CNF

S  ABAB

A  a|

B  b|

Solution : Removing the null productions

A   and B  , and introducing the new productions as

S  BAB|AAB|ABB|ABA|AA|AB|BA|BB|A|B

Solution continued …

Thus the required CNF becomes

SRR|AR|BR|RA|RB|AA|AB|BA|BB|a|b

R  AB

A  a

B  b

A new format for FAs

A class of machines (FAs) has been discussed accepting the regular language i.e. corresponding to a regular language there is a machine in this class, accepting that language and corresponding to a machine of this class there is a regular language accepted by this machine. It has also been discussed that there is a CFG corresponding to regular language and CFGs also define some nonregular languages, as well

A new format for FAs contd. …

Input TAPE The part of an FA, where the input string is placed before it is run, is called the input TAPE. The input TAPE is supposed to accommodate all possible strings. The input TAPE is partitioned with cells, so that each letter of the input string can be placed in each cell. The input string abbaa is shown in the following input TAPE.

Input TAPE contd…

The character ∆ indicates a blank in the TAPE. The input string is read from the TAPE starting from the cell (i).

It is assumed that when first ∆ is read, the rest of the TAPE is supposed to be blank.

a b b a a ∆ ∆.

Cell i (^) Cell ii Cell iii

An Accept state

ACCEPT: This state is like a final state of an FA and is expressed by

ACCEPT

A REJECT state

REJECT: This state is like dead-end non final state and is expressed by

NOTE: It may be noted that the ACCEPT and REJECT states are called the halt states.

REJECT

Example

Obviously the above FA accepts the

language of strings, expressed by (a+b)*a.

Following is the new format of the above

FA

b

a x-

b^ a

y+

Before some other states are defined consider

the following example of an FA alongwith its new

format

Example contd. …

REJECT ACCEPT

START

READ a^ READ

a

b

b

Example

The above FA accepts the language

expressed by (a+b)bb(a+b)

a

b

a

1 b +

a,b

Example cont. …

REJECT ACCEPT

START

READ

a READ

a

b (^) READ

REJECT

b

a,b

∆ ∆ ∆

PUSH and STACK contd. …

d The PUSH state is expressed by

c

b

a

PUSH a

STACK

When a letter is pushed, it replaces the existing letter and pushes it one position below.

POP and STACK

POP : POP is an operation that takes out a letter from the top of the STACK. The rest of the letters are moved one location up. POP state is expressed as

POP

a

b