πŸ›οΈ Atlasβœ’οΈFormalizations.NumberTheory.SymplecticCharacterOrders.LinearCoefficient view on GitHub β†—14 theorems
/-Copyright (c) 2026 Carles MarΓ­n. All rights reserved.Released under Apache 2.0 license as described in the file LICENSE.Authors: Carles MarΓ­n-/module public import Mathlib.RingTheory.MvPolynomial.Symmetric.Defspublic import Mathlib.RingTheory.MvPolynomial.Homogeneouspublic import Mathlib.Algebra.Polynomial.Derivativepublic import Mathlib.Algebra.Polynomial.BigOperatorspublic import Mathlib.Algebra.BigOperators.Group.Finset.Basicpublic import Mathlib.Algebra.BigOperators.Group.Finset.Lemmaspublic import Mathlib.Tactic.Ring /-!# Constant and linear parts of `e_k(2 + x_1, …, 2 + x_m)` Over any commutative ring, `e_k(2 + a_j t) ≑ C(m,k) 2^k + C(mβˆ’1,kβˆ’1) 2^{kβˆ’1} (βˆ‘ a_j) t (mod tΒ²)`.For `a_j = jΒ²` the coefficient of `t` is `T_m C(mβˆ’1,kβˆ’1) 2^{kβˆ’1}` with `6 T_m = m(m+1)(2m+1)`.The same in `MvPolynomial` form, as homogeneous components of degree `0` and `1`. ## Main results * `Conductor.LinearCoeff.coeff_zero_esymm_shift`, `Conductor.LinearCoeff.coeff_one_esymm_shift`:  the polynomial-in-`t` form.* `Conductor.LinearCoeff.coeff_one_esymm_sq`, `Conductor.LinearCoeff.six_mul_T`: the case  `a_j = jΒ²`.* `Conductor.LinearCoeff.homogeneousComponent_zero_esymm_shift`,  `Conductor.LinearCoeff.homogeneousComponent_one_esymm_shift`: the `MvPolynomial` form. ## References * C. MarΓ­n, *Conductors of orders generated by character values of Sp(2m)*, preprint (2026);  programs and outputs: Zenodo, doi:10.5281/zenodo.23090540.* C. MarΓ­n, *Where the character values of Sp(2m) at a torsion element fail to generate the ring  of integers*, Zenodo (2026), doi:10.5281/zenodo.22813216 (a longer preprint of the same work).-/ @[expose] public section open Finset namespace Conductor.LinearCoeff variable {R : Type*} [CommRing R] /-- Double counting: Ξ£_{|s|=k} Ξ£_{i∈s} g i = C(mβˆ’1,kβˆ’1) Β· Ξ£_i g i  (1 ≀ k). -/theorem sum_powersetCard_sum (m k : β„•) (hk : 1 ≀ k) (g : Fin m β†’ R) :    βˆ‘ s ∈ powersetCard k (univ : Finset (Fin m)), βˆ‘ i ∈ s, g i      = ((m - 1).choose (k - 1) : R) * βˆ‘ i, g i := by  classical  have h1 : βˆ€ s : Finset (Fin m), βˆ‘ i ∈ s, g i = βˆ‘ i, if i ∈ s then g i else 0 := fun s => by    rw [← Finset.sum_filter]; congr 1; ext; simp  rw [Finset.sum_congr rfl (fun s _ => h1 s)]  rw [Finset.sum_comm, Finset.mul_sum]  refine Finset.sum_congr rfl fun i _ => ?_  rw [← Finset.sum_filter, Finset.sum_const, nsmul_eq_mul]  congr 1  have := card_filter_powersetCard_subset {i} (univ : Finset (Fin m)) k (by simp) (by simpa)  simp only [singleton_subset_iff, card_univ, Fintype.card_fin, card_singleton] at this  rw [this] /-- The family `t ↦ 2 + a_j t` in `R[t]`. -/noncomputable def shift {m : β„•} (a : Fin m β†’ R) : Fin m β†’ Polynomial R :=  fun j => Polynomial.C 2 + Polynomial.C (a j) * Polynomial.X theorem aeval_esymm (m k : β„•) (f : Fin m β†’ Polynomial R) :    MvPolynomial.aeval f (MvPolynomial.esymm (Fin m) R k)      = βˆ‘ s ∈ powersetCard k univ, ∏ i ∈ s, f i := by  simp [MvPolynomial.esymm, map_sum, map_prod] theorem coeff_zero_esymm_shift (m k : β„•) (a : Fin m β†’ R) :    (MvPolynomial.aeval (shift a) (MvPolynomial.esymm (Fin m) R k)).coeff 0      = (m.choose k : R) * 2 ^ k := by  rw [aeval_esymm, Polynomial.finsetSum_coeff]  have : βˆ€ s ∈ powersetCard k (univ : Finset (Fin m)),      (∏ i ∈ s, shift a i).coeff 0 = (2 : R) ^ k := by    intro s hs    rw [Polynomial.coeff_zero_prod]    simp [shift, (mem_powersetCard.1 hs).2]  rw [Finset.sum_congr rfl this, Finset.sum_const, card_powersetCard, card_univ,    Fintype.card_fin, nsmul_eq_mul] theorem coeff_one_prod_shift {m : β„•} (a : Fin m β†’ R) (s : Finset (Fin m)) :    (∏ i ∈ s, shift a i).coeff 1 = 2 ^ (s.card - 1) * βˆ‘ i ∈ s, a i := by  classical  have hd : βˆ€ p : Polynomial R, p.coeff 1 = (Polynomial.derivative p).coeff 0 := fun p => by    simp [Polynomial.coeff_derivative]  rw [hd, Polynomial.derivative_prod_finset, Polynomial.finsetSum_coeff, Finset.mul_sum]  refine Finset.sum_congr rfl fun i hi => ?_  rw [Polynomial.mul_coeff_zero, Polynomial.coeff_zero_prod]  simp [shift, Finset.card_erase_of_mem hi] theorem coeff_one_esymm_shift (m k : β„•) (hk : 1 ≀ k) (a : Fin m β†’ R) :    (MvPolynomial.aeval (shift a) (MvPolynomial.esymm (Fin m) R k)).coeff 1      = ((m - 1).choose (k - 1) : R) * 2 ^ (k - 1) * βˆ‘ j, a j := by  rw [aeval_esymm, Polynomial.finsetSum_coeff]  have : βˆ€ s ∈ powersetCard k (univ : Finset (Fin m)),      (∏ i ∈ s, shift a i).coeff 1 = βˆ‘ i ∈ s, (2 : R) ^ (k - 1) * a i := by    intro s hs    rw [coeff_one_prod_shift, (mem_powersetCard.1 hs).2, Finset.mul_sum]  rw [Finset.sum_congr rfl this, sum_powersetCard_sum m k hk, ← Finset.mul_sum]  ring /-! ### Specialisation x_j = jΒ² t -/ /-- T_m = Ξ£_{j=1}^m jΒ². -/def T (m : β„•) : β„• := βˆ‘ j ∈ range m, (j + 1) ^ 2 theorem six_mul_T (m : β„•) : 6 * T m = m * (m + 1) * (2 * m + 1) := by  induction m with  | zero => simp [T]  | succ n ih =>    simp only [T, sum_range_succ] at ih ⊒    rw [mul_add, ih]; ring theorem sum_sq_fin (m : β„•) : βˆ‘ j : Fin m, (((j : β„•) + 1 : β„•) : R) ^ 2 = (T m : R) := by  rw [Fin.sum_univ_eq_sum_range (fun j => (((j + 1 : β„•)) : R) ^ 2), T]  push_cast; rfl theorem coeff_zero_esymm_sq (m k : β„•) :    (MvPolynomial.aeval (shift (fun j : Fin m => (((j : β„•) + 1 : β„•) : R) ^ 2))      (MvPolynomial.esymm (Fin m) R k)).coeff 0 = (m.choose k : R) * 2 ^ k :=  coeff_zero_esymm_shift m k _ theorem coeff_one_esymm_sq (m k : β„•) (hk : 1 ≀ k) :    (MvPolynomial.aeval (shift (fun j : Fin m => (((j : β„•) + 1 : β„•) : R) ^ 2))      (MvPolynomial.esymm (Fin m) R k)).coeff 1      = (T m : R) * ((m - 1).choose (k - 1) : R) * 2 ^ (k - 1) := by  rw [coeff_one_esymm_shift m k hk, sum_sq_fin]; ring /-! ### MvPolynomial form: homogeneous components of esymm(2 + X) -/ section Mvopen MvPolynomial theorem prodX_mem {m : β„•} (t : Finset (Fin m)) :    (∏ i ∈ t, X i : MvPolynomial (Fin m) R) ∈ homogeneousSubmodule (Fin m) R t.card := by  rw [mem_homogeneousSubmodule]  simpa using IsHomogeneous.prod t (fun i => (X i : MvPolynomial (Fin m) R)) (fun _ => 1)    (fun i _ => isHomogeneous_X R i) /-- Degree-n component of ∏_{i∈s} (X_i + 2). -/theorem homogeneousComponent_prod_shift {m : β„•} (n : β„•) (s : Finset (Fin m)) :    homogeneousComponent n (∏ i ∈ s, (X i + C 2) : MvPolynomial (Fin m) R)      = βˆ‘ t ∈ powersetCard n s, C ((2 : R) ^ (s.card - n)) * ∏ i ∈ t, X i := by  classical  rw [Finset.prod_add, map_sum, powersetCard_eq_filter, Finset.sum_filter]  refine Finset.sum_congr rfl fun t ht => ?_  have hts : t βŠ† s := mem_powerset.1 ht  rw [Finset.prod_const, ← map_pow, mul_comm, homogeneousComponent_C_mul,    homogeneousComponent_of_mem (prodX_mem t), card_sdiff_of_subset hts]  by_cases h : t.card = n  Β· subst h; simp  Β· simp [h, Ne.symm h] theorem aeval_esymm_mv (m k : β„•) :    aeval (fun j : Fin m => (X j + C 2 : MvPolynomial (Fin m) R)) (esymm (Fin m) R k)      = βˆ‘ s ∈ powersetCard k univ, ∏ i ∈ s, (X i + C 2) := by  simp [esymm, map_sum, map_prod] /-- Degree-0 part of e_k(2 + X): C(m,k)Β·2^k. -/theorem homogeneousComponent_zero_esymm_shift (m k : β„•) :    homogeneousComponent 0      (aeval (fun j : Fin m => (X j + C 2 : MvPolynomial (Fin m) R)) (esymm (Fin m) R k))      = C ((m.choose k : R) * 2 ^ k) := by  rw [aeval_esymm_mv, map_sum]  have : βˆ€ s ∈ powersetCard k (univ : Finset (Fin m)),      homogeneousComponent 0 (∏ i ∈ s, (X i + C 2) : MvPolynomial (Fin m) R)        = C ((2 : R) ^ k) := by    intro s hs    rw [homogeneousComponent_prod_shift, (mem_powersetCard.1 hs).2]    simp  rw [Finset.sum_congr rfl this, Finset.sum_const, card_powersetCard, card_univ,    Fintype.card_fin, nsmul_eq_mul, map_mul, map_natCast] /-- Degree-1 part of e_k(2 + X): C(mβˆ’1,kβˆ’1)Β·2^{kβˆ’1}Β·Ξ£ X_j  (1 ≀ k). -/theorem homogeneousComponent_one_esymm_shift (m k : β„•) (hk : 1 ≀ k) :    homogeneousComponent 1      (aeval (fun j : Fin m => (X j + C 2 : MvPolynomial (Fin m) R)) (esymm (Fin m) R k))      = C (((m - 1).choose (k - 1) : R) * 2 ^ (k - 1)) * βˆ‘ j, X j := by  rw [aeval_esymm_mv, map_sum]  have : βˆ€ s ∈ powersetCard k (univ : Finset (Fin m)),      homogeneousComponent 1 (∏ i ∈ s, (X i + C 2) : MvPolynomial (Fin m) R)        = βˆ‘ i ∈ s, C ((2 : R) ^ (k - 1)) * X i := by    intro s hs    rw [homogeneousComponent_prod_shift, (mem_powersetCard.1 hs).2, powersetCard_one,      Finset.sum_map]    simp  rw [Finset.sum_congr rfl this, sum_powersetCard_sum m k hk, ← Finset.mul_sum, map_mul,    map_natCast]  ring end Mv end Conductor.LinearCoeff