is_subcube
For an implicit dimension $n$, a dimension $d : \mathbb{N}$, and a finite subset $F : \mathrm{Finset} (\mathrm{Fin}\ n \to \mathrm{Bool})$, is_subcube d F holds if there exist a subset of coordinates $S : \mathrm{Finset} (\mathrm{Fin}\ n)$ and a pattern $c : \mathrm{Fin}\ n \to \mathrm{Bool}$ such that $|S| + d = n$ and $F$ consists of all $x : \mathrm{Fin}\ n \to \mathrm{Bool}$ that satisfy $x(i) = c(i)$ for all $i \in S$.
Statement
def is_subcube {n : ℕ} (d : ℕ) (F : Finset (Fin n → Bool)) : Prop
- Defined in
- arXiv:2610.40486 Sec. 1
- Verified
- 30 Oct 2026
- Axioms
- none listed
- Used by 3
- min_avg_pairwise_hamming_dist_density_one_sixteenth_n_eq_fourFor $n = 4$, every subset $F \subseteq (\mathrm{Fin}\ 4 \to \mathrm{Bool})$ of cardinality $2^{4-4} = 1$ attains average pairwise Hamming…
- is_subcube_univFor any natural number $n$, the entire hypercube $\mathrm{Finset.univ} \subseteq (\mathrm{Fin}\ n \to \mathrm{Bool})$ is an…
- is_subcube_singletonFor any natural number $n$ and any point $c : \mathrm{Fin}\ n \to \mathrm{Bool}$, the singleton subset…
Read back from the Lean
Given an implicit natural number $n$, a natural number $d$, and a finite set $F$ of functions from $\mathrm{Fin}\ n$ to $\mathrm{Bool}$, is_subcube d F asserts that there exist a subset $S \subseteq \mathrm{Fin}\ n$ (as a Finset) and a function $c : \mathrm{Fin}\ n \to \mathrm{Bool}$ such that:
1. $|S| + d = n$, and
2. $F$ is the set of all $x : \mathrm{Fin}\ n \to \mathrm{Bool}$ satisfying $x(i) = c(i)$ for all $i \in S$.
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
/-- A subset `F` of the Boolean hypercube `Fin n → Bool` is a `d`-dimensional subcube if `n - d` coordinates are fixed to values in `c`. -/ def is_subcube {n : ℕ} (d : ℕ) (F : Finset (Fin n → Bool)) : Prop := ∃ (S : Finset (Fin n)) (c : Fin n → Bool), S.card + d = n ∧ F = Finset.univ.filter (fun x => ∀ i ∈ S, x i = c i)