AFTD Auto-Formalizing Theoretical Domains

slow_exact_nim_unit_shift

def

For any natural number k and position x on k+1 piles, slow_exact_nim_unit_shift k x is the position that leaves pile 0 unchanged and increases every pile i with i.val ≠ 0 by 1.

Statement

def slow_exact_nim_unit_shift (k : ℕ) (x : Fin (k + 1) → ℕ) : Fin (k + 1) → ℕ
Defined in
arXiv:2611.14546, Section 7.1
Verified
15 Nov 2026
Axioms
none listed

Read back from the Lean

Given a natural number $k$ and a function $x : \text{Fin}(k + 1) \to \mathbb{N}$, slow_exact_nim_unit_shift k x is defined as the function from $\text{Fin}(k + 1)$ to $\mathbb{N}$ that maps each index $i$ to $x(i)$ if $i.\text{val} = 0$, and to $x(i) + 1$ if $i.\text{val} \neq 0$.

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 unit-shift operator T adding one stone to every pile except the first in slow exact k-Nim with k+1 piles. -/
def slow_exact_nim_unit_shift (k : ℕ) (x : Fin (k + 1) → ℕ) : Fin (k + 1) → ℕ := fun i => if i.val = 0 then x i else x i + 1
See it in the graphDiscuss this resultChallenge it