0 Up votes0 Down votes

25 views20 pagesMELJUN CORTES Automata Lecture Pushdown Automata 2

Jun 12, 2015

© © All Rights Reserved

PDF, TXT or read online from Scribd

MELJUN CORTES Automata Lecture Pushdown Automata 2

© All Rights Reserved

25 views

MELJUN CORTES Automata Lecture Pushdown Automata 2

© All Rights Reserved

- TOC Assignment No-1
- Introduction to the Theory of Computation
- ALC QBANK
- QX
- Some Minesweeper Configurations
- SIS: A System for Sequential Circuit Analysis
- If a Finite Automata is Modified to Permit Transitions Without Input Symbols
- B[1].TechCSE-IIYEAR.R10Students
- State Machines in Windows Workflow
- Approximate Pattern Matching Using Fuzzy Logic
- MODULE 1 theory of computation
- 110999_Lecture 01 _ Finite Automat I.pdf
- Rbl Report1
- uptu syllabus
- JFLAP Tutorial
- Chapter 3
- 01FAandND
- LECTURE B 1 FSM Minimization Intro
- vlsi
- 00170224

You are on page 1of 20

PUSHDOWN AUTOMATA

Pushdown Automata

Introduction

generate the strings of the

regular language it represents.

generate the strings of the

context-free

language

it

represents.

regular languages.

context-free

languages

is

called

a

pushdown

automaton (PDA).

Pushdown Automata

* Property of STI

Page 1 of 20

except that it has access to a

stack.

Representation of an NFA:

NFA

Input String

Pushdown Automata

* Property of STI

Page 2 of 20

Representation of a PDA:

PDA

Input String

a

b

Stack

a

b

first-out (LIFO) structure.

Pushdown Automata

* Property of STI

Page 3 of 20

on the stack are push (add a

symbol to the top of the stack)

and pop (remove a symbol

from the top of the stack).

depend on the current state,

the incoming input symbol,

and the symbol at the top of

the stack.

memory beyond what is

available in an NFA (as

represented by the states).

NFAs because they can

recognize some non-regular

languages.

Pushdown Automata

* Property of STI

Page 4 of 20

Case Study:

Consider the non-regular

language L1 = {0n1n n 0}.

There is no NFA that can

recognize this language but a

PDA can be constructed to

recognize it.

PDA Operation:

input string.

2. While the input is a 0, push

it onto the stack.

3. While the input symbol is a

1, pop a 0 off the stack.

4. If there is no more input

symbol and the stack is

empty, the input string is

accepted.

Pushdown Automata

* Property of STI

Page 5 of 20

Automata

Q, , , and F are all finite

sets, and

1. Q is the set of states,

2.

3.

4.

state, and

6. F Q and is the set of final

states.

Pushdown Automata

* Property of STI

Page 6 of 20

of symbols that can be pushed

onto the stack. It may or may

not be the same as the input

string alphabet .

Transitions in a PDA

In an NFA, transitions are

represented by:

(qi, 0) = qj

This equation indicates that if

the current state is state qi and

the input is 0, the NFA goes to

state qj. State transitions are

therefore determined by the

current state and the input

symbol.

Pushdown Automata

* Property of STI

Page 7 of 20

In a PDA, transitions

represented by:

are

(qi, 0, a) = (qj, b)

This equation indicates that if

the current state is state qi and

the input symbol is 0, and the

symbol at the top of the stack

is a, the PDA goes to state qj

and pushes the symbol b onto

the stack.

State transitions are thus

determined

by the current

state, the input symbol, and

the symbol at the top of the

stack.

Pushdown Automata

* Property of STI

Page 8 of 20

PDA state diagrams are similar

to NFA state diagrams except

for the labels of the transition

edges.

Example:

a, b c

qi

qj

if the input symbol is a and the

symbol read from the top of

the stack is b, then the PDA

goes to state qj and it pushes

the symbol c unto the stack.

Pushdown Automata

* Property of STI

