Langlib

Langlib.Automata.Pushdown.Equivalence.ContextFree

theorem is_CF_of_is_PDA {T : Type} [Fintype T] {L : Language T} :

Every context-free language (with possibly infinite NT) is accepted by some PDA. This removes the [Fintype g.NT] requirement from is_PDA_of_mathlib_cfg by first restricting the grammar to one with finite nonterminals.

The PDA-recognizable languages are exactly the context-free languages.

The class of context-free languages equals the class of PDA-recognizable languages.