Skip to content

Commit

Permalink
feat(GroupTheory/Sylow): add inverse to card_eq_multiplicity (#5831)
Browse files Browse the repository at this point in the history
  • Loading branch information
b-reinke committed Jul 13, 2023
1 parent acb87f0 commit 350feed
Showing 1 changed file with 26 additions and 7 deletions.
33 changes: 26 additions & 7 deletions Mathlib/GroupTheory/Sylow.lean
Expand Up @@ -4,7 +4,7 @@ Released under Apache 2.0 license as described in the file LICENSE.
Authors: Chris Hughes, Thomas Browning
! This file was ported from Lean 3 source module group_theory.sylow
! leanprover-community/mathlib commit c55911f6166b348e1c72b08c8664e3af5f1ce334
! leanprover-community/mathlib commit bd365b1a4901dbd878e86cb146c2bd86533df468
! Please do not edit these lines, except to modify the commit id
! if you have ported upstream changes.
-/
Expand Down Expand Up @@ -37,7 +37,7 @@ The Sylow theorems are the following results for every finite group `G` and ever
there exists a subgroup of `G` of order `pⁿ`.
* `IsPGroup.exists_le_sylow`: A generalization of Sylow's first theorem:
Every `p`-subgroup is contained in a Sylow `p`-subgroup.
* `Sylow.card_eq_multiplicity`: The cardinality of a Sylow group is `p ^ n`
* `Sylow.card_eq_multiplicity`: The cardinality of a Sylow subgroup is `p ^ n`
where `n` is the multiplicity of `p` in the group order.
* `sylow_conjugate`: A generalization of Sylow's second theorem:
If the number of Sylow `p`-subgroups is finite, then all Sylow `p`-subgroups are conjugate.
Expand Down Expand Up @@ -686,7 +686,7 @@ theorem ne_bot_of_dvd_card [Fintype G] {p : ℕ} [hp : Fact p.Prime] (P : Sylow
rwa [h, card_bot] at key
#align sylow.ne_bot_of_dvd_card Sylow.ne_bot_of_dvd_card

/-- The cardinality of a Sylow group is `p ^ n`
/-- The cardinality of a Sylow subgroup is `p ^ n`
where `n` is the multiplicity of `p` in the group order. -/
theorem card_eq_multiplicity [Fintype G] {p : ℕ} [hp : Fact p.Prime] (P : Sylow p G) :
card P = p ^ Nat.factorization (card G) p := by
Expand All @@ -696,6 +696,25 @@ theorem card_eq_multiplicity [Fintype G] {p : ℕ} [hp : Fact p.Prime] (P : Sylo
exact P.1.card_subgroup_dvd_card
#align sylow.card_eq_multiplicity Sylow.card_eq_multiplicity

/-- A subgroup with cardinality `p ^ n` is a Sylow subgroup
where `n` is the multiplicity of `p` in the group order. -/
def ofCard [Fintype G] {p : ℕ} [Fact p.Prime] (H : Subgroup G) [Fintype H]
(card_eq : card H = p ^ (card G).factorization p) : Sylow p G
where
toSubgroup := H
isPGroup' := IsPGroup.of_card card_eq
is_maximal' := by
obtain ⟨P, hHP⟩ := (IsPGroup.of_card card_eq).exists_le_sylow
exact SetLike.ext'
(Set.eq_of_subset_of_card_le hHP (P.card_eq_multiplicity.trans card_eq.symm).le).symm ▸ P.3
#align sylow.of_card Sylow.ofCard

@[simp, norm_cast]
theorem coe_ofCard [Fintype G] {p : ℕ} [Fact p.Prime] (H : Subgroup G) [Fintype H]
(card_eq : card H = p ^ (card G).factorization p) : ↑(ofCard H card_eq) = H :=
rfl
#align sylow.coe_of_card Sylow.coe_ofCard

theorem subsingleton_of_normal {p : ℕ} [Fact p.Prime] [Finite (Sylow p G)] (P : Sylow p G)
(h : (P : Subgroup G).Normal) : Subsingleton (Sylow p G) := by
apply Subsingleton.intro
Expand Down Expand Up @@ -759,14 +778,14 @@ theorem normal_of_normalizerCondition (hnc : NormalizerCondition G) {p : ℕ} [F

open BigOperators

/-- If all its sylow groups are normal, then a finite group is isomorphic to the direct product
of these sylow groups.
/-- If all its Sylow subgroups are normal, then a finite group is isomorphic to the direct product
of these Sylow subgroups.
-/
noncomputable def directProductOfNormal [Fintype G]
(hn : ∀ {p : ℕ} [Fact p.Prime] (P : Sylow p G), (↑P : Subgroup G).Normal) :
(∀ p : (card G).factorization.support, ∀ P : Sylow p G, (↑P : Subgroup G)) ≃* G := by
set ps := (Fintype.card G).factorization.support
-- “The” sylow group for p
-- “The” Sylow subgroup for p
let P : ∀ p, Sylow p G := default
have hcomm : Pairwise fun p₁ p₂ : ps => ∀ x y : G, x ∈ P p₁ → y ∈ P p₂ → _root_.Commute x y := by
rintro ⟨p₁, hp₁⟩ ⟨p₂, hp₂⟩ hne
Expand All @@ -776,7 +795,7 @@ noncomputable def directProductOfNormal [Fintype G]
apply Subgroup.commute_of_normal_of_disjoint _ _ (hn (P p₁)) (hn (P p₂))
apply IsPGroup.disjoint_of_ne p₁ p₂ hne' _ _ (P p₁).isPGroup' (P p₂).isPGroup'
refine' MulEquiv.trans (N := ∀ p : ps, P p) _ _
-- There is only one sylow group for each p, so the inner product is trivial
-- There is only one Sylow subgroup for each p, so the inner product is trivial
show (∀ p : ps, ∀ P : Sylow p G, P) ≃* ∀ p : ps, P p
· -- here we need to help the elaborator with an explicit instantiation
apply @MulEquiv.piCongrRight ps (fun p => ∀ P : Sylow p G, P) (fun p => P p) _ _
Expand Down

0 comments on commit 350feed

Please sign in to comment.