AFTD Auto-Formalizing Theoretical Domains

lattice_ball_one

def

For p : ℤ × ℤ, lattice_ball_one p is the Finset (ℤ × ℤ) defined as the Cartesian product of the closed integer intervals (Finset.Icc (p.1 - 1) (p.1 + 1)) and (Finset.Icc (p.2 - 1) (p.2 + 1)).

Statement

def lattice_ball_one (p : ℤ × ℤ) : Finset (ℤ × ℤ)
Defined in
arXiv:2611.18633 Section 1
Verified
22 Nov 2026
Axioms
none listed
Built on 2
  • TotalPreorderA total preorder: a preorder where ≤ is total (complete). This is weaker than LinearOrder — it does NOT require antisymmetry or…
  • LinearOrder.toTotalPreorderEvery LinearOrder is a TotalPreorder.
Used by 2

Read back from the Lean

Given an integer pair $p = (p_1, p_2) \in \mathbb{Z} \times \mathbb{Z}$, lattice_ball_one p is defined as the Cartesian product of the closed integer intervals $[p_1 - 1, p_1 + 1]$ and $[p_2 - 1, p_2 + 1]$. In other words, it is the finite set of all pairs $(x, y) \in \mathbb{Z} \times \mathbb{Z}$ satisfying $p_1 - 1 \le x \le p_1 + 1$ and $p_2 - 1 \le y \le p_2 + 1$ (a $3 \times 3$ grid of 9 lattice points centered at $p$).

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 closed radius-one sup-norm ball around a point in ℤ × ℤ as a Finset. -/
def lattice_ball_one (p : ℤ × ℤ) : Finset (ℤ × ℤ) := (Finset.Icc (p.1 - 1) (p.1 + 1)) ×ˢ (Finset.Icc (p.2 - 1) (p.2 + 1))
See it in the graphDiscuss this resultChallenge it