Skip to content

Commit cadee3a

Browse files
tdM05Bergschaf
authored andcommitted
feat(Algebra/Group/Subgroup/ZPowers): add Int.closure_eq_zmultiples (leanprover-community#39435)
- Show that for `a b : ℤ`, `AddSubgroup.closure {a, b} = AddSubgroup.zmultiples (a.gcd b : ℤ)` - Used Claude to find the names of relevant theorems to use. However, I wrote the whole proof on my own. Co-authored-by: tdM05 <taddmao@gmail.com>
1 parent c599759 commit cadee3a

1 file changed

Lines changed: 6 additions & 0 deletions

File tree

Mathlib/Algebra/Group/Subgroup/ZPowers/Lemmas.lean

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ public import Mathlib.Algebra.Group.Subgroup.Ker
99
public import Mathlib.Algebra.Group.Subgroup.ZPowers.Basic
1010
public import Mathlib.Data.Countable.Basic
1111
public import Mathlib.Data.Int.Cast.Lemmas
12+
public import Mathlib.Data.Int.GCD
1213

1314
/-!
1415
# Subgroups generated by an element
@@ -69,4 +70,9 @@ lemma range_nsmulAddMonoidHom (n : ℕ) : (nsmulAddMonoidHom n).range = zmultipl
6970
simp [mem_zmultiples_iff, dvd_def]
7071
grind
7172

73+
theorem closure_eq_zmultiples (a b : ℤ) : closure {a, b} = zmultiples (a.gcd b : ℤ) := by
74+
apply le_antisymm
75+
· grind [closure_le, mem_zmultiples_iff, SetLike.mem_coe, gcd_dvd_left, gcd_dvd_right]
76+
· simp [zmultiples_le, mem_closure_pair, gcd_eq_gcd_ab, mul_comm]
77+
7278
end Int

0 commit comments

Comments
 (0)