Encodings and Cardinality of First-Order Syntax #
Main Definitions #
FirstOrder.Language.Term.encodingencodes terms as lists.FirstOrder.Language.BoundedFormula.encodingencodes bounded formulas as lists.
Main Results #
FirstOrder.Language.Term.card_leshows that the number of terms inL.Term αis at mostmax ℵ₀ # (α ⊕ Σ i, L.Functions i).FirstOrder.Language.BoundedFormula.card_leshows that the number of bounded formulas inΣ n, L.BoundedFormula α nis at mostmax ℵ₀ (Cardinal.lift.{max u v} #α + Cardinal.lift.{u'} L.card).
TODO #
Primcodableinstances for terms and formulas, based on theencodings- Computability facts about term and formula operations, to set up a computability approach to incompleteness
theorem
FirstOrder.Language.Term.listDecode_encode_list
{L : Language}
{α : Type u'}
(l : List (L.Term α))
:
def
FirstOrder.Language.Term.encoding
{L : Language}
{α : Type u'}
:
Computability.Encoding (L.Term α)
An encoding of terms as lists.
Equations
Instances For
@[simp]
@[simp]
theorem
FirstOrder.Language.Term.card_sigma
{L : Language}
{α : Type u'}
:
Cardinal.mk ((n : ℕ) × L.Term (α ⊕ Fin n)) = max Cardinal.aleph0 (Cardinal.mk (α ⊕ (i : ℕ) × L.Functions i))
instance
FirstOrder.Language.Term.small
{L : Language}
{α : Type u'}
[Small.{u, u'} α]
:
Small.{u, max u u'} (L.Term α)
def
FirstOrder.Language.BoundedFormula.sigmaAll
{L : Language}
{α : Type u'}
:
(n : ℕ) × L.BoundedFormula α n → (n : ℕ) × L.BoundedFormula α n
Applies the forall quantifier to an element of (Σ n, L.BoundedFormula α n),
or returns default if not possible.
Equations
Instances For
def
FirstOrder.Language.BoundedFormula.sigmaImp
{L : Language}
{α : Type u'}
:
(n : ℕ) × L.BoundedFormula α n → (n : ℕ) × L.BoundedFormula α n → (n : ℕ) × L.BoundedFormula α n
Applies imp to two elements of (Σ n, L.BoundedFormula α n),
or returns default if not possible.
Equations
Instances For
@[simp]
theorem
FirstOrder.Language.BoundedFormula.listDecode_encode_list
{L : Language}
{α : Type u'}
(l : List ((n : ℕ) × L.BoundedFormula α n))
:
def
FirstOrder.Language.BoundedFormula.encoding
{L : Language}
{α : Type u'}
:
Computability.Encoding ((n : ℕ) × L.BoundedFormula α n)
An encoding of bounded formulas as lists.
Equations
Instances For
@[simp]
theorem
FirstOrder.Language.BoundedFormula.encoding_encode
{L : Language}
{α : Type u'}
(φ : (n : ℕ) × L.BoundedFormula α n)
:
theorem
FirstOrder.Language.BoundedFormula.listEncode_sigma_injective
{L : Language}
{α : Type u'}
:
Function.Injective fun (φ : (n : ℕ) × L.BoundedFormula α n) => φ.snd.listEncode
theorem
FirstOrder.Language.BoundedFormula.card_le
{L : Language}
{α : Type u'}
:
Cardinal.mk ((n : ℕ) × L.BoundedFormula α n) ≤ max Cardinal.aleph0 (Cardinal.lift.{max u v, u'} (Cardinal.mk α) + Cardinal.lift.{u', max u v} L.card)