Skip to content

Commit 1b78b6e

Browse files
feat(Algebra/Module/Submodule): Symmetric submodules are modular elements in the lattice of submodules over a semiring (#36689)
Add two lemmas that are replacements for modularity on the lattice of submodules that are not necessarily over a ring, but a semiring: - `sup_inf_assoc_of_le_of_neg_le`: if `s ≤ p` and `-s ≤ p` then `(s ⊔ t) ⊓ p = s ⊔ (t ⊓ p)` - `inf_sup_assoc_of_le_of_neg_le`: if `p ≤ s` and `-p ≤ s` then `(s ⊓ t) ⊔ p = s ⊓ (t ⊔ p)` This allows to shorten the proof that the lattice of submodules over a ring is modular. I also add specialized versions for cones. Co-authored-by: Martin Winter <martin.winter.math@gmail.com>
1 parent c60f516 commit 1b78b6e

File tree

2 files changed

+38
-9
lines changed

2 files changed

+38
-9
lines changed

Mathlib/Geometry/Convex/Cone/Pointed.lean

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -284,7 +284,22 @@ theorem toConvexCone_positive : ↑(positive R E) = ConvexCone.positive R E :=
284284

285285
end PositiveCone
286286

287+
section AddCommGroup
288+
289+
variable {R M : Type*} [Ring R] [PartialOrder R] [IsOrderedRing R] [AddCommGroup E] [Module R E]
290+
291+
lemma sup_inf_assoc_of_le_submodule {C : PointedCone R E} (D : PointedCone R E)
292+
{S : Submodule R E} (hCS : C ≤ S) : (C ⊔ D) ⊓ S = C ⊔ (D ⊓ S) :=
293+
sup_inf_assoc_of_le_of_neg_le _ hCS (fun _ hx => by simpa using hCS hx)
294+
295+
lemma inf_sup_assoc_of_le_of_submodule_le {C : PointedCone R E} (D : PointedCone R E)
296+
{S : Submodule R E} (hSC : S ≤ C) : (C ⊓ D) ⊔ S = C ⊓ (D ⊔ S) :=
297+
inf_sup_assoc_of_le_of_neg_le _ hSC (fun _ hx => by apply hSC; simpa [hSC] using hx)
298+
299+
end AddCommGroup
300+
287301
section OrderedAddCommGroup
302+
288303
variable [Ring R] [PartialOrder R] [IsOrderedRing R] [AddCommGroup E] [PartialOrder E]
289304
[IsOrderedAddMonoid E] [Module R E]
290305

Mathlib/LinearAlgebra/Span/Basic.lean

Lines changed: 23 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -457,7 +457,27 @@ end AddCommMonoid
457457

458458
section AddCommGroup
459459

460-
variable [Ring R] [AddCommGroup M] [Module R M]
460+
variable {R M : Type*} [Semiring R] [AddCommGroup M] [Module R M]
461+
462+
lemma sup_inf_assoc_of_le_of_neg_le {s : Submodule R M} (t : Submodule R M)
463+
{p : Submodule R M} (hsp : s ≤ p) (hnsp : ∀ x ∈ s, -x ∈ p) :
464+
(s ⊔ t) ⊓ p = s ⊔ (t ⊓ p) := by
465+
ext x; simp only [mem_sup, mem_inf]
466+
constructor
467+
· rintro ⟨⟨y, hy, z, hz, hyzx⟩, hx⟩
468+
refine ⟨y, hy, z, ⟨hz, ?_⟩, hyzx⟩
469+
rw [← add_right_inj, neg_add_cancel_left] at hyzx
470+
simpa [hyzx] using p.add_mem (hnsp y hy) hx
471+
· rintro ⟨y, hy, z, ⟨hz, hz'⟩, hyzx⟩
472+
refine ⟨⟨y, hy, z, hz, hyzx⟩, ?_⟩
473+
simpa [← hyzx] using p.add_mem (hsp hy) hz'
474+
475+
lemma inf_sup_assoc_of_le_of_neg_le {s : Submodule R M} (t : Submodule R M)
476+
{p : Submodule R M} (hps : p ≤ s) (hnps : ∀ x ∈ p, -x ∈ s) :
477+
(s ⊓ t) ⊔ p = s ⊓ (t ⊔ p) := by
478+
rw [sup_comm, inf_comm, ← sup_inf_assoc_of_le_of_neg_le t hps hnps, inf_comm, sup_comm]
479+
480+
variable {R M : Type*} [Ring R] [AddCommGroup M] [Module R M]
461481

462482
lemma _root_.AddSubgroup.toIntSubmodule_closure (s : Set M) :
463483
(AddSubgroup.closure s).toIntSubmodule = .span ℤ s :=
@@ -471,14 +491,8 @@ theorem span_neg (s : Set M) : span R (-s) = span R s :=
471491
_ = map (-LinearMap.id) (span R s) := (map_span (-LinearMap.id) _).symm
472492
_ = span R s := by simp
473493

474-
instance : IsModularLattice (Submodule R M) :=
475-
fun y z xz a ha => by
476-
rw [mem_inf, mem_sup] at ha
477-
rcases ha with ⟨⟨b, hb, c, hc, rfl⟩, haz⟩
478-
rw [mem_sup]
479-
refine ⟨b, hb, c, mem_inf.2 ⟨hc, ?_⟩, rfl⟩
480-
rw [← add_sub_cancel_right c b, add_comm]
481-
apply z.sub_mem haz (xz hb)⟩
494+
instance : IsModularLattice (Submodule R M) := ⟨fun x _ hxy _ _ => by
495+
rwa [← sup_inf_assoc_of_le_of_neg_le x hxy (fun _ hy => neg_mem (hxy hy))]⟩
482496

483497
lemma isCompl_comap_subtype_of_isCompl_of_le {p q r : Submodule R M}
484498
(h₁ : IsCompl q r) (h₂ : q ≤ p) :

0 commit comments

Comments
 (0)