is_joint_error_correcting_detecting
Given 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 codewords in C have disjoint radius-c Hamming balls, and every codeword's radius-c Hamming ball is disjoint from every codeword's (c, c') Hamming ring.
Statement
def is_joint_error_correcting_detecting {n q : ℕ} (c c' : ℕ) (C : Finset (Fin n → Fin q)) : Prop
- Defined in
- arXiv:2611.18156 Definition II.4, Theorem III.3
- Verified
- 16 Nov 2026
- Axioms
- none listed
- Built on 2
- hamming_ballGiven implicit parameters n and q, the Hamming ball
hamming_ball r xof radius r centered at x : Fin n → Fin q is the finite set… - hamming_ringGiven implicit parameters n and q, the (c, c') Hamming ring
hamming_ring c c' xcentered at x : Fin n → Fin q is the finite set (Finset)…
- hamming_ballGiven implicit parameters n and q, the Hamming ball
- Used by 4
- 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,… - binary_repetition_code_is_joint_perfect_codeFor an explicit natural number n with 2 ≤ n and natural numbers c, c' such that 2 * c + c' + 1 = n, the binary repetition code of length n…
- 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…
- is_joint_perfect_codeA code C ⊆ (Fin n → Fin q) is a (c, c') joint perfect code if it is a (c, c') joint error-correcting and detecting code and satisfies |C|…
- 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,
Read back from the Lean
A code $C$ (a finite set of words of length $n$ over an alphabet of size $q$) is jointly error-correcting and error-detecting with parameters $c, c' \in \mathbb{N}$ if both of the following hold: 1. For all distinct codewords $x_1, x_2 \in C$, the closed Hamming balls of radius $c$ centered at $x_1$ and $x_2$ are disjoint. 2. For all codewords $x_1, x_2 \in C$ (not necessarily distinct), the closed Hamming ball of radius $c$ centered at $x_1$ is disjoint from the Hamming ring centered at $x_2$ with inner radius $c + 1$ and outer radius $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
/-- Predicate for a code C in (Fin n → Fin q) to be (c, c') joint error-correcting and detecting. -/ def is_joint_error_correcting_detecting {n q : ℕ} (c c' : ℕ) (C : Finset (Fin n → Fin q)) : Prop := (∀ x₁ ∈ C, ∀ x₂ ∈ C, x₁ ≠ x₂ → Disjoint (hamming_ball c x₁) (hamming_ball c x₂)) ∧ (∀ x₁ ∈ C, ∀ x₂ ∈ C, Disjoint (hamming_ball c x₁) (hamming_ring c c' x₂))