- initial_state : Q
- start_symbol : S
- final_states : Set Q
Instances For
Equations
- One or more equations did not get rendered due to their size.
- PDA.step { state := q, input := [], stack := Z :: α } = {r₂ : pda.conf | ∃ (p : Q) (β : List S), (p, β) ∈ pda.transition_fun' q Z ∧ r₂ = { state := p, input := [], stack := β ++ α }}
- PDA.step { state := state, input := input, stack := [] } = ∅
Instances For
- refl {Q T S : Type} [Fintype Q] [Fintype T] [Fintype S] {pda : PDA Q T S} (r₁ : pda.conf) : ReachesIn 0 r₁ r₁
- step {Q T S : Type} [Fintype Q] [Fintype T] [Fintype S] {pda : PDA Q T S} {n : ℕ} {r₁ r₂ r₃ : pda.conf} : ReachesIn n r₁ r₂ → Reaches₁ r₂ r₃ → ReachesIn (n + 1) r₁ r₃
Instances For
def
PDA.acceptsByEmptyStack
{Q T S : Type}
[Fintype Q]
[Fintype T]
[Fintype S]
(pda : PDA Q T S)
:
Language T
Equations
- pda.acceptsByEmptyStack = {w : List T | ∃ (q : Q), PDA.Reaches { state := pda.initial_state, input := w, stack := [pda.start_symbol] } { state := q, input := [], stack := [] }}
Instances For
theorem
PDA.reaches1_of_same_transitions
{Q T S : Type}
[Fintype Q]
[Fintype T]
[Fintype S]
(P₁ P₂ : PDA Q T S)
(ht : P₁.transition_fun = P₂.transition_fun)
(ht' : P₁.transition_fun' = P₂.transition_fun')
(q q' : Q)
(w w' : List T)
(γ γ' : List S)
:
Two PDAs with the same transition functions have the same single-step relation.
theorem
PDA.reaches_of_same_transitions
{Q T S : Type}
[Fintype Q]
[Fintype T]
[Fintype S]
(P₁ P₂ : PDA Q T S)
(ht : P₁.transition_fun = P₂.transition_fun)
(ht' : P₁.transition_fun' = P₂.transition_fun')
(c₁ c₂ : P₁.conf)
(h : Reaches c₁ c₂)
:
Two PDAs with the same transition functions have the same multi-step relation.
Equations
- PDA.is_PDA_emptyStack L = ∃ (Q : Type) (S : Type) (x : Fintype Q) (x_1 : Fintype S) (M : PDA Q T S), M.acceptsByEmptyStack = L
Instances For
@[reducible, inline]
A language over a finite terminal alphabet is accepted by some PDA via empty-stack acceptance.
Equations
Instances For
@[simp]
A language over a finite terminal alphabet is accepted by some PDA via final-state acceptance.
Equations
- PDA.is_PDA_finalState L = ∃ (Q : Type) (S : Type) (x : Fintype Q) (x_1 : Fintype S) (M : PDA Q T S), M.acceptsByFinalState = L
Instances For
The class of languages recognized by PDAs via empty-stack acceptance.
Equations
Instances For
The class of languages recognized by PDAs via final-state acceptance.