Skip to content

Commit 885827f

Browse files
committed
refactor(NumberTheory): golf Mathlib/NumberTheory/NumberField/Norm (#38277)
- refactors `NumberField/Norm` by moving `isUnit_norm_of_isGalois` after `dvd_norm` and shortening its proof to a direct application of `dvd_norm` together with `isUnit_of_dvd_unit` Extracted from #38144 [![Open in Gitpod](https://gitpod.io/button/open-in-gitpod.svg)](https://gitpod.io/from-referrer/)
1 parent 9067310 commit 885827f

1 file changed

Lines changed: 4 additions & 15 deletions

File tree

Mathlib/NumberTheory/NumberField/Norm.lean

Lines changed: 4 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -68,21 +68,6 @@ theorem norm_algebraMap (x : 𝓞 K) : norm K (algebraMap (𝓞 K) (𝓞 L) x) =
6868
RingOfIntegers.algebraMap_norm_algebraMap, Algebra.norm_algebraMap,
6969
RingOfIntegers.coe_eq_algebraMap, map_pow]
7070

71-
theorem isUnit_norm_of_isGalois [FiniteDimensional K L] [IsGalois K L] {x : 𝓞 L} :
72-
IsUnit (norm K x) ↔ IsUnit x := by
73-
classical
74-
refine ⟨fun hx => ?_, IsUnit.map _⟩
75-
replace hx : IsUnit (algebraMap (𝓞 K) (𝓞 L) <| norm K x) := hx.map (algebraMap (𝓞 K) <| 𝓞 L)
76-
refine @isUnit_of_mul_isUnit_right (𝓞 L) _ _
77-
⟨(univ \ {AlgEquiv.refl}).prod fun σ : Gal(L/K) => σ x,
78-
prod_mem fun σ _ => x.2.map (σ : L →+* L).toIntAlgHom⟩ _ ?_
79-
convert hx using 1
80-
ext
81-
convert_to ((univ \ {AlgEquiv.refl}).prod fun σ : Gal(L/K) => σ x) *
82-
∏ σ ∈ {(AlgEquiv.refl : Gal(L/K))}, σ x = _
83-
· simp
84-
· rw [prod_sdiff <| subset_univ _, ← norm_eq_prod_automorphisms, coe_algebraMap_norm]
85-
8671
/-- If `L/K` is a finite Galois extension of fields, then, for all `(x : 𝓞 L)` we have that
8772
`x ∣ algebraMap (𝓞 K) (𝓞 L) (norm K x)`. -/
8873
theorem dvd_norm [FiniteDimensional K L] [IsGalois K L] (x : 𝓞 L) :
@@ -97,6 +82,10 @@ theorem dvd_norm [FiniteDimensional K L] [IsGalois K L] (x : 𝓞 L) :
9782
rw [coe_algebraMap_norm K x, norm_eq_prod_automorphisms]
9883
simp [← Finset.mul_prod_erase _ _ (mem_univ AlgEquiv.refl)]
9984

85+
theorem isUnit_norm_of_isGalois [FiniteDimensional K L] [IsGalois K L] {x : 𝓞 L} :
86+
IsUnit (norm K x) ↔ IsUnit x :=
87+
fun hx ↦ isUnit_of_dvd_unit (dvd_norm K x) (hx.map _), IsUnit.map _⟩
88+
10089
variable (F : Type*) [Field F] [Algebra K F] [FiniteDimensional K F]
10190

10291
theorem norm_norm [Algebra F L] [FiniteDimensional F L] [IsScalarTower K F L] (x : 𝓞 L) :

0 commit comments

Comments
 (0)