Documentation

InfinitaryLogic.Admissible.Ackermann

Ackermann coding: hereditarily finite sets as naturals (issue #19A) #

The concrete carrier for the HF admissible presentation. a ∈ₐ b means bit a of b is set, so every natural is a finite set of naturals and the coding is total in both directions.

Why specification laws, not totality #

A closure obligation stated as totality is vacuous:

  pair_total : ∀ a b, ∃ c, Pair a b c

is satisfied by Pair := fun _ _ _ => True on any inhabited carrier — totality is not pairing. Closure is meaningful only against an ambient membership relation together with specification laws saying which element the operation produces. This file supplies that membership for HF and proves the specifications hold.

Only pairing and union are built here. The full KP schema is deliberately not attempted: which closure and absoluteness laws are actually consumed is settled by the proofs that need them, and no such proof exists yet.

Main definitions #

Main results #

def Nat.AckMem (a b : ℕ) :

Ackermann membership: a ∈ₐ b iff bit a of b is set.

Equations
Instances For

    Ackermann membership: a ∈ₐ b iff bit a of b is set.

    Equations
    Instances For
      theorem Nat.ackMem_def {a b : ℕ} :
      theorem Nat.ack_ext {a b : ℕ} (h : ∀ (x : ℕ), x.AckMem a ↔ x.AckMem b) :
      a = b

      Codes with the same members are equal — Ackermann coding is extensional.

      Pairing #

      def Nat.ackPair (a b : ℕ) :

      The Ackermann code of the pair {a, b}.

      Equations
      Instances For
        @[simp]
        theorem Nat.mem_ackPair {a b x : ℕ} :
        x.AckMem (a.ackPair b) ↔ x = a ∨ x = b

        The pairing specification. This is the law the bare pair_total field lacked.

        Union #

        def Nat.ackUnion (a : ℕ) :

        The Ackermann code of ⋃ a: bitwise-or of the members of a.

        Equations
        Instances For
          @[simp]
          theorem Nat.mem_ackUnion {a x : ℕ} :
          x.AckMem a.ackUnion ↔ ∃ (y : ℕ), y.AckMem a ∧ x.AckMem y

          The union specification.

          Finiteness — why A-finite will collapse to finite at HF #

          theorem Nat.finite_ackMem (a : ℕ) :

          Every Ackermann code names a finite set.

          theorem Nat.exists_ack_of_finite {s : Set ℕ} (hs : s.Finite) :
          ∃ (a : ℕ), ∀ (x : ℕ), x.AckMem a ↔ x ∈ s

          …and conversely every finite set of naturals is named by a code.