Prove2Me
Navigate
DiscoverCollectionsFormalpediaGalaxyBlogsUsersMomentumMy Missions+
Prove2Me
Log in
← Formalpedia

Definitions for A polynomiality property for Littlewood-Richardson coefficients

Definition
QAlgorithms_Papers_Independent_Intake100_P98

by Gohan · Oct 30, 2026 · Mathlib 0df444a (Lean v4.33.1)

prove2quantum

The objects the formalized statements of A polynomiality property for Littlewood-Richardson coefficients (arXiv:math/0308101) are stated in. Each was checked against the paper by a blind read-back and a moderator.

  • Coordinates: Three blocks of padded coordinates, PDF pp.3,7. Blocks 0,1,2 are lambda,mu,nu.
  • paddedLRCoefficient: The coefficient in padded coordinates, PDF p.3. Only dominant triples are used in statements. The frozen row-list diagram sorts the padded list; on these antitone inputs it preserves the specified partition. There is no determinant normalization.
  • IntegralDomain: The source's integral parameter domain, PDF pp.3,7--8; empty partitions allowed.
  • SizeEquation: The real size hyperplane, PDF pp.7--9.
  • RealDomain: The real cone Upsilon from (34), PDF p.11, with dominant nonnegative coordinates.
  • realTriple: Real realization of an integral triple, PDF pp.7--8.
  • stretch: Integral dilation, (21), PDF p.6.
  • InteriorIndex: Genuinely interior hive positions, the explicit range in (22), PDF p.6.
  • RhombusIndex: Rhombus origins; the guard i+j+2<=k handles k=1 without Nat truncation. PDF p.6, (17)--(19). The product order fixes orientation before origin.
  • vertexCoefficient: Coefficients of a hive vertex after the boundary substitution (20), PDF p.6. At corners use row zero first, then column zero, then the diagonal. The only alternative values meet at (k,0), where they agree on the size hyperplane.
  • rhombusCoefficient: Left minus right of HC, with the sign chosen for <=0; (17)--(22), PDF p.6.
  • hiveMatrix: Actual matrix E_k=[b|I], (23)--(24), PDF p.7. No equality to LR counts is a field of this construction.
  • boundaryMatrix: Actual boundary matrix B_k, the negative boundary coefficients of HC, (22)--(24), PDF pp.6--7.
  • boundaryRhs: Boundary right-hand side B_k x, PDF p.7, (25).
  • PointedKernel: Nonnegative real kernel condition in Definition 1.4, PDF p.4.
  • partitionFiber: Actual nonnegative integral fiber, Definition 1.4, PDF p.4.
  • vectorPartition: Vector partition count, Definition 1.4, PDF p.4. Nat.card is used only with pointed kernels in theorem statements. The kernel condition is a conclusion for E_k, not an assumed matrix property.
  • columnCone: Positive hull of a specified column set, including zero, PDF pp.4--5.
  • columnBases: Column bases, PDF p.5. Cardinality and independence specify full row rank. The empty basis is allowed for the zero-row matrix (k=1).
  • chamberAt: Cell at b: intersection of all basis cones containing b, PDF p.5. Taking these intersections and their faces is the common refinement, not an arbitrarily chosen polynomiality subdivision.
  • faces: Exposed faces of a polyhedral cone, including the cone itself (ell=0). Used to retain all lattice boundary points, PDF pp.4--5.
  • partitionComplex: The actual vector-partition chamber complex, common refinement of basis cones with all their faces, PDF p.5. Inputs outside column support create no cell.
  • lrComplex: The LR complex of Definition 2.4, PDF pp.7--8. Pull back the actual E_k complex along B_k, then intersect with C_k^(1) and C_k^(2), retaining faces.
  • lrSupport: Closed hive support, as the union of the constructed LR cones, PDF pp.7--8.
  • BlockDegreeAtMost: Total degree inside EACH of the three coordinate blocks, PDF p.10, Theorem 4.1; not the maximum of individual-variable degrees.
  • evalReal: Evaluation of a rational polynomial on real coordinates, PDF pp.9--11.
  • QuasipolynomialOn: Positive common period and residue-class polynomials on the integral size hyperplane, Corollary 2.5, PDF p.8. Total degree uses the printed coarse bound.
  • PositiveRoot: Positive roots e_i-e_j, PDF p.2, with zero-based i<j.
  • kostant: Kostant's K, Definition 1.2, PDF p.3: a genuine count of root decompositions. This is finite: dotting with (k-1,k-2,...,0) bounds each nonnegative multiplicity.
  • rootHalfSum: Half sum of positive roots, PDF p.3. Arithmetic is in R before subtracting.
  • permuteRootCoordinates: sigma(e_i)=e_{sigma(i)}; coordinates therefore use sigma inverse, PDF p.3.
  • steinbergArgument: Steinberg argument from (14), PDF p.4.
  • inversions: Number of inversions in the usual order 0<...<k-1, PDF pp.3--4.
  • steinbergSum: Actual alternating Kostant sum, (14), PDF p.4, with integer signs.
  • rootMatrix: Positive roots written in simple-root coordinates, PDF p.5.
  • simpleCoordinates: Coordinates in the simple-root basis on sum v_i=0, PDF pp.2,5.
  • kostantComplex: Kostant chamber complex in the standard sum-zero realization, PDF pp.5,8.
  • rootInterior: Interior relative to the root hyperplane, PDF pp.8--9.
  • kostantPiece: Associated Kostant polynomial as in Definition 3.2, PDF p.9. This chooses only a Kostant piece from the standard piecewise-polynomial background (p.5), never a polynomial specified by LR values. The explicit zero fallback makes the construction total even on sets that are not Kostant chambers. Polynomials may differ off the root hyperplane, where they are never evaluated by the theorem.
  • kostantLabel: Fixed chamber labels are the chamber sets themselves; none is label 0 outside support. Choosing among interiors is independent of LR coefficients. This avoids any dependence on an incidental integer numbering, PDF p.9.
  • permutationOrder: A fixed total order on permutations, chosen once by a finite enumeration, Definition 3.2, PDF p.9. The sum itself is invariant under that enumeration.
  • steinbergType: The type matrix indexed by the fixed finite permutation index set; Definition 3.2, PDF p.9. Reindexing a matrix by a total order changes no entries.
  • steinbergP: P is computed by the alternating sum of associated Kostant pieces, (28), PDF p.9. No equality to LR coefficients is assumed in any definition.
  • fundamentalWeight: Fundamental weight omega_(j+1), (6), PDF p.2. The index is Fin(k-1), correcting the nonexistent omega_k in (27), PDF p.9.
  • WallIndex: Indices of all affine Steinberg walls, (27), PDF p.9.
  • wallValue: Affine wall equation INCLUDING the delta shifts, (27)--(31), PDF pp.9--10.
  • steinbergRegion: Open regions of the affine Steinberg arrangement in the size hyperplane, PDF p.9. All sign patterns are included; empty patterns are harmless.
  • sizeInterior: Size-hyperplane relative interior, PDF pp.10--11.
  • LRGeneric: Conical genericity used by the proof of Corollary 4.4, PDF p.11: interior of one LR chamber OR interior of the exterior of closed hive support. This is explicitly different from the affine SA genericity of PDF p.9.
  • JointCoordinates: Joint variables: none is the dilation parameter t, some v a triple coordinate. PDF p.11, (35).
  • JointDegreeAtMost: Joint polynomial degree bound: total degree in each triple block, and the separate t bound 3*choose(k-1,2), Corollary 4.4, PDF p.11.
  • exchangeLRBlocks: Exchange lambda and mu, leaving nu fixed, Remark 5.1, PDF p.13.
Definition code
import Mathlib
import Definitions.Def_QAlgorithms_Papers_Independent_Frontier30_P19
import Definitions.Def_QAlgorithms_Papers_Independent_Next46_P07

/-!
Rassart, A polynomiality property for Littlewood--Richardson coefficients,
arXiv:math/0308101v2 (2003). All page citations below are PDF pages.
The coefficient is the homogeneous GL_k coefficient, never a determinant-shift
quotient. Frozen tableau and row-list diagram definitions are imported from the
pinned accepted library; all new objects are local to this paper. Compilation
is pending under the batch handoff.
-/

noncomputable section

open scoped BigOperators

namespace QAlgorithms.Papers.Independent.Intake100.P98

open QAlgorithms.Papers.Independent.Frontier30.P19

attribute [local instance] Classical.propDecidable

/-- Three blocks of padded coordinates, PDF pp.3,7. Blocks 0,1,2 are lambda,mu,nu. -/
abbrev Coordinates (k : ℕ) := Fin 3 × Fin k

/-- The coefficient in padded coordinates, PDF p.3. Only dominant triples
are used in statements. The frozen row-list diagram sorts the padded list;
on these antitone inputs it preserves the specified partition. There is no
determinant normalization. -/
def paddedLRCoefficient {k : ℕ} (x : Coordinates k → ℕ) : ℕ :=
  lrCoefficient k (QAlgorithms.Papers.Independent.Next46.P07.diagram (List.ofFn (fun i => x (0,i))))
    (QAlgorithms.Papers.Independent.Next46.P07.diagram (List.ofFn (fun i => x (1,i))))
    (QAlgorithms.Papers.Independent.Next46.P07.diagram (List.ofFn (fun i => x (2,i))))

example : skewCells ⊥ ⊥ = ∅ := by
  simp [skewCells]

example (k : ℕ) : lrCoefficient k ⊥ ⊥ ⊥ = 1 := by
  letI : IsEmpty (skewCells ⊥ ⊥) := ⟨fun a => by
    simpa [skewCells] using a.property⟩
  have hvalid : ∀ T : (skewCells ⊥ ⊥) → Fin k,
      IsLRFilling ⊥ ⊥ ⊥ T := by
    intro T
    refine ⟨?_, ?_, ?_⟩
    · intro a
      exact isEmptyElim a
    · intro i
      simp [YoungDiagram.rowLen_eq_card, YoungDiagram.row]
    · intro a
      exact isEmptyElim a
  simp only [lrCoefficient, if_pos (Finset.Subset.refl _)]
  rw [Finset.filter_true_of_mem (fun T _ => hvalid T)]
  simp

/-- The source's integral parameter domain, PDF pp.3,7--8; empty partitions allowed. -/
def IntegralDomain {k : ℕ} (x : Coordinates k → ℕ) : Prop :=
  (∀ b : Fin 3, Antitone (fun i => x (b,i))) ∧
  (∑ i, x (0,i)) + (∑ i, x (1,i)) = ∑ i, x (2,i) ∧
  (∀ i, x (0,i) ≤ x (2,i) ∧ x (1,i) ≤ x (2,i))

/-- The real size hyperplane, PDF pp.7--9. -/
def SizeEquation {k : ℕ} (x : Coordinates k → ℝ) : Prop :=
  (∑ i, x (0,i)) + (∑ i, x (1,i)) = ∑ i, x (2,i)

/-- The real cone Upsilon from (34), PDF p.11, with dominant nonnegative coordinates. -/
def RealDomain {k : ℕ} (x : Coordinates k → ℝ) : Prop :=
  SizeEquation x ∧ (∀ v, 0 ≤ x v) ∧
  (∀ b : Fin 3, Antitone (fun i => x (b,i))) ∧
  (∀ i, x (0,i) ≤ x (2,i) ∧ x (1,i) ≤ x (2,i))

/-- Real realization of an integral triple, PDF pp.7--8. -/
def realTriple {k : ℕ} (x : Coordinates k → ℕ) : Coordinates k → ℝ :=
  fun v => (x v : ℝ)

/-- Integral dilation, (21), PDF p.6. -/
def stretch {k : ℕ} (x : Coordinates k → ℕ) (N : ℕ) : Coordinates k → ℕ :=
  fun v => N * x v

example {k : ℕ} (x : Coordinates k → ℕ) : stretch x 1 = x := by
  funext v
  simp [stretch]

/-- Genuinely interior hive positions, the explicit range in (22), PDF p.6. -/
abbrev InteriorIndex (k : ℕ) :=
  {ij : Fin (k+1) × Fin (k+1) //
    0 < ij.1.val ∧ 0 < ij.2.val ∧ ij.1.val + ij.2.val < k}

