Build a pushdown automaton
Hopcroft 2e §6.1 and §6.4. Type δ the way the book writes it — one move per line — and the graph, the validation list and the DPDA check follow as you type. The determinism report names the exact pairs of moves that can fire on the same ID, which is the thing an exam answer about DPDAs has to point at.
Is it a DPDA?
Not deterministic — 1 pair of moves can fire on the same ID:
- q0 —a, Z0/AZ0→ q0 and q0 —ε, Z0/Z0→ q2
In state q0 with stack top Z0, the ε-move competes with the move reading a: the machine must choose whether to consume input.
Run it
Narration
Enter a string and press Run to step through the machine.
Where DPDAs sit (§6.4)
Regular ⊊ DPDA languages ⊊ context-free — both inclusions are strict. Every regular language is a DPDA language (ignore the stack and run the DFA), but wcwᴿ is a DPDA language and not regular. And wwᴿ is context-free but no DPDA accepts it: without the centre mark there is nothing to tell the machine when to stop pushing and start matching, and a deterministic machine cannot guess.
For DPDAs the two acceptance modes also stop agreeing: by final state a DPDA can accept a language with two strings where one is a prefix of the other, but by empty stack it cannot — once the stack is empty the machine is done, so no accepted string can be a proper prefix of another (§6.4.2–6.4.3).