Push Down Automata Flashcards

(16 cards)

1
Q

What model of computation recognizes context-free languages?

A

Pushdown Automata (PDA).

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

Why can’t finite automata recognize the language aⁿbⁿ?

A

Because they have no memory to track how many a’s and b’s have been seen.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

What feature gives PDAs more power than DFAs?

A

A stack, which allows them to store and recall information.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

What is the key idea for using a PDA to recognize aⁿbⁿ?

A

Push an ‘a’ for each a read, and pop one for each b read — accept if the stack is empty.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

What is the formal definition of a PDA?

A

A 6-tuple: (Q, Σ, Γ, s, Δ, F), where Q is states, Σ is input alphabet, Γ is stack alphabet, s is start state, Δ is transition relation, and F is accepting states.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

What does the PDA transition function Δ contain?

A

Tuples of the form ((p, a, α), (q, β)) — meaning read a, pop α, move to q, and push β.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

What happens if the PDA cannot match the required top stack symbol?

A

The transition is not valid — the move is blocked.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

What is a PDA configuration?

A

A triple (p, w, γ), representing the current state, input remaining, and stack content.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

What does a one-step PDA transition look like?

A

(p, av, γ) ⊢ (q, v, δ), where a is read, α is popped, β is pushed, and state changes from p to q.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

When does a PDA accept a word?

A

If it reads all input, ends in an accepting state, and the stack is empty.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

What language does a PDA that pushes a’s and pops for b’s recognize?

A

L = { aⁿbⁿ | n ≥ 0 }

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

How does a PDA recognize aⁿbⁿ using three states?

A

State 2 pushes a’s, state 3 pops a’s for b’s, accept in state 3 with empty stack.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

What does the stack symbol ‘c’ represent in the equal-a-b PDA?

A

It marks the bottom of the stack — a guard symbol.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

What language does a PDA that balances total counts of a’s and b’s (regardless of order) recognize?

A

L = { w ∈ {a,b}* | #a(w) = #b(w) }

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

How does a PDA process a word with equal a’s and b’s in arbitrary order?

A

It pushes opposing symbols and cancels out matching pairs using stack transitions.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

What is the major difference between DFAs and PDAs?

A

DFAs have no memory; PDAs use a stack to track nested or balanced structure.