Skip to content
This repository has been archived by the owner on Jul 24, 2024. It is now read-only.

Commit

Permalink
feat(group_theory/subgroup): Add mem_infi and coe_infi (#3634)
Browse files Browse the repository at this point in the history
These already existed for submonoid, but were not lifted to subgroup.

Also adds some missing `norm_cast` attributes to similar lemmas.
  • Loading branch information
eric-wieser committed Jul 30, 2020
1 parent 985a56b commit f78a012
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 1 deletion.
10 changes: 10 additions & 0 deletions src/group_theory/subgroup.lean
Original file line number Diff line number Diff line change
Expand Up @@ -363,6 +363,16 @@ attribute [norm_cast] coe_Inf add_subgroup.coe_Inf
@[simp, to_additive]
lemma mem_Inf {S : set (subgroup G)} {x : G} : x ∈ Inf S ↔ ∀ p ∈ S, x ∈ p := set.mem_bInter_iff

@[to_additive]
lemma mem_infi {ι : Sort*} {S : ι → subgroup G} {x : G} : (x ∈ ⨅ i, S i) ↔ ∀ i, x ∈ S i :=
by simp only [infi, mem_Inf, set.forall_range_iff]

@[simp, to_additive]
lemma coe_infi {ι : Sort*} {S : ι → subgroup G} : (↑(⨅ i, S i) : set G) = ⋂ i, S i :=
by simp only [infi, coe_Inf, set.bInter_range]

attribute [norm_cast] coe_infi add_subgroup.coe_infi

/-- Subgroups of a group form a complete lattice. -/
@[to_additive "The `add_subgroup`s of an `add_group` form a complete lattice."]
instance : complete_lattice (subgroup G) :=
Expand Down
4 changes: 3 additions & 1 deletion src/group_theory/submonoid/basic.lean
Original file line number Diff line number Diff line change
Expand Up @@ -213,6 +213,8 @@ instance : has_Inf (submonoid M) :=
@[simp, to_additive]
lemma coe_Inf (S : set (submonoid M)) : ((Inf S : submonoid M) : set M) = ⋂ s ∈ S, ↑s := rfl

attribute [norm_cast] coe_Inf add_submonoid.coe_Inf

@[to_additive]
lemma mem_Inf {S : set (submonoid M)} {x : M} : x ∈ Inf S ↔ ∀ p ∈ S, x ∈ p := set.mem_bInter_iff

Expand All @@ -224,7 +226,7 @@ by simp only [infi, mem_Inf, set.forall_range_iff]
lemma coe_infi {ι : Sort*} {S : ι → submonoid M} : (↑(⨅ i, S i) : set M) = ⋂ i, S i :=
by simp only [infi, coe_Inf, set.bInter_range]

attribute [norm_cast] coe_Inf coe_infi
attribute [norm_cast] coe_infi add_submonoid.coe_infi

/-- Submonoids of a monoid form a complete lattice. -/
@[to_additive "The `add_submonoid`s of an `add_monoid` form a complete lattice."]
Expand Down

0 comments on commit f78a012

Please sign in to comment.