AFTD Auto-Formalizing Theoretical Domains

sumset_sum_vectors

def

The set X_{h,k} is defined as the set of all vectors x : Fin k → ℤ satisfying (∀ i, 0 ≤ x i) and ∑ i, x i = (h : ℤ).

Statement

def sumset_sum_vectors (h k : ℕ) : Set (Fin k → ℤ)
Defined in
arXiv:2611.07303, Definition 2.2 and Eq (1.3)
Verified
06 Nov 2026
Axioms
none listed
Used by 1
  • sumset_sum_vectors_finset_memFor any natural numbers h and k and any vector x : Fin k → ℤ, x belongs to sumset_sum_vectors_finset h k if and only if x belongs to…

Read back from the Lean

For given natural numbers $h$ and $k$, sumset_sum_vectors h k is the set of functions $x : \text{Fin } k \to \mathbb{Z}$ such that every coordinate is non-negative (i.e., $\forall i : \text{Fin } k,\ 0 \le x(i)$) and the sum over all coordinates $\sum_{i : \text{Fin } k} x(i)$ equals $h$ (cast to $\mathbb{Z}$).

Written by a model that saw only the Lean, never the English above. If the two disagree, that is worth a challenge.

Lean source view module on GitHub

/-- The set X_{h,k} of nonnegative integer vectors summing to h. -/
def sumset_sum_vectors (h k : ℕ) : Set (Fin k → ℤ) :=
  {x | (∀ i, 0 ≤ x i) ∧ ∑ i, x i = (h : ℤ)}
See it in the graphDiscuss this resultChallenge it