Skip to content

Commit f9aa536

Browse files
committed
feat: inf of principal ideals is principal ideal of lcm (#31867)
A basic lemma that seems to be missing from mathlib: I used this when teaching ring theory in the Lean course with `fpvandoorn`.
1 parent 36a2b22 commit f9aa536

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

Mathlib/RingTheory/PrincipalIdealDomain.lean

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -560,3 +560,12 @@ theorem nonPrincipals_zorn (c : Set (Ideal R)) (hs : c ⊆ { I : Ideal R | ¬I.I
560560
exact hs ⟨⟨x, rfl⟩⟩
561561

562562
end PrincipalOfPrime_old
563+
564+
open Ideal in
565+
lemma span_singleton_inf_span_singleton [EuclideanDomain R] [GCDMonoid R] (n m : R) :
566+
span {n} ⊓ span {m} = span {lcm n m} := by
567+
rw [Ideal.ext_iff]
568+
intro x
569+
rw [Ideal.mem_inf]
570+
simp only [Ideal.mem_span_singleton]
571+
exact lcm_dvd_iff.symm

0 commit comments

Comments
 (0)