The Chomsky hierarchy is strict

Statement

Langlib formalizes the following strict inclusions and the currently available bridges between the grammar classes:

  • Regular ⊊ Deterministic context-free ⊊ Context-free
  • Context-free ⊊ Indexed ⊊ Context-sensitive ⊊ Recursive ⊊ Recursively enumerable
  • Regular ⊊ Linear ⊊ CFL

The displayed chains are class-level shorthand. The per-alphabet strictness theorems carry the hypotheses listed below. In particular, IndexedCS is proved for finite alphabets with at least two symbols, whereas IndexedCS holds over every terminal type.

In Lean

Proof idea

Each strict inclusion combines an inclusion (every grammar/automaton of the lower class is one of the upper class) with strictness witnessed in one of two ways — a separating language in the upper class but provably not the lower, or a closure mismatch where the two classes differ on a closure operation.

Keywords / also known as

Chomsky hierarchy strict, regular proper subset context-free, DCFL proper subset CFL, context-free proper subset indexed, indexed proper subset context-sensitive, recursive proper subset recursively enumerable, language class separations, proper containment Chomsky hierarchy.

Formalized in Lean 4 with Mathlib, in Langlib.