hamming_ring
def
Given implicit parameters n and q, the (c, c') Hamming ring hamming_ring c c' x centered at x : Fin n → Fin q is the finite set (Finset) of all y : Fin n → Fin q satisfying c + 1 ≤ hammingDist x y ∧ hammingDist x y ≤ c + c'.
Statement
def hamming_ring {n q : ℕ} (c c' : ℕ) (x : Fin n → Fin q) : Finset (Fin n → Fin q)- Defined in
- arXiv:2611.18156 Definition III.1
- Verified
- 16 Nov 2026
- Axioms
- none listed
- Used by 6
- is_joint_error_correcting_detectingGiven implicit parameters n and q, a code C : Finset (Fin n → Fin q) is a (c, c') joint error-correcting and detecting code if distinct…
- card_hamming_ringFor natural numbers n, q, c, c' with 2 ≤ q and c + c' ≤ n, and any x : Fin n → Fin q, the cardinality of the (c, c') Hamming ring centered…
- binary_repetition_code_is_joint_error_correcting_detectingFor an explicit natural number n with 2 ≤ n and natural numbers c, c' such that 2 * c + c' + 1 = n,
binary_repetition_code nis a (c,… - joint_hamming_boundLet q ≥ 2, n ≥ 1, and let c, c' be non-negative integers with c + c' ≤ n. If C ⊆ (Fin n → Fin q) is a (c, c') joint error-correcting and…
- hamming_ring_subset_ballGiven implicit parameters n and q, for any x : Fin n → Fin q, the (c, c') Hamming ring centered at x is a subset of the Hamming ball of…
- disjoint_hamming_ball_hamming_ring_sameGiven implicit parameters n and q, for any point x : Fin n → Fin q, the Hamming ball of radius c centered at x and the (c, c') Hamming…
Read back from the Lean
hamming_ring {n q : ℕ} (c c' : ℕ) (x : Fin n → Fin q) is defined as the finite set (Finset) of all vectors y : Fin n → Fin q such that c + 1 ≤ hammingDist x y and hammingDist x y ≤ c + c' (that is, the Hamming distance between x and y is strictly greater than c and at most c + c').
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 (c, c') Hamming ring centered at x in (Fin n → Fin q), as a Finset. -/ def hamming_ring {n q : ℕ} (c c' : ℕ) (x : Fin n → Fin q) : Finset (Fin n → Fin q) := Finset.filter (fun y => c + 1 ≤ hammingDist x y ∧ hammingDist x y ≤ c + c') Finset.univ