Riemann hypothesis: the Lean proof, cleaned up together
The 2026 Lean proof of the Riemann hypothesis and GRH, machine-checked by others, not refereed, no word from Clay; cleaned up together: more readable, faster to build, the theorems unchanged

| 1 | module |
| 2 | |
| 3 | import Mathlib.Algebra.Order.Sub.Prod |
| 4 | import Mathlib.Algebra.Polynomial.Bivariate |
| 5 | import Mathlib.Data.Finsupp.Pointwise |
| 6 | import Mathlib.Order.Grade |
| 7 | public import Lib.GLn.SchurModule.Basic |
| 8 | public import TauCeti.RingTheory.MvPolynomial.HasLeadingTerm |
| 9 | |
| 10 | /-! |
| 11 | # A basis of minor products for Borel semi-invariants over any ring, by induction on rows |
| 12 | |
| 13 | Polynomials are in variables `X (a, i)`, where `a` is a row with colour `c a` and `i : ℕ` is a |
| 14 | column (`New.MatrixPoly`). For finitely many rows and `l = New.GL.columnWeight τ h`, the module |
| 15 | `New.nabla R c l` of Borel semi-invariants has a basis of products of minors that does not depend on |
| 16 | the ring `R`. The proof takes leading terms in one row: bordering lifts a family of minor products, |
| 17 | and a leading-term analysis describes the leading term of a semi-invariant. |
| 18 | |
| 19 | ## Main definitions and results |
| 20 | |
| 21 | * Leading terms are Tau Ceti's `MonomialOrder.HasLeadingTerm` for `New.GL.columnOrder`; |
| 22 | `New.GL.rowExpansion x` expands in row `x`. |
| 23 | * `New.GL.columnWeight`, `New.GL.ColoredTableau`, `New.GL.minorProduct`: the weight of a family of |
| 24 | coloured columns, its fillings by rows, and the product of the minors of a filling. |
| 25 | * `New.GL.interlacing l`: the exponents `γ` with `γ i ≤ l i - l (i + 1)` (truncated subtraction). |
| 26 | For antitone `l`, these are the `γ ≤ l` such that `l - γ` interlaces `l`. |
| 27 | * `New.GL.exists_bordering`: a filling that avoids `x` is lifted to one whose product of minors has, |
| 28 | in the variables of row `x`, leading term `X ^ γ` times the old product. |
| 29 | * `New.GL.degree_rowExpansion_mem_interlacing`: the leading exponent of a Borel semi-invariant in |
| 30 | the variables of one row `x` lies in `New.GL.interlacing` of its weight at the colour of `x`. |
| 31 | * `New.GL.HasLeadingTerm.leadingCoeff_mem_nabla`: the leading coefficient of a semi-invariant in row |
| 32 | `x` is a semi-invariant in the other rows, of the weight lowered by that exponent. |
| 33 | * `New.GL.exists_isStdMinorFamily`: some finite family of fillings has products of minors that are |
| 34 | linearly independent and span the semi-invariants of its weight over every ring, recorded as |
| 35 | `New.GL.IsStdMinorFamily`. |
| 36 | |
| 37 | Notions from other files: |
| 38 | * `New.nabla`: For a row colouring c and weight l, the module of Borel semi-invariants: polynomials |
| 39 | f with f(yβ) = ∏β_{τ,ii}^{l(τ,i)} f(y) for generic upper triangular matrices β_τ, one per colour. |
| 40 | * `New.minor`: For an h-tuple I of rows, the polynomial determinant of the h×h matrix of variables |
| 41 | in rows I and the first h columns. |
| 42 | * `New.GL.alternant`: For x in ℂ^N and l : ℕ → ℕ, the alternant det(x_i^{l(N−1−j)+j}), 0 ≤ i, j < N, |
| 43 | if l(N) = 0, and zero otherwise. |
| 44 | |
| 45 | ## Relation to the literature |
| 46 | |
| 47 | Known result: The standard basis theorem for Schur (dual Weyl) modules over any ring, with their |
| 48 | character. Here the module is the space of polynomials on matrices that are semi-invariant under a |
| 49 | triangular group, for several row colours at once. It lies in the span of a set of products of |
| 50 | minors built one row at a time rather than the semistandard tableaux, and this set is linearly |
| 51 | independent over every ring. For a single colour its character is given by Weyl's quotient of |
| 52 | alternants. Source: De Concini, Eisenbud, Procesi, Young diagrams and determinantal varieties, |
| 53 | Invent. Math. 56 (1980); Akin, Buchsbaum, Weyman, Schur functors and Schur complexes, Adv. Math. 44 |
| 54 | (1982), II.2.16, II.4.11. |
| 55 | |
| 56 | See also `Lib.DiscreteSeries.Character.WeylCharacterFormula`. |
| 57 | -/ |
| 58 | |
| 59 | @[expose] public section |
| 60 | |
| 61 | noncomputable section |
| 62 | |
| 63 | /-! ## Leading terms of products of minors and bordering -/ |
| 64 | |
| 65 | section Bordering |
| 66 | |
| 67 | open MvPolynomial Finset MonomialOrder Finsupp Matrix Fin |
| 68 | |
| 69 | namespace New.GL |
| 70 | |
| 71 | variable {Φ J m R : Type} [DecidableEq m] [CommRing R] {γ : ℕ →₀ ℕ} |
| 72 | |
| 73 | /-! ### Leading terms -/ |
| 74 | |
| 75 | /-- The lexicographic monomial order on variables indexed by ℕ that compares exponents at the |
| 76 | highest index first, so that x₀ ≺ x₁ ≺ …. -/ |
| 77 | def columnOrder : MonomialOrder ℕ := lex (σ := ℕᵒᵈ) |
| 78 | |
| 79 | /-- If the exponents `γ` and `δ` agree in the columns beyond `i` and `γ i < δ i`, then `γ` is |
| 80 | below `δ` in `New.GL.columnOrder`. -/ |
| 81 | lemma columnOrder_lt_of_eq_above {γ : ℕ →₀ ℕ} (i : ℕ) (δ : ℕ →₀ ℕ) (h_eq : ∀ j > i, γ j = δ j) |
| 82 | (h_lt : γ i < δ i) : γ ≺[columnOrder] δ := |
| 83 | ⟨OrderDual.toDual i, h_eq, h_lt⟩ |
| 84 | |
| 85 | /-- If each `u j` has leading term `b j` times the variable `x j` (exponent `single j 1`), |
| 86 | then the product of the powers `u j ^ n j` has leading term `∏ b j ^ n j` times the monomial of |
| 87 | exponent `n`. -/ |
| 88 | lemma HasLeadingTerm.finsuppProd_pow {u : ℕ → MvPolynomial ℕ R} {b : ℕ → R} |
| 89 | (hu_lead : ∀ j : ℕ, columnOrder.HasLeadingTerm (u j) (Finsupp.single j 1) (b j)) (n : ℕ →₀ ℕ) : |
| 90 | columnOrder.HasLeadingTerm (n.prod fun j e : ℕ ↦ u j ^ e) n (n.prod fun j e : ℕ ↦ b j ^ e) := by |
| 91 | have h_pow (j : ℕ) : |
| 92 | columnOrder.HasLeadingTerm (u j ^ n j) (Finsupp.single j (n j)) (b j ^ n j) := by |
| 93 | simpa using HasLeadingTerm.prod (s := range (n j)) fun _ _ ↦ hu_lead j |
| 94 | have h_sum_single : ∑ j ∈ n.support, Finsupp.single j (n j) = n := n.sum_single |
| 95 | simpa only [Finsupp.prod, h_sum_single] using |
| 96 | HasLeadingTerm.prod (s := n.support) fun j _ ↦ h_pow j |
| 97 | |
| 98 | variable [Fintype J] {c : m → Φ} {τ : J → Φ} {h : J → ℕ} {x : m} (l : ℕ →₀ ℕ) |
| 99 | |
| 100 | /-! ### Columns, fillings and products of minors -/ |
| 101 | |
| 102 | /-- For a row x, the R-algebra isomorphism writing a polynomial in the y_{a,i} as a polynomial |
| 103 | in the y_{x,i}, i ∈ ℕ, over the polynomials in the other rows. -/ |
| 104 | def rowExpansion (x : m) : MatrixPoly m R ≃ₐ[R] MvPolynomial ℕ (MatrixPoly {a // a ≠ x} R) := |
| 105 | -- split the variables into those of row `x` and the others |
| 106 | (renameEquiv R (((Equiv.optionSubtypeNe x).symm.prodCongr 1).trans optionProdEquiv)).trans |
| 107 | (sumAlgEquiv R ℕ ({a // a ≠ x} × ℕ)) |
| 108 | |
| 109 | /-- The finite set of the `γ` with `γ i ≤ l i - l (i + 1)` (truncated subtraction) for all `i`. For |
| 110 | antitone `l` these are the `γ ≤ l` such that `μ = l - γ` interlaces `l`: `l (i + 1) ≤ μ i ≤ l i`. -/ |
| 111 | def interlacing : Finset (ℕ →₀ ℕ) := Icc 0 (l - l.comapDomain Nat.succ (by simp)) |
| 112 | |
| 113 | lemma mem_interlacing_iff {γ : ℕ →₀ ℕ} : γ ∈ interlacing l ↔ ∀ i : ℕ, γ i ≤ l i - l (i + 1) := by |
| 114 | simp [interlacing, Finsupp.le_def] |
| 115 | |
| 116 | /-- For finitely many columns j with colour τ_j and height h_j, the weight whose value at (τ,i) |
| 117 | counts the columns of colour τ with height exceeding i. -/ |
| 118 | def columnWeight (τ : J → Φ) (h : J → ℕ) : Φ × ℕ →₀ ℕ := |
| 119 | ∑ j : J, ∑ i ∈ range (h j), Finsupp.single ((τ j : Φ), i) 1 |
| 120 | |
| 121 | /-- The type of assignments giving each column j an h_j-tuple of rows, all of colour τ_j. -/ |
| 122 | abbrev ColoredTableau (c : m → Φ) (τ : J → Φ) (h : J → ℕ) : Type := |
| 123 | ∀ j : J, Fin (h j) → {a // c a = τ j} |
| 124 | |
| 125 | variable (S : Type) [CommRing S] (I : ColoredTableau c τ h) |
| 126 | |
| 127 | /-- For a coloured column filling I, the polynomial over S that is the product over columns j of |
| 128 | the minor with rows I_j on the first h_j columns. -/ |
| 129 | def minorProduct : MatrixPoly m S := ∏ j : J, minor S fun s ↦ (I j s).val |
| 130 | |
| 131 | /-- The weight `New.diagramWeight N κ` equals the weight `New.GL.columnWeight` of the family having |
| 132 | `κ τ h` columns of colour `τ` and height `h`, for every `τ` and `h < N τ`: its columns are the |
| 133 | triples `⟨τ, h, j⟩` with `j < κ τ h`, of colour `τ` and height `h`. -/ |
| 134 | lemma diagramWeight_eq_columnWeight [Fintype Φ] (N : Φ → ℕ) (κ : Φ → ℕ → ℕ) : |
| 135 | diagramWeight N κ = |
| 136 | columnWeight (fun j : Σ τ : Φ, Σ h : Fin (N τ), Fin (κ τ h) ↦ j.fst) |
| 137 | fun j : Σ τ : Φ, Σ h : Fin (N τ), Fin (κ τ h) ↦ (j.snd.fst : ℕ) := by |
| 138 | -- `↓`: the sums over the sigma type must be split before the definitions unfold |
| 139 | simp [↓Fintype.sum_sigma, diagramWeight, sum_range, columnWeight] |
| 140 | |
| 141 | omit [DecidableEq m] in |
| 142 | /-- For an assignment I of h_j rows of colour τ_j to each column j, the product of minors |
| 143 | `New.GL.minorProduct` of I is a Borel semi-invariant: it lies in `New.nabla` for the weight |
| 144 | `New.GL.columnWeight` of τ, h. -/ |
| 145 | lemma minorProduct_mem_nabla : minorProduct R I ∈ nabla R c (columnWeight τ h) := by |
| 146 | -- each minor is a semi-invariant, and semi-invariants form a graded monoid |
| 147 | rw [minorProduct, columnWeight] |
| 148 | apply SetLike.prod_mem_graded |
| 149 | exact fun j _ ↦ minor_mem_nabla fun s ↦ (I j s).prop |
| 150 | |
| 151 | /-- Bordering one minor: take a tuple `I` of `k` rows other than `x` and append the row `x` if |
| 152 | `e = 1`. After `New.GL.rowExpansion x`, the new minor has leading term `X k ^ e` times the old |
| 153 | minor, where `X k` is the variable of row `x` in column `k`. -/ |
| 154 | lemma hasLeadingTerm_rowExpansion_minor_border {k e : ℕ} (I : Fin k → {a : m // a ≠ x}) |
| 155 | (he_le_one : e ≤ 1) : |
| 156 | columnOrder.HasLeadingTerm |
| 157 | (rowExpansion x (minor S fun s : Fin (k + e) ↦ if hs : s < k then (I ⟨s, hs⟩).val else x)) |
| 158 | (Finsupp.single k e) (minor S I) := by |
| 159 | interval_cases e |
| 160 | · -- the minor does not involve row `x` |
| 161 | have h_const : rowExpansion x (minor S fun s : Fin (k + 0) ↦ |
| 162 | if hs : s < k then (I ⟨s, hs⟩).val else x) = monomial (Finsupp.single k 0) (minor S I) := by |
| 163 | simp [rowExpansion, (I _).prop, monomial_eq, minor, det_apply'] |
| 164 | rw [h_const] |
| 165 | exact hasLeadingTerm_monomial _ _ |
| 166 | · -- Expand along the last row: column `s` contributes a cofactor times `X (x, s)`. |
| 167 | let cofactor (s : Fin (k + 1)) : MatrixPoly {a // a ≠ x} S := |
| 168 | (-1) ^ (k + s.val) * det (of fun a t ↦ X (I a, (s.succAbove t).val)) |
| 169 | -- The variable of the last column is the largest. |
| 170 | have h_lt (s : Fin (k + 1)) (hs : s ≠ last k) : |
| 171 | Finsupp.single s.val 1 ≺[columnOrder] Finsupp.single k 1 := by |
| 172 | grind [columnOrder_lt_of_eq_above k] |
| 173 | have h_expand : rowExpansion x (minor S fun s : Fin (k + 1) ↦ |
| 174 | if hs : s < k then (I ⟨s, hs⟩).val else x) = |
| 175 | ∑ s : Fin (k + 1), monomial (Finsupp.single s.val 1) (cofactor s) := by |
| 176 | rw [minor, det_succ_row _ (last k), map_sum] |
| 177 | refine sum_congr rfl fun s _ ↦ ?_ |
| 178 | simp [cofactor, rowExpansion, (I _).prop, monomial_eq, mul_comm, mul_left_comm, |
| 179 | mul_assoc, det_apply'] |
| 180 | have h_last : cofactor (last k) = minor S I := by simp [cofactor, minor] |
| 181 | rw [h_expand, ← h_last] |
| 182 | exact .sum (γ := fun s : Fin (k + 1) ↦ Finsupp.single s.val 1) (a := cofactor) |
| 183 | (fun s ↦ hasLeadingTerm_monomial _ _) (last k) (fun s _ ↦ h_lt s) (absurd (mem_univ (last k))) |
| 184 | |
| 185 | /-- Bordering. Let `γ` lie in `interlacing` of the weight `l` of the columns at the colour of the |
| 186 | row `x`, that is `γ i ≤ l i - l (i + 1)` for all `i`, so `γ` is the amount by which `l` is lowered |
| 187 | to an interlacing weight. Then (a) there are heights `k` whose column weight is that of `h` minus |
| 188 | `γ` placed in colour `c x`. For every filling `I` of heights `k` by rows other than `x` there is a |
| 189 | filling `K` of heights `h` such that (b) over every commutative ring `R`, the expansion of |
| 190 | `minorProduct R K` in the variables of row `x` has no monomial above the one of exponent `γ` in |
| 191 | `columnOrder`, and the coefficient of that monomial is `minorProduct R I`, and (c) the entries of |
| 192 | `K` are those of `I` together with `degree γ` copies of `x`. -/ |
| 193 | lemma exists_bordering (h : J → ℕ) (hγ : γ ∈ interlacing ((columnWeight τ h).curry (c x))) : |
| 194 | ∃ k : J → ℕ, |
| 195 | -- (a) |
| 196 | columnWeight τ h = γ.mapDomain (fun i : ℕ ↦ (c x, i)) + columnWeight τ k ∧ |
| 197 | -- every filling `I` of heights `k` that avoids `x` has a lift `K` of heights `h` such that |
| 198 | ∀ I : ColoredTableau (c ∘ ((↑) : {a : m // a ≠ x} → m)) τ k, ∃ K : ColoredTableau c τ h, |
| 199 | -- (b) |
| 200 | (∀ (R : Type) [CommRing R], |
| 201 | columnOrder.HasLeadingTerm (rowExpansion x (minorProduct R K)) γ (minorProduct R I)) ∧ |
| 202 | -- (c) |
| 203 | ∀ y : m → ℂ, |
| 204 | ∏ j : J, ∏ s : Fin (h j), y (K j s) = |
| 205 | y x ^ Finsupp.degree γ * ∏ j : J, ∏ s : Fin (k j), y (I j s) := by |
| 206 | classical |
| 207 | -- Among the columns of the colour of `x` and of height `i + 1` choose `γ i` and shorten them by |
| 208 | -- one. A filling `I` of the shortened columns is lifted by putting `x` back at the end. |
| 209 | let taller (i : ℕ) : Finset J := {j ∈ {j | τ j = c x} | i < h j} |
| 210 | have h_weight (i : ℕ) : (columnWeight τ h).curry (c x) i = #(taller i) := by |
| 211 | simp [columnWeight, taller, Finsupp.single_apply, sum_ite, ite_and] |
| 212 | -- interlacing says that at least `γ i` columns of this colour have height exactly `i + 1` |
| 213 | have h_count (i : ℕ) : γ i ≤ #(taller i) - #(taller (i + 1)) := by |
| 214 | simpa only [h_weight] using (mem_interlacing_iff _).mp hγ i |
| 215 | have h_exists_S (i : ℕ) : ∃ S ⊆ taller i \ taller (i + 1), #S = γ i := |
| 216 | exists_subset_card_eq ((h_count i).trans (le_card_sdiff (taller (i + 1)) (taller i))) |
| 217 | choose S h_S_sub card_S using h_exists_S |
| 218 | have h_of_mem_S {i : ℕ} {j : J} (hj : j ∈ S i) : τ j = c x ∧ h j = i + 1 := by grind |
| 219 | clear hγ h_S_sub h_count h_weight taller |
| 220 | -- `e j = 1` for the chosen columns and `0` for the others; `k` are the new heights. |
| 221 | let e (j : J) : ℕ := if ∀ i, j ∉ S i then 0 else 1 |
| 222 | have h_e_le_one (j : J) : e j ≤ 1 := by grind |
| 223 | obtain ⟨k, rfl⟩ : ∃ k : J → ℕ, h = k + e := le_iff_exists_add'.mp (by grind [Pi.le_def]) |
| 224 | -- `γ i` counts the columns chosen at height `i + 1`, which now have height `k j = i` |
| 225 | have h_γ_eq : γ = ∑ j, Finsupp.single (k j) (e j) := by |
| 226 | ext i |
| 227 | have h_chosen (j : J) : (if j ∈ S i then 1 else 0) = Finsupp.single (k j) (e j) i := by |
| 228 | grind [Pi.add_apply] |
| 229 | simp [Finsupp.finsetSum_apply, ← h_chosen, card_S, Finset.univ_inter] |
| 230 | subst h_γ_eq |
| 231 | refine ⟨k, ?weights, fun I ↦ |
| 232 | ⟨fun j s ↦ ⟨if hs : s < k j then I j ⟨s, hs⟩ else x, ?colour⟩, fun R _ ↦ ?lead, ?entries⟩⟩ |
| 233 | case weights => |
| 234 | -- a chosen column loses the entry `(c x, k j)` of its weight |
| 235 | have h_column (j : J) : |
| 236 | ∑ i ∈ range (k j + e j), Finsupp.single (τ j, i) 1 = |
| 237 | Finsupp.single (c x, k j) (e j) + ∑ i ∈ range (k j), Finsupp.single (τ j, i) 1 := by |
| 238 | rcases Nat.le_one_iff_eq_zero_or_eq_one.mp (h_e_le_one j) with h_e_zero | h_e_one |
| 239 | · simp [h_e_zero] |
| 240 | · have h_colour : τ j = c x := by grind |
| 241 | rw [h_e_one, sum_range_succ, h_colour, add_comm] |
| 242 | simp only [columnWeight, mapDomain_finsetSum, mapDomain_single, Pi.add_apply, h_column, |
| 243 | sum_add_distrib] |
| 244 | case colour => |
| 245 | -- the appended row `x` has the colour of its column |
| 246 | grind [Pi.add_apply] |
| 247 | case lead => |
| 248 | -- leading terms multiply, column by column |
| 249 | simp only [minorProduct, map_prod] |
| 250 | exact .prod fun j ↦ by simpa using hasLeadingTerm_rowExpansion_minor_border R |
| 251 | (fun s ↦ (I j s).val) (h_e_le_one j) |
| 252 | case entries => |
| 253 | -- in each column, the lifted filling adds `e j` copies of `x` |
| 254 | simp [prod_univ_add, mul_comm, prod_mul_distrib, prod_pow_eq_pow_sum] |
| 255 | |
| 256 | /-! ### The recursion for alternants -/ |
| 257 | |
| 258 | /-- Column reduction for a matrix of powers. Let `p` be a monotone family of exponents and `i` a |
| 259 | row. Subtracting from each column `j + 1` the power `x i ^ (p (j + 1) - p j)` times column `j` |
| 260 | keeps the determinant of `(x a ^ p j)`, and turns the entry `x a ^ p (j + 1)` into `x a - x i` |
| 261 | times the sum of `x a ^ k * x i ^ (p (j + 1) - 1 - k)` over `p j ≤ k < p (j + 1)`. -/ |
| 262 | lemma _root_.Matrix.det_pow_eq_det_sub_mul_geom_sum {N : ℕ} (x : Fin (N + 1) → R) |
| 263 | (i : Fin (N + 1)) (p : Fin (N + 1) → ℕ) (h_mono : ∀ j : Fin N, p j.castSucc ≤ p j.succ) : |
| 264 | det (of fun a j : Fin (N + 1) ↦ x a ^ p j) = |
| 265 | det (of fun a : Fin (N + 1) ↦ vecCons (x a ^ p 0) fun j : Fin N ↦ (x a - x i) * |
| 266 | ∑ k ∈ Ico (p j.castSucc) (p j.succ), x a ^ k * x i ^ (p j.succ - 1 - k)) := by |
| 267 | refine det_eq_of_forall_col_eq_smul_add_pred (fun j ↦ x i ^ (p j.succ - p j.castSucc)) |
| 268 | (fun _ ↦ rfl) fun a j ↦ ?_ |
| 269 | simp only [of_apply, cons_val_succ, mul_geom_sum₂_Ico _ _ (h_mono j)] |
| 270 | ring |
| 271 | |
| 272 | /-- The branching rule for alternants. Here `alternant x l` for `x : Fin (N + 1) → ℂ` is |
| 273 | `det (x a ^ (l (N - j) + j))` over `0 ≤ a, j ≤ N`, or zero if `l (N + 1) ≠ 0`, and `interlacing l` |
| 274 | is the set of `γ` with `γ k ≤ l k - l (k + 1)` for all `k`, so that `l - γ` interlaces `l`. For |
| 275 | antitone `l` and an index `i`, the alternant of `l` is `(-1) ^ i * ∏ a ≠ i, (x a - x i)` times the |
| 276 | sum, over `γ ∈ interlacing l`, of `x i ^ |γ|` times the alternant of `l - γ` in the other `N` |
| 277 | variables. -/ |
| 278 | lemma alternant_succ {N : ℕ} (hl_anti : Antitone l) (i : Fin (N + 1)) (x : Fin (N + 1) → ℂ) : |
| 279 | alternant x l = |
| 280 | (-1) ^ i.val * (∏ a : Fin N, (x (i.succAbove a) - x i)) * |
| 281 | ∑ γ ∈ interlacing l, x i ^ Finsupp.degree γ * alternant (x ∘ i.succAbove) (l - γ) := by |
| 282 | -- Column `j` has exponent `p j`. Subtract from each column but the first a power of `x i` times |
| 283 | -- the column before: row `i` becomes `(x i ^ l N, 0, …, 0)` and the entry `(a, j + 1)` becomes |
| 284 | -- `x a - x i` times a geometric sum. Expand along row `i`, then each geometric sum. |
| 285 | -- used by `grind` in the bijection below |
| 286 | have h_beyond {n : ℕ} (hn : N + 1 ≤ n) : l n ≤ l (N + 1) := hl_anti hn |
| 287 | let p (j : Fin (N + 1)) : ℕ := l j.rev + j |
| 288 | have h_mono (j : Fin N) : p j.castSucc ≤ p j.succ := add_le_add (hl_anti (by grind)) (by simp) |
| 289 | rw [alternant, interlacing, det_pow_eq_det_sub_mul_geom_sum x i p h_mono, det_succ_row _ i] |
| 290 | -- Write both sides as sums over permutations, the left side also over the exponents `g`. |
| 291 | simp [p, alternant, sum_univ_succ, det_apply', prod_univ_sum, Finset.mul_sum, |
| 292 | Equiv.prod_comp _ fun a ↦ x (i.succAbove a) - x i, -val_rev, prod_mul_distrib, |
| 293 | prod_pow_eq_pow_sum] |
| 294 | rw [univ.sum_comm, ite_sum_zero, ← sum_filter, ← sum_filter] |
| 295 | -- Both sides are now sums over permutations `σ` of `Fin N`: on the left also over the exponents |
| 296 | -- `g j` chosen from the geometric sums, on the right also over the interlacing `γ`. |
| 297 | change ∑ g ∈ Fintype.piFinset (fun j : Fin N ↦ Ico (p j.castSucc) (p j.succ)) with l (N + 1) = 0, |
| 298 | ∑ σ : Equiv.Perm (Fin N), (-1) ^ (i : ℕ) * x i ^ l N * (((Equiv.Perm.sign σ : ℤ) : ℂ) * |
| 299 | ((∏ a : Fin N, (x (i.succAbove a) - x i)) * ((∏ j : Fin N, x (i.succAbove (σ j)) ^ g j) * |
| 300 | x i ^ ∑ j : Fin N, (l (j.succ.rev : ℕ) + (j : ℕ) - g j)))) = |
| 301 | ∑ γ ∈ interlacing l with l N - γ N = 0, |
| 302 | ∑ σ : Equiv.Perm (Fin N), ((-1) ^ (i : ℕ) * ∏ a : Fin N, (x (i.succAbove a) - x i)) * |
| 303 | (x i ^ Finsupp.degree γ * (((Equiv.Perm.sign σ : ℤ) : ℂ) * |
| 304 | ∏ j : Fin N, x (i.succAbove (σ j)) ^ (l (j.rev : ℕ) - γ (j.rev : ℕ) + (j : ℕ)))) |
| 305 | -- A choice of one exponent `g j` from each geometric sum is the same as an interlacing `γ` with |
| 306 | -- `γ N = l N`: the partition `μ = l - γ` has `μ (N - 1 - j) + j = g j`. |
| 307 | -- (`alternant` of `μ` vanishes unless `μ N = 0`. If `l (N + 1) ≠ 0` there is no such `γ`, and |
| 308 | -- the left side is zero too.) |
| 309 | clear h_mono |
| 310 | let μ (g : Fin N → ℕ) (n : ℕ) : ℕ := if hn : n < N then g (rev ⟨n, hn⟩) - rev ⟨n, hn⟩ else 0 |
| 311 | refine sum_bij' (fun g hg ↦ onFinset (range (N + 1)) (fun n ↦ l n - μ g n) ?support) |
| 312 | (fun γ _ j ↦ (l - γ) j.rev + j) ?to_mem ?inv_mem ?left_inv ?right_inv ?terms |
| 313 | case support => grind |
| 314 | -- the four conditions of the bijection are one computation with `μ` |
| 315 | case to_mem | inv_mem | left_inv | right_inv => |
| 316 | simp [μ, interlacing, le_tsub_iff_left (hl_anti _), -val_rev, Finsupp.le_def] |
| 317 | grind |
| 318 | case terms => |
| 319 | simp [μ, degree_eq_weight_one, weight_apply, sum_range_succ, sum_range, |
| 320 | ← rev_bijective.sum_comp (l · - _), -val_rev] |
| 321 | grind |
| 322 | |
| 323 | end New.GL |
| 324 | |
| 325 | end Bordering |
| 326 | |
| 327 | /-! |
| 328 | ## The leading term of a semi-invariant in one row |
| 329 | |
| 330 | Throughout, `f` is a Borel semi-invariant and `G * X_x ^ γ` is its leading term in the variables |
| 331 | `X (x, i)` of one row `x`, where `X_x ^ γ` is the monomial of exponent `γ` in these variables. |
| 332 | -/ |
| 333 | |
| 334 | section Interlacing |
| 335 | |
| 336 | open MvPolynomial Finset Finsupp Algebra MonomialOrder |
| 337 | |
| 338 | namespace New.GL |
| 339 | |
| 340 | /-- Let the exponents `n` and `γ` agree outside the columns `i` and `i + 1` and have the same sum |
| 341 | `n i + n (i + 1) = γ i + γ (i + 1)`, in the pointwise form that a comparison of coefficients |
| 342 | gives. If `n i ≤ γ i` and `n ≠ γ`, then `γ` is below `n` for `columnOrder`. -/ |
| 343 | private lemma columnOrder_lt_of_forall_add_ite_eq {γ n : ℕ →₀ ℕ} {i : ℕ} |
| 344 | (h_eq : ∀ a : ℕ, (if i + 1 = a then n i else 0) + ((if i = a then n (i + 1) else 0) + n a) = |
| 345 | (if i + 1 = a then γ i else 0) + ((if i = a then γ (i + 1) else 0) + γ a)) |
| 346 | (h_le : n i ≤ γ i) (h_ne : n ≠ γ) : γ ≺[columnOrder] n := by |
| 347 | have h_sum : n (i + 1) + n i = γ (i + 1) + γ i := by simpa using h_eq i |
| 348 | have h_off (a : ℕ) (ha : a ≠ i) (ha' : a ≠ i + 1) : n a = γ a := by |
| 349 | simpa [Ne.symm ha, Ne.symm ha'] using h_eq a |
| 350 | -- `n i = γ i` would force `n = γ`, so `n i < γ i` and hence `γ (i + 1) < n (i + 1)`. |
| 351 | have h_lt_i : n i < γ i := by |
| 352 | refine h_le.lt_of_ne fun h_eq_i ↦ h_ne (Finsupp.ext fun a ↦ ?_) |
| 353 | rcases eq_or_ne a i with rfl | ha |
| 354 | · exact h_eq_i |
| 355 | rcases eq_or_ne a (i + 1) with rfl | ha' |
| 356 | · lia |
| 357 | exact h_off a ha ha' |
| 358 | have h_lt_succ : γ (i + 1) < n (i + 1) := by lia |
| 359 | exact columnOrder_lt_of_eq_above (i + 1) n (fun a ha ↦ (h_off a (by lia) (by lia)).symm) h_lt_succ |
| 360 | |
| 361 | variable {Φ m : Type} [DecidableEq m] {R : Type} [CommRing R] |
| 362 | {c : m → Φ} {x : m} {l : Φ × ℕ →₀ ℕ} {f : MatrixPoly m R} |
| 363 | |
| 364 | /-- Let `f` be a Borel semi-invariant of weight `l` for the row colouring `c` (`f ∈ nabla R c l`), |
| 365 | and let `γ` be the leading exponent of `f` in the variables `X (x, i)` of the row `x`, for the order |
| 366 | `columnOrder` (which compares the highest column first). Then `γ i ≤ l (c x, i) - l (c x, i + 1)` |
| 367 | for every column `i`, with truncated subtraction: `γ` lies in `interlacing` of the weight at the |
| 368 | colour of `x`. -/ |
| 369 | lemma degree_rowExpansion_mem_interlacing (hf : f ∈ nabla R c l) : |
| 370 | columnOrder.degree (rowExpansion x f) ∈ interlacing (l.curry (c x)) := by |
| 371 | classical |
| 372 | -- Let `v, v'` be the columns `i, i + 1` of the colour of `x`. Semi-invariance under the block |
| 373 | -- `!![s, -1; 0, T]` gives `f (s v + s T v', -v) = s ^ l i * T ^ l (i + 1) * f (v + T v', v')`. |
| 374 | -- On the left `T` enters only as `s T`, so no term has more `T` than `s`. On the right, if |
| 375 | -- `G X_x ^ γ` is the leading term of `f` in row `x`, then `G` is a coefficient of |
| 376 | -- `T ^ (l (i + 1) + γ i) * s ^ l i`. |
| 377 | set γ : ℕ →₀ ℕ := columnOrder.degree (rowExpansion x f) |
| 378 | suffices h_bound : ∀ i : ℕ, γ i ≤ l.curry (c x) i - l.curry (c x) (i + 1) by |
| 379 | exact (mem_interlacing_iff _).mpr h_bound |
| 380 | intro i |
| 381 | rw [Finsupp.curry_apply, Finsupp.curry_apply] |
| 382 | by_contra! h_lt : l (c x, i) - l (c x, i + 1) < γ i |
| 383 | -- As `γ ≠ 0`, the polynomial `rowExpansion x f` is not zero, nor is its leading coefficient `G`. |
| 384 | have hG : (rowExpansion x f).coeff γ ≠ 0 := by grind [degree_zero, coeff_degree_eq_zero_iff] |
| 385 | -- Coefficients lie in `P`, polynomials in `s` and `T`: `T` is `Polynomial.X` and `s` is `.C .X`. |
| 386 | -- `θ` replaces `v` by `v + T v'` in the rows other than `x`. |
| 387 | let P : Type _ := Polynomial (Polynomial (MatrixPoly {a // a ≠ x} R)) |
| 388 | let θ : MatrixPoly {a // a ≠ x} R →ₐ[R] P := |
| 389 | aeval fun y ↦ .CC (X y) + .X * .CC (single (c x, i) (X (y.1, i + 1)) (c y.1, y.2)) |
| 390 | have hθ (p : MatrixPoly {a // a ≠ x} R) : (θ p).coeff 0 = .C p := by |
| 391 | induction p using MvPolynomial.induction_on with |
| 392 | | C r => simp [P, θ, Polynomial.algebraMap_apply] |
| 393 | | add p q hp hq => rw [map_add, Polynomial.coeff_add, hp, hq, map_add] |
| 394 | | mul_X p y hp => |
| 395 | have h_X : (θ (X y)).coeff 0 = .C (X y) := by simp [P, θ] |
| 396 | rw [map_mul, Polynomial.mul_coeff_zero, hp, h_X, map_mul] |
| 397 | -- `Ψ` does the same in row `x`, at `v = 0` and `v' = X i * X (i + 1)`. |
| 398 | let Ψ : MatrixPoly m R →ₐ[R] MvPolynomial ℕ P := |
| 399 | (aevalTower ((mapAlgHom θ).comp |
| 400 | (algHom R (MatrixPoly {a // a ≠ x} R) (MvPolynomial ℕ (MatrixPoly {a // a ≠ x} R)))) fun j ↦ |
| 401 | (C Polynomial.X * X (i + 1)) ^ single i 1 j * X i ^ single (i + 1) 1 j * X j).comp |
| 402 | (rowExpansion x).toAlgHom |
| 403 | -- `b` is the identity matrix but for the block `!![s, -1; 0, T]`. |
| 404 | let b : Φ × ℕ × ℕ → MvPolynomial ℕ P := fun (τ, j, k) ↦ |
| 405 | single j (C (.C .X ^ single (c x, i) 1 (τ, j) * .X ^ single (c x, i + 1) 1 (τ, j))) k - |
| 406 | single (c x, i) (single (j + 1) 1 k) (τ, j) |
| 407 | -- `Ψ` sends `X_x ^ γ` to `T ^ γ i` times the monomial of exponent `δ`. |
| 408 | let δ : ℕ →₀ ℕ := single (i + 1) (γ i) + (single i (γ (i + 1)) + γ) |
| 409 | -- Left side: the substitution factors through `scale : T ↦ s T`. An entry of `y b` (`y = Ψ ∘ X`) |
| 410 | -- is `scale` of the entry of `y` plus the value at `T = 0` of the entry of `y b - y`. |
| 411 | let scale : P →ₐ[R] P := |
| 412 | .restrictScalars R (Polynomial.aeval (R := Polynomial (MatrixPoly {a // a ≠ x} R)) (.C .X * .X)) |
| 413 | have h_factor : aeval (borelMul c b (Ψ ∘ X)) = (mapAlgHom scale).comp |
| 414 | (aeval (mapAlgHom (Polynomial.aeval 0) ∘ (borelMul c b (Ψ ∘ X) - Ψ ∘ X) + Ψ ∘ X)) := by |
| 415 | -- Multiplying by `b` scales the columns `i` and `i + 1` of the colour of `x` by `s` and `T`, |
| 416 | -- and subtracts column `i` from column `i + 1`. |
| 417 | have h_mul (Y : m × ℕ → MvPolynomial ℕ P) (y : m) (j : ℕ) : borelMul c b Y (y, j) = |
| 418 | Y (y, j) * C (.C .X ^ single (c x, i) 1 (c y, j) * .X ^ single (c x, i + 1) 1 (c y, j)) - |
| 419 | if (c x, i + 1) = (c y, j) then Y (y, i) else 0 := by |
| 420 | rcases eq_or_ne (i + 1) j with rfl | hj |
| 421 | · simp [borelMul, b, mul_sub, sum_sub_distrib, single_apply, ite_and] |
| 422 | · simp [borelMul, b, mul_sub, sum_sub_distrib, single_apply, ite_and, hj] |
| 423 | -- The values of `Ψ` on the variables of the row `x` and of another row `y`. |
| 424 | have hΨx (j : ℕ) : Ψ (X (x, j)) = |
| 425 | (C Polynomial.X * X (i + 1)) ^ single i 1 j * X i ^ single (i + 1) 1 j * X j := by |
| 426 | simp [Ψ, rowExpansion] |
| 427 | have hΨy (y : m) (hy : y ≠ x) (j : ℕ) : Ψ (X (y, j)) = C (θ (X (⟨y, hy⟩, j))) := by |
| 428 | simp [Ψ, rowExpansion, hy, algHom] |
| 429 | refine algHom_ext fun ⟨y, j⟩ ↦ ?_ |
| 430 | by_cases hy : y = x |
| 431 | · -- Row `x`: casework on the column `j` against `i` and `i + 1`; each case is a ring identity. |
| 432 | by_cases hj : j = i |
| 433 | · simp [h_mul, hΨx, scale, P, hy, hj] |
| 434 | ring |
| 435 | by_cases hj' : j = i + 1 |
| 436 | · simp [h_mul, hΨx, scale, P, hy, hj'] |
| 437 | ring |
| 438 | · simp [h_mul, hΨx, scale, P, hy, Ne.symm hj, Ne.symm hj'] |
| 439 | · -- Another row: the entries are constants `C p`, so this is an identity in `P`. Casework on |
| 440 | -- `(c y, j)` against `(c x, i)` and `(c x, i + 1)`. |
| 441 | simp only [aeval_X, AlgHom.comp_apply, mapAlgHom_apply, Pi.add_apply, Pi.sub_apply, |
| 442 | Function.comp_apply, h_mul, hΨy _ hy, ← apply_ite C, ← C_0, ← C_mul, ← C_sub, ← C_add, |
| 443 | map_C] |
| 444 | refine congrArg C ?_ |
| 445 | by_cases hα : (c x, i) = (c y, j) |
| 446 | · obtain ⟨hc, rfl⟩ := Prod.mk.inj hα |
| 447 | simp [θ, scale, P, hc] |
| 448 | ring |
| 449 | by_cases hβ : (c x, i + 1) = (c y, j) |
| 450 | · obtain ⟨hc, rfl⟩ := Prod.mk.inj hβ |
| 451 | simp [θ, scale, P, hc] |
| 452 | · simp [θ, scale, P, hα, hβ] |
| 453 | -- After `T ↦ s T` the coefficient of `T ^ a` is divisible by `s ^ a`. |
| 454 | have h_scale (p : P) {a k : ℕ} (hk : k < a) : ((scale p).coeff a).coeff k = 0 := by |
| 455 | simp [P, scale, ← Polynomial.comp_eq_aeval, Polynomial.coeff_mul_X_pow', hk.not_ge] |
| 456 | have h_left : (((aeval (borelMul c b (Ψ ∘ X)) f).coeff δ).coeff (l (c x, i + 1) + γ i)).coeff |
| 457 | (l (c x, i)) = 0 := by |
| 458 | have h_deg_lt : l (c x, i) < l (c x, i + 1) + γ i := by lia |
| 459 | rw [h_factor, AlgHom.comp_apply, mapAlgHom_apply, coeff_map] |
| 460 | exact h_scale _ h_deg_lt |
| 461 | -- Right side: the weight factor, and the coefficient of `T ^ γ i` at `δ` in `Ψ f`. |
| 462 | have h_weight : |
| 463 | (l.prod fun p k ↦ b (p.1, p.2, p.2) ^ k) = C (.C .X ^ l (c x, i) * .X ^ l (c x, i + 1)) := by |
| 464 | -- The flags stop `simp` from splitting the powers `s ^ [p = (c x, i)]` into cases, and from |
| 465 | -- rewriting `C (a ^ n)` as `C a ^ n`. |
| 466 | simp [b, prod_mul_distrib, -pow_ite, -Prod.mk.injEq, prod_pow_eq_pow_sum, ↓if_mem_support, prod, |
| 467 | single_apply, mul_pow, ← pow_mul, -C_pow] |
| 468 | have h_top : (((Ψ f).coeff δ).coeff (γ i)).coeff 0 = (rowExpansion x f).coeff γ := by |
| 469 | -- Expand `f` along row `x` and apply `Ψ` term by term; only the term of `γ` contributes. |
| 470 | have h_expand : (Ψ f).coeff δ = ∑ n ∈ (rowExpansion x f).support, |
| 471 | θ ((rowExpansion x f).coeff n) * |
| 472 | (.X ^ n i * (X (i + 1) ^ n i * (X i ^ n (i + 1) * monomial n 1) : MvPolynomial ℕ P).coeff |
| 473 | δ) := by |
| 474 | rw [AlgHom.comp_apply] |
| 475 | change (eval₂ _ _ ((rowExpansion x).toAlgHom f) : MvPolynomial ℕ P).coeff δ = _ |
| 476 | rw [eval₂_eq] |
| 477 | -- Flags as in `h_weight`; `-map_aeval` keeps `θ` applied to the coefficients. |
| 478 | simp [prod_mul_distrib, -pow_ite, prod_pow_eq_pow_sum, -map_aeval, ↓if_mem_support, |
| 479 | algHom, single_apply, mul_pow, ← map_pow, mul_assoc, ← pow_mul, ← map_prod, -C_pow] |
| 480 | rw [h_expand, Polynomial.finsetSum_coeff, Polynomial.finsetSum_coeff, Finset.sum_eq_single γ] |
| 481 | · simp [P, δ, hθ, X_pow_eq_monomial, Polynomial.coeff_mul_X_pow'] |
| 482 | · -- Another exponent `n` reaching `δ` with `n i ≤ γ i` has `n i < γ i`, hence |
| 483 | -- `γ (i + 1) < n (i + 1)` and equal entries beyond: it exceeds the leading exponent `γ`. |
| 484 | intro n hn hne |
| 485 | have h_not_lt : ¬ γ ≺[columnOrder] n := fun h_lt ↦ |
| 486 | MvPolynomial.mem_support_iff.mp hn (coeff_eq_zero_of_lt h_lt) |
| 487 | -- The term of `n` is nonzero only if `n` reaches `δ` with `n i ≤ γ i`. |
| 488 | suffices h_vanish : (∀ a : ℕ, |
| 489 | (if i + 1 = a then n i else 0) + ((if i = a then n (i + 1) else 0) + n a) = |
| 490 | (if i + 1 = a then γ i else 0) + ((if i = a then γ (i + 1) else 0) + γ a)) → |
| 491 | n i ≤ γ i → ((θ ((rowExpansion x f).coeff n)).coeff (γ i - n i)).coeff 0 = 0 by |
| 492 | simpa [P, δ, X_pow_eq_monomial, Polynomial.coeff_mul_X_pow', Finsupp.ext_iff, |
| 493 | apply_ite AddMonoidAlgebra.coeff, DFunLike.ite_apply, single_apply, ite_apply] using |
| 494 | h_vanish |
| 495 | intro h_shape h_le |
| 496 | exact absurd (columnOrder_lt_of_forall_add_ite_eq h_shape h_le hne) h_not_lt |
| 497 | · intro hγ |
| 498 | exact absurd (MvPolynomial.mem_support_iff.mpr hG) hγ |
| 499 | -- By semi-invariance the coefficient in `h_left` is the one in `h_top`, so `G = 0`. |
| 500 | apply hG |
| 501 | rw [← h_top, ← h_left, mem_nabla.mp hf (MvPolynomial ℕ P) b (Ψ ∘ X), h_weight, ← aeval_unique] |
| 502 | -- `← map_pow` gathers powers inside `C`, which `C_pow` would undo. |
| 503 | simp [P, Polynomial.coeff_X_pow_mul', ← map_pow, mul_assoc, -C_pow] |
| 504 | |
| 505 | /-- Let `γ` be the leading exponent of `f` in the variables of the row `x` (for `columnOrder`, the |
| 506 | lexicographic order that compares exponents at the highest column first), and let `f` be a Borel |
| 507 | semi-invariant of weight `γ + l`, where `γ` is placed at the colour `c x` (`γ.mapDomain (c x, ·)`). |
| 508 | Then the leading coefficient `G` of `f` in the row `x`, a polynomial in the other rows, is a Borel |
| 509 | semi-invariant of weight `l` for the colouring `c` restricted to the rows other than `x`. -/ |
| 510 | lemma HasLeadingTerm.leadingCoeff_mem_nabla |
| 511 | (hf : f ∈ nabla R c |
| 512 | ((columnOrder.degree (rowExpansion x f)).mapDomain (fun i : ℕ ↦ (c x, i)) + l)) : |
| 513 | columnOrder.leadingCoeff (rowExpansion x f) ∈ nabla R (c ∘ (↑)) l := by |
| 514 | -- Let `G X_x ^ γ` be the leading term of `f` in row `x`. Compare the coefficients of `X_x ^ γ` |
| 515 | -- in `f (y β) = ∏ β ^ (γ + l) * f y` for a generic upper triangular `β`. As `(y β) (x, j)` is |
| 516 | -- `β j j * y (x, j)` plus smaller terms, the left one is `G (y β) * ∏ β j j ^ γ j`; the factor |
| 517 | -- `∏ β j j ^ γ j` cancels. |
| 518 | set γ : ℕ →₀ ℕ := columnOrder.degree (rowExpansion x f) |
| 519 | let A : Type _ := MatrixPoly {a // a ≠ x} (MvPolynomial (Φ × ℕ × ℕ) R) |
| 520 | let β : Φ × ℕ × ℕ → A := C ∘ X |
| 521 | -- `ρ` substitutes `y β` in the rows other than `x`; `u j` is the entry `(x, j)` of `y β`. |
| 522 | let ρ : MatrixPoly {a // a ≠ x} R →ₐ[R] A := aeval (borelMul (c ∘ (↑)) β X) |
| 523 | let u (j : ℕ) : MvPolynomial ℕ A := borelMul c (C ∘ β) (fun p ↦ X p.2) (x, j) |
| 524 | have hu_lead (j : ℕ) : columnOrder.HasLeadingTerm (u j) (single j 1) (β (c x, j, j)) := by |
| 525 | -- `u j` is the sum of the `X i * C (β (c x, i, j))` over `i ≤ j`. |
| 526 | have h_term (i : ℕ) : |
| 527 | columnOrder.HasLeadingTerm (X i * C (β (c x, i, j))) (single i 1) (β (c x, i, j)) := by |
| 528 | rw [X, C_apply, monomial_mul_monomial, add_zero, one_mul] |
| 529 | exact hasLeadingTerm_monomial _ _ |
| 530 | have h_lt : ∀ i ∈ range (j + 1), i ≠ j → single i 1 ≺[columnOrder] single j 1 := by |
| 531 | grind [columnOrder_lt_of_eq_above j] |
| 532 | simpa only [u, borelMul, Function.comp_apply] using |
| 533 | HasLeadingTerm.sum (s := range (j + 1)) h_term j h_lt (absurd (self_mem_range_succ j)) |
| 534 | -- `subst` substitutes `y β` in `f` and expands along row `x`; by the definitions of |
| 535 | -- `aevalTower` and `eval₂`, `subst f` is a sum over the exponents of `f` in row `x`. |
| 536 | let subst : MatrixPoly m R →ₐ[R] MvPolynomial ℕ A := |
| 537 | (aevalTower ((algHom R A (MvPolynomial ℕ A)).comp ρ) u).comp (rowExpansion x).toAlgHom |
| 538 | have h_eval : subst f = ∑ n ∈ (rowExpansion x f).support, |
| 539 | C (ρ ((rowExpansion x f).coeff n)) * n.prod fun j e ↦ u j ^ e := |
| 540 | rfl |
| 541 | -- In this sum the term of `γ` leads. |
| 542 | have h_lead : columnOrder.HasLeadingTerm (subst f) γ |
| 543 | (ρ ((rowExpansion x f).coeff γ) * γ.prod fun j e ↦ β (c x, j, j) ^ e) := by |
| 544 | rw [h_eval] |
| 545 | refine HasLeadingTerm.sum (γ := fun n ↦ n) |
| 546 | (a := fun n ↦ ρ ((rowExpansion x f).coeff n) * n.prod _) (fun n ↦ ?_) γ |
| 547 | (fun n hn hne ↦ ?_) fun hγ ↦ ?_ |
| 548 | · simpa using (hasLeadingTerm_monomial 0 _).mul (finsuppProd_pow hu_lead n) |
| 549 | · exact lt_of_le_of_ne (columnOrder.le_degree hn) (columnOrder.toSyn.injective.ne hne) |
| 550 | · simp [MvPolynomial.notMem_support_iff.mp hγ] |
| 551 | -- The semi-invariance of `f`, with both sides expanded along row `x`; `W` is the weight factor. |
| 552 | let Ψ : MatrixPoly m R →ₐ[R] MvPolynomial ℕ A := |
| 553 | (mapAlgHom (aeval X)).comp (rowExpansion x).toAlgHom |
| 554 | let W : MvPolynomial ℕ A := (γ.mapDomain (fun i : ℕ ↦ (c x, i)) + l).prod |
| 555 | fun (p : Φ × ℕ) (k : ℕ) ↦ (C ∘ β) (p.1, p.2, p.2) ^ k |
| 556 | have h_subst : aeval (borelMul c (C ∘ β) (Ψ ∘ X)) = subst := by |
| 557 | refine algHom_ext fun ⟨y, j⟩ ↦ ?_ |
| 558 | by_cases hy : y = x <;> simp [rowExpansion, Ψ, ρ, u, subst, hy, borelMul, algHom] |
| 559 | have h_semi : subst f = W * Ψ f := by |
| 560 | have h_nabla : aeval (borelMul c (C ∘ β) (Ψ ∘ X)) f = W * aeval (Ψ ∘ X) f := |
| 561 | mem_nabla.mp hf (MvPolynomial ℕ A) (C ∘ β) (Ψ ∘ X) |
| 562 | rwa [← aeval_unique, h_subst] at h_nabla |
| 563 | -- The factor to cancel is a monomial in the generic entries, hence regular. |
| 564 | have h_reg : IsRegular (γ.prod fun j e ↦ β (c x, j, j) ^ e) := by |
| 565 | simpa [β, Finsupp.prod, ← map_pow, ← map_prod, -C_pow] using .monomial (.prod (by simp)) |
| 566 | -- Membership in `nabla` is by definition the identity `ρ G = ∏ β ^ l * G` for the generic `β`. |
| 567 | -- Multiplied by the regular factor, its left side is the coefficient at `γ` of `subst f` (by |
| 568 | -- `h_lead`), and the right side that of `W * Ψ f`. |
| 569 | have h_rhs : (W * Ψ f).coeff γ = |
| 570 | ((l.prod fun (p : Φ × ℕ) (k : ℕ) ↦ (X (p.1, p.2, p.2) : MvPolynomial (Φ × ℕ × ℕ) R) ^ k) • |
| 571 | (aeval X : MatrixPoly {a // a ≠ x} R →ₐ[R] A) |
| 572 | (columnOrder.leadingCoeff (rowExpansion x f))) * |
| 573 | γ.prod fun j e ↦ β (c x, j, j) ^ e := by |
| 574 | -- `W` is a constant, so it comes out of the coefficient; it is the product of the factors for |
| 575 | -- `l` and for `γ`. `↓` splits this product before the definitions unfold. |
| 576 | simp [A, β, Ψ, γ, W, leadingCoeff, ↓prod_add_index', pow_add, ↓prod_mapDomain_index, |
| 577 | ← map_pow, Finsupp.prod, ← map_prod, mul_assoc, coeff_map, -C_pow, Algebra.smul_def, |
| 578 | MvPolynomial.algebraMap_eq] |
| 579 | ring |
| 580 | rw [← h_semi, h_lead.coeff_eq] at h_rhs |
| 581 | exact h_reg.right h_rhs |
| 582 | |
| 583 | end New.GL |
| 584 | |
| 585 | end Interlacing |
| 586 | |
| 587 | /-! |
| 588 | ## The basis theorem and the character identity |
| 589 | |
| 590 | The proof of `New.GL.exists_isStdMinorFamily` is an induction on the number of rows by leading |
| 591 | terms in one row. |
| 592 | -/ |
| 593 | |
| 594 | section MinorBasis |
| 595 | |
| 596 | open MvPolynomial Finset MonomialOrder Submodule Finsupp Nat |
| 597 | |
| 598 | namespace New.GL |
| 599 | |
| 600 | /-- A standard family of fillings `I` for rows coloured by `c` and columns `j` of colour `τ j` and |
| 601 | height `h j`: each `I i` (a `ColoredTableau`) gives column `j` an `h j`-tuple of rows of colour |
| 602 | `τ j`; `minorProduct R (I i)` is the product of the minors on these rows and the first `h j` |
| 603 | columns. -/ |
| 604 | structure IsStdMinorFamily {Φ J m ι : Type} [Fintype m] [Fintype J] [Fintype ι] |
| 605 | {c : m → Φ} {τ : J → Φ} {h : J → ℕ} (I : ι → ColoredTableau c τ h) : Prop where |
| 606 | /-- Over every commutative ring the products of minors are linearly independent. -/ |
| 607 | linearIndependent (R : Type) [CommRing R] : |
| 608 | LinearIndependent R fun i : ι ↦ minorProduct R (I i) |
| 609 | /-- Over every commutative ring the span of the products of minors contains the |
| 610 | semi-invariants of weight `columnWeight τ h`. -/ |
| 611 | nabla_le_span (R : Type) [CommRing R] : |
| 612 | nabla R c (columnWeight τ h) ≤ span R (Set.range fun i : ι ↦ minorProduct R (I i)) |
| 613 | /-- If `t` is the only colour and `e` enumerates the rows, then the sum over the fillings of the |
| 614 | products of the `x a` over their entries `a`, times the alternant of the zero weight, is the |
| 615 | alternant of the weight `columnWeight τ h (t, ·)`. -/ |
| 616 | character [Subsingleton Φ] (t : Φ) (N : ℕ) (e : Fin N ≃ m) (x : m → ℂ) : |
| 617 | (∑ i : ι, ∏ j : J, ∏ s : Fin (h j), x (I i j s)) * alternant (x ∘ e) 0 = |
| 618 | alternant (x ∘ e) fun k : ℕ ↦ columnWeight τ h (t, k) |
| 619 | |
| 620 | section LeadingTerms |
| 621 | |
| 622 | variable {Φ m R : Type} [DecidableEq m] [CommRing R] {y : m} |
| 623 | |
| 624 | /-- If `p i` has leading term `q i` times the monomial of exponent `γ` in the row `y` for every `i`, |
| 625 | then a combination of the `p i` has as leading term the same combination of the `q i`, times that |
| 626 | monomial. Here `columnOrder.HasLeadingTerm F γ G` says that no exponent of `F` exceeds `γ` for |
| 627 | `columnOrder` (lexicographic, comparing exponents at the highest column first) and that the |
| 628 | coefficient of the monomial of exponent `γ` is `G`; `rowExpansion y` writes a polynomial as one in |
| 629 | the variables of the row `y` over the polynomials in the other rows. -/ |
| 630 | lemma HasLeadingTerm.rowExpansion_combination {ι : Type} {γ : ℕ →₀ ℕ} {p : ι → MatrixPoly m R} |
| 631 | {q : ι → MatrixPoly {a : m // a ≠ y} R} |
| 632 | (h_lead : ∀ i : ι, columnOrder.HasLeadingTerm (rowExpansion y (p i)) γ (q i)) (a : ι →₀ R) : |
| 633 | columnOrder.HasLeadingTerm (rowExpansion y (a.sum fun (i : ι) (r : R) ↦ r • p i)) γ |
| 634 | (a.sum fun (i : ι) (r : R) ↦ r • q i) := by |
| 635 | have h_above (i : ι) (δ : ℕ →₀ ℕ) (hδ : γ ≺[columnOrder] δ) : |
| 636 | (rowExpansion y (p i)).coeff δ = 0 := |
| 637 | coeff_eq_zero_of_lt ((h_lead i).degree_le.trans_lt hδ) |
| 638 | refine .mk ?_ ?_ |
| 639 | · -- No exponent above `γ` occurs in any `p i`, hence none in the combination. |
| 640 | simp +contextual [Finsupp.sum, degree_le_iff, not_imp_comm, h_above] |
| 641 | · simp [Finsupp.sum, fun i ↦ (h_lead i).coeff_eq] |
| 642 | |
| 643 | /-- Polynomials `p γ i` with leading terms `q γ i` times the monomial of exponent `γ` in the row `y` |
| 644 | (`columnOrder.HasLeadingTerm`), for distinct exponents `γ` from a finite set `Γ`, are linearly |
| 645 | independent if for each exponent `γ` the coefficients `q γ i` are. -/ |
| 646 | lemma linearIndependent_of_hasLeadingTerm {Γ : Finset (ℕ →₀ ℕ)} {ι : Γ → Type} |
| 647 | {p : ∀ γ : Γ, ι γ → MatrixPoly m R} {q : ∀ γ : Γ, ι γ → MatrixPoly {a : m // a ≠ y} R} |
| 648 | (h_lead : ∀ (γ : Γ) (i : ι γ), columnOrder.HasLeadingTerm (rowExpansion y (p γ i)) γ (q γ i)) |
| 649 | (h_indep : ∀ γ : Γ, LinearIndependent R (q γ)) : |
| 650 | LinearIndependent R fun i : Σ γ : Γ, ι γ ↦ p i.fst i.snd := by |
| 651 | -- In a relation `a ≠ 0` take the largest `γ` that occurs. The coefficient of that monomial is a |
| 652 | -- relation among the `q γ i`, so the `γ`-part of `a` vanishes. |
| 653 | refine linearIndependent_iff.mpr fun a ha ↦ by_contra fun ha_ne ↦ ?_ |
| 654 | have h_nonempty : a.splitSupport.Nonempty := by simpa [splitSupport] using ha_ne |
| 655 | obtain ⟨γ, hγ, hγ_max⟩ := |
| 656 | a.splitSupport.exists_max_image (fun δ ↦ columnOrder.toSyn δ.val) h_nonempty |
| 657 | have h_lt : ∀ δ ∈ a.splitSupport, δ ≠ γ → δ.val ≺[columnOrder] γ.val := fun δ hδ h_ne ↦ |
| 658 | lt_of_le_of_ne (hγ_max δ hδ) fun h_eq ↦ h_ne (Subtype.ext (columnOrder.toSyn.injective h_eq)) |
| 659 | have h_top : columnOrder.HasLeadingTerm |
| 660 | (∑ δ ∈ a.splitSupport, rowExpansion y ((a.split δ).sum fun i r ↦ r • p δ i)) |
| 661 | γ ((a.split γ).sum fun i r ↦ r • q γ i) := |
| 662 | .sum (fun δ ↦ HasLeadingTerm.rowExpansion_combination (h_lead δ) (a.split δ)) γ h_lt (absurd hγ) |
| 663 | have h_rel : (a.split γ).sum (fun i r ↦ r • q γ i) = 0 := by |
| 664 | rw [linearCombination_apply, sigma_sum] at ha |
| 665 | simp [← h_top.coeff_eq, ← map_sum, ha] |
| 666 | exact (mem_splitSupport_iff_ne_zero a γ).mp hγ (linearIndependent_iff.mp (h_indep γ) _ h_rel) |
| 667 | |
| 668 | /-- Let `γ` run over the exponents interlacing the weight `l` at the colour of the row `y`, and let |
| 669 | `l' γ` be `l` lowered by `γ`. Borel semi-invariants (`nabla`) `p γ i` of weight `l` with leading |
| 670 | terms `q γ i` times the monomial of exponent `γ` in the row `y` span all semi-invariants of weight |
| 671 | `l`, if for each `γ` the span of the `q γ i` contains the semi-invariants of weight `l' γ` in the |
| 672 | other rows. -/ |
| 673 | lemma nabla_le_span_of_hasLeadingTerm {c : m → Φ} {l : Φ × ℕ →₀ ℕ} |
| 674 | {ι : interlacing (l.curry (c y)) → Type} {l' : interlacing (l.curry (c y)) → Φ × ℕ →₀ ℕ} |
| 675 | {p : ∀ γ : interlacing (l.curry (c y)), ι γ → MatrixPoly m R} |
| 676 | {q : ∀ γ : interlacing (l.curry (c y)), ι γ → MatrixPoly {a : m // a ≠ y} R} |
| 677 | (h_weight : ∀ γ : interlacing (l.curry (c y)), |
| 678 | l = γ.val.mapDomain (fun k : ℕ ↦ (c y, k)) + l' γ) |
| 679 | (h_mem : ∀ (γ : interlacing (l.curry (c y))) (i : ι γ), p γ i ∈ nabla R c l) |
| 680 | (h_lead : ∀ (γ : interlacing (l.curry (c y))) (i : ι γ), |
| 681 | columnOrder.HasLeadingTerm (rowExpansion y (p γ i)) γ (q γ i)) |
| 682 | (h_span : ∀ γ : interlacing (l.curry (c y)), |
| 683 | nabla R (fun a : {a : m // a ≠ y} ↦ c a) (l' γ) ≤ span R (Set.range (q γ))) : |
| 684 | nabla R c l ≤ |
| 685 | span R (Set.range fun i : Σ γ : interlacing (l.curry (c y)), ι γ ↦ p i.fst i.snd) := by |
| 686 | -- Induction on the leading exponent of `f` in the variables of row `y`. |
| 687 | intro f |
| 688 | induction f using (wellFounded_lt.onFun |
| 689 | (f := fun f ↦ columnOrder.toSyn (columnOrder.degree (rowExpansion y f)))).induction with |
| 690 | | h f ih => |
| 691 | intro hf |
| 692 | -- The leading exponent `γ` interlaces, and the leading coefficient is a semi-invariant for |
| 693 | -- the other rows, hence a combination `a` of the `q γ i`. |
| 694 | let γ : interlacing (l.curry (c y)) := |
| 695 | ⟨columnOrder.degree (rowExpansion y f), degree_rowExpansion_mem_interlacing hf⟩ |
| 696 | have h_coeff_mem : columnOrder.leadingCoeff (rowExpansion y f) ∈ |
| 697 | nabla R (fun a : {a : m // a ≠ y} ↦ c a) (l' γ) := |
| 698 | HasLeadingTerm.leadingCoeff_mem_nabla (by rwa [← h_weight γ]) |
| 699 | obtain ⟨a, ha⟩ : ∃ a : ι γ →₀ R, |
| 700 | (a.sum fun i r ↦ r • q γ i) = columnOrder.leadingCoeff (rowExpansion y f) := |
| 701 | mem_span_range_iff_exists_finsupp.mp (h_span γ h_coeff_mem) |
| 702 | -- The same combination `g` of the `p γ i` has the same leading term as `f`. |
| 703 | let g : MatrixPoly m R := a.sum fun i r ↦ r • p γ i |
| 704 | have hg_span : |
| 705 | g ∈ span R (Set.range fun i : Σ δ : interlacing (l.curry (c y)), ι δ ↦ p i.fst i.snd) := |
| 706 | mem_span_range_iff_exists_finsupp.mpr |
| 707 | ⟨a.mapDomain (Sigma.mk γ), sum_mapDomain_index_inj sigma_mk_injective⟩ |
| 708 | have hg_mem : g ∈ nabla R c l := sum_mem fun i _ ↦ smul_mem _ _ (h_mem γ i) |
| 709 | have hg_lead : |
| 710 | columnOrder.HasLeadingTerm (rowExpansion y g) γ |
| 711 | (columnOrder.leadingCoeff (rowExpansion y f)) := by |
| 712 | rw [← ha] |
| 713 | exact HasLeadingTerm.rowExpansion_combination (h_lead γ) a |
| 714 | -- So `f - g` has a smaller leading exponent or is zero. |
| 715 | have h_le : columnOrder.degree (rowExpansion y (f - g)) ≼[columnOrder] γ.val := by |
| 716 | rw [map_sub] |
| 717 | exact degree_sub_le.trans (sup_le le_rfl hg_lead.degree_le) |
| 718 | have h_coeff : (rowExpansion y (f - g)).coeff γ = 0 := by |
| 719 | rw [map_sub, AddMonoidAlgebra.coeff_sub_apply, hg_lead.coeff_eq] |
| 720 | exact sub_self _ |
| 721 | refine (sub_mem_iff_left _ hg_span).mp ?_ |
| 722 | rcases h_le.lt_or_eq with h_lt | h_eq |
| 723 | · exact ih (f - g) h_lt (sub_mem hf hg_mem) |
| 724 | · -- The leading coefficient of `f - g` vanishes, so `f - g = 0`. |
| 725 | rw [← columnOrder.toSyn.injective h_eq, coeff_degree_eq_zero_iff, |
| 726 | EmbeddingLike.map_eq_zero_iff] at h_coeff |
| 727 | simp [h_coeff] |
| 728 | |
| 729 | end LeadingTerms |
| 730 | |
| 731 | /-- At each colour `t` the number of columns of height above `k` does not increase with `k`. -/ |
| 732 | lemma antitone_columnWeight_curry {Φ J : Type} [Fintype J] (τ : J → Φ) (h : J → ℕ) (t : Φ) : |
| 733 | Antitone ((columnWeight τ h).curry t) := by |
| 734 | classical |
| 735 | have h_count (k : ℕ) : (columnWeight τ h).curry t k = #{j : J | τ j = t ∧ k < h j} := by |
| 736 | simp [columnWeight, card_filter, ite_and, single_apply] |
| 737 | intro a b hab |
| 738 | rw [h_count, h_count] |
| 739 | -- A column of height above `b` also has height above any `a ≤ b`. |
| 740 | gcongr |
| 741 | |
| 742 | /-- Rows `m` are coloured by `c`; column `j : J` has colour `τ j` and height `h j`, and a |
| 743 | `ColoredTableau c τ h` gives it an `h j`-tuple of rows of colour `τ j`. With no rows there is a |
| 744 | standard family (`IsStdMinorFamily`) of these: the one empty filling if all heights are zero, and |
| 745 | the empty family otherwise. -/ |
| 746 | lemma exists_isStdMinorFamily_of_isEmpty {Φ J m : Type} [Fintype m] [IsEmpty m] [Fintype J] |
| 747 | (c : m → Φ) (τ : J → Φ) (h : J → ℕ) : |
| 748 | ∃ (ι : Type) (_ : Fintype ι) (I : ι → ColoredTableau c τ h), IsStdMinorFamily I := by |
| 749 | -- Polynomials are constants, and an enumeration `Fin N ≃ m` forces `N = 0`. |
| 750 | rcases eq_or_ne h 0 with rfl | h_ne |
| 751 | · refine ⟨Unit, inferInstance, nofun, ⟨?indep, ?span, ?character⟩⟩ |
| 752 | case indep => |
| 753 | intro R _ |
| 754 | simp [Fintype.linearIndependent_iff, minorProduct, minor, ← C_mul', Unique.forall_iff] |
| 755 | case span => |
| 756 | intro R _ f _ |
| 757 | rw [f.eq_C_of_isEmpty] |
| 758 | simp [minorProduct, minor, ← one_eq_span] |
| 759 | case character => |
| 760 | intro _ t N e x |
| 761 | obtain rfl : N = 0 := by simpa using Fintype.card_congr e |
| 762 | simp [alternant, columnWeight, univ_eq_empty] |
| 763 | · have h_sum : ∑ j, h j ≠ 0 := by simpa using Function.ne_iff.mp h_ne |
| 764 | refine ⟨Empty, inferInstance, nofun, |
| 765 | fun R _ ↦ linearIndependent_empty_type, fun R _ f hf ↦ ?_, fun t N e x ↦ ?_⟩ |
| 766 | · -- The weight is not zero, so semi-invariance for the zero matrix kills every constant. |
| 767 | obtain ⟨r, rfl⟩ : ∃ r : R, f = C r := ⟨f.coeff 0, f.eq_C_of_isEmpty⟩ |
| 768 | have h_semi : r = ((columnWeight τ h).prod fun (p : Φ × ℕ) (k : ℕ) ↦ (0 : R) ^ k) * r := by |
| 769 | simpa using mem_nabla.mp hf R 0 0 |
| 770 | have h_prod_zero : ((columnWeight τ h).prod fun (p : Φ × ℕ) (k : ℕ) ↦ (0 : R) ^ k) = 0 := by |
| 771 | simp [columnWeight, pow_add, ← prod_finsetSum_index, prod_pow_eq_pow_sum, h_sum] |
| 772 | have h_r : r = 0 := by rwa [h_prod_zero, zero_mul] at h_semi |
| 773 | simp [h_r] |
| 774 | · obtain rfl : N = 0 := by simpa using Fintype.card_congr e |
| 775 | simpa [alternant, columnWeight, univ_eq_empty, Subsingleton.elim _ t, single_apply] using |
| 776 | Function.ne_iff.mp h_ne |
| 777 | |
| 778 | /-- Take finitely many rows coloured by `c`, and finitely many columns `j` of colour `τ j` and |
| 779 | height `h j`. Then there is a finite type `ι` and a family `I` of fillings indexed by it that is |
| 780 | standard in the sense of `IsStdMinorFamily`. Each `I i` gives column `j` an `h j`-tuple of rows of |
| 781 | colour `τ j`, and has minor product `minorProduct R (I i)`: the product of the minors on these rows |
| 782 | and the first `h j` columns. |
| 783 | |
| 784 | This is an existence form of the standard basis theorem for Schur modules (Akin–Buchsbaum–Weyman), |
| 785 | stated for products of minors with coloured rows; the index type is not identified with the |
| 786 | semistandard tableaux. -/ |
| 787 | lemma exists_isStdMinorFamily {Φ J m : Type} [Fintype m] [Fintype J] (c : m → Φ) |
| 788 | (τ : J → Φ) (h : J → ℕ) : |
| 789 | ∃ (ι : Type) (_ : Fintype ι) (I : ι → ColoredTableau c τ h), IsStdMinorFamily I := by |
| 790 | classical |
| 791 | -- Induction on the number of rows. Fix a row `y` and expand polynomials in its variables. For |
| 792 | -- each exponent `γ` interlacing the weight, take the family for the other rows and the weight |
| 793 | -- lowered by `γ`, and lift its members by `exists_bordering`; the lifts have leading terms `y^γ` |
| 794 | -- times the smaller products, which gives independence and spanning. |
| 795 | induction h_card : Nat.card m using Nat.strongRec generalizing m h with | ind n ih => ?_ |
| 796 | rcases isEmpty_or_nonempty m with hm | ⟨⟨y⟩⟩ |
| 797 | · exact exists_isStdMinorFamily_of_isEmpty c τ h |
| 798 | -- For each `γ`, the heights `k γ` give the weight lowered by `γ` (`h_weight`), and `lift γ` |
| 799 | -- borders the fillings that avoid `y` (`h_lift`, `h_monomial`), by `exists_bordering`. |
| 800 | have h_border (γ : interlacing ((columnWeight τ h).curry (c y))) := |
| 801 | exists_bordering h γ.prop |
| 802 | choose k h_weight lift h_lift h_monomial using h_border |
| 803 | -- The induction hypothesis: standard families `I γ` for the other rows. |
| 804 | have h_fewer : Nat.card {a : m // a ≠ y} < n := |
| 805 | h_card.subst (Finite.card_subtype_lt (x := y) (not_not_intro rfl)) |
| 806 | have h_family : ∀ γ : interlacing ((columnWeight τ h).curry (c y)), |
| 807 | ∃ (ι : Type) (_ : Fintype ι) |
| 808 | (I : ι → ColoredTableau (c ∘ (↑) : {a : m // a ≠ y} → Φ) τ (k γ)), IsStdMinorFamily I := |
| 809 | fun γ ↦ ih _ h_fewer (c ∘ (↑) : {a : m // a ≠ y} → Φ) (k γ) rfl |
| 810 | choose ι hι_fintype I hI using h_family |
| 811 | refine ⟨Sigma ι, inferInstance, fun i ↦ lift i.fst (I i.fst i.snd), fun R _ ↦ ?_, |
| 812 | fun R _ ↦ ?_, ?_⟩ |
| 813 | · exact linearIndependent_of_hasLeadingTerm (p := fun γ i ↦ minorProduct R (lift γ (I γ i))) |
| 814 | (fun γ i ↦ h_lift γ (I γ i) R) fun γ ↦ (hI γ).linearIndependent R |
| 815 | · exact nabla_le_span_of_hasLeadingTerm (p := fun γ i ↦ minorProduct R (lift γ (I γ i))) |
| 816 | h_weight (fun γ i ↦ minorProduct_mem_nabla (lift γ (I γ i))) |
| 817 | (fun γ i ↦ h_lift γ (I γ i) R) fun γ ↦ (hI γ).nabla_le_span R |
| 818 | · -- The character: both sides obey the same recursion `alternant_succ` in the row `y`. |
| 819 | intro _ t N e x |
| 820 | rcases N with _ | N |
| 821 | · exact nomatch e.symm y |
| 822 | have h_only : interlacing 0 = {0} := by simp [interlacing] |
| 823 | obtain rfl : t = c y := Subsingleton.elim t (c y) |
| 824 | -- Write both weights as finitely supported functions, the form that `alternant_succ` takes. |
| 825 | change _ * alternant (x ∘ e) ⇑(0 : ℕ →₀ ℕ) = |
| 826 | alternant (x ∘ e) ⇑((columnWeight τ h).curry (c y)) |
| 827 | -- Expand both alternants at the index of `y`; the common factor `± ∏ (x a - x y)` cancels and |
| 828 | -- the two sums over `γ` are compared term by term. |
| 829 | rw [alternant_succ _ (antitone_columnWeight_curry τ h (c y)) (e.symm y), |
| 830 | ← (interlacing _).sum_coe_sort, alternant_succ 0 antitone_const (e.symm y), |
| 831 | h_only, mul_left_comm, Fintype.sum_sigma, univ.sum_mul] |
| 832 | congr with γ |
| 833 | -- For each `γ` use the identity for the other rows, enumerated by `e` with `y` left out. |
| 834 | let e' : Fin N ≃ {a : m // a ≠ y} := |
| 835 | .optionSubtype _ ⟨(finSuccEquiv' (e.symm y)).symm.trans e, e.apply_symm_apply y⟩ |
| 836 | have h_rest := (hI γ).character (c y) N e' fun a ↦ x a |
| 837 | -- `e'` is `e` composed with the embedding that skips the index of `y`. |
| 838 | have h_e' : (fun a : {a : m // a ≠ y} ↦ x a) ∘ e' = |
| 839 | (x ∘ e) ∘ (e.symm y).succAbove := by |
| 840 | simp [funext_iff, e', finSuccEquiv'_symm_some] |
| 841 | rw [h_e'] at h_rest |
| 842 | -- The weight lowered by `γ` is that of `k γ` (`h_weight γ`), and a lift adds `x y ^ |γ|` to the |
| 843 | -- product over the entries (`h_monomial`); so both sides are `x y ^ |γ|` times the sides of |
| 844 | -- `h_rest`. |
| 845 | have h_lowered : (⇑((columnWeight τ h).curry (c y)) - ⇑γ.val) = |
| 846 | fun n : ℕ ↦ columnWeight τ (k γ) (c y, n) := by |
| 847 | simp [funext_iff, h_weight γ, Prod.mk_right_injective] |
| 848 | rw [h_lowered, ← h_rest] |
| 849 | simp [h_monomial, ← univ.mul_sum, mul_assoc] |
| 850 | |
| 851 | end New.GL |
| 852 | |
| 853 | end MinorBasis |
| 854 | |
| 855 | end |