Documentation

CslibFrontier.Computability.Complexity.Fagin.Small

Small structures and cardinality splitting #

In Fagin's theorem, the Cook–Levin tableau of a verifier is encoded by k-tuples over the domain M. When Nat.card M ≥ 2, n ^ k grows large enough to index the tableau's time steps and tape positions; when Nat.card M ≤ 1, n ^ k ≤ 1 cannot.

Over a fixed finite relational vocabulary v : Vocabulary L, however, there are only finitely many isomorphism classes of structures of cardinality 0 or 1: every relation table has length n ^ a ≤ 1, so an isomorphism-closed class K restricted to Nat.card M ≤ 1 is determined by a finite Boolean table of first-order sentences and is therefore first-order definable (FO.Definable.inter_card_le_one). Combining this with Mathlib's Sentence.cardGe L 2 reduces existential second-order definability of any isomorphism-closed class K to agreeing with K on finite structures of cardinality at least 2 (ESO.Definable.of_card_ge_two).

Main definitions #

Main results #

References #

Small structures over a finite vocabulary #

The sentence testing whether a relation symbol r is nullary and holds on the empty tuple.

The sentence testing whether the i-th symbol of v is nullary and holds on the empty tuple.

The sentence testing whether a relation symbol r holds on every constant tuple fun _ => x.

The sentence testing whether the i-th symbol of v holds on every constant tuple fun _ => x. In a singleton structure this is the single bit of the symbol's relation table.

The EncodedStructure of cardinality 0 whose nullary tables are given by s.

The EncodedStructure of cardinality 1 whose singleton tables are given by s.

For any isomorphism-closed class K over a finite relational vocabulary, the restriction of K to structures of cardinality at most 1 is first-order definable.

To prove that an isomorphism-closed class K over a finite relational vocabulary is existential second-order definable, it suffices to exhibit an existential second-order sentence Φ that agrees with K on finite structures of cardinality at least 2.

To prove that an isomorphism-closed class K over a finite relational vocabulary is existential second-order definable, it suffices to exhibit an existential second-order sentence Φ over L.sum orderLanguage that agrees with K on finite structures of cardinality at least 2 under every numbering e : M ≃ Fin (Nat.card M).