Page 9 of 20

symbol at the top of the stack

implies a pop operation. The

label a, b c implies that the

symbol b was popped off the

stack.

Furthermore, any of the

symbols a, b, c in the given

label can also be the empty

string .

1. If a = , the PDA makes

the transition without any

input symbol.

2. If b = , the PDA makes

the

transition

without

reading any symbol from

the stack.

3. If c = , the PDA does not

push any symbol onto the

stack.

Pushdown Automata

* Property of STI

Page 10 of 20

determine if the stack is

empty, a special symbol will be

designated as the stack empty

symbol.

onto the stack every time a

computation is started.

here will be the dollar sign ($).

that the symbol at the top of

the stack is $, then the stack is

considered empty.

Pushdown Automata

* Property of STI

Page 11 of 20

Sample Transitions

0, a b

top of the

stack

qi

qj

a

x

y

$

b

x

y

$

stack before

transition

stack after

transition

top of the

stack

0, a a

top of the

stack

Pushdown Automata

qi

qj

a

x

y

$

a

x

y

$

stack before

transition

stack after

transition

top of the

stack

* Property of STI

Page 12 of 20

0, e b

top of the

stack

qi

qj

a

x

y

$

b

a

x

y

$

stack before

transition

stack after

transition

top of the

stack

0, a e

top of the

stack

Pushdown Automata

qi

qj

a

x

y

$

x

y

$

stack before

transition

stack after

transition

top of the

stack

* Property of STI

Page 13 of 20

0, e e

top of the

stack

qi

qj

a

x

y

$

a

x

y

$

stack before

transition

stack after

transition

top of the

stack

PDA can make a state

transition without any input

symbol.

This implies that PDAs are

nondeterministic.

Pushdown Automata

* Property of STI

Page 14 of 20

recognize the non-regular

language L1 = {0n1n n 0} is:

q0

q3

e, e $

q1

0, e 0

Pushdown Automata

e, $ e

1, 0 e

q2

1, 0 e

* Property of STI

Page 15 of 20

defined as P1 = (Q, , , , q0,

F) where:

2.

= {0, 1}

3.

= {0, $}

5. F = {q0, q3}

Pushdown Automata

* Property of STI

Page 16 of 20

given by:

Input Stack

is

Current State

q0

q1

q2

q3

0

0

$

(q1, 0)

0

1

(q2, )

(q2, )

$

0

$

(q3, )

(q1, $)

Pushdown Automata

* Property of STI

Page 17 of 20

Example 2:

recognize the non-regular

language L2 = {wwR w

{0,

1}*} is:

q0

q3

e, e $

q1

0, e 0

1, e 1

Pushdown Automata

e, $ e

e, e e

q2

0, 0 e

1, 1 e

* Property of STI

Page 18 of 20

Example 3:

recognize the non-regular

language L3 = {aibjck i, j, k 0

and i = j or i = k} is:

b, a e

q0

q2

e, $ e

q3

e,

e, e $

c, e e

q1

a, e a

Pushdown Automata

e, e e

q4

b, e e

e, e e

q5

e, $ e

q6

c, a e

* Property of STI

Page 19 of 20

Exercises:

recognize the language L4 =

{w w is composed of an equal

number of 0s and 1s}.

recognize the language L5 =

{02n1n n 1}.

Pushdown Automata

* Property of STI

Page 20 of 20

