@@ -79,6 +79,7 @@ def modalToPropModel (MM : Modal.FMT.Model κ α) : FMTSemantics.Model (κ ⊕ U
7979 | .inl k => MM.Val a k
8080 | .inr () => True
8181
82+ /-- Lemma 6.9 -/
8283theorem modalToProp_truthlemma {x : MM.World} :
8384 Modal.FMT.Forced (M := MM) x (A.corsi) ↔ FMTSemantics.Forces (M := modalToPropModel MM) (.inl x) A := by
8485 induction A generalizing x with
@@ -132,49 +133,10 @@ end ModalToProp
132133
133134
134135
135- namespace Formula
136-
137- @[grind]
138- def IsNegation : Formula α → Prop
139- | ∼_ => True
140- | _ => False
141-
142- instance : DecidablePred (IsNegation : Formula α → Prop ) := by
143- intro A;
144- match A with
145- | ∼_ => exact isTrue trivial
146- | #_ | ⊥ | _ ⋏ _ | _ ⋎ _
147- | _ 🡒 #_ | _ 🡒 (_ ⋏ _) | _ 🡒 (_ 🡒 _) | _ 🡒 (_ ⋎ _)
148- => exact isFalse (by grind);
149-
150- end Formula
151136
152137
153138variable {α : Type u} [DecidableEq α]
154139
155- namespace Formula
156-
157- def cases_neg {P : Formula α → Prop }
158- (falsum : P (⊥ : Formula α))
159- (atom : ∀ a, P (#a))
160- (and : ∀ A B, P (A ⋏ B))
161- (or : ∀ A B, P (A ⋎ B))
162- (imp : ∀ A B, B ≠ (⊥ : Formula α) → P (A 🡒 B))
163- (neg : ∀ A, P (∼A))
164- : ∀ A, P A := by
165- intro A;
166- match A with
167- | ⊥ | #_ | _ ⋏ _ | _ ⋎ _
168- | _ 🡒 ⊥ | _ 🡒 #_
169- | _ 🡒 (_ ⋏ _) | _ 🡒 (_ ⋎ _) | _ 🡒 (_ 🡒 _)
170- => grind;
171-
172- omit [DecidableEq α] in
173- @[grind →]
174- lemma isClosed_of_isCNA {A : Formula α} : A.IsClosedNegativeAxiom → A.Closed := by grind;
175-
176- end Formula
177-
178140namespace Axioms
179141
180142def star (Λ : Axioms α) := Λ.filterMap (λ A => match A with | ∼B => some (∼(B.corsi)) | _ => none) $ by
@@ -193,51 +155,127 @@ lemma mem_star_of_mem_neg {B : Formula α} (hB : ∼B ∈ Λ) : ∼(B.corsi) ∈
193155end Axioms
194156
195157
158+ namespace Modal.Formula
159+
160+ @[grind]
161+ def negRepeat : ℕ → Formula α → Formula α
162+ | 0 , A => A
163+ | n + 1 , A => ∼(negRepeat n A)
164+
165+ notation " ∼^[" n " ]" A => negRepeat n A
166+
167+ lemma negRepeat_succ_rw {n : ℕ} : (∼^[2 * (n + 1 )]A) = ∼(∼^[2 * n](∼A)) := by
168+ induction n <;> simp_all [negRepeat];
169+
170+ end Modal.Formula
196171
197- theorem modal_companion
198- {Λ : Axioms α} (hX : ∀ B ∈ Λ, B.IsClosedNegativeAxiom)
199- [Fact ((Λ.star) ⊬ᴺ ⊥)] [Axioms.DisjunctiveVF Λ]
200- : (Λ ⊢ⱽ A) ↔ ((Λ.star) ⊢ᴺ A.corsi) := by
201- have : Fact (∀ B ∈ Λ, B.IsClosedNegativeAxiom) := ⟨hX⟩;
172+
173+ namespace Formula
174+
175+ variable {C : Formula α}
176+
177+ omit [DecidableEq α] in
178+ @[simp, grind .]
179+ lemma top_neq_corsi : (⊤ : Modal.Formula α) ≠ C.corsi := by induction C <;> grind [Formula.corsi];
180+
181+ omit [DecidableEq α] in
182+ @[simp, grind .]
183+ lemma double_negRepeat_top_neq_corsi {n} {C : Formula α} : (∼^[2 * n]⊤) ≠ C.corsi := by
184+ match n with
185+ | 0 => grind [top_neq_corsi];
186+ | n + 1 => induction C <;> grind [Formula.corsi, double_negRepeat_top_neq_corsi (n := n)];
187+
188+ omit [DecidableEq α] in
189+ @[simp, grind .]
190+ lemma double_negRepeat_bot_neq_corsi_imp {n} {C D : Formula α} : (∼^[2 * n]⊥) ≠ (C.corsi 🡒 D.corsi) := by
191+ cases n <;> grind [Modal.Formula.negRepeat_succ_rw, Modal.Formula.negRepeat];
192+
193+ end Formula
194+
195+
196+ namespace Modal.FMT
197+
198+ omit [DecidableEq α] in
199+ @[grind =]
200+ lemma notForces_double_negRepeat {M : Model κ α} {x : M.World} : (x ⊩ (∼^[2 * n]A)) ↔ (x ⊩ A) := by
201+ induction n with
202+ | zero => grind;
203+ | succ n ih =>
204+ apply Iff.trans ?_ ih;
205+ simp [Modal.Formula.negRepeat];
206+ grind;
207+
208+ end Modal.FMT
209+
210+
211+ section
212+
213+ variable {Λ : Axioms α} {A : Formula α}
214+
215+ lemma provableN_star_of_provableVF
216+ [Fact (∀ B ∈ Λ, B.IsClosedNegativeAxiom)] [Fact ((Λ.star) ⊬ᴺ ⊥)]
217+ : (Λ ⊢ⱽ A) → (Λ.star ⊢ᴺ A.corsi) := by
218+ have hCNA : ∀ B ∈ Λ, B.IsClosedNegativeAxiom := Fact.out;
219+ intro h;
220+ apply Modal.FMT.finite_model_property;
221+ intro κ _ MM hValid x;
222+ apply (modalToProp_truthlemma).mpr;
223+ apply FMTSemantics.soundness_model h (modalToPropModel MM);
224+ intro B hB;
225+ obtain ⟨C, rfl, hCClosed, _⟩ := Formula.iff_isCNA.mp (Fact.elim (p := ∀ B ∈ Λ, B.IsClosedNegativeAxiom) inferInstance B hB);
226+ intro y z Ryz hzC;
227+ have hValC : ∀ y, ¬ Modal.FMT.Forced (M := MM) y (C.corsi) := by
228+ intro y';
229+ have hMem : ∼(C.corsi) ∈ Λ.star := Axioms.mem_star_of_mem_neg hB;
230+ exact hValid _ hMem y';
231+ exact modalToProp_notForces_closed_of_neg hCClosed hValC hzC;
232+
233+ lemma provableN_star_repeatNeg_of_provableN_star {N : Finset ℕ} : Λ.star ⊢ᴺ A.corsi → (Λ.star ∪ N.image (λ n => ∼□∼^[2 * n]⊥)) ⊢ᴺ A.corsi := by
234+ apply Modal.ProvableN.ofSubsetAxm;
235+ grind;
236+
237+ lemma provableVF_of_provableN_star_repeatNeg
238+ {N : Finset ℕ}
239+ [Fact (∀ B ∈ Λ, B.IsClosedNegativeAxiom)]
240+ [Fact (Λ.star ∪ Finset.image (λ n ↦ ∼□∼^[2 * n]⊥) N ⊬ᴺ ⊥)]
241+ : (Λ.star ∪ N.image (λ n => ∼□(∼^[2 * n]⊥))) ⊢ᴺ A.corsi → Λ ⊢ⱽ A := by
242+ have hCNA : ∀ B ∈ Λ, B.IsClosedNegativeAxiom := Fact.out;
243+ contrapose;
244+ intro h;
245+ replace h := FMTSemantics.result_frame (Λ := Λ) (by grind) |>.not.out 0 1 |>.mp h;
246+ push Not at h;
247+ obtain ⟨_, PF, hPF, h⟩ := h;
248+ obtain ⟨PV, x, hx⟩ := FMTSemantics.iff_notFrameValid_exists_model_world.mp h;
249+ apply Modal.FMT.result_model.not.out 0 1 |>.mpr;
250+ push Not;
251+ use ‹_›, propToModalModel ⟨PF, PV⟩;
202252 constructor;
203- · intro h;
204- apply Modal.FMT.finite_model_property;
205- intro κ _ MM hValid x;
206- apply (modalToProp_truthlemma).mpr;
207- apply FMTSemantics.soundness_model h (modalToPropModel MM);
208- intro B hB;
209- obtain ⟨C, rfl, hCClosed, _⟩ := Formula.iff_isCNA.mp (hX B hB);
210- intro y z Ryz hzC;
211- have hValC : ∀ y, ¬ Modal.FMT.Forced (M := MM) y (C.corsi) := by
212- intro y';
213- have hMem : ∼(C.corsi) ∈ Λ.star := Axioms.mem_star_of_mem_neg hB;
214- exact hValid _ hMem y';
215- exact modalToProp_notForces_closed_of_neg hCClosed hValC hzC;
216- · contrapose;
217- intro h;
218- replace h := FMTSemantics.result_frame (Λ := Λ) (by grind) |>.not.out 0 1 |>.mp h;
219- push Not at h;
220- obtain ⟨_, PF, hPF, h⟩ := h;
221- obtain ⟨PV, x, hx⟩ := FMTSemantics.iff_notFrameValid_exists_model_world.mp h;
222- apply Modal.FMT.result_model.not.out 0 1 |>.mpr;
223- push Not;
224- use ‹_›, propToModalModel ⟨PF, PV⟩;
225- constructor;
226- . intro B hB;
227- obtain ⟨C, hC₁, hC₂⟩ := Finset.mem_filterMap _ |>.mp hB;
253+ . intro B hB;
254+ simp only [Finset.mem_union, Finset.mem_image] at hB;
255+ rcases hB with (hB | ⟨n, hN, rfl⟩);
256+ . obtain ⟨C, hC₁, hC₂⟩ := Finset.mem_filterMap _ |>.mp hB;
228257 split at hC₂;
229258 . simp only [Option.some.injEq] at hC₂;
230259 subst hC₂;
231260 rename_i C;
232- obtain ⟨D, _, _, _⟩ := Formula.iff_isCNA.mp $ hX (∼C) ‹_›;
261+ obtain ⟨D, _, _, _⟩ := Formula.iff_isCNA.mp $ hCNA (∼C) ‹_›;
233262 intro y;
234263 apply Modal.FMT.forces_not.mpr;
235264 apply propToModal_truthlemma.not.mp;
236265 exact FMTSemantics.iff_FrameForces_Forces_of_closed (by grind) |>.not.mp
237266 $ FMTSemantics.iff_FrameValid_neg_of_closed (by grind) |>.mp (hPF _ hC₁) y;
238267 . contradiction;
239- . replace hx := propToModal_truthlemma.not.mp hx;
240- apply Modal.FMT.iff_Valid_exists_world_not_Forces.mpr;
241- use x;
268+ . intro y;
269+ apply Modal.FMT.notForces_box.mpr;
270+ use y;
271+ constructor;
272+ . intro C D;
273+ grind;
274+ . grind;
275+ . replace hx := propToModal_truthlemma.not.mp hx;
276+ apply Modal.FMT.iff_Valid_exists_world_not_Forces.mpr;
277+ use x;
278+
279+ end
242280
243281end
0 commit comments