AFTD Auto-Formalizing Theoretical Domains

radial_coloring_apply_eq_true

theoremverified

A point is coloured true by the radial colouring S exactly when its squared norm lies in S.

Statement

theorem radial_coloring_apply_eq_true (S : Set ℝ) {n : ℕ} (x : EuclideanSpace ℝ (Fin n)) :
    radial_coloring S x = true ↔ ‖x‖ ^ 2 ∈ S
Source
step towards op_1481_avoidance_three_twenty_one_exceptional_spacings
Verified
13 Nov 2026
Axioms
Classical.choiceQuot.soundpropext
Built on 2
  • radial_coloringThe radial two-colouring of Euclidean space attached to a set S ⊆ ℝ: a point x is coloured true exactly when its squared norm ‖x‖² lies in…
  • norm_sq_three_ap_unitFor any 3-term arithmetic progression x₀, x₀ + v, x₀ + 2 • v in n-dimensional Euclidean space with unit spacing ||v|| = 1, the alternating…
Used by 1
  • radial_coloring_trivial_witnessesSanity witnesses for the radial colouring: with S = Set.univ every point is coloured true, and with S = ∅ every point is coloured false.…

The proof, explained

The theorem states that a point in Euclidean space is coloured `true` under the radial colouring defined by a set of radii squared $S$ if and only if its squared norm lies in $S$. By definition, `radial_coloring S x` is `if ‖x‖ ^ 2 ∈ S then true else false`. Unfolding this definition reduces the statement to the tautology `(if P then true else false) = true ↔ P`, which is closed by boolean simplification.

  1. `radial_coloring S x = true ↔ ‖x‖ ^ 2 ∈ S` automation

    Unfolding the definition of `radial_coloring` expands `radial_coloring S x` to `if ‖x‖ ^ 2 ∈ S then true else false`. The equivalence `(if ‖x‖ ^ 2 ∈ S then true else false) = true ↔ ‖x‖ ^ 2 ∈ S` is then closed by boolean simplification (`simpa`), since an if-then-else returning `true` when a proposition holds and `false` otherwise is equal to `true` if and only if that proposition holds. The surrounding `first | ...` search harness and the lemma `norm_sq_three_ap_unit` are remnants of automated proof search and do not participate in the simplification.

    line 3

    uses radial_coloring, norm_sq_three_ap_unit

        radial_coloring S x = true ↔ ‖x‖ ^ 2 ∈ S := by first | exact norm_sq_three_ap_unit | (apply norm_sq_three_ap_unit <;> assumption) | (apply norm_sq_three_ap_unit <;> simp_all) | simpa using norm_sq_three_ap_unit | (simp only [radial_coloring] at *; first | exact norm_sq_three_ap_unit | (apply norm_sq_three_ap_unit <;> assumption) | (apply norm_sq_three_ap_unit <;> simp_all) | simpa using norm_sq_three_ap_unit)
radial_coloring
The function that assigns `true` to a point `x` if its squared norm `‖x‖ ^ 2` belongs to `S`, and `false` otherwise.
norm_sq_three_ap_unit
For any point `x₀` and unit vector `v`, the linear combination of squared distances `‖x₀‖ ^ 2 - 2 * ‖x₀ + v‖ ^ 2 + ‖x₀ + 2 • v‖ ^ 2` equals `2`.

Written by a model (gemini-3.8-flash) from the Lean proof and the goal states Lean reported at each step. Lean verified the proof; this explanation is a reading aid and is not itself machine-checked.

Lean source view module on GitHub

/-- The defining property of `radial_coloring`, in `↔` form. -/theorem radial_coloring_apply_eq_true (S : Set ℝ) {n : ℕ} (x : EuclideanSpace ℝ (Fin n)) :    radial_coloring S x = true ↔ ‖x‖ ^ 2 ∈ S := by first | exact norm_sq_three_ap_unit | (apply norm_sq_three_ap_unit <;> assumption) | (apply norm_sq_three_ap_unit <;> simp_all) | simpa using norm_sq_three_ap_unit | (simp only [radial_coloring] at *; first | exact norm_sq_three_ap_unit | (apply norm_sq_three_ap_unit <;> assumption) | (apply norm_sq_three_ap_unit <;> simp_all) | simpa using norm_sq_three_ap_unit)
See it in the graphDiscuss this resultChallenge it