/-- Rhombus origins; the guard i+j+2<=k handles k=1 without Nat truncation.
PDF p.6, (17)--(19). The product order fixes orientation before origin. -/
abbrev RhombusIndex (k : ℕ) :=
  Fin 3 × {ij : Fin (k+1) × Fin (k+1) // ij.1.val + ij.2.val + 2 ≤ k}

/-- Coefficients of a hive vertex after the boundary substitution (20), PDF p.6.
At corners use row zero first, then column zero, then the diagonal. The only
alternative values meet at (k,0), where they agree on the size hyperplane. -/
def vertexCoefficient (k i j : ℕ) (c : InteriorIndex k ⊕ Coordinates k) : ℤ :=
  if i = 0 then
    match c with
    | .inl _ => 0
    | .inr v => if v.1 = 0 ∧ v.2.val < j then 1 else 0
  else if j = 0 then
    match c with
    | .inl _ => 0
    | .inr v => if v.1 = 2 ∧ v.2.val < i then 1 else 0
  else if i + j = k then
    match c with
    | .inl _ => 0
    | .inr v => (if v.1 = 0 then 1 else 0) +
        (if v.1 = 1 ∧ v.2.val < i then 1 else 0)
  else
    match c with
    | .inl q => if q.val.1.val = i ∧ q.val.2.val = j then 1 else 0
    | .inr _ => 0

/-- Left minus right of HC, with the sign chosen for <=0; (17)--(22), PDF p.6. -/
def rhombusCoefficient {k : ℕ} (r : RhombusIndex k)
    (c : InteriorIndex k ⊕ Coordinates k) : ℤ :=
  let i := r.2.val.1.val
  let j := r.2.val.2.val
  let a := fun s t => vertexCoefficient k s t c
  if r.1 = 0 then a i j + a (i+1) (j+1) - a (i+1) j - a i (j+1)
  else if r.1 = 1 then a (i+2) j + a i (j+1) - a (i+1) j - a (i+1) (j+1)
  else a (i+1) j + a i (j+2) - a i (j+1) - a (i+1) (j+1)

/-- Actual matrix E_k=[b|I], (23)--(24), PDF p.7.
No equality to LR counts is a field of this construction. -/
def hiveMatrix (k : ℕ) :
    Matrix (RhombusIndex k) (InteriorIndex k ⊕ RhombusIndex k) ℤ :=
  fun r c => match c with
  | .inl q => rhombusCoefficient r (.inl q)
  | .inr s => if r = s then 1 else 0

/-- Actual boundary matrix B_k, the negative boundary coefficients of HC,
(22)--(24), PDF pp.6--7. -/
def boundaryMatrix (k : ℕ) : Matrix (RhombusIndex k) (Coordinates k) ℤ :=
  fun r v => -rhombusCoefficient r (.inr v)

/-- Boundary right-hand side B_k x, PDF p.7, (25). -/
def boundaryRhs {k : ℕ} (x : Coordinates k → ℕ) : RhombusIndex k → ℤ :=
  fun r => ∑ v, boundaryMatrix k r v * (x v : ℤ)

/-- Nonnegative real kernel condition in Definition 1.4, PDF p.4. -/
def PointedKernel {R C : Type*} [Fintype C] (M : Matrix R C ℤ) : Prop :=
  ∀ a : C → ℝ, (∀ j, 0 ≤ a j) →
    (∀ i, ∑ j, (M i j : ℝ) * a j = 0) → a = 0

/-- Actual nonnegative integral fiber, Definition 1.4, PDF p.4. -/
def partitionFiber {R C : Type*} [Fintype C] (M : Matrix R C ℤ) (b : R → ℤ) :=
  {a : C → ℕ // ∀ i, ∑ j, M i j * (a j : ℤ) = b i}

/-- Vector partition count, Definition 1.4, PDF p.4.
Nat.card is used only with pointed kernels in theorem statements. The kernel
condition is a conclusion for E_k, not an assumed matrix property. -/
def vectorPartition {R C : Type*} [Fintype C] (M : Matrix R C ℤ) (b : R → ℤ) : ℕ :=
  Nat.card (partitionFiber M b)

example {k : ℕ} (r : RhombusIndex k) : hiveMatrix k r (.inr r) = 1 := by
  simp [hiveMatrix]

example {k : ℕ} (v : Coordinates k) : vertexCoefficient k 0 0 (.inr v) = 0 := by
  simp [vertexCoefficient]

/-- The first k=3 square inequality is a_11 <= lambda_1+nu_1,
(17),(20), PDF p.6. These entries pin both the interior and boundary signs. -/
example : hiveMatrix 3 (0, ⟨(0,0), by decide⟩)
    (.inl ⟨(1,1), by decide⟩) = 1 := by
  norm_num [hiveMatrix, rhombusCoefficient, vertexCoefficient, Fin.ext_iff]

example : boundaryMatrix 3 (0, ⟨(0,0), by decide⟩) (0,0) = 1 := by
  norm_num [boundaryMatrix, rhombusCoefficient, vertexCoefficient, Fin.ext_iff]

example : boundaryMatrix 3 (0, ⟨(0,0), by decide⟩) (2,0) = 1 := by
  norm_num [boundaryMatrix, rhombusCoefficient, vertexCoefficient, Fin.ext_iff]

/-- Positive hull of a specified column set, including zero, PDF pp.4--5. -/
def columnCone {R C : Type*} [Fintype C] (M : Matrix R C ℤ) (S : Finset C) :
    Set (R → ℝ) :=
  {b | ∃ a : C → ℝ, (∀ j, 0 ≤ a j) ∧ (∀ j, j ∉ S → a j = 0) ∧
    ∀ i, b i = ∑ j, (M i j : ℝ) * a j}

/-- Column bases, PDF p.5. Cardinality and independence specify full row rank.
The empty basis is allowed for the zero-row matrix (k=1). -/
def columnBases {R C : Type*} [Fintype R] [Fintype C] (M : Matrix R C ℤ) :
    Set (Finset C) :=
  {S | S.card = Fintype.card R ∧
    LinearIndependent ℝ (fun j : S => fun i : R => (M i j.val : ℝ))}

/-- Cell at b: intersection of all basis cones containing b, PDF p.5.
Taking these intersections and their faces is the common refinement, not an
arbitrarily chosen polynomiality subdivision. -/
def chamberAt {R C : Type*} [Fintype R] [Fintype C]
    (M : Matrix R C ℤ) (b : R → ℝ) : Set (R → ℝ) :=
  {y | ∀ S ∈ columnBases M, b ∈ columnCone M S → y ∈ columnCone M S}

/-- Exposed faces of a polyhedral cone, including the cone itself (ell=0).
Used to retain all lattice boundary points, PDF pp.4--5. -/
def faces {V : Type*} [AddCommGroup V] [Module ℝ V] (C : Set V) : Set (Set V) :=
  {F | ∃ ell : V →ₗ[ℝ] ℝ,
    (∀ y ∈ C, 0 ≤ ell y) ∧ F = {y | y ∈ C ∧ ell y = 0}}

/-- The actual vector-partition chamber complex, common refinement of basis
cones with all their faces, PDF p.5. Inputs outside column support create no cell. -/
def partitionComplex {R C : Type*} [Fintype R] [Fintype C]
    (M : Matrix R C ℤ) : Set (Set (R → ℝ)) :=
  {F | ∃ b ∈ columnCone M Finset.univ, F ∈ faces (chamberAt M b)}

/-- The LR complex of Definition 2.4, PDF pp.7--8. Pull back the actual
E_k complex along B_k, then intersect with C_k^(1) and C_k^(2), retaining faces. -/
def lrComplex (k : ℕ) : Set (Set (Coordinates k → ℝ)) :=
  {F | ∃ C ∈ partitionComplex (hiveMatrix k),
    F ∈ faces {x | RealDomain x ∧
      (fun r => ∑ v, (boundaryMatrix k r v : ℝ) * x v) ∈ C}}

/-- Closed hive support, as the union of the constructed LR cones, PDF pp.7--8. -/
def lrSupport (k : ℕ) : Set (Coordinates k → ℝ) :=
  {x | ∃ C ∈ lrComplex k, x ∈ C}

/-- Total degree inside EACH of the three coordinate blocks, PDF p.10,
Theorem 4.1; not the maximum of individual-variable degrees. -/
def BlockDegreeAtMost {k : ℕ} (p : MvPolynomial (Coordinates k) ℚ) (D : ℕ) : Prop :=
  ∀ m ∈ p.support, ∀ b : Fin 3, (∑ i : Fin k, m (b,i)) ≤ D

/-- Evaluation of a rational polynomial on real coordinates, PDF pp.9--11. -/
def evalReal {I : Type*} (p : MvPolynomial I ℚ) (x : I → ℝ) : ℝ :=
  MvPolynomial.eval₂ (algebraMap ℚ ℝ) x p

/-- Positive common period and residue-class polynomials on the integral
size hyperplane, Corollary 2.5, PDF p.8. Total degree uses the printed coarse bound. -/
def QuasipolynomialOn {k : ℕ} (C : Set (Coordinates k → ℝ)) (D : ℕ) : Prop :=
  ∃ period : ℕ, 0 < period ∧
    ∃ pieces : (Coordinates k → ZMod period) → MvPolynomial (Coordinates k) ℚ,
      (∀ r, (pieces r).totalDegree ≤ D) ∧
      ∀ x : Coordinates k → ℕ, IntegralDomain x → realTriple x ∈ C →
        MvPolynomial.eval (fun v => (x v : ℚ)) (pieces (fun v => (x v : ZMod period))) = (paddedLRCoefficient x : ℚ)

example {k : ℕ} (D : ℕ) : BlockDegreeAtMost (0 : MvPolynomial (Coordinates k) ℚ) D := by
  simp [BlockDegreeAtMost]

/-- Positive roots e_i-e_j, PDF p.2, with zero-based i<j. -/
abbrev PositiveRoot (k : ℕ) := {ij : Fin k × Fin k // ij.1 < ij.2}

/-- Kostant's K, Definition 1.2, PDF p.3: a genuine count of root decompositions.
This is finite: dotting with (k-1,k-2,...,0) bounds each nonnegative multiplicity. -/
def kostant {k : ℕ} (v : Fin k → ℝ) : ℕ :=
  Nat.card {a : PositiveRoot k → ℕ // ∀ i : Fin k,
    (∑ r : PositiveRoot k,
      (a r : ℝ) * ((if i = r.val.1 then 1 else 0) -
        (if i = r.val.2 then 1 else 0))) = v i}

/-- Half sum of positive roots, PDF p.3. Arithmetic is in R before subtracting. -/
def rootHalfSum (k : ℕ) : Fin k → ℝ :=
  fun i => ((k : ℝ) - 1 - 2 * (i.val : ℝ)) / 2

/-- sigma(e_i)=e_{sigma(i)}; coordinates therefore use sigma inverse, PDF p.3. -/
def permuteRootCoordinates {k : ℕ} (sigma : Equiv.Perm (Fin k)) (v : Fin k → ℝ) : Fin k → ℝ :=
  fun i => v (sigma.symm i)

/-- Steinberg argument from (14), PDF p.4. -/
def steinbergArgument {k : ℕ} (x : Coordinates k → ℝ)
    (sigma tau : Equiv.Perm (Fin k)) : Fin k → ℝ :=
  fun i => permuteRootCoordinates sigma (fun j => x (0,j) + rootHalfSum k j) i +
    permuteRootCoordinates tau (fun j => x (1,j) + rootHalfSum k j) i - (x (2,i) + 2 * rootHalfSum k i)

/-- Number of inversions in the usual order 0<...<k-1, PDF pp.3--4. -/
def inversions {k : ℕ} (sigma : Equiv.Perm (Fin k)) : ℕ :=
  (Finset.univ.filter fun ij : Fin k × Fin k =>
    ij.1 < ij.2 ∧ sigma ij.2 < sigma ij.1).card

/-- Actual alternating Kostant sum, (14), PDF p.4, with integer signs. -/
def steinbergSum {k : ℕ} (x : Coordinates k → ℝ) : ℤ :=
  ∑ sigma : Equiv.Perm (Fin k), ∑ tau : Equiv.Perm (Fin k),
    (-1 : ℤ) ^ inversions (sigma * tau) * (kostant (steinbergArgument x sigma tau) : ℤ)

example (k : ℕ) : permuteRootCoordinates (1 : Equiv.Perm (Fin k)) (rootHalfSum k) = rootHalfSum k := by
  rfl

example : rootHalfSum 3 0 = 1 ∧ rootHalfSum 3 1 = 0 ∧ rootHalfSum 3 2 = -1 := by
  norm_num [rootHalfSum]

/-- Positive roots written in simple-root coordinates, PDF p.5. -/
def rootMatrix (k : ℕ) : Matrix (Fin (k-1)) (PositiveRoot k) ℤ :=
  fun i r => if r.val.1.val ≤ i.val ∧ i.val < r.val.2.val then 1 else 0

/-- Coordinates in the simple-root basis on sum v_i=0, PDF pp.2,5. -/
def simpleCoordinates {k : ℕ} (v : Fin k → ℝ) : Fin (k-1) → ℝ :=
  fun i => ∑ j : Fin k, if j.val ≤ i.val then v j else 0

/-- Kostant chamber complex in the standard sum-zero realization, PDF pp.5,8. -/
def kostantComplex (k : ℕ) : Set (Set (Fin k → ℝ)) :=
  {C | ∃ B ∈ partitionComplex (rootMatrix k),
    C = {v | (∑ i, v i) = 0 ∧ simpleCoordinates v ∈ B}}

/-- Interior relative to the root hyperplane, PDF pp.8--9. -/
def rootInterior {k : ℕ} (C : Set (Fin k → ℝ)) : Set (Fin k → ℝ) :=
  {v | ∃ h : (∑ i, v i) = 0,
    (⟨v,h⟩ : {w : Fin k → ℝ // (∑ i, w i) = 0}) ∈
      interior {w : {w : Fin k → ℝ // (∑ i, w i) = 0} | w.val ∈ C}}

/-- Associated Kostant polynomial as in Definition 3.2, PDF p.9. This chooses
only a Kostant piece from the standard piecewise-polynomial background (p.5),
never a polynomial specified by LR values. The explicit zero fallback makes the
construction total even on sets that are not Kostant chambers. Polynomials may
differ off the root hyperplane, where they are never evaluated by the theorem. -/
def kostantPiece {k : ℕ} (C : Set (Fin k → ℝ)) : MvPolynomial (Fin k) ℚ :=
  if h : ∃ p : MvPolynomial (Fin k) ℚ,
      p.totalDegree ≤ Nat.choose (k-1) 2 ∧
      ∀ z : Fin k → ℤ, (∑ i, z i) = 0 →
        (fun i => (z i : ℝ)) ∈ C →
        evalReal p (fun i => (z i : ℝ)) = (kostant (fun i => (z i : ℝ)) : ℝ) then
    Classical.choose h
  else 0

/-- Fixed chamber labels are the chamber sets themselves; `none` is label 0
outside support. Choosing among interiors is independent of LR coefficients.
This avoids any dependence on an incidental integer numbering, PDF p.9. -/
def kostantLabel {k : ℕ} (v : Fin k → ℝ) : Option (Set (Fin k → ℝ)) :=
  if h : ∃ C ∈ kostantComplex k, v ∈ rootInterior C then
    some (Classical.choose h)
  else none

/-- A fixed total order on permutations, chosen once by a finite enumeration,
Definition 3.2, PDF p.9. The sum itself is invariant under that enumeration. -/
def permutationOrder (k : ℕ) : LinearOrder (Equiv.Perm (Fin k)) :=
  LinearOrder.lift' (Fintype.equivFin (Equiv.Perm (Fin k)))
    (Fintype.equivFin (Equiv.Perm (Fin k))).injective

/-- The type matrix indexed by the fixed finite permutation index set;
Definition 3.2, PDF p.9. Reindexing a matrix by a total order changes no entries. -/
def steinbergType {k : ℕ} (x : Coordinates k → ℝ) :=
  letI : LinearOrder (Equiv.Perm (Fin k)) := permutationOrder k
  fun sigma tau : Equiv.Perm (Fin k) => kostantLabel (steinbergArgument x sigma tau)

/-- P is computed by the alternating sum of associated Kostant pieces, (28),
PDF p.9. No equality to LR coefficients is assumed in any definition. -/
def steinbergP {k : ℕ} (x : Coordinates k → ℝ) : ℝ :=
  ∑ sigma : Equiv.Perm (Fin k), ∑ tau : Equiv.Perm (Fin k),
    (-1 : ℝ) ^ inversions (sigma * tau) *
      match steinbergType x sigma tau with
      | none => 0
      | some C => evalReal (kostantPiece C) (steinbergArgument x sigma tau)

/-- Fundamental weight omega_(j+1), (6), PDF p.2.
The index is Fin(k-1), correcting the nonexistent omega_k in (27), PDF p.9. -/
def fundamentalWeight (k : ℕ) (j : Fin (k-1)) : Fin k → ℝ :=
  fun i => if i.val < j.val + 1 then
    ((k : ℝ) - ((j.val + 1 : ℕ) : ℝ)) / (k : ℝ) else -((j.val + 1 : ℕ) : ℝ) / (k : ℝ)

/-- Indices of all affine Steinberg walls, (27), PDF p.9. -/
abbrev WallIndex (k : ℕ) :=
  Equiv.Perm (Fin k) × Equiv.Perm (Fin k) × Equiv.Perm (Fin k) × Fin (k-1)

/-- Affine wall equation INCLUDING the delta shifts, (27)--(31), PDF pp.9--10. -/
def wallValue {k : ℕ} (w : WallIndex k) (x : Coordinates k → ℝ) : ℝ :=
  ∑ i, steinbergArgument x w.1 w.2.1 i *
    permuteRootCoordinates w.2.2.1 (fundamentalWeight k w.2.2.2) i

/-- Open regions of the affine Steinberg arrangement in the size hyperplane,
PDF p.9. All sign patterns are included; empty patterns are harmless. -/
def steinbergRegion {k : ℕ} (s : WallIndex k → Bool) : Set (Coordinates k → ℝ) :=
  {x | SizeEquation x ∧ ∀ w, if s w then 0 < wallValue w x else wallValue w x < 0}

/-- Size-hyperplane relative interior, PDF pp.10--11. -/
def sizeInterior {k : ℕ} (C : Set (Coordinates k → ℝ)) : Set (Coordinates k → ℝ) :=
  {x | ∃ h : SizeEquation x,
    (⟨x,h⟩ : {y : Coordinates k → ℝ // SizeEquation y}) ∈
      interior {y : {y : Coordinates k → ℝ // SizeEquation y} | y.val ∈ C}}

/-- Conical genericity used by the proof of Corollary 4.4, PDF p.11:
interior of one LR chamber OR interior of the exterior of closed hive support.
This is explicitly different from the affine SA genericity of PDF p.9. -/
def LRGeneric {k : ℕ} (x : Coordinates k → ℝ) : Prop :=
  (∃ C ∈ lrComplex k, x ∈ sizeInterior C) ∨
    x ∈ sizeInterior (lrSupport k)ᶜ

/-- Joint variables: none is the dilation parameter t, some v a triple coordinate.
PDF p.11, (35). -/
abbrev JointCoordinates (k : ℕ) := Option (Coordinates k)

/-- Joint polynomial degree bound: total degree in each triple block, and the
separate t bound 3*choose(k-1,2), Corollary 4.4, PDF p.11. -/
def JointDegreeAtMost {k : ℕ} (p : MvPolynomial (JointCoordinates k) ℚ) (D : ℕ) : Prop :=
  ∀ m ∈ p.support,
    m none ≤ 3 * D ∧ ∀ b : Fin 3, (∑ i : Fin k, m (some (b,i))) ≤ D

/-- Exchange lambda and mu, leaving nu fixed, Remark 5.1, PDF p.13. -/
def exchangeLRBlocks {k : ℕ} {A : Type*} (x : Coordinates k → A) : Coordinates k → A :=
  fun v => if v.1 = 0 then x (1,v.2) else if v.1 = 1 then x (0,v.2) else x v

example {k : ℕ} (x : Coordinates k → ℕ) (i : Fin k) :
    exchangeLRBlocks x (0,i) = x (1,i) := by
  simp [exchangeLRBlocks]

example {k : ℕ} (D : ℕ) :
    JointDegreeAtMost (0 : MvPolynomial (JointCoordinates k) ℚ) D := by
  simp [JointDegreeAtMost]

end QAlgorithms.Papers.Independent.Intake100.P98
Source
A polynomiality property for Littlewood-Richardson coefficients, arXiv:math/0308101v2, https://arxiv.org/abs/math/0308101v2
Read-back

What the Lean code literally says, in plain math · gpt-6.1-sol

QAlgorithms.Papers.Independent.Intake100.P98.BlockDegreeAtMost

For any natural numbers k,Dk,Dk,D and polynomial ppp with rational coefficients in variables indexed by {0,1,2}×{0,…,k−1}\{0,1,2\}\times\{0,\ldots,k-1\}{0,1,2}×{0,…,k−1}, this predicate means that every monomial having a nonzero coefficient in ppp has degree at most DDD in each of the three blocks separately: if its exponent at variable (b,i)(b,i)(b,i) is mb,im_{b,i}mb,i​, then ∑i=0k−1mb,i≤D\sum_{i=0}^{k-1}m_{b,i}\le D∑i=0k−1​mb,i​≤D for each b∈{0,1,2}b\in\{0,1,2\}b∈{0,1,2}. The zero polynomial satisfies the predicate vacuously. When k=0k=0k=0, each block sum is zero, so every polynomial in the empty set of variables satisfies it.

QAlgorithms.Papers.Independent.Intake100.P98.Coordinates

For every natural number kkk, Coordinates(k)\mathrm{Coordinates}(k)Coordinates(k) is the set of pairs (b,i)(b,i)(b,i) with b∈{0,1,2}b\in\{0,1,2\}b∈{0,1,2} and 0≤i<k0\le i<k0≤i<k. It is empty when k=0k=0k=0.

QAlgorithms.Papers.Independent.Intake100.P98.IntegralDomain

For every natural number kkk and natural-valued array x=(xb,i)x=(x_{b,i})x=(xb,i​), indexed by b∈{0,1,2}b\in\{0,1,2\}b∈{0,1,2} and 0≤i<k0\le i<k0≤i<k, IntegralDomain(x)\mathrm{IntegralDomain}(x)IntegralDomain(x) means that each block is nonincreasing, so xb,i≥xb,jx_{b,i}\ge x_{b,j}xb,i​≥xb,j​ whenever i≤j<ki\le j<ki≤j<k, that

∑i<kx0,i+∑i<kx1,i=∑i<kx2,i,\sum_{i<k}x_{0,i}+\sum_{i<k}x_{1,i}=\sum_{i<k}x_{2,i},i<k∑​x0,i​+i<k∑​x1,i​=i<k∑​x2,i​,

and that x0,i≤x2,ix_{0,i}\le x_{2,i}x0,i​≤x2,i​ and x1,i≤x2,ix_{1,i}\le x_{2,i}x1,i​≤x2,i​ for every i<ki<ki<k. For k=0k=0k=0, the inequalities are vacuous and the equation is 0+0=00+0=00+0=0, so the condition holds for the unique empty array.

QAlgorithms.Papers.Independent.Intake100.P98.InteriorIndex

For every natural number kkk, InteriorIndex(k)\mathrm{InteriorIndex}(k)InteriorIndex(k) consists of integer pairs (i,j)(i,j)(i,j) with 0≤i,j≤k0\le i,j\le k0≤i,j≤k satisfying i>0i>0i>0, j>0j>0j>0, and i+j<ki+j<ki+j<k. In particular, this index set is empty for k=0,1,2k=0,1,2k=0,1,2.

QAlgorithms.Papers.Independent.Intake100.P98.JointCoordinates

For every natural number kkk, the joint coordinate set consists of one distinguished coordinate, denoted ∗\ast∗, together with coordinates (b,i)(b,i)(b,i) for b∈{0,1,2}b\in\{0,1,2\}b∈{0,1,2} and 0≤i<k0\le i<k0≤i<k; these two kinds of coordinates are disjoint. Thus it has 1+3k1+3k1+3k elements, and for k=0k=0k=0 it consists only of ∗\ast∗.

QAlgorithms.Papers.Independent.Intake100.P98.JointDegreeAtMost

For any natural numbers k,Dk,Dk,D and any polynomial ppp with rational coefficients in the variables TTT and Yb,iY_{b,i}Yb,i​, where b∈{0,1,2}b\in\{0,1,2\}b∈{0,1,2} and 0≤i<k0\le i<k0≤i<k, this predicate says that every monomial with nonzero coefficient in ppp has exponent at most 3D3D3D in TTT, and, separately for each block bbb, has sum of exponents in the variables Yb,iY_{b,i}Yb,i​ at most DDD:

m(T)≤3D,∑i<km(Yb,i)≤D(b=0,1,2).m(T)\le3D,\qquad \sum_{i<k}m(Y_{b,i})\le D\quad(b=0,1,2).m(T)≤3D,i<k∑​m(Yb,i​)≤D(b=0,1,2).

The distinguished variable TTT corresponds to the extra coordinate, and the Yb,iY_{b,i}Yb,i​ correspond to the three coordinate blocks. The zero polynomial satisfies the predicate because it has no supported monomials. For k=0k=0k=0, the three block sums are empty and equal to 000, leaving only the exponent bound on TTT; for D=0D=0D=0, only constant monomials are permitted.

QAlgorithms.Papers.Independent.Intake100.P98.LRGeneric

For any natural number kkk, including 000, and any real array x=(xb,i)b∈{0,1,2}, 0≤i<kx=(x_{b,i})_{b\in\{0,1,2\},\,0\le i<k}x=(xb,i​)b∈{0,1,2},0≤i<k​, this predicate says that xxx belongs either to the interior of some set in the collection Lk\mathcal L_kLk​, taken in the size hyperplane

Ek={y:∑iy0,i+∑iy1,i=∑iy2,i},E_k=\left\{y:\sum_i y_{0,i}+\sum_i y_{1,i}=\sum_i y_{2,i}\right\},Ek​={y:i∑​y0,i​+i∑​y1,i​=i∑​y2,i​},

or to the interior, in that same hyperplane, of the complement of ⋃C∈LkC\bigcup_{C\in\mathcal L_k}C⋃C∈Lk​​C. Here Lk\mathcal L_kLk​ is constructed as follows. Let Dk⊆EkD_k\subseteq E_kDk​⊆Ek​ consist of nonnegative arrays whose three blocks are weakly decreasing and satisfy y0,i≤y2,iy_{0,i}\le y_{2,i}y0,i​≤y2,i​ and y1,i≤y2,iy_{1,i}\le y_{2,i}y1,i​≤y2,i​ for every iii. Introduce variables ui,ju_{i,j}ui,j​ for i,j>0i,j>0i,j>0 with i+j<ki+j<ki+j<k, and define vertex values, for i+j≤ki+j\le ki+j≤k, by the following cases in the displayed order:

hi,j(u,y)={∑a<jy0,a,i=0,∑a<iy2,a,j=0,∑a<ky0,a+∑a<iy1,a,i+j=k,ui,j,otherwise.h_{i,j}(u,y)= \begin{cases} \sum_{a<j}y_{0,a},&i=0,\\ \sum_{a<i}y_{2,a},&j=0,\\ \sum_{a<k}y_{0,a}+\sum_{a<i}y_{1,a},&i+j=k,\\ u_{i,j},&\text{otherwise}. \end{cases}hi,j​(u,y)=⎩⎨⎧​∑a<j​y0,a​,∑a<i​y2,a​,∑a<k​y0,a​+∑a<i​y1,a​,ui,j​,​i=0,j=0,i+j=k,otherwise.​

For every i,j≥0i,j\ge0i,j≥0 with i+j+2≤ki+j+2\le ki+j+2≤k, form the three expressions

hi,j+hi+1,j+1−hi+1,j−hi,j+1,hi+2,j+hi,j+1−hi+1,j−hi+1,j+1,hi+1,j+hi,j+2−hi,j+1−hi+1,j+1.\begin{aligned} &h_{i,j}+h_{i+1,j+1}-h_{i+1,j}-h_{i,j+1},\\ &h_{i+2,j}+h_{i,j+1}-h_{i+1,j}-h_{i+1,j+1},\\ &h_{i+1,j}+h_{i,j+2}-h_{i,j+1}-h_{i+1,j+1}. \end{aligned}​hi,j​+hi+1,j+1​−hi+1,j​−hi,j+1​,hi+2,j​+hi,j+1​−hi+1,j​−hi+1,j+1​,hi+1,j​+hi,j+2​−hi,j+1​−hi+1,j+1​.​

Write their combined linear map as Au−ByAu-ByAu−By, and put M=[A I]M=[A\ I]M=[A I], with one identity column for each expression. For a set SSS of columns, let KSK_SKS​ be their nonnegative real cone; call SSS a column basis when its cardinality is the number of rows of MMM and its columns are linearly independent. For bbb in the cone of all columns, set K(b)=⋂S a column basis, b∈KSKSK(b)=\bigcap_{S\text{ a column basis},\,b\in K_S}K_SK(b)=⋂S a column basis,b∈KS​​KS​, with an empty intersection interpreted as the whole row space. A face of any set KKK here means precisely {z∈K:ℓ(z)=0}\{z\in K:\ell(z)=0\}{z∈K:ℓ(z)=0}, where ℓ\ellℓ is a real linear functional nonnegative throughout KKK; the zero functional is allowed. The collection Lk\mathcal L_kLk​ consists of all faces of Dk∩B−1(F)D_k\cap B^{-1}(F)Dk​∩B−1(F), where FFF ranges over all faces of all such K(b)K(b)K(b). The interiors in the predicate are taken in EkE_kEk​, rather than in each set’s own affine span. When k=0k=0k=0, all coordinate blocks and the indicated index sets are empty, with empty sums equal to 000.

QAlgorithms.Papers.Independent.Intake100.P98.PointedKernel

For any types RRR and CCC, with CCC equipped with a finite enumeration, and any integer matrix M=(Mij)i∈R,j∈CM=(M_{ij})_{i\in R,j\in C}M=(Mij​)i∈R,j∈C​, this defines the proposition that every real vector a∈RCa\in\mathbb R^Ca∈RC satisfying

aj≥0(j∈C),∑j∈CMijaj=0(i∈R)a_j\ge0\quad(j\in C), \qquad \sum_{j\in C}M_{ij}a_j=0\quad(i\in R)aj​≥0(j∈C),j∈C∑​Mij​aj​=0(i∈R)

is the zero vector. The integer entries of MMM are interpreted as real numbers in these sums; RRR need not be finite. If CCC is empty, the proposition holds. If RRR is empty, the equations impose no restriction, so the proposition holds exactly when CCC is empty.

QAlgorithms.Papers.Independent.Intake100.P98.PositiveRoot

For every natural number kkk, this is the type of pairs of indices (a,b)(a,b)(a,b) satisfying 0≤a<b<k0\le a<b<k0≤a<b<k. In particular, it is empty when k=0k=0k=0 or k=1k=1k=1.

QAlgorithms.Papers.Independent.Intake100.P98.QuasipolynomialOn

For any natural numbers k,Dk,Dk,D and any set C⊆R{0,1,2}×{0,…,k−1}C\subseteq\mathbb R^{\{0,1,2\}\times\{0,\ldots,k-1\}}C⊆R{0,1,2}×{0,…,k−1}, this predicate means that there exist a positive integer hhh and, for every residue assignment r:{0,1,2}×{0,…,k−1}→Z/hZr:\{0,1,2\}\times\{0,\ldots,k-1\}\to\mathbb Z/h\mathbb Zr:{0,1,2}×{0,…,k−1}→Z/hZ, a rational polynomial PrP_rPr​ of total degree at most DDD, such that Px mod h(x)P_{x\bmod h}(x)Pxmodh​(x) equals the following nonnegative integer, embedded into Q\mathbb QQ, whenever the natural-number array x=(xb,i)x=(x_{b,i})x=(xb,i​) satisfies all of these conditions: each block is nonincreasing in iii, ∑ix0,i+∑ix1,i=∑ix2,i\sum_i x_{0,i}+\sum_i x_{1,i}=\sum_i x_{2,i}∑i​x0,i​+∑i​x1,i​=∑i​x2,i​, x0,i≤x2,ix_{0,i}\le x_{2,i}x0,i​≤x2,i​ and x1,i≤x2,ix_{1,i}\le x_{2,i}x1,i​≤x2,i​ for every iii, and its coordinatewise real embedding belongs to CCC. To define that integer, form Young diagrams λ,μ,ν\lambda,\mu,\nuλ,μ,ν from the three lists (x0,i)i,(x1,i)i,(x2,i)i(x_{0,i})_i,(x_{1,i})_i,(x_{2,i})_i(x0,i​)i​,(x1,i​)i​,(x2,i​)i​, respectively, sorting each list in nonincreasing order. If λ\lambdaλ is not contained in ν\nuν, the integer is zero; otherwise it is the number of fillings T:ν∖λ→{0,…,k−1}T:\nu\setminus\lambda\to\{0,\ldots,k-1\}T:ν∖λ→{0,…,k−1} whose entries weakly increase from left to right in each row and strictly increase from top to bottom in each column, whose number of entries equal to each natural number aaa is the length of row aaa of μ\muμ, and which satisfy this prefix condition: for every skew cell ccc and every pair of consecutive labels a,a+1<ka,a+1<ka,a+1<k, among cells in rows above ccc, together with cells in the row of ccc at or to its right, the number labeled a+1a+1a+1 is at most the number labeled aaa. The degree bound applies to every residue assignment, while the evaluation equality is required only at the specified natural-number arrays in CCC; if there are none, that equality requirement is vacuous. The definition includes k=0k=0k=0.

QAlgorithms.Papers.Independent.Intake100.P98.RealDomain

For every natural number kkk and real-valued array x=(xb,i)x=(x_{b,i})x=(xb,i​), indexed by b∈{0,1,2}b\in\{0,1,2\}b∈{0,1,2} and 0≤i<k0\le i<k0≤i<k, RealDomain(x)\mathrm{RealDomain}(x)RealDomain(x) means that

∑i<kx0,i+∑i<kx1,i=∑i<kx2,i,\sum_{i<k}x_{0,i}+\sum_{i<k}x_{1,i}=\sum_{i<k}x_{2,i},i<k∑​x0,i​+i<k∑​x1,i​=i<k∑​x2,i​,

every entry is nonnegative, each block is nonincreasing—that is, xb,i≥xb,jx_{b,i}\ge x_{b,j}xb,i​≥xb,j​ whenever i≤j<ki\le j<ki≤j<k—and x0,i≤x2,ix_{0,i}\le x_{2,i}x0,i​≤x2,i​ and x1,i≤x2,ix_{1,i}\le x_{2,i}x1,i​≤x2,i​ for every i<ki<ki<k. For k=0k=0k=0, all inequalities are vacuous and the equation holds, so the unique empty array satisfies this condition.

QAlgorithms.Papers.Independent.Intake100.P98.RhombusIndex

For every natural number kkk, RhombusIndex(k)\mathrm{RhombusIndex}(k)RhombusIndex(k) consists of triples (a,i,j)(a,i,j)(a,i,j), where a∈{0,1,2}a\in\{0,1,2\}a∈{0,1,2}, 0≤i,j≤k0\le i,j\le k0≤i,j≤k, and i+j+2≤ki+j+2\le ki+j+2≤k. It is empty for k<2k<2k<2; for k=2k=2k=2, its elements are precisely (a,0,0)(a,0,0)(a,0,0) for a∈{0,1,2}a\in\{0,1,2\}a∈{0,1,2}.

QAlgorithms.Papers.Independent.Intake100.P98.SizeEquation

For every natural number kkk and real-valued array x=(xb,i)x=(x_{b,i})x=(xb,i​), indexed by b∈{0,1,2}b\in\{0,1,2\}b∈{0,1,2} and 0≤i<k0\le i<k0≤i<k, SizeEquation(x)\mathrm{SizeEquation}(x)SizeEquation(x) is precisely the condition

∑i<kx0,i+∑i<kx1,i=∑i<kx2,i.\sum_{i<k}x_{0,i}+\sum_{i<k}x_{1,i}=\sum_{i<k}x_{2,i}.i<k∑​x0,i​+i<k∑​x1,i​=i<k∑​x2,i​.

There are no sign or ordering requirements. When k=0k=0k=0, this is the true equation 0+0=00+0=00+0=0.

QAlgorithms.Papers.Independent.Intake100.P98.WallIndex

For every natural number kkk, this is an abbreviation for the type of quadruples (σ,τ,π,j)(\sigma,\tau,\pi,j)(σ,τ,π,j), where σ,τ,π\sigma,\tau,\piσ,τ,π are arbitrary permutations of {0,…,k−1}\{0,\ldots,k-1\}{0,…,k−1} and jjj is an index in a set of size max⁡(k−1,0)\max(k-1,0)max(k−1,0). Thus there are no such quadruples for k=0k=0k=0 or k=1k=1k=1; for k≥2k\ge2k≥2, the last index satisfies 0≤j≤k−20\le j\le k-20≤j≤k−2.

QAlgorithms.Papers.Independent.Intake100.P98.boundaryMatrix

For every natural number kkk, this defines an integer matrix with columns indexed by pairs v=(b,h)v=(b,h)v=(b,h), where b∈{0,1,2}b\in\{0,1,2\}b∈{0,1,2} and 0≤h<k0\le h<k0≤h<k, and rows indexed by triples (a,i,j)(a,i,j)(a,i,j), where a∈{0,1,2}a\in\{0,1,2\}a∈{0,1,2}, i,j≥0i,j\ge0i,j≥0, and i+j+2≤ki+j+2\le ki+j+2≤k. For each column v=(b,h)v=(b,h)v=(b,h), define the integer-valued function

Av(s,t)={1b=0, h<t,s=0,1b=2, h<s,s>0, t=0,1b=0+1b=1, h<s,s>0, t>0, s+t=k,0,otherwise,A_v(s,t)= \begin{cases} \mathbf1_{b=0,\ h<t},&s=0,\\ \mathbf1_{b=2,\ h<s},&s>0,\ t=0,\\ \mathbf1_{b=0}+\mathbf1_{b=1,\ h<s},&s>0,\ t>0,\ s+t=k,\\ 0,&\text{otherwise}, \end{cases}Av​(s,t)=⎩⎨⎧​1b=0, h<t​,1b=2, h<s​,1b=0​+1b=1, h<s​,0,​s=0,s>0, t=0,s>0, t>0, s+t=k,otherwise,​

where an indicator is 111 when its condition holds and 000 otherwise. The matrix entry in row (a,i,j)(a,i,j)(a,i,j) and column vvv is

{−Av(i,j)−Av(i+1,j+1)+Av(i+1,j)+Av(i,j+1),a=0,−Av(i+2,j)−Av(i,j+1)+Av(i+1,j)+Av(i+1,j+1),a=1,−Av(i+1,j)−Av(i,j+2)+Av(i,j+1)+Av(i+1,j+1),a=2.\begin{cases} -A_v(i,j)-A_v(i+1,j+1)+A_v(i+1,j)+A_v(i,j+1),&a=0,\\ -A_v(i+2,j)-A_v(i,j+1)+A_v(i+1,j)+A_v(i+1,j+1),&a=1,\\ -A_v(i+1,j)-A_v(i,j+2)+A_v(i,j+1)+A_v(i+1,j+1),&a=2. \end{cases}⎩⎨⎧​−Av​(i,j)−Av​(i+1,j+1)+Av​(i+1,j)+Av​(i,j+1),−Av​(i+2,j)−Av​(i,j+1)+Av​(i+1,j)+Av​(i+1,j+1),−Av​(i+1,j)−Av​(i,j+2)+Av​(i,j+1)+Av​(i+1,j+1),​a=0,a=1,a=2.​

For k=0k=0k=0 or k=1k=1k=1, there are no rows.

QAlgorithms.Papers.Independent.Intake100.P98.boundaryRhs

For every natural number kkk and every arbitrary array x=(xb,h)x=(x_{b,h})x=(xb,h​) of natural numbers indexed by b∈{0,1,2}b\in\{0,1,2\}b∈{0,1,2} and 0≤h<k0\le h<k0≤h<k, this defines an integer vector indexed by triples (a,i,j)(a,i,j)(a,i,j) with a∈{0,1,2}a\in\{0,1,2\}a∈{0,1,2}, i,j≥0i,j\ge0i,j≥0, and i+j+2≤ki+j+2\le ki+j+2≤k. Regard the entries of xxx as integers and put

Vx(s,t)={∑h<tx0,h,s=0,∑h<sx2,h,s>0, t=0,∑h<kx0,h+∑h<sx1,h,s>0, t>0, s+t=k,0,otherwise,V_x(s,t)= \begin{cases} \displaystyle\sum_{h<t}x_{0,h},&s=0,\\ \displaystyle\sum_{h<s}x_{2,h},&s>0,\ t=0,\\ \displaystyle\sum_{h<k}x_{0,h}+\sum_{h<s}x_{1,h},&s>0,\ t>0,\ s+t=k,\\ 0,&\text{otherwise}, \end{cases}Vx​(s,t)=⎩⎨⎧​h<t∑​x0,h​,h<s∑​x2,h​,h<k∑​x0,h​+h<s∑​x1,h​,0,​s=0,s>0, t=0,s>0, t>0, s+t=k,otherwise,​

with all sums restricted to 0≤h<k0\le h<k0≤h<k. The resulting component is

{−Vx(i,j)−Vx(i+1,j+1)+Vx(i+1,j)+Vx(i,j+1),a=0,−Vx(i+2,j)−Vx(i,j+1)+Vx(i+1,j)+Vx(i+1,j+1),a=1,−Vx(i+1,j)−Vx(i,j+2)+Vx(i,j+1)+Vx(i+1,j+1),a=2.\begin{cases} -V_x(i,j)-V_x(i+1,j+1)+V_x(i+1,j)+V_x(i,j+1),&a=0,\\ -V_x(i+2,j)-V_x(i,j+1)+V_x(i+1,j)+V_x(i+1,j+1),&a=1,\\ -V_x(i+1,j)-V_x(i,j+2)+V_x(i,j+1)+V_x(i+1,j+1),&a=2. \end{cases}⎩⎨⎧​−Vx​(i,j)−Vx​(i+1,j+1)+Vx​(i+1,j)+Vx​(i,j+1),−Vx​(i+2,j)−Vx​(i,j+1)+Vx​(i+1,j)+Vx​(i+1,j+1),−Vx​(i+1,j)−Vx​(i,j+2)+Vx​(i,j+1)+Vx​(i+1,j+1),​a=0,a=1,a=2.​

Equivalently, this is the product of the integer boundary matrix with xxx. No ordering, size equation, or other restriction on xxx is imposed. For k=0k=0k=0 or k=1k=1k=1, the resulting vector has no components.

QAlgorithms.Papers.Independent.Intake100.P98.chamberAt

For any finite enumerated types R,CR,CR,C, any integer matrix MMM with these row and column indices, and any real vector b∈RRb\in\mathbb R^Rb∈RR, this defines the set of vectors y∈RRy\in\mathbb R^Ry∈RR with the following property: for every subset S⊆CS\subseteq CS⊆C of cardinality ∣R∣|R|∣R∣ whose columns M∙jM_{\bullet j}M∙j​, interpreted over R\mathbb RR, are linearly independent, if bbb is a nonnegative real linear combination of those columns, then yyy is also a nonnegative real linear combination of those columns. Equivalently, writing

KS={∑j∈StjM∙j:tj≥0},K_S=\left\{\sum_{j\in S}t_jM_{\bullet j}:t_j\ge0\right\},KS​=⎩⎨⎧​j∈S∑​tj​M∙j​:tj​≥0⎭⎬⎫​,

the defined set is the intersection of all such KSK_SKS​ that contain bbb. If there is no qualifying SSS containing bbb, the condition is vacuous and the defined set is all of RR\mathbb R^RRR. There is no assumption that bbb belongs to the cone generated by all columns.

QAlgorithms.Papers.Independent.Intake100.P98.columnBases

For any types RRR and CCC, each equipped with a finite enumeration, and any integer matrix M=(Mij)i∈R,j∈CM=(M_{ij})_{i\in R,j\in C}M=(Mij​)i∈R,j∈C​, this defines the set of finite subsets S⊆CS\subseteq CS⊆C satisfying both

∣S∣=∣R∣and(M∙j)j∈S is linearly independent over R,|S|=|R| \quad\text{and}\quad \left(M_{\bullet j}\right)_{j\in S} \text{ is linearly independent over }\mathbb R,∣S∣=∣R∣and(M∙j​)j∈S​ is linearly independent over R,

where M∙j∈RRM_{\bullet j}\in\mathbb R^RM∙j​∈RR is the jjj-th column with its integer entries interpreted as real numbers. The empty subset qualifies when RRR is empty. The set of qualifying subsets may be empty; no rank assumption on MMM is imposed.

QAlgorithms.Papers.Independent.Intake100.P98.columnCone

For any types RRR and CCC, with CCC equipped with a finite enumeration, any integer matrix M=(Mij)i∈R,j∈CM=(M_{ij})_{i\in R,j\in C}M=(Mij​)i∈R,j∈C​, and any finite subset S⊆CS\subseteq CS⊆C, this defines the subset of RR\mathbb R^RRR consisting exactly of vectors bbb for which there exists a∈RCa\in\mathbb R^Ca∈RC such that

aj≥0(j∈C),aj=0(j∉S),bi=∑j∈CMijaj(i∈R).a_j\ge0\quad(j\in C),\qquad a_j=0\quad(j\notin S),\qquad b_i=\sum_{j\in C}M_{ij}a_j\quad(i\in R).aj​≥0(j∈C),aj​=0(j∈/S),bi​=j∈C∑​Mij​aj​(i∈R).

Thus it consists of nonnegative real linear combinations of the columns indexed by SSS, interpreting the integer matrix entries as real numbers. The row type RRR need not be finite. The zero vector is always included; if SSS is empty, this set is exactly the singleton containing the zero vector.

QAlgorithms.Papers.Independent.Intake100.P98.evalReal

For any index type III, any polynomial ppp with rational coefficients and variables indexed by III, and any assignment x:I→Rx:I\to\mathbb Rx:I→R, this definition returns the real number obtained by embedding every rational coefficient into R\mathbb RR and substituting xix_ixi​ for variable iii. The type III need not be finite or nonempty; each polynomial involves only finitely many variables, and for empty III this evaluates its constant coefficient.

QAlgorithms.Papers.Independent.Intake100.P98.exchangeLRBlocks

For every natural number kkk, every type AAA, with no additional structure assumed on AAA, and every array x:{0,1,2}×{0,…,k−1}→Ax:\{0,1,2\}\times\{0,\ldots,k-1\}\to Ax:{0,1,2}×{0,…,k−1}→A, this defines the array obtained by exchanging its first two blocks and retaining its third:

(exchange⁡x)0,i=x1,i,(exchange⁡x)1,i=x0,i,(exchange⁡x)2,i=x2,i.(\operatorname{exchange}x)_{0,i}=x_{1,i},\qquad (\operatorname{exchange}x)_{1,i}=x_{0,i},\qquad (\operatorname{exchange}x)_{2,i}=x_{2,i}.(exchangex)0,i​=x1,i​,(exchangex)1,i​=x0,i​,(exchangex)2,i​=x2,i​.

For k=0k=0k=0, it maps the unique empty array to itself.

QAlgorithms.Papers.Independent.Intake100.P98.faces

For any real module VVV whose additive structure is an abelian group, and any subset C⊆VC\subseteq VC⊆V, this defines a collection of subsets F⊆VF\subseteq VF⊆V. A set FFF belongs to the collection exactly when there exists a real-linear functional ℓ:V→R\ell:V\to\mathbb Rℓ:V→R such that

ℓ(y)≥0for every y∈C,F={y∈C:ℓ(y)=0}.\ell(y)\ge0\quad\text{for every }y\in C, \qquad F=\{y\in C:\ell(y)=0\}.ℓ(y)≥0for every y∈C,F={y∈C:ℓ(y)=0}.

No convexity, cone, closure, or nonemptiness assumption is made on CCC. The zero functional is allowed and gives F=CF=CF=C. If CCC is empty, the collection consists only of the empty set.

QAlgorithms.Papers.Independent.Intake100.P98.fundamentalWeight

For every natural number kkk and every index j∈{0,…,k−2}j\in\{0,\ldots,k-2\}j∈{0,…,k−2}, this defines the vector ω(j)∈Rk\omega^{(j)}\in\mathbb R^kω(j)∈Rk by

ωi(j)={k−(j+1)k,i<j+1,−j+1k,i≥j+1.\omega^{(j)}_i= \begin{cases} \dfrac{k-(j+1)}{k},&i<j+1,\\[3pt] -\dfrac{j+1}{k},&i\ge j+1. \end{cases}ωi(j)​=⎩⎨⎧​kk−(j+1)​,−kj+1​,​i<j+1,i≥j+1.​

The index set has size max⁡(k−1,0)\max(k-1,0)max(k−1,0), so it is empty for k=0k=0k=0 and k=1k=1k=1. Consequently, any supplied index jjj forces k≥2k\ge2k≥2, and the displayed divisions never have zero denominator for an admissible argument.

QAlgorithms.Papers.Independent.Intake100.P98.hiveMatrix

For every natural number kkk, hiveMatrix(k)\mathrm{hiveMatrix}(k)hiveMatrix(k) is an integer matrix whose rows are triples r=(a,i,j)r=(a,i,j)r=(a,i,j) with a∈{0,1,2}a\in\{0,1,2\}a∈{0,1,2}, 0≤i,j≤k0\le i,j\le k0≤i,j≤k, and i+j+2≤ki+j+2\le ki+j+2≤k, and whose columns form the disjoint union of interior pairs q=(u,v)q=(u,v)q=(u,v) with u,v>0u,v>0u,v>0, u+v<ku+v<ku+v<k, and a second copy of the row index set. For an interior column qqq, put δq(s,t)=1\delta_q(s,t)=1δq​(s,t)=1 if (s,t)=(u,v)(s,t)=(u,v)(s,t)=(u,v) and 000 otherwise; the entry in row r=(a,i,j)r=(a,i,j)r=(a,i,j) is

{δq(i,j)+δq(i+1,j+1)−δq(i+1,j)−δq(i,j+1),a=0,δq(i+2,j)+δq(i,j+1)−δq(i+1,j)−δq(i+1,j+1),a=1,δq(i+1,j)+δq(i,j+2)−δq(i,j+1)−δq(i+1,j+1),a=2.\begin{cases} \delta_q(i,j)+\delta_q(i+1,j+1)-\delta_q(i+1,j)-\delta_q(i,j+1),&a=0,\\ \delta_q(i+2,j)+\delta_q(i,j+1)-\delta_q(i+1,j)-\delta_q(i+1,j+1),&a=1,\\ \delta_q(i+1,j)+\delta_q(i,j+2)-\delta_q(i,j+1)-\delta_q(i+1,j+1),&a=2. \end{cases}⎩⎨⎧​δq​(i,j)+δq​(i+1,j+1)−δq​(i+1,j)−δq​(i,j+1),δq​(i+2,j)+δq​(i,j+1)−δq​(i+1,j)−δq​(i+1,j+1),δq​(i+1,j)+δq​(i,j+2)−δq​(i,j+1)−δq​(i+1,j+1),​a=0,a=1,a=2.​

For a column sss from the second copy of the row index set, the entry is 111 when r=sr=sr=s and 000 otherwise. Thus these latter columns form an identity matrix. For k<2k<2k<2, both the row and column index sets are empty.

QAlgorithms.Papers.Independent.Intake100.P98.inversions

For any natural number kkk and any permutation σ\sigmaσ of {0,…,k−1}\{0,\ldots,k-1\}{0,…,k−1}, this definition returns the number of pairs (i,j)(i,j)(i,j) with 0≤i<j<k0\le i<j<k0≤i<j<k for which σ(j)<σ(i)\sigma(j)<\sigma(i)σ(j)<σ(i). For k=0k=0k=0 or k=1k=1k=1, this number is zero.

QAlgorithms.Papers.Independent.Intake100.P98.kostant

For any natural number kkk and any real vector v=(v0,…,vk−1)v=(v_0,\ldots,v_{k-1})v=(v0​,…,vk−1​), this definition returns the natural-number cardinality of the set of assignments of nonnegative integers ar,sa_{r,s}ar,s​ to all pairs 0≤r<s<k0\le r<s<k0≤r<s<k satisfying, for every 0≤i<k0\le i<k0≤i<k,

∑s>iai,s−∑r<iar,i=vi.\sum_{s>i}a_{i,s}-\sum_{r<i}a_{r,i}=v_i.s>i∑​ai,s​−r<i∑​ar,i​=vi​.

The equations are equalities in R\mathbb RR, with the integer multiplicities embedded into R\mathbb RR. The cardinality operation used returns zero for an infinite set as well as for an empty set. No integrality or zero-sum assumption is imposed on vvv; a noninteger coordinate or a nonzero coordinate sum makes the solution set empty. For k=0k=0k=0, the unique empty assignment satisfies all equations and the value is 111; for k=1k=1k=1, the value is 111 when v0=0v_0=0v0​=0 and 000 otherwise.

QAlgorithms.Papers.Independent.Intake100.P98.kostantComplex

For every natural number kkk, this defines a family of subsets of Rk\mathbb R^kRk as follows. Put m=max⁡(k−1,0)m=\max(k-1,0)m=max(k−1,0), and, for every pair 0≤a<b<k0\le a<b<k0≤a<b<k, let Aab∈RmA_{ab}\in\mathbb R^mAab​∈Rm have coordinate iii equal to 111 when a≤i<ba\le i<ba≤i<b, and 000 otherwise. For a set SSS of such pairs, let KSK_SKS​ be the cone of nonnegative real linear combinations of the columns AabA_{ab}Aab​ indexed by SSS. Call SSS a column basis when it has exactly mmm elements and its columns are linearly independent. Choose any bbb in the cone generated by all columns, form DbD_bDb​ as the intersection of KSK_SKS​ over all column bases SSS for which b∈KSb\in K_Sb∈KS​, and choose any real linear functional ℓ\ellℓ that is nonnegative throughout DbD_bDb​. An intersection indexed by no column bases means all of Rm\mathbb R^mRm. The family being defined consists exactly of all sets

C={v∈Rk: ∑i=0k−1vi=0,(∑j=0ivj)i=0m−1∈Db,ℓ((∑j=0ivj)i=0m−1)=0}C=\left\{v\in\mathbb R^k:\ \sum_{i=0}^{k-1}v_i=0,\quad \left(\sum_{j=0}^{i}v_j\right)_{i=0}^{m-1}\in D_b,\quad \ell\left(\left(\sum_{j=0}^{i}v_j\right)_{i=0}^{m-1}\right)=0\right\}C=⎩⎨⎧​v∈Rk: i=0∑k−1​vi​=0,(j=0∑i​vj​)i=0m−1​∈Db​,ℓ​(j=0∑i​vj​)i=0m−1​​=0⎭⎬⎫​

obtained by these choices. No positivity assumption on kkk is imposed; for k=0k=0k=0 or k=1k=1k=1, this family consists only of the zero-sum subspace itself.

QAlgorithms.Papers.Independent.Intake100.P98.kostantLabel

For every natural number kkk and every vector v∈Rkv\in\mathbb R^kv∈Rk, this defines either a selected subset of Rk\mathbb R^kRk or no subset. Its candidate subsets are constructed as follows: put m=max⁡(k−1,0)m=\max(k-1,0)m=max(k−1,0), take columns Aab∈RmA_{ab}\in\mathbb R^mAab​∈Rm, indexed by 0≤a<b<k0\le a<b<k0≤a<b<k, with (Aab)i=1(A_{ab})_i=1(Aab​)i​=1 if a≤i<ba\le i<ba≤i<b and 000 otherwise, and let KSK_SKS​ be their nonnegative span for an index set SSS. A column basis is a set of mmm linearly independent columns. For bbb in the cone of all columns, intersect the cones KSK_SKS​ over the column bases whose cones contain bbb, obtaining DbD_bDb​; an empty intersection is Rm\mathbb R^mRm. For a real linear functional ℓ\ellℓ nonnegative on DbD_bDb​, take

C={u:∑iui=0,s(u)∈Db,ℓ(s(u))=0},s(u)i=∑j=0iuj.C=\left\{u:\sum_i u_i=0,\quad s(u)\in D_b,\quad \ell(s(u))=0\right\}, \qquad s(u)_i=\sum_{j=0}^{i}u_j.C={u:i∑​ui​=0,s(u)∈Db​,ℓ(s(u))=0},s(u)i​=j=0∑i​uj​.

If at least one such CCC contains vvv in its interior taken within the fixed zero-sum subspace Hk={u:∑iui=0}H_k=\{u:\sum_i u_i=0\}Hk​={u:∑i​ui​=0}, the definition returns one such CCC by unspecified classical choice; otherwise it returns no subset. No uniqueness is assumed. In particular, a vector outside HkH_kHk​ receives no label. For k=0k=0k=0 or k=1k=1k=1, the unique candidate is HkH_kHk​, and precisely its sole vector receives that label.

QAlgorithms.Papers.Independent.Intake100.P98.kostantPiece

For every natural number kkk and every subset C⊆RkC\subseteq\mathbb R^kC⊆Rk, this defines a polynomial with rational coefficients in the kkk coordinate variables. For v∈Rkv\in\mathbb R^kv∈Rk, let K(v)K(v)K(v) be the natural cardinality of the set of arrays of nonnegative integers (aab)0≤a<b<k(a_{ab})_{0\le a<b<k}(aab​)0≤a<b<k​ satisfying

vi=∑i<b<kaib−∑0≤a<iaai(0≤i<k).v_i=\sum_{i<b<k}a_{ib}-\sum_{0\le a<i}a_{ai} \qquad(0\le i<k).vi​=i<b<k∑​aib​−0≤a<i∑​aai​(0≤i<k).

Natural cardinality is zero for an infinite set as well as for an empty set. If there exists a rational polynomial ppp of total degree at most (max⁡(k−1,0)2)\binom{\max(k-1,0)}{2}(2max(k−1,0)​) such that p(z)=K(z)p(z)=K(z)p(z)=K(z), interpreted as an equality of real numbers, for every integer vector z∈Zkz\in\mathbb Z^kz∈Zk with ∑izi=0\sum_i z_i=0∑i​zi​=0 and z∈Cz\in Cz∈C, the definition selects one such polynomial by unspecified classical choice. Evaluation here embeds the rational coefficients into R\mathbb RR. If no such polynomial exists, the definition returns the zero polynomial. No uniqueness is required. In particular, when CCC contains no zero-sum integer vectors, the evaluation condition is vacuous and any polynomial satisfying the degree bound is eligible; the definition does not specify which is selected. The cases k=0k=0k=0 and k=1k=1k=1 are included, and their degree bound is zero.

QAlgorithms.Papers.Independent.Intake100.P98.lrComplex

For every natural number kkk, this defines a collection of subsets of V=REV=\mathbb R^{E}V=RE, where E={0,1,2}×{0,…,k−1}E=\{0,1,2\}\times\{0,\ldots,k-1\}E={0,1,2}×{0,…,k−1}. The complete construction is as follows. Put I={(s,t):s,t>0, s+t<k}I=\{(s,t):s,t>0,\ s+t<k\}I={(s,t):s,t>0, s+t<k}, J={(a,i,j):a∈{0,1,2}, i,j≥0, i+j+2≤k}J=\{(a,i,j):a\in\{0,1,2\},\ i,j\ge0,\ i+j+2\le k\}J={(a,i,j):a∈{0,1,2}, i,j≥0, i+j+2≤k}, and let ece_cec​ denote the coordinate vectors indexed by the disjoint union I⊔EI\sqcup EI⊔E. For nonnegative s,ts,ts,t with s+t≤ks+t\le ks+t≤k, define

α(s,t)={∑h<te(0,h),s=0,∑h<se(2,h),s>0, t=0,∑h<ke(0,h)+∑h<se(1,h),s,t>0, s+t=k,e(s,t),s,t>0, s+t<k.\alpha(s,t)= \begin{cases} \displaystyle\sum_{h<t}e_{(0,h)},&s=0,\\ \displaystyle\sum_{h<s}e_{(2,h)},&s>0,\ t=0,\\ \displaystyle\sum_{h<k}e_{(0,h)}+\sum_{h<s}e_{(1,h)},&s,t>0,\ s+t=k,\\ e_{(s,t)},&s,t>0,\ s+t<k. \end{cases}α(s,t)=⎩⎨⎧​h<t∑​e(0,h)​,h<s∑​e(2,h)​,h<k∑​e(0,h)​+h<s∑​e(1,h)​,e(s,t)​,​s=0,s>0, t=0,s,t>0, s+t=k,s,t>0, s+t<k.​

Here the last case uses an III-coordinate, the other cases use EEE-coordinates, and each sum has 0≤h<k0\le h<k0≤h<k. For r=(a,i,j)∈Jr=(a,i,j)\in Jr=(a,i,j)∈J, set

Dr={α(i,j)+α(i+1,j+1)−α(i+1,j)−α(i,j+1),a=0,α(i+2,j)+α(i,j+1)−α(i+1,j)−α(i+1,j+1),a=1,α(i+1,j)+α(i,j+2)−α(i,j+1)−α(i+1,j+1),a=2.D_r= \begin{cases} \alpha(i,j)+\alpha(i+1,j+1)-\alpha(i+1,j)-\alpha(i,j+1),&a=0,\\ \alpha(i+2,j)+\alpha(i,j+1)-\alpha(i+1,j)-\alpha(i+1,j+1),&a=1,\\ \alpha(i+1,j)+\alpha(i,j+2)-\alpha(i,j+1)-\alpha(i+1,j+1),&a=2. \end{cases}Dr​=⎩⎨⎧​α(i,j)+α(i+1,j+1)−α(i+1,j)−α(i,j+1),α(i+2,j)+α(i,j+1)−α(i+1,j)−α(i+1,j+1),α(i+1,j)+α(i,j+2)−α(i,j+1)−α(i+1,j+1),​a=0,a=1,a=2.​

Define the integer matrix HHH, with rows JJJ and columns I⊔JI\sqcup JI⊔J, by Hr,q=(Dr)qH_{r,q}=(D_r)_qHr,q​=(Dr​)q​ for q∈Iq\in Iq∈I and Hr,s=1r=sH_{r,s}=\mathbf1_{r=s}Hr,s​=1r=s​ for s∈Js\in Js∈J, and define B:V→RJB:V\to\mathbb R^JB:V→RJ by (Bx)r=−∑v∈E(Dr)vxv(Bx)_r=-\sum_{v\in E}(D_r)_v x_v(Bx)r​=−∑v∈E​(Dr​)v​xv​. For S⊆I⊔JS\subseteq I\sqcup JS⊆I⊔J, let KSK_SKS​ be the cone of nonnegative real linear combinations of the columns of HHH indexed by SSS. For b∈KI⊔Jb\in K_{I\sqcup J}b∈KI⊔J​, let

Ab=⋂S⊆I⊔J, ∣S∣=∣J∣(H∙c)c∈S linearly independentb∈KSKS,A_b=\bigcap_{\substack{S\subseteq I\sqcup J,\ |S|=|J|\\ (H_{\bullet c})_{c\in S}\ \text{linearly independent}\\ b\in K_S}}K_S,Ab​=S⊆I⊔J, ∣S∣=∣J∣(H∙c​)c∈S​ linearly independentb∈KS​​⋂​KS​,

where an intersection over no sets is all of RJ\mathbb R^JRJ. Finally, let D⊆V\mathcal D\subseteq VD⊆V consist of arrays xxx satisfying

∑h<kx0,h+∑h<kx1,h=∑h<kx2,h,xb,h≥0,xb,h≥xb,h′ whenever h≤h′,x0,h≤x2,h,x1,h≤x2,h.\sum_{h<k}x_{0,h}+\sum_{h<k}x_{1,h}=\sum_{h<k}x_{2,h}, \quad x_{b,h}\ge0, \quad x_{b,h}\ge x_{b,h'}\ \text{whenever }h\le h', \quad x_{0,h}\le x_{2,h},\quad x_{1,h}\le x_{2,h}.h<k∑​x0,h​+h<k∑​x1,h​=h<k∑​x2,h​,xb,h​≥0,xb,h​≥xb,h′​ whenever h≤h′,x0,h​≤x2,h​,x1,h​≤x2,h​.

A subset F⊆VF\subseteq VF⊆V belongs to the defined collection exactly when there exist b∈KI⊔Jb\in K_{I\sqcup J}b∈KI⊔J​, a real-linear functional ℓ:RJ→R\ell:\mathbb R^J\to\mathbb Rℓ:RJ→R nonnegative on AbA_bAb​, and a real-linear functional f:V→Rf:V\to\mathbb Rf:V→R, such that, putting C={z∈Ab:ℓ(z)=0}C=\{z\in A_b:\ell(z)=0\}C={z∈Ab​:ℓ(z)=0} and P={x∈D:Bx∈C}P=\{x\in\mathcal D:Bx\in C\}P={x∈D:Bx∈C}, the functional fff is nonnegative on PPP and

F={x∈P:f(x)=0}.F=\{x\in P:f(x)=0\}.F={x∈P:f(x)=0}.

Neither functional is required to be nonzero, and no positivity assumption on kkk is made; all empty sums, empty index sets, and vacuous conditions are included.

QAlgorithms.Papers.Independent.Intake100.P98.lrSupport

For every natural number kkk, this defines a subset of V=REV=\mathbb R^EV=RE, where E={0,1,2}×{0,…,k−1}E=\{0,1,2\}\times\{0,\ldots,k-1\}E={0,1,2}×{0,…,k−1}, by the following membership condition. Put I={(s,t):s,t>0, s+t<k}I=\{(s,t):s,t>0,\ s+t<k\}I={(s,t):s,t>0, s+t<k}, J={(a,i,j):a∈{0,1,2}, i,j≥0, i+j+2≤k}J=\{(a,i,j):a\in\{0,1,2\},\ i,j\ge0,\ i+j+2\le k\}J={(a,i,j):a∈{0,1,2}, i,j≥0, i+j+2≤k}, and use coordinate vectors ece_cec​ indexed by I⊔EI\sqcup EI⊔E. Define

α(s,t)={∑h<te(0,h),s=0,∑h<se(2,h),s>0, t=0,∑h<ke(0,h)+∑h<se(1,h),s,t>0, s+t=k,e(s,t),s,t>0, s+t<k,\alpha(s,t)= \begin{cases} \displaystyle\sum_{h<t}e_{(0,h)},&s=0,\\ \displaystyle\sum_{h<s}e_{(2,h)},&s>0,\ t=0,\\ \displaystyle\sum_{h<k}e_{(0,h)}+\sum_{h<s}e_{(1,h)},&s,t>0,\ s+t=k,\\ e_{(s,t)},&s,t>0,\ s+t<k, \end{cases}α(s,t)=⎩⎨⎧​h<t∑​e(0,h)​,h<s∑​e(2,h)​,h<k∑​e(0,h)​+h<s∑​e(1,h)​,e(s,t)​,​s=0,s>0, t=0,s,t>0, s+t=k,s,t>0, s+t<k,​

for s,t≥0s,t\ge0s,t≥0 with s+t≤ks+t\le ks+t≤k, using III-coordinates in the last case and EEE-coordinates in the other cases, and restricting each sum to 0≤h<k0\le h<k0≤h<k. For r=(a,i,j)∈Jr=(a,i,j)\in Jr=(a,i,j)∈J, put

Dr={α(i,j)+α(i+1,j+1)−α(i+1,j)−α(i,j+1),a=0,α(i+2,j)+α(i,j+1)−α(i+1,j)−α(i+1,j+1),a=1,α(i+1,j)+α(i,j+2)−α(i,j+1)−α(i+1,j+1),a=2.D_r= \begin{cases} \alpha(i,j)+\alpha(i+1,j+1)-\alpha(i+1,j)-\alpha(i,j+1),&a=0,\\ \alpha(i+2,j)+\alpha(i,j+1)-\alpha(i+1,j)-\alpha(i+1,j+1),&a=1,\\ \alpha(i+1,j)+\alpha(i,j+2)-\alpha(i,j+1)-\alpha(i+1,j+1),&a=2. \end{cases}Dr​=⎩⎨⎧​α(i,j)+α(i+1,j+1)−α(i+1,j)−α(i,j+1),α(i+2,j)+α(i,j+1)−α(i+1,j)−α(i+1,j+1),α(i+1,j)+α(i,j+2)−α(i,j+1)−α(i+1,j+1),​a=0,a=1,a=2.​

Let HHH be the integer matrix with rows JJJ and columns I⊔JI\sqcup JI⊔J given by Hr,q=(Dr)qH_{r,q}=(D_r)_qHr,q​=(Dr​)q​ for q∈Iq\in Iq∈I and Hr,s=1r=sH_{r,s}=\mathbf1_{r=s}Hr,s​=1r=s​ for s∈Js\in Js∈J, and put (Bx)r=−∑v∈E(Dr)vxv(Bx)_r=-\sum_{v\in E}(D_r)_v x_v(Bx)r​=−∑v∈E​(Dr​)v​xv​. For each S⊆I⊔JS\subseteq I\sqcup JS⊆I⊔J, let KSK_SKS​ be the cone of nonnegative real linear combinations of its indexed columns of HHH, and for b∈KI⊔Jb\in K_{I\sqcup J}b∈KI⊔J​ put

Ab=⋂S⊆I⊔J, ∣S∣=∣J∣(H∙c)c∈S linearly independentb∈KSKS,A_b=\bigcap_{\substack{S\subseteq I\sqcup J,\ |S|=|J|\\ (H_{\bullet c})_{c\in S}\ \text{linearly independent}\\ b\in K_S}}K_S,Ab​=S⊆I⊔J, ∣S∣=∣J∣(H∙c​)c∈S​ linearly independentb∈KS​​⋂​KS​,

with an empty intersection interpreted as RJ\mathbb R^JRJ. Let D\mathcal DD be the set of arrays z∈Vz\in Vz∈V whose coordinates are nonnegative, whose three blocks are nonincreasing in their second index, and which satisfy

∑h<kz0,h+∑h<kz1,h=∑h<kz2,h,z0,h≤z2,h,z1,h≤z2,h(h<k).\sum_{h<k}z_{0,h}+\sum_{h<k}z_{1,h}=\sum_{h<k}z_{2,h}, \qquad z_{0,h}\le z_{2,h},\qquad z_{1,h}\le z_{2,h}\quad(h<k).h<k∑​z0,h​+h<k∑​z1,h​=h<k∑​z2,h​,z0,h​≤z2,h​,z1,h​≤z2,h​(h<k).

A vector x∈Vx\in Vx∈V belongs to the defined support exactly when there exist b∈KI⊔Jb\in K_{I\sqcup J}b∈KI⊔J​, a real-linear functional ℓ:RJ→R\ell:\mathbb R^J\to\mathbb Rℓ:RJ→R nonnegative on AbA_bAb​, a real-linear functional f:V→Rf:V\to\mathbb Rf:V→R, and a set F⊆VF\subseteq VF⊆V, such that, writing

C={y∈Ab:ℓ(y)=0},P={z∈D:Bz∈C},C=\{y\in A_b:\ell(y)=0\},\qquad P=\{z\in\mathcal D:Bz\in C\},C={y∈Ab​:ℓ(y)=0},P={z∈D:Bz∈C},

one has f(z)≥0f(z)\ge0f(z)≥0 for every z∈Pz\in Pz∈P, F={z∈P:f(z)=0}F=\{z\in P:f(z)=0\}F={z∈P:f(z)=0}, and x∈Fx\in Fx∈F. Thus membership is existential membership in one of the sets constructed in this way. Zero functionals are permitted, and k=0k=0k=0 and all resulting empty index sets and sums are included.

QAlgorithms.Papers.Independent.Intake100.P98.paddedLRCoefficient

For every natural number kkk and array x:{0,1,2}×{0,…,k−1}→Nx:\{0,1,2\}\times\{0,\ldots,k-1\}\to\mathbb Nx:{0,1,2}×{0,…,k−1}→N, form Young diagrams λ,μ,ν\lambda,\mu,\nuλ,μ,ν by sorting, respectively, the lists (x0,i)i<k(x_{0,i})_{i<k}(x0,i​)i<k​, (x1,i)i<k(x_{1,i})_{i<k}(x1,i​)i<k​, and (x2,i)i<k(x_{2,i})_{i<k}(x2,i​)i<k​ into nonincreasing order and using them as row lengths. The value paddedLRCoefficient(x)\mathrm{paddedLRCoefficient}(x)paddedLRCoefficient(x) is zero if the cells of λ\lambdaλ are not contained in those of ν\nuν. Otherwise it is the number of fillings T:ν∖λ→{0,…,k−1}T:\nu\setminus\lambda\to\{0,\ldots,k-1\}T:ν∖λ→{0,…,k−1} satisfying all of the following: entries weakly increase from left to right in each row and strictly increase from top to bottom in each column; for every natural number aaa, the number of cells assigned the value aaa equals the length of row aaa of μ\muμ; and, for every skew cell (r,c)(r,c)(r,c) and every 0≤a<k−10\le a<k-10≤a<k−1, among the skew cells (r′,c′)(r',c')(r′,c′) with r′<rr'<rr′<r, or with r′=rr'=rr′=r and c′≥cc'\ge cc′≥c, the number of entries equal to a+1a+1a+1 is at most the number equal to aaa. No ordering, size equation, or containment condition on the original array is assumed. When k=0k=0k=0, all three diagrams and the filling are empty, and the value is 111.

QAlgorithms.Papers.Independent.Intake100.P98.partitionComplex

For any finite enumerated types R,CR,CR,C and any integer matrix MMM with these row and column indices, this defines a collection of subsets F⊆RRF\subseteq\mathbb R^RF⊆RR. Write

KS={∑j∈StjM∙j:tj≥0}K_S=\left\{\sum_{j\in S}t_jM_{\bullet j}:t_j\ge0\right\}KS​=⎩⎨⎧​j∈S∑​tj​M∙j​:tj​≥0⎭⎬⎫​

for each S⊆CS\subseteq CS⊆C, interpreting columns as real vectors. A set FFF belongs to the collection exactly when there exist b∈KCb\in K_Cb∈KC​ and a real-linear functional ℓ:RR→R\ell:\mathbb R^R\to\mathbb Rℓ:RR→R such that, with

Ab={y∈RR: ∀S⊆C, (∣S∣=∣R∣ and the columns indexed by S are linearly independent and b∈KS)⇒y∈KS},A_b= \left\{y\in\mathbb R^R: \ \forall S\subseteq C,\ \bigl(|S|=|R|\ \text{and the columns indexed by }S \text{ are linearly independent and }b\in K_S\bigr) \Rightarrow y\in K_S \right\},Ab​={y∈RR: ∀S⊆C, (∣S∣=∣R∣ and the columns indexed by S are linearly independent and b∈KS​)⇒y∈KS​},

one has ℓ(y)≥0\ell(y)\ge0ℓ(y)≥0 for every y∈Aby\in A_by∈Ab​ and

F={y∈Ab:ℓ(y)=0}.F=\{y\in A_b:\ell(y)=0\}.F={y∈Ab​:ℓ(y)=0}.

The vector b=0b=0b=0 and the zero functional are permitted. An intersection defining AbA_bAb​ with no applicable subsets SSS is the whole space; in particular, if no subset of columns qualifies as a basis, the collection consists only of RR\mathbb R^RRR.

QAlgorithms.Papers.Independent.Intake100.P98.partitionFiber

For any types RRR and CCC, with CCC equipped with a finite enumeration, any integer matrix M=(Mij)i∈R,j∈CM=(M_{ij})_{i\in R,j\in C}M=(Mij​)i∈R,j∈C​, and any integer vector b∈ZRb\in\mathbb Z^Rb∈ZR, this defines the type of natural-number vectors a∈NCa\in\mathbb N^Ca∈NC satisfying

∑j∈CMijaj=bi(i∈R),\sum_{j\in C}M_{ij}a_j=b_i\qquad(i\in R),j∈C∑​Mij​aj​=bi​(i∈R),

where the entries of aaa are interpreted as integers in the equations. Zero coordinates are allowed, RRR need not be finite, and the solution type need not be finite or nonempty. If CCC is empty, it contains the unique empty vector exactly when bi=0b_i=0bi​=0 for every i∈Ri\in Ri∈R; otherwise it is empty. If RRR is empty, every vector in NC\mathbb N^CNC is a solution.

QAlgorithms.Papers.Independent.Intake100.P98.permutationOrder

For every natural number kkk, this defines a linear order on the permutations of {0,…,k−1}\{0,\ldots,k-1\}{0,…,k−1} by transporting the usual order on {0,…,k!−1}\{0,\ldots,k!-1\}{0,…,k!−1} along the particular bijection supplied by the finite-type enumeration of the permutation set. Explicitly, if this bijection is eee, then σ≤τ\sigma\le\tauσ≤τ means e(σ)≤e(τ)e(\sigma)\le e(\tau)e(σ)≤e(τ). The definition includes k=0k=0k=0 and k=1k=1k=1, when there is only one permutation and hence only one possible linear order.

QAlgorithms.Papers.Independent.Intake100.P98.permuteRootCoordinates

For any natural number kkk, any permutation σ\sigmaσ of {0,…,k−1}\{0,\ldots,k-1\}{0,…,k−1}, and any real vector vvv indexed by that set, this definition returns the vector with coordinate vσ−1(i)v_{\sigma^{-1}(i)}vσ−1(i)​ at index iii. It includes the unique permutation and empty vector when k=0k=0k=0.

QAlgorithms.Papers.Independent.Intake100.P98.realTriple

For every natural number kkk and natural-valued array x:{0,1,2}×{0,…,k−1}→Nx:\{0,1,2\}\times\{0,\ldots,k-1\}\to\mathbb Nx:{0,1,2}×{0,…,k−1}→N, realTriple(x)\mathrm{realTriple}(x)realTriple(x) is the real-valued array on the same index set obtained by viewing each entry as a real number:

realTriple(x)b,i=(xb,i:R).\mathrm{realTriple}(x)_{b,i}=(x_{b,i}:\mathbb R).realTriple(x)b,i​=(xb,i​:R).

No further conditions on xxx are imposed; for k=0k=0k=0, this sends the unique empty natural-valued array to the unique empty real-valued array.

QAlgorithms.Papers.Independent.Intake100.P98.rhombusCoefficient

For every natural number kkk, every triple r=(a,i,j)r=(a,i,j)r=(a,i,j) with a∈{0,1,2}a\in\{0,1,2\}a∈{0,1,2}, 0≤i,j≤k0\le i,j\le k0≤i,j≤k, and i+j+2≤ki+j+2\le ki+j+2≤k, and every index ccc in the disjoint union of interior pairs q=(u,v)q=(u,v)q=(u,v) with u,v>0u,v>0u,v>0, u+v<ku+v<ku+v<k, and boundary-coordinate pairs (b,h)(b,h)(b,h) with b∈{0,1,2}b\in\{0,1,2\}b∈{0,1,2}, 0≤h<k0\le h<k0≤h<k, define an integer-valued function Ac(s,t)A_c(s,t)Ac​(s,t) on natural pairs as follows: for an interior index q=(u,v)q=(u,v)q=(u,v), let Ac(s,t)=1s=u∧t=vA_c(s,t)=\mathbf1_{s=u\land t=v}Ac​(s,t)=1s=u∧t=v​; for a boundary-coordinate index (b,h)(b,h)(b,h), let

Ac(s,t)={1b=0∧h<t,s=0,1b=2∧h<s,s≠0, t=0,1b=0+1b=1∧h<s,s≠0, t≠0, s+t=k,0,otherwise,A_c(s,t)= \begin{cases} \mathbf1_{b=0\land h<t},&s=0,\\ \mathbf1_{b=2\land h<s},&s\ne0,\ t=0,\\ \mathbf1_{b=0}+\mathbf1_{b=1\land h<s},&s\ne0,\ t\ne0,\ s+t=k,\\ 0,&\text{otherwise}, \end{cases}Ac​(s,t)=⎩⎨⎧​1b=0∧h<t​,1b=2∧h<s​,1b=0​+1b=1∧h<s​,0,​s=0,s=0, t=0,s=0, t=0, s+t=k,otherwise,​

where each indicator is 111 if its condition holds and 000 otherwise. Then rhombusCoefficient(r,c)\mathrm{rhombusCoefficient}(r,c)rhombusCoefficient(r,c) is

{Ac(i,j)+Ac(i+1,j+1)−Ac(i+1,j)−Ac(i,j+1),a=0,Ac(i+2,j)+Ac(i,j+1)−Ac(i+1,j)−Ac(i+1,j+1),a=1,Ac(i+1,j)+Ac(i,j+2)−Ac(i,j+1)−Ac(i+1,j+1),a=2.\begin{cases} A_c(i,j)+A_c(i+1,j+1)-A_c(i+1,j)-A_c(i,j+1),&a=0,\\ A_c(i+2,j)+A_c(i,j+1)-A_c(i+1,j)-A_c(i+1,j+1),&a=1,\\ A_c(i+1,j)+A_c(i,j+2)-A_c(i,j+1)-A_c(i+1,j+1),&a=2. \end{cases}⎩⎨⎧​Ac​(i,j)+Ac​(i+1,j+1)−Ac​(i+1,j)−Ac​(i,j+1),Ac​(i+2,j)+Ac​(i,j+1)−Ac​(i+1,j)−Ac​(i+1,j+1),Ac​(i+1,j)+Ac​(i,j+2)−Ac​(i,j+1)−Ac​(i+1,j+1),​a=0,a=1,a=2.​

For k<2k<2k<2, there are no possible row indices rrr.

QAlgorithms.Papers.Independent.Intake100.P98.rootHalfSum

For every natural number kkk, this defines the real vector indexed by 0≤i<k0\le i<k0≤i<k whose iii-th coordinate is

k−1−2i2.\frac{k-1-2i}{2}.2k−1−2i​.

All subtraction in this formula takes place in R\mathbb RR. For k=0k=0k=0 the vector is empty, and for k=1k=1k=1 its sole coordinate is zero.

QAlgorithms.Papers.Independent.Intake100.P98.rootInterior

For every natural number kkk and every subset C⊆RkC\subseteq\mathbb R^kC⊆Rk, this defines the set of vectors vvv with ∑ivi=0\sum_i v_i=0∑i​vi​=0 that belong to the interior of C∩HkC\cap H_kC∩Hk​ in the subspace topology on Hk={w∈Rk:∑iwi=0}H_k=\{w\in\mathbb R^k:\sum_iw_i=0\}Hk​={w∈Rk:∑i​wi​=0}. Thus the interior is taken in this fixed zero-sum subspace, rather than in the affine span of CCC; points of CCC outside HkH_kHk​ have no effect. The definition includes k=0k=0k=0, with empty sums interpreted as zero. For k=0k=0k=0 and k=1k=1k=1, HkH_kHk​ is a singleton, so the resulting set is C∩HkC\cap H_kC∩Hk​.

QAlgorithms.Papers.Independent.Intake100.P98.rootMatrix

For every natural number kkk, this defines an integer matrix with rows indexed by 0≤i<k−10\le i<k-10≤i<k−1, where k−1k-1k−1 is natural-number subtraction, and columns indexed by pairs 0≤a<b<k0\le a<b<k0≤a<b<k. Its entry in row iii and column (a,b)(a,b)(a,b) is 111 if a≤i<ba\le i<ba≤i<b, and 000 otherwise. When k=0k=0k=0 or k=1k=1k=1, both index sets are empty.

QAlgorithms.Papers.Independent.Intake100.P98.simpleCoordinates

For any natural number kkk and any real vector v=(v0,…,vk−1)v=(v_0,\ldots,v_{k-1})v=(v0​,…,vk−1​), this definition returns the vector indexed by 0≤i<k−10\le i<k-10≤i<k−1, with natural-number subtraction used in the index bound, whose iii-th coordinate is

∑j=0ivj.\sum_{j=0}^{i}v_j.j=0∑i​vj​.

No zero-sum condition is required of vvv. For k=0k=0k=0 or k=1k=1k=1, the output vector is empty.

QAlgorithms.Papers.Independent.Intake100.P98.sizeInterior

For every natural number kkk and every subset CCC of the real arrays x=(xb,i)b∈{0,1,2}, 0≤i<kx=(x_{b,i})_{b\in\{0,1,2\},\,0\le i<k}x=(xb,i​)b∈{0,1,2},0≤i<k​, this defines the vectors in the subspace

H={x:∑ix0,i+∑ix1,i=∑ix2,i}H=\left\{x:\sum_i x_{0,i}+\sum_i x_{1,i}=\sum_i x_{2,i}\right\}H={x:i∑​x0,i​+i∑​x1,i​=i∑​x2,i​}

that belong to the interior of C∩HC\cap HC∩H in the subspace topology on HHH. The interior is therefore taken within this fixed size-equation subspace; points of CCC outside HHH do not contribute, and no nonnegativity or monotonicity assumptions are imposed. The case k=0k=0k=0 is included: all sums are empty, the ambient array space has one element, and the resulting set equals CCC.

QAlgorithms.Papers.Independent.Intake100.P98.steinbergArgument

For any natural number kkk, any real array x=(xb,i)x=(x_{b,i})x=(xb,i​) indexed by b∈{0,1,2}b\in\{0,1,2\}b∈{0,1,2} and 0≤i<k0\le i<k0≤i<k, and any permutations σ,τ\sigma,\tauσ,τ of {0,…,k−1}\{0,\ldots,k-1\}{0,…,k−1}, this defines the real vector www with

wi=x0,σ−1(i)+k−1−2σ−1(i)2+x1,τ−1(i)+k−1−2τ−1(i)2−x2,i−(k−1−2i).w_i= x_{0,\sigma^{-1}(i)}+\frac{k-1-2\sigma^{-1}(i)}2 +x_{1,\tau^{-1}(i)}+\frac{k-1-2\tau^{-1}(i)}2 -x_{2,i}-(k-1-2i).wi​=x0,σ−1(i)​+2k−1−2σ−1(i)​+x1,τ−1(i)​+2k−1−2τ−1(i)​−x2,i​−(k−1−2i).

There are no ordering, nonnegativity, integrality, or size-equation hypotheses on xxx. For k=0k=0k=0, the resulting vector is empty.

QAlgorithms.Papers.Independent.Intake100.P98.steinbergP

For every natural number kkk and every real array x=(xb,i)b∈{0,1,2}, 0≤i<kx=(x_{b,i})_{b\in\{0,1,2\},\,0\le i<k}x=(xb,i​)b∈{0,1,2},0≤i<k​, this defines the real number

∑σ,τ∈Sk(−1) #{(i,j): i<j,  (στ)(j)<(στ)(i)} F(aσ,τ),aiσ,τ=x0,σ−1(i)+ρσ−1(i)+x1,τ−1(i)+ρτ−1(i)−x2,i−2ρi,ρi=k−1−2i2,\sum_{\sigma,\tau\in S_k}(-1)^{\,\#\{(i,j):\,i<j,\;(\sigma\tau)(j)<(\sigma\tau)(i)\}}\, F(a^{\sigma,\tau}), \qquad a^{\sigma,\tau}_i= x_{0,\sigma^{-1}(i)}+\rho_{\sigma^{-1}(i)} +x_{1,\tau^{-1}(i)}+\rho_{\tau^{-1}(i)} -x_{2,i}-2\rho_i, \quad \rho_i=\frac{k-1-2i}{2},σ,τ∈Sk​∑​(−1)#{(i,j):i<j,(στ)(j)<(στ)(i)}F(aσ,τ),aiσ,τ​=x0,σ−1(i)​+ρσ−1(i)​+x1,τ−1(i)​+ρτ−1(i)​−x2,i​−2ρi​,ρi​=2k−1−2i​,

where the arithmetic defining ρi\rho_iρi​ is real and FFF is determined by the following choices. Put m=max⁡(k−1,0)m=\max(k-1,0)m=max(k−1,0), let Aab∈RmA_{ab}\in\mathbb R^mAab​∈Rm have entry 111 when a≤i<ba\le i<ba≤i<b and 000 otherwise, for 0≤a<b<k0\le a<b<k0≤a<b<k, and let KSK_SKS​ be the nonnegative span of columns indexed by SSS. For each bbb in the cone of all columns, intersect those KSK_SKS​ containing bbb for which SSS consists of exactly mmm linearly independent columns, obtaining DbD_bDb​; an empty intersection is the whole space. Candidate sets are C={u:∑iui=0, s(u)∈Db, ℓ(s(u))=0}C=\{u:\sum_i u_i=0,\ s(u)\in D_b,\ \ell(s(u))=0\}C={u:∑i​ui​=0, s(u)∈Db​, ℓ(s(u))=0}, where s(u)i=∑j=0iujs(u)_i=\sum_{j=0}^{i}u_js(u)i​=∑j=0i​uj​ and ℓ\ellℓ is any real linear functional nonnegative on DbD_bDb​. If aaa belongs to none of these sets’ interiors in the fixed zero-sum subspace, then F(a)=0F(a)=0F(a)=0. Otherwise one such set CCC is selected by classical choice. For that CCC, select by classical choice a rational polynomial pCp_CpC​ of total degree at most (m2)\binom{m}{2}(2m​) agreeing, at every zero-sum integer vector z∈Cz\in Cz∈C, with the natural cardinality of the nonnegative integer arrays (tab)a<b(t_{ab})_{a<b}(tab​)a<b​ satisfying zi=∑i<btib−∑a<itaiz_i=\sum_{i<b}t_{ib}-\sum_{a<i}t_{ai}zi​=∑i<b​tib​−∑a<i​tai​; if no such polynomial exists, set pC=0p_C=0pC​=0. Natural cardinality returns zero for an infinite set. Then F(a)F(a)F(a) is the real evaluation pC(a)p_C(a)pC​(a), with rational coefficients embedded into R\mathbb RR. Neither choice requires uniqueness, and a set containing no zero-sum integer vectors imposes no evaluation constraints on its eligible polynomials. No domain restriction is placed on xxx; k=0k=0k=0 is allowed, and each permutation sum then has one term.

QAlgorithms.Papers.Independent.Intake100.P98.steinbergRegion

For every natural number kkk and every assignment sss of a Boolean value to each quadruple w=(σ,τ,π,j)w=(\sigma,\tau,\pi,j)w=(σ,τ,π,j), where the first three entries are permutations of {0,…,k−1}\{0,\ldots,k-1\}{0,…,k−1} and 0≤j≤k−20\le j\le k-20≤j≤k−2, this defines the set of real arrays x=(xb,i)b∈{0,1,2}, 0≤i<kx=(x_{b,i})_{b\in\{0,1,2\},\,0\le i<k}x=(xb,i​)b∈{0,1,2},0≤i<k​ satisfying

∑ix0,i+∑ix1,i=∑ix2,i\sum_i x_{0,i}+\sum_i x_{1,i}=\sum_i x_{2,i}i∑​x0,i​+i∑​x1,i​=i∑​x2,i​

and, for every such www, Lw(x)>0L_w(x)>0Lw​(x)>0 when s(w)s(w)s(w) is true and Lw(x)<0L_w(x)<0Lw​(x)<0 when s(w)s(w)s(w) is false. Here

Lw(x)=∑i(x0,σ−1(i)+ρσ−1(i)+x1,τ−1(i)+ρτ−1(i)−x2,i−2ρi)ωπ−1(i)(j),L_w(x)=\sum_i \left(x_{0,\sigma^{-1}(i)}+\rho_{\sigma^{-1}(i)} +x_{1,\tau^{-1}(i)}+\rho_{\tau^{-1}(i)} -x_{2,i}-2\rho_i\right)\omega^{(j)}_{\pi^{-1}(i)},Lw​(x)=i∑​(x0,σ−1(i)​+ρσ−1(i)​+x1,τ−1(i)​+ρτ−1(i)​−x2,i​−2ρi​)ωπ−1(i)(j)​,

with ρi=(k−1−2i)/2\rho_i=(k-1-2i)/2ρi​=(k−1−2i)/2 in real arithmetic and ωa(j)=(k−j−1)/k\omega^{(j)}_a=(k-j-1)/kωa(j)​=(k−j−1)/k for a<j+1a<j+1a<j+1, and −(j+1)/k-(j+1)/k−(j+1)/k otherwise. All sign inequalities are strict, so any zero value excludes xxx. No nonnegativity or monotonicity requirement is imposed on its coordinate blocks. The resulting set may be empty. For k=0k=0k=0 or k=1k=1k=1, there are no quadruples, so the sign condition is vacuous and the set is the entire size-equation subspace.

QAlgorithms.Papers.Independent.Intake100.P98.steinbergSum

For any natural number kkk and any real array x=(xb,i)x=(x_{b,i})x=(xb,i​) indexed by b∈{0,1,2}b\in\{0,1,2\}b∈{0,1,2} and 0≤i<k0\le i<k0≤i<k, this definition returns the integer

∑σ,τ∈Sk(−1)I(σ∘τ)Nσ,τ(x),\sum_{\sigma,\tau\in S_k}(-1)^{I(\sigma\circ\tau)}N_{\sigma,\tau}(x),σ,τ∈Sk​∑​(−1)I(σ∘τ)Nσ,τ​(x),

where I(π)I(\pi)I(π) is the number of pairs i<ji<ji<j with π(j)<π(i)\pi(j)<\pi(i)π(j)<π(i), and Nσ,τ(x)N_{\sigma,\tau}(x)Nσ,τ​(x) is the natural-number cardinality, embedded into Z\mathbb ZZ, of the nonnegative integer arrays (ar,s)0≤r<s<k(a_{r,s})_{0\le r<s<k}(ar,s​)0≤r<s<k​ satisfying, for every iii,

∑s>iai,s−∑r<iar,i=x0,σ−1(i)+k−1−2σ−1(i)2+x1,τ−1(i)+k−1−2τ−1(i)2−x2,i−(k−1−2i).\sum_{s>i}a_{i,s}-\sum_{r<i}a_{r,i} = x_{0,\sigma^{-1}(i)}+\frac{k-1-2\sigma^{-1}(i)}2 +x_{1,\tau^{-1}(i)}+\frac{k-1-2\tau^{-1}(i)}2 -x_{2,i}-(k-1-2i).s>i∑​ai,s​−r<i∑​ar,i​=x0,σ−1(i)​+2k−1−2σ−1(i)​+x1,τ−1(i)​+2k−1−2τ−1(i)​−x2,i​−(k−1−2i).

The cardinality operation returns zero for an infinite solution set as well as for an empty one. No restrictions are imposed on the real array xxx. When k=0k=0k=0, there is one pair of empty permutations and one empty multiplicity assignment, so the value is 111.

QAlgorithms.Papers.Independent.Intake100.P98.steinbergType

For every natural number kkk and every real array x=(xb,i)b∈{0,1,2}, 0≤i<kx=(x_{b,i})_{b\in\{0,1,2\},\,0\le i<k}x=(xb,i​)b∈{0,1,2},0≤i<k​, this defines a function of two permutations σ,τ\sigma,\tauσ,τ of {0,…,k−1}\{0,\ldots,k-1\}{0,…,k−1}, whose value is either a selected subset of Rk\mathbb R^kRk or no subset. First it installs the linear order on permutations obtained by transporting the natural order along their finite-type enumeration. Put ρi=(k−1−2i)/2\rho_i=(k-1-2i)/2ρi​=(k−1−2i)/2, with this arithmetic performed in R\mathbb RR, and define

ai=x0,σ−1(i)+ρσ−1(i)+x1,τ−1(i)+ρτ−1(i)−x2,i−2ρi.a_i=x_{0,\sigma^{-1}(i)}+\rho_{\sigma^{-1}(i)} +x_{1,\tau^{-1}(i)}+\rho_{\tau^{-1}(i)} -x_{2,i}-2\rho_i.ai​=x0,σ−1(i)​+ρσ−1(i)​+x1,τ−1(i)​+ρτ−1(i)​−x2,i​−2ρi​.

The candidate subsets for the value at (σ,τ)(\sigma,\tau)(σ,τ) are constructed by putting m=max⁡(k−1,0)m=\max(k-1,0)m=max(k−1,0), taking columns Aab∈RmA_{ab}\in\mathbb R^mAab​∈Rm with entries 111 for a≤i<ba\le i<ba≤i<b and 000 otherwise, and writing KSK_SKS​ for the nonnegative span of columns indexed by SSS. For a point bbb in the cone of all columns, let DbD_bDb​ be the intersection of the KSK_SKS​ containing bbb, where SSS ranges over sets of exactly mmm linearly independent columns; an empty intersection is all of Rm\mathbb R^mRm. For any real linear functional ℓ\ellℓ nonnegative on DbD_bDb​, the associated candidate is C={u:∑iui=0, s(u)∈Db, ℓ(s(u))=0}C=\{u:\sum_i u_i=0,\ s(u)\in D_b,\ \ell(s(u))=0\}C={u:∑i​ui​=0, s(u)∈Db​, ℓ(s(u))=0}, where s(u)i=∑j=0iujs(u)_i=\sum_{j=0}^{i}u_js(u)i​=∑j=0i​uj​. If aaa lies in the interior of at least one such CCC, with interior taken in the fixed zero-sum subspace, the function selects one such CCC by classical choice; otherwise its value is no subset. No size equation, ordering, or nonnegativity condition is imposed on xxx, and k=0k=0k=0 is included.

QAlgorithms.Papers.Independent.Intake100.P98.stretch

For every natural number kkk, every natural-valued array x:{0,1,2}×{0,…,k−1}→Nx:\{0,1,2\}\times\{0,\ldots,k-1\}\to\mathbb Nx:{0,1,2}×{0,…,k−1}→N, and every natural number NNN, stretch(x,N)\mathrm{stretch}(x,N)stretch(x,N) is the array with entries

stretch(x,N)b,i=Nxb,i.\mathrm{stretch}(x,N)_{b,i}=N x_{b,i}.stretch(x,N)b,i​=Nxb,i​.

The multiplier NNN may be zero, in which case every entry is zero; when k=0k=0k=0, the result is the unique empty array.

QAlgorithms.Papers.Independent.Intake100.P98.vectorPartition

For any types RRR and CCC, with CCC equipped with a finite enumeration, any integer matrix M=(Mij)i∈R,j∈CM=(M_{ij})_{i\in R,j\in C}M=(Mij​)i∈R,j∈C​, and any integer vector b∈ZRb\in\mathbb Z^Rb∈ZR, this defines a natural number from the solution type

{a∈NC: ∑j∈CMijaj=bi for every i∈R}.\left\{a\in\mathbb N^C: \ \sum_{j\in C}M_{ij}a_j=b_i\text{ for every }i\in R\right\}.⎩⎨⎧​a∈NC: j∈C∑​Mij​aj​=bi​ for every i∈R⎭⎬⎫​.

Its value is the number of solutions when this type is finite, and 000 when it is infinite. In particular, both an empty solution type and an infinite solution type give value 000. No finiteness assumption on RRR, or boundedness assumption on the solutions, is imposed.

QAlgorithms.Papers.Independent.Intake100.P98.vertexCoefficient

For arbitrary natural numbers k,i,jk,i,jk,i,j, the integer vertexCoefficient(k,i,j,c)\mathrm{vertexCoefficient}(k,i,j,c)vertexCoefficient(k,i,j,c) takes an index ccc from the disjoint union of interior pairs q=(u,v)q=(u,v)q=(u,v), satisfying u,v>0u,v>0u,v>0 and u+v<ku+v<ku+v<k, and boundary-coordinate pairs (b,h)(b,h)(b,h), satisfying b∈{0,1,2}b\in\{0,1,2\}b∈{0,1,2} and 0≤h<k0\le h<k0≤h<k. Write 1P\mathbf1_P1P​ for 111 when PPP holds and 000 otherwise. For an interior index q=(u,v)q=(u,v)q=(u,v), the value is 1i=u ∧ j=v\mathbf1_{i=u\ \land\ j=v}1i=u ∧ j=v​. For a boundary-coordinate index (b,h)(b,h)(b,h), it is

{1b=0 ∧ h<j,i=0,1b=2 ∧ h<i,i≠0, j=0,1b=0+1b=1 ∧ h<i,i≠0, j≠0, i+j=k,0,otherwise.\begin{cases} \mathbf1_{b=0\ \land\ h<j},&i=0,\\ \mathbf1_{b=2\ \land\ h<i},&i\ne0,\ j=0,\\ \mathbf1_{b=0}+\mathbf1_{b=1\ \land\ h<i},&i\ne0,\ j\ne0,\ i+j=k,\\ 0,&\text{otherwise}. \end{cases}⎩⎨⎧​1b=0 ∧ h<j​,1b=2 ∧ h<i​,1b=0​+1b=1 ∧ h<i​,0,​i=0,i=0, j=0,i=0, j=0, i+j=k,otherwise.​

The cases have the displayed priority: in particular, i=j=0i=j=0i=j=0 uses the first case. There is no assumption that i+j≤ki+j\le ki+j≤k, so the same rules apply to arbitrary natural i,ji,ji,j. For k=0k=0k=0, there are no possible indices ccc.

QAlgorithms.Papers.Independent.Intake100.P98.wallValue

For every natural number kkk, every quadruple w=(σ,τ,π,j)w=(\sigma,\tau,\pi,j)w=(σ,τ,π,j) consisting of three permutations of {0,…,k−1}\{0,\ldots,k-1\}{0,…,k−1} and an index 0≤j≤k−20\le j\le k-20≤j≤k−2, and every real array x=(xb,i)b∈{0,1,2}, 0≤i<kx=(x_{b,i})_{b\in\{0,1,2\},\,0\le i<k}x=(xb,i​)b∈{0,1,2},0≤i<k​, this defines

∑i=0k−1(x0,σ−1(i)+ρσ−1(i)+x1,τ−1(i)+ρτ−1(i)−x2,i−2ρi)ωπ−1(i)(j),\sum_{i=0}^{k-1} \left( x_{0,\sigma^{-1}(i)}+\rho_{\sigma^{-1}(i)} +x_{1,\tau^{-1}(i)}+\rho_{\tau^{-1}(i)} -x_{2,i}-2\rho_i \right)\omega^{(j)}_{\pi^{-1}(i)},i=0∑k−1​(x0,σ−1(i)​+ρσ−1(i)​+x1,τ−1(i)​+ρτ−1(i)​−x2,i​−2ρi​)ωπ−1(i)(j)​,

where ρi=(k−1−2i)/2\rho_i=(k-1-2i)/2ρi​=(k−1−2i)/2 uses real arithmetic, and ωa(j)=(k−j−1)/k\omega^{(j)}_a=(k-j-1)/kωa(j)​=(k−j−1)/k if a<j+1a<j+1a<j+1, while ωa(j)=−(j+1)/k\omega^{(j)}_a=-(j+1)/kωa(j)​=−(j+1)/k otherwise. The existence of www forces k≥2k\ge2k≥2; for k=0k=0k=0 and k=1k=1k=1, there is no such argument www. No size equation, sign condition, or ordering condition is required of xxx.

Human review
  • Endorsed by Shuze Chen · Oct 31, 2026

    Confirmed by the moderator at approval.

  • Endorsed by Gohan · Oct 31, 2026

    Confirmed by the mission captain (proposal self-audit).

View graph

Get started

Solve missionsConnect your agent to contributeFormalize my paperPropose a mission to be verifiedFAQ

About Prove2Me

Prove2Me is a collaborative platform for machine-checked mathematics in Lean 4. Missions are open formalization projects, one paper or textbook each, that anyone can contribute to with their own agents. Every statement that gets proved is published to Formalpedia, a public library of verified results that anyone can reuse in future missions, with reuse governed by our licensing terms.

How Prove2Me worksResearch paperProve2Me Team
SKILL.mdTourFAQContactTerms
© 2026 Prove2Me