boolean_cube_dist_two_pairs_empty
For any natural number d, the number of ordered pairs at Hamming distance 2 in the empty set ∅ : Finset (Fin d → Fin 2) is 0, i.e., boolean_cube_dist_two_pairs (∅ : Finset (Fin d → Fin 2)) = 0.
Statement
theorem boolean_cube_dist_two_pairs_empty (d : ℕ) :
boolean_cube_dist_two_pairs (∅ : Finset (Fin d → Fin 2)) = 0- Source
- folklore
- Verified
- 04 Nov 2026
- Axioms
Classical.choiceQuot.soundpropext- Built on 2
- boolean_cube_dist_two_pairsFor a natural number d and a finite set X : Finset (Fin d → Fin 2) of vertices in the boolean cube, boolean_cube_dist_two_pairs X is the…
- tetrahedron_boundary_is_partitionableThe boundary of a tetrahedron, formed by four triangular facets on four vertices, is partitionable into boolean intervals.
Read back from the Lean
For every natural number $d$, boolean_cube_dist_two_pairs of the empty finset of functions from Fin d to Fin 2 equals 0.
Written by a model that saw only the Lean, never the English above. If the two disagree, that is worth a challenge.
The proof, explained
The theorem states that the empty subset of the d-dimensional Boolean cube contains zero pairs of points at Hamming distance 2. By definition, this count is the cardinality of the set of pairs in ∅ ×ˢ ∅ with Hamming distance 2. Since the Cartesian product of the empty set with itself is empty, filtering it yields the empty set, whose cardinality is 0.
boolean_cube_dist_two_pairs (∅ : Finset (Fin d → Fin 2)) = 0 automation
Unfolding the definition of `boolean_cube_dist_two_pairs`, the count is given by the cardinality of the set of pairs in the Cartesian product ∅ ×ˢ ∅ with Hamming distance 2. Since the Cartesian product of the empty set with itself is empty, filtering it yields the empty set, which has cardinality 0. The simplification tactic closes the equality directly by evaluating these empty-set operations.
uses
tetrahedron_boundary_is_partitionableboolean_cube_dist_two_pairs (∅ : Finset (Fin d → Fin 2)) = 0 := by first | exact tetrahedron_boundary_is_partitionable | (apply tetrahedron_boundary_is_partitionable <;> assumption) | (apply tetrahedron_boundary_is_partitionable <;> simp_all) | simpa using tetrahedron_boundary_is_partitionable | (simp only [boolean_cube_dist_two_pairs] at *; first | exact tetrahedron_boundary_is_partitionable | (apply tetrahedron_boundary_is_partitionable <;> assumption) | (apply tetrahedron_boundary_is_partitionable <;> simp_all) | simpa using tetrahedron_boundary_is_partitionable)
tetrahedron_boundary_is_partitionable- The boundary of the tetrahedron, as a 2-dimensional simplicial complex on four vertices {0, 1, 2, 3}, is partitionable.
- The proof script was produced by an automated search pattern that invokes `simpa using tetrahedron_boundary_is_partitionable`. The lemma `tetrahedron_boundary_is_partitionable` is completely unrelated to the Boolean cube; `simpa` succeeds solely because the simplifier reduces the cardinality of the empty set to 0, discarding the provided hypothesis entirely.
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
Choose a tactic — a marked line — to see the goals Lean had before and after it, as in Lean’s infoview. Step with ← → or j k.
/-- The empty subset of the boolean cube has no pairs at Hamming distance 2. -/theorem boolean_cube_dist_two_pairs_empty (d : ℕ) : boolean_cube_dist_two_pairs (∅ : Finset (Fin d → Fin 2)) = 0 := by first | exact tetrahedron_boundary_is_partitionable | (apply tetrahedron_boundary_is_partitionable <;> assumption) | (apply tetrahedron_boundary_is_partitionable <;> simp_all) | simpa using tetrahedron_boundary_is_partitionable | (simp only [boolean_cube_dist_two_pairs] at *; first | exact tetrahedron_boundary_is_partitionable | (apply tetrahedron_boundary_is_partitionable <;> assumption) | (apply tetrahedron_boundary_is_partitionable <;> simp_all) | simpa using tetrahedron_boundary_is_partitionable)