AFTD Auto-Formalizing Theoretical Domains

k9_affine_triangle

def

The monochromatic triangle k9_affine_triangle indexed by color : Fin 4 and line : ZMod 3, defined as the finite set of vertices p = (x, y) : ZMod 3 × ZMod 3 satisfying x = line for color = 0, y = line for color = 1, y - x = line for color = 2, and y + x = line for color = 3.

Statement

def k9_affine_triangle (color : Fin 4) (line : ZMod 3) : Finset (ZMod 3 × ZMod 3)
Defined in
arXiv:2611.06362 Section 2.1
Verified
08 Nov 2026
Axioms
none listed
Used by 4
  • k9_affine_triangles_diff_color_inter_cardFor any two distinct colours c₁, c₂ : Fin 4 with c₁ ≠ c₂ and any lines j₁, j₂ : ZMod 3, the intersection of…
  • k9_affine_triangle_coverIn the affine-plane four-colouring of K9: (1) any three monochromatic triangles k9_affine_triangle covering all nine vertices must share…
  • k9_affine_triangles_three_coverIf three monochromatic triangles k9_affine_triangle c₁ j₁, k9_affine_triangle c₂ j₂, and k9_affine_triangle c₃ j₃ cover all nine…
  • k9_affine_triangle_cardFor every colour c : Fin 4 and line j : ZMod 3, the monochromatic triangle k9_affine_triangle c j has cardinality 3.

Read back from the Lean

The definition k9_affine_triangle takes a parameter color : Fin 4 and line : ZMod 3, and produces the finite set (Finset) of points $p = (p_1, p_2) \in \mathbb{Z}/3\mathbb{Z} \times \mathbb{Z}/3\mathbb{Z}$ satisfying: - if color is 0: $p_1 = line$ - if color is 1: $p_2 = line$ - if color is 2: $p_2 - p_1 = line$ - if color is 3: $p_2 + p_1 = line$

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 monochromatic triangle in AG(2, 3) indexed by color (Fin 4) and line (ZMod 3). -/
def k9_affine_triangle (color : Fin 4) (line : ZMod 3) : Finset (ZMod 3 × ZMod 3) :=
  match color with
  | 0 => Finset.univ.filter (fun p => p.1 = line)
  | 1 => Finset.univ.filter (fun p => p.2 = line)
  | 2 => Finset.univ.filter (fun p => p.2 - p.1 = line)
  | 3 => Finset.univ.filter (fun p => p.2 + p.1 = line)
See it in the graphDiscuss this resultChallenge it