Hereditarily Finite Sets in Constructive Type Theory

Introduction
Finding an Axiomatization
Operations and Categoricity
Constructing a Model
Sources
Hereditarily Finite Sets
in Constructive Type Theory
joint work with
Gert Smolka
Kathrin Stark
Advisor: Prof. Dr. Gert Smolka
saarland
university
computer science
15th March 2016
1
Introduction
Finding an Axiomatization
Operations and Categoricity
Constructing a Model
Sources
Constructive Type Theory
I
based on the Curry-Howard Isomorphism:
propositions as types, proofs as programs
I
working with
I dependent function types:
I dependent pair types:
I
∀
∃
Coq: an interactive theorem prover working on the
Calculus of Inductive Constructions
2
Introduction
Finding an Axiomatization
Operations and Categoricity
Constructing a Model
Sources
What are Hereditarily Finite (HF) Sets?
x
∅ : HF
: HF y : HF
{x } ∪ y : HF
| {z }
x .y
⇒ nite and well-founded sets whose members are again HF
...
...
3
Introduction
Finding an Axiomatization
Operations and Categoricity
Constructing a Model
Sources
Sources
Moto-o Takahashi, 1977.
A foundation of nite mathematics.
Steven Givant, Alfred Tarski, 1977.
Peano arithmetic and the Zermelo-like theory of sets with nite rank.
Flavio Previale, 1994.
Induction and foundation in the theory of hereditarily nite sets.
S. ‘wierczowski, 2003.
Finite sets and Gödel's incompleteness theorems.
Laurence Kirby, 2009.
Finitary set theory.
Lawrence C. Paulson, 2015.
A mechanised Proof of Gödel's Incompleteness Theorem using Nominal
Isabelle.
Lawrence C. Paulson, 2015.
A formalisation of nite automata using hereditarily nite sets.
4
Introduction
Finding an Axiomatization
Operations and Categoricity
Constructing a Model
Sources
Outline
Ordinals & Cardinality
∪, power, TC...
Categoricity
Axiomatization
Models
naive set-th. model
Tree Model
Ackermann Model
5
Introduction
Finding an Axiomatization
Operations and Categoricity
Constructing a Model
Sources
ZF with Negated Innity
Primitives:
∅, ∈
ˆ (∀z .z ∈ x ↔ z ∈ y ) → x = y
ˆ (∀x .(∀z ∈ x .p (x )) → ∀x .p (x ))
ˆ z∈
/∅
ˆ z ∈ pair x y ↔ z = x ∨ z = y
Extensionality
Epsilon induction
Empty Set
Unordered Pair
ˆ z ∈∪x y ↔z ∈x ∨z ∈y
Union
ˆ z ∈Px ↔z ⊆x
Power
ˆ z ∈ f [x ] ↔ ∃a ∈ x .f a = z
ˆ z ∈ x |p ↔ z ∈ x ∧ p z
Replacement
Separation
ˆ + restriction to get just the nite sets?
6
Introduction
Finding an Axiomatization
Operations and Categoricity
Constructing a Model
Sources
Takahashi (1977), Givant & Tarksi (1977),
‘wierczkowski (2003)
Primitives:
∅, x .y ,
x
∈y
ˆ (∀z .z ∈ x ↔ z ∈ y ) → x = y
ˆ z∈
/∅
ˆ z ∈ x .y ↔ z = x ∨ z ∈ y
ˆ p (∅) → (∀ax .p (a) → p (x ) → p (a.x )) → ∀x .p (x )
Extensionality
Empty Set
Membership
Induction
7
Introduction
Finding an Axiomatization
Operations and Categoricity
Constructing a Model
Sources
Previale, 1994
Primitives:
∅, x .y , x \y ,
x
∈ y,
x
<y
ˆ (∀z .z ∈ x ↔ z ∈ y ) → x = y
ˆ z∈
/∅
ˆ z ∈ x .y ↔ z = x ∨ z ∈ y
ˆ p (∅) → (∀xy .p (x ) → p (y ) → y ∈
/ x → p (x .y )) → ∀x .p (x )
ˆ z ∈ x \y ↔ z ∈ x ∧ z 6= y
ˆ z 6< ∅
ˆ z < x .y ↔ z < x ∨ z ≤ y
Extensionality
Empty Set
Membership
Induction
Without
Size
∅
Size Adj.
8
Introduction
Finding an Axiomatization
Operations and Categoricity
Constructing a Model
Sources
Kirby, 2009
Primitives:
∅, x .y
ˆ x .∅ 6= ∅
ˆ x .(x .y ) = x .y
ˆ x .(y .z ) = y .(x .z )
Empty Set
Cancel
Swap
ˆ z ∈ x .y ↔ z = x ∨ z ∈ y
Membership
ˆ z .x .y = x .y → z = x ∨ z .y = y
Membership
ˆ p (∅) → (∀ax .p (a) → p (x ) → p (a.x )) → ∀x .p (x )
Induction
Dene x ∈ y := x .y = y .
Extensionality is still provable.
9
Introduction
Finding an Axiomatization
Operations and Categoricity
Constructing a Model
Sources
Our Axiomatization
Primitives:
∅, x .y
ˆ ∀x y : HF .x = y ∨ x 6= y
ˆ x .y 6= ∅
ˆ x .(x .y ) = x .y
ˆ x .(y .z ) = y .(x .z )
ˆ z .x .y = x .y → z = x ∨ z .y = y
Discreteness
Empty Set
Cancel
Swap
Membership
ˆ ∀p : X → Type .
p (∅) → (∀ax .p (a) → p (x ) → p (a.x )) → ∀x .p (x )
Induction
10
Introduction
Finding an Axiomatization
Operations and Categoricity
Constructing a Model
Sources
Outline
Ordinals & Cardinality
∪, power, TC...
Categoricity
Axiomatization
Models
naive set-th. model
Tree Model
Ackermann Model
11
Introduction
Finding an Axiomatization
Operations and Categoricity
Constructing a Model
Sources
Dening Union
Functional Programming
1. Dene recursive equations.
⇒ x ∪ y :=
R y (λa x pa
|{z}
∅∪y
px .(a.px )) x
|{z} |{z}
a∪y
x ∪y
2. Prove specication.
Recursion Principle
: We have no equations for
the recursor! So how to prove
that x ∪ y satises the desired
properties?
1. Dene specication.
But
x ∪0 y :
∃u .∀z . z ∈ u ↔ z ∈ x ∨ z ∈ y
2. Prove recursive equations.
R
: ∀p : X → Type .p (∅) → (∀ax .p (a) → p (x ) → p (a.x )) → ∀x .p
x
12
Introduction
Finding an Axiomatization
Operations and Categoricity
Constructing a Model
Sources
Outline
Ordinals & Cardinality
∪, power, TC...
Categoricity
Axiomatization
Models
naive set-th. model
Tree Model
Ackermann Model
13
Introduction
Finding an Axiomatization
Operations and Categoricity
Constructing a Model
Sources
Categoricity
structure-preserving
Y
X
algebraic isomorphism + homomorphism + bisimulation
R a b
R
∅∅
Totality:
∀x ∃y .R
Simulation:
R x y
Functionality:
R x y
R
R x y
(a.x ) (b.y )
x y
→ a ∈ x → ∃b.b ∈ y ∧ R
→R
x
0
y
→y =
a b
0
y
14
Introduction
Finding an Axiomatization
Operations and Categoricity
Constructing a Model
Sources
Outline
Ordinals & Cardinality
∪, power, TC...
Categoricity
Axiomatization
Models
naive set-th. model
Tree Model
Ackermann Model
15
Introduction
Finding an Axiomatization
Operations and Categoricity
Constructing a Model
Sources
Equality of HF Sets
=
{∅, ∅}
16
Introduction
Finding an Axiomatization
Operations and Categoricity
Constructing a Model
Sources
Constructing a Model From Binary Trees
≡
≡
{{∅}, ∅}
⇒ Construct a normalizer σ and then a quotient of binary trees.
Denis Müller. A Syntactic Theory of Finitary Sets. Bachelor Thesis, 2015.
17
Introduction
Finding an Axiomatization
Operations and Categoricity
Constructing a Model
Sources
Future Work
I
I
I
Construct the Ackermann model.
Finite sets of decidable types.
Extension to non-wellfounded sets.
18
Introduction
Finding an Axiomatization
Operations and Categoricity
Constructing a Model
Sources
Thank you for your attention!
19