The Equivalence of Context-Free Grammars and PushDown Automata

Theorem:

Informal Proof:

Every CFL language is accepted by some PDA.

Let MATH be the CFL in Chomsky Normal Form.

1. The corresponding PDA has the following states:

2. The input alphabet is MATH

3. The stack alphabet MATH MATH , where $\QTR{Large}{\$}$ is some new nonterminal.

4. The transition rules are:

Example: To be done in class:

MATH

A Chomsky Version:

MATH

MATH

MATH

________________________________________________________

Homework Due October 20

a. Problem 2.10 Page 129 from the Text.

b. Apply the above method to find a PDA equivalent to

MATH .

_________________________________________________

Every PDA language is accepted by some CFL.

Some assumptions:

We can always find an equivalent PDA MATH such that:

  1. There is a single accept state , MATH

  2. The stack is empty when a string is accepted.

  3. Every stack operation is either a push or a pop. That is there are no replacement operations.

We now construct G:

Production Rules: