Skip to content

Commit 970bcfe

Browse files
committed
clean up, skip transitive import, unuse Vector.lean
1 parent bd6c6dc commit 970bcfe

File tree

7 files changed

+31
-437
lines changed

7 files changed

+31
-437
lines changed

Pdl.lean

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,6 @@ import Pdl.LocalTableau
1515
import Pdl.Tableau
1616
import Pdl.TableauExamples
1717
import Pdl.TableauPath
18-
import Pdl.Vector
1918
import Pdl.Soundness
2019
import Pdl.Game
2120
import Pdl.Completeness

Pdl/Distance.lean

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -434,14 +434,8 @@ theorem relateSeq_existsH_dist (v_αγ_w : relateSeq M (α :: γ) v w)
434434
rw [αγ_eq_α_γ, ← δ_eq_α]
435435
simp [distance_list_append]
436436
apply iInf_le
437-
have two : distance_list M v w (α :: γ) ≤ distance_list M v w (δ ++ γ) := by
438-
have := fun u => @relateSeq_H_imp_relate α W M v u _ _ in_H v_X
439-
have : ∀ (u : W), relateSeq M (δ ++ γ) v u → relateSeq M (α :: γ) v u := by
440-
intro u
441-
rw [relateSeq_append]
442-
rw [relateSeq_cons]
443-
aesop
444-
exact distList_le_of_Hsat M v _ α γ in_H v_X -- use (e)
437+
have two : distance_list M v w (α :: γ) ≤ distance_list M v w (δ ++ γ) :=
438+
distList_le_of_Hsat M v _ α γ in_H v_X -- use (e)
445439
exact ⟨in_H, v_X, eq_of_le_of_le one two⟩
446440

447441
/-- 7.47 (h)

Pdl/PartInterpolation.lean

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
import Mathlib.Data.Finset.Basic
22

33
import Pdl.Completeness
4-
import Pdl.Distance
54

65
/-! # Interpolants for Partitions (big part of Section 7) -/
76

Pdl/Soundness.lean

Lines changed: 28 additions & 40 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,8 @@ import Mathlib.Data.Prod.Lex
55
import Mathlib.Data.Vector.Defs
66
import Pdl.TableauPath
77
import Mathlib.Data.ENat.Defs
8+
89
import Pdl.LocalSoundness
9-
import Pdl.Distance
10-
import Pdl.Measures
1110

1211
/-! # Soundness (Section 6) -/
1312

@@ -164,9 +163,6 @@ theorem nodeAt_companionOf_multisetEq {tab : Tableau .nil X} (s : PathIn tab) lp
164163
convert k_same
165164
simp only [List.get_eq_getElem]
166165
have := PathIn.toHistory_eq_Hist s
167-
have : (tabAt_fst_length_eq_toHistory_length s ▸ k).val = k.val := by
168-
apply Fin.val_eq_val_of_heq
169-
simp
170166
simp_all
171167

172168
/-- Any repeat and companion are both loaded. -/
@@ -465,41 +461,34 @@ theorem ePropB.b {tab : Tableau .nil X} (s t : PathIn tab) :
465461
exact Relation.ReflTransGen.single comp
466462

467463
theorem c_claim {a : Sequent} {tab : Tableau [] a} (t l c : PathIn tab) :
468-
(nodeAt t).isFree → t < l → l ♥ c → t < c := by
469-
intro t_free t_above_l l_hearts_c
470-
have ⟨lpr, tabAt_l_def, c_def⟩ := l_hearts_c
471-
by_contra hyp
472-
have c_above_l : c < l := companion_lt l_hearts_c
473-
have comp_leq_t : c ≤ t := by
474-
rcases path_revEuclidean _ _ _ t_above_l c_above_l with h|h|h
475-
· exact False.elim (hyp h)
476-
· exact Relation.TransGen.to_reflTransGen h
477-
· rw [h]
478-
exact Relation.ReflTransGen.refl
479-
have comp_lt_t : c < t := by
480-
apply Relation.TransGen_of_ReflTransGen comp_leq_t
481-
intro c_eq_t
482-
have c_loaded := (companion_loaded l_hearts_c).2
464+
(nodeAt t).isFree → t < l → l ♥ c → t < c := by
465+
intro t_free t_above_l l_hearts_c
466+
have ⟨lpr, tabAt_l_def, c_def⟩ := l_hearts_c
467+
by_contra hyp
468+
have c_above_l : c < l := companion_lt l_hearts_c
469+
have comp_leq_t : c ≤ t := by
470+
rcases path_revEuclidean _ _ _ t_above_l c_above_l with h|h|h
471+
· exact False.elim (hyp h)
472+
· exact Relation.TransGen.to_reflTransGen h
473+
· rw [h]
474+
exact Relation.ReflTransGen.refl
475+
have ⟨k, k', def_c, def_t, k'_le_k⟩ := exists_rewinds_middle comp_leq_t (Relation.TransGen.to_reflTransGen t_above_l)
476+
have t_loaded : (nodeAt t).isLoaded := by
477+
rw [←def_t]
478+
apply companion_to_repeat_all_loaded lpr tabAt_l_def c_def k'
479+
apply Fin.le_def.1 at k'_le_k
480+
have k_is_lpr_succ : k.1 = lpr.1.1.succ := by
481+
have ⟨k_val, k_def⟩ := k
482+
have ⟨⟨lpr_len, lpr_len_pf⟩, ⟨eq_con, loaded_con⟩⟩ := lpr
483+
unfold companionOf at c_def
484+
rw [c_def] at def_c
485+
have := rewind_is_inj def_c
486+
simp [Fin.cast] at this
487+
exact this
488+
simp_all
483489
simp [Sequent.isFree] at t_free
484-
rw [←c_eq_t, c_loaded] at t_free
485-
contradiction
486-
have ⟨k, k', def_c, def_t, k'_le_k⟩ := exists_rewinds_middle comp_leq_t (Relation.TransGen.to_reflTransGen t_above_l)
487-
have t_loaded : (nodeAt t).isLoaded := by
488-
rw [←def_t]
489-
apply companion_to_repeat_all_loaded lpr tabAt_l_def c_def k'
490-
apply Fin.le_def.1 at k'_le_k
491-
have k_is_lpr_succ : k.1 = lpr.1.1.succ := by
492-
have ⟨k_val, k_def⟩ := k
493-
have ⟨⟨lpr_len, lpr_len_pf⟩, ⟨eq_con, loaded_con⟩⟩ := lpr
494-
unfold companionOf at c_def
495-
rw [c_def] at def_c
496-
have := rewind_is_inj def_c
497-
simp [Fin.cast] at this
498-
exact this
499-
simp_all
500-
simp [Sequent.isFree] at t_free
501-
rw [t_loaded] at t_free
502-
contradiction
490+
rw [t_loaded] at t_free
491+
cases t_free
503492

504493
theorem ePropB.c {X} {tab : Tableau .nil X} (s t : PathIn tab) :
505494
(nodeAt s).isFree → s < t → s <ᶜ t := by
@@ -546,7 +535,6 @@ theorem not_cEquiv_of_free_loaded (s t : PathIn tab)
546535
have l_s : l ◃* s := Relation.ReflTransGen.trans l_t t_s
547536
cases eq_or_ne l s
548537
case inl les =>
549-
have := edge_is_strict_ordering sel
550538
simp_all
551539
case inr lnes => exact Relation.TransGen_of_ReflTransGen l_s lnes
552540
case inr shl =>

Pdl/TableauPath.lean

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@ import Mathlib.Data.Finset.Lattice.Fold
22
import Mathlib.Logic.Relation
33

44
import Pdl.Tableau
5-
import Pdl.Vector
65

76
/-! # Navigating through tableaux with PathIn
87

Pdl/Vector.lean renamed to Unused/Vector.lean

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import Mathlib.Tactic.Linarith
33

44
/-! # Helper Lemmas about Vector
55
6-
These are used in `Soundness.lean`.
6+
These were previously used in `Soundness.lean`.
77
-/
88

99
lemma List.nonempty_drop_sub_succ (δ_not_empty : δ ≠ []) (k : Fin δ.length) :

0 commit comments

Comments
 (0)