math / data /lean /OAI /Computability /DegreeRigidity /Syntax /LevySigmaNormalization.lean
introvoyz045's picture
Migrated from GitHub
4a56cd6 verified
Raw History Blame Contribute Delete
3.42 kB
import OAI.Computability.DegreeRigidity.Syntax.SigmaDisjunction
namespace OAI
namespace TuringRigidity.BoundedSetTheory
open TransitiveNameModel
universe u
inductive LevySigma where
| bounded (Ο† : Formula)
| conj (Ο† ψ : LevySigma)
| disj (Ο† ψ : LevySigma)
| existsSet (Ο† : LevySigma)
| existsMem (a : β„•) (Ο† : LevySigma)
| allMem (a : β„•) (Ο† : LevySigma)
namespace LevySigma
def Realize (M : ZFSet.{u}) (e : β„• β†’ ZFSet.{u}) : LevySigma β†’ Prop
| .bounded Ο† => Ο†.Realize M e
| .conj Ο† ψ => Ο†.Realize M e ∧ ψ.Realize M e
| .disj Ο† ψ => Ο†.Realize M e ∨ ψ.Realize M e
| .existsSet Ο† => βˆƒ x ∈ M, Ο†.Realize M (cons x e)
| .existsMem a Ο† => βˆƒ x ∈ M, x ∈ e a ∧ Ο†.Realize M (cons x e)
| .allMem a Ο† => βˆ€ x ∈ M, x ∈ e a β†’ Ο†.Realize M (cons x e)
def normalize : LevySigma β†’ SigmaFormula
| .bounded Ο† => .bounded Ο†
| .conj Ο† ψ => .conj Ο†.normalize ψ.normalize
| .disj Ο† ψ => .disj Ο†.normalize ψ.normalize
| .existsSet Ο† => .existsSet Ο†.normalize
| .existsMem a Ο† => .existsMem a Ο†.normalize
| .allMem a Ο† => .allMem a Ο†.normalize
theorem normalize_correct (M : ZFSet.{u}) (hM : Transitive M)
(hP : Pairing M) (hU : BoundedSetTheory.Union M) (hS : Separation M)
(hR : SigmaReplacement M) (hI : Infinity M) (hC : SigmaCollection M)
(Ο† : LevySigma) (e : β„• β†’ ZFSet.{u}) (he : βˆ€ i, e i ∈ M) :
Ο†.normalize.Realize M e ↔ Ο†.Realize M e := by
have hω := omega_mem M hM hS hI
have h0 := hM _ hω _ ZFSet.omega_zero
induction Ο† generalizing e with
| bounded Ο† => rfl
| conj Ο† ψ ihΟ† ihψ => exact (SigmaFormula.realize_conj _ _ _ _).trans (and_congr (ihΟ† e he) (ihψ e he))
| disj Ο† ψ ihΟ† ihψ => exact (SigmaFormula.realize_disj M h0 _ _ _).trans (or_congr (ihΟ† e he) (ihψ e he))
| existsSet Ο† ih =>
simp only [normalize,SigmaFormula.Realize,Realize]
apply exists_congr; intro x
apply and_congr_right; intro hx
exact ih (cons x e) (by intro i; cases i <;> simp [cons,he,hx])
| existsMem a Ο† ih =>
rw [normalize,SigmaFormula.realize_existsMem]
change (βˆƒ x ∈ M, x ∈ e a ∧ _) ↔ βˆƒ x ∈ M, x ∈ e a ∧ _
apply exists_congr; intro x
apply and_congr_right; intro hx
exact and_congr_right (fun _ => ih (cons x e) (by intro i; cases i <;> simp [cons,he,hx]))
| allMem a Ο† ih =>
rw [normalize,SigmaFormula.realize_allMem M hM hP hU hS hR hI hC _ _ _ he]
change (βˆ€ x ∈ e a, _) ↔ βˆ€ x ∈ M, x ∈ e a β†’ _
constructor
Β· intro h x hx hxa
exact (ih (cons x e) (by intro i; cases i <;> simp [cons,he,hx])).mp (h x hxa)
Β· intro h x hxa
have hx := hM _ (he a) x hxa
exact (ih (cons x e) (by intro i; cases i <;> simp [cons,he,hx])).mpr (h x hx hxa)
end LevySigma
def LevySigmaSeparation (M : ZFSet.{u}) : Prop :=
βˆ€ (Ο† : LevySigma) (e : β„• β†’ ZFSet.{u}), (βˆ€ i, e i ∈ M) β†’ βˆ€ a ∈ M,
βˆƒ b ∈ M, βˆ€ x ∈ M, x ∈ b ↔ x ∈ a ∧ Ο†.Realize M (cons x e)
def LevySigmaReplacement (M : ZFSet.{u}) : Prop :=
βˆ€ (Ο† : LevySigma) (e : β„• β†’ ZFSet.{u}), (βˆ€ i, e i ∈ M) β†’ βˆ€ a ∈ M,
(βˆ€ x ∈ a, βˆƒ y ∈ M, Ο†.Realize M (cons y (cons x e)) ∧
βˆ€ z ∈ M, Ο†.Realize M (cons z (cons x e)) β†’ z = y) β†’
βˆƒ b ∈ M, βˆ€ y ∈ M, y ∈ b ↔ βˆƒ x ∈ a, Ο†.Realize M (cons y (cons x e))
end TuringRigidity.BoundedSetTheory
end OAI