- TOC Assignment No-1Uploaded byDhruv Kuchhal
- Introduction to the Theory of ComputationUploaded byskimdad
- ALC QBANKUploaded byagila ganapathy
- QXUploaded bytheresa.painter
- Some Minesweeper ConfigurationsUploaded bygagomat
- SIS: A System for Sequential Circuit AnalysisUploaded byravi84m3679
- If a Finite Automata is Modified to Permit Transitions Without Input SymbolsUploaded bybiswasrajib
- B[1].TechCSE-IIYEAR.R10StudentsUploaded byvitcse2010
- State Machines in Windows WorkflowUploaded byBogdan Comsa
- Approximate Pattern Matching Using Fuzzy LogicUploaded byMauliadi
- MODULE 1 theory of computationUploaded byanusha k
- 110999_Lecture 01 _ Finite Automat I.pdfUploaded byvignesvaran
- Rbl Report1Uploaded byShrikant Kumbhar
- uptu syllabusUploaded byYogita Pal
- JFLAP TutorialUploaded byModitha Dharmasiri
- Chapter 3Uploaded bylikufanele
- 01FAandNDUploaded byElmer Perez
- LECTURE B 1 FSM Minimization IntroUploaded bySathish Kumar
- vlsiUploaded byRajveer Sekhon
- 00170224Uploaded byRafia Naz Memon
- DDI0068Uploaded bylosber2
- SyllabusUploaded bygj
- or_introUploaded bySasa Syalallaa
- 10.1.1.97.3251[1]Uploaded byms0416
- r7311502-Automata and Compiler DesignUploaded bysivabharathamurthy
- PresentationUploaded byRitesh Reddy
- 333_Answers_2009_10_Q1_finalUploaded byaku011987
- CODIGO2.CPPUploaded bySantiago Gonzalez Diego Eduardo
- [Qm] Chapter 13 - Project Management (1)Uploaded byNguyên Bùi
- 1.IJECIERDAPR20181Uploaded byTJPRC Publications

- TCU 2019 Certificate Recognization SERVICE AWARD 5 YearsUploaded byMELJUN CORTES, MBA,MPA
- TCU 2018 Certificate of Recognition Outstanding FacultyUploaded byMELJUN CORTES, MBA,MPA
- MELJUN CORTES TCU Evaluation Faculty TCU Taguig City 2nd Semester 2018 2019Uploaded byMELJUN CORTES, MBA,MPA
- MELJUN CORTES TCU Evaluation Faculty TCU Taguig City 1st Semester 2018 2019Uploaded byMELJUN CORTES, MBA,MPA
- MELJUN CORTES TCU Evaluation Faculty TCU Taguig City 2nd Semester 2017 2018Uploaded byMELJUN CORTES, MBA,MPA
- MELJUN CORTES TCU Evaluation Faculty TCU Taguig City 1st Semester 2017 2018Uploaded byMELJUN CORTES, MBA,MPA
- MELJUN CORTES TCU Evaluation Faculty TCU Taguig City 2nd Semester 2016 2017Uploaded byMELJUN CORTES, MBA,MPA
- MELJUN CORTES TCU Evaluation Faculty TCU Taguig City 1st Semester 2016 2017Uploaded byMELJUN CORTES, MBA,MPA
- MELJUN CORTES TCU Evaluation Faculty TCU Taguig City 2nd Semester 2015 2016Uploaded byMELJUN CORTES, MBA,MPA
- MELJUN CORTES TCU Evaluation Faculty TCU Taguig City 1st Semester 2015 2016Uploaded byMELJUN CORTES, MBA,MPA
- MELJUN CORTES TCU Evaluation Faculty TCU Taguig City 2nd Semester 2014 2015Uploaded byMELJUN CORTES, MBA,MPA
- MELJUN CORTES TCU Evaluation Faculty TCU Taguig City 1st Semester 2014 2015Uploaded byMELJUN CORTES, MBA,MPA
- MELJUN CORTES TCU 2019 Certificate Recognization SERVICE AWARD 5 years of TCU OSASUploaded byMELJUN CORTES, MBA,MPA
- MELJUN CORTES TCU 2018 Certificate of Recognition Outstanding Faculty of TCUUploaded byMELJUN CORTES, MBA,MPA
- MELJUN CORTES TESDA License NC III BookkeepingUploaded byMELJUN CORTES, MBA,MPA
- MELJUN CORTES TESDA License NC II CSS Computer Systems ServicingUploaded byMELJUN CORTES, MBA,MPA
- MELJUN CORTES TESDA TM 1 2016 Trainer's Methodology IUploaded byMELJUN CORTES, MBA,MPA
- MELJUN CORTES TESDA Data Encoder Eligibility 2Uploaded byMELJUN CORTES, MBA,MPA
- MELJUN CORTES TESDA Data Encoder Eligibility 1Uploaded byMELJUN CORTES, MBA,MPA
- MELJUN CORTES TESDA License NC II PC OperationsUploaded byMELJUN CORTES, MBA,MPA
- MELJUN CORTES TESDA License NC I Data EncoderUploaded byMELJUN CORTES, MBA,MPA
- MELJUN CORTES TESDA License NC I TechnicianUploaded byMELJUN CORTES, MBA,MPA
- MELJUN CORTES TESDA 2009 Tm Am Trainers AMUploaded byMELJUN CORTES, MBA,MPA
- MELJUN CORTES TESDA 2009 CHS NC II 392 Hours Certificate of Training Computer Hardware ServicingUploaded byMELJUN CORTES, MBA,MPA
- MELJUN CORTES TCU OSAS 2019 Certificate Recognization SERVICE AWARD 5 YearsUploaded byMELJUN CORTES, MBA,MPA
- MELJUN CORTES TCU 2018 Certificate of Recognition Outstanding Faculty - TEACHERUploaded byMELJUN CORTES, MBA,MPA
- MELJUN CORTES IBM COGNOS Certified 2013Uploaded byMELJUN CORTES, MBA,MPA
- MELJUN CORTES IBM Training Certificate DATA WareHousingUploaded byMELJUN CORTES, MBA,MPA
- MELJUN CORTES IBM Training Certificate BIG DATAUploaded byMELJUN CORTES, MBA,MPA
- MELJUN CORTES IBM Training Certificate Predictive AnalyticsUploaded byMELJUN CORTES, MBA,MPA

- Week-2 Architecture v1.10Uploaded byAnonymous G0oZQa
- FAQ GettextUploaded byWajih Letaief
- Human Machine ArtUploaded byLaCasaIda.org
- The Incredible Power of Post Selection (Scott Aaronson)Uploaded byDanielleFong
- ESDUploaded bysandeepvs
- AI In LogisticsUploaded byumansh
- Face Recognition Using Neuro Networks PDFUploaded byLori
- thread.docxUploaded bytrupti.kodinariya9810
- CS605 SE_II.pdfUploaded byKaleem Chaudhary
- weeerrUploaded byforkrak
- baduraUploaded byAdonis Saidler
- Software development methodlogyUploaded byTushar Gupta
- Briscoe G., Caelli T. a Compendium of Machine Learning. Symbolic Machine LearningUploaded byVíctor Iván González Guevara
- 2001-2002-answersUploaded byAndre Robles
- Automatically Detecting and TrackingUploaded bymatri0807
- 617Uploaded byNEERAJ
- Divide and Conquer For Convex HullUploaded byJournal of Computing
- Tool-path Optimization for Minimizing Airtime During MachiningUploaded byRomeu Bertho
- 8086 Internal Block Diagram EnotesUploaded byveera
- ResumeUploaded byAnkit Sharma
- Multithreading and Concurrency QuestionsUploaded byZsolt Bokor
- Kent Noss Report Engineering MathsUploaded bypejscott
- Reda Seireg Phd ResumeUploaded byReda Seireg
- C_ProgrammingEmmbededSystemsUploaded byPranav Gairola
- Advertisment for General Admissions 2020Uploaded byMehru Alim
- C++ CompleteUploaded byforumid2697
- Brian Harrell Resume (IT)Uploaded byBsharrell
- CS321 Computer architectureUploaded byAnurag kumar
- LSTM Based Scene LabellingUploaded byAnshuman Sabath
- Computer ArchitectureUploaded byThangavel Murugan

## Much more than documents.

Discover everything Scribd has to offer, including books and audiobooks from major publishers.

Cancel anytime.