Boolean degree-2 functions on the q-ary cube depend on at most q + 1 variables for q ≥ 3, formalised in Lean 4

Let Rd,q be the largest number of relevant variables of a Boolean function of degree d onthe q-ary cube Znq, over all n. We prove that every Boolean function of degree at most 2 on Znqhas at most max(q + 1, 4) relevant variables, so R2,q = q + 1 for every q ≥ 3, while R2,2 = 4. The bound is attained by the selector function, which is the degree-two case of the decision-treelower bound. The proof studies the interaction graph of the degree-two part of the function:the graph has maximum degree at most q, it has no induced path on four vertices, and two nonadjacentvertices have at most two common neighbours. A connected graph with no inducedpath on four vertices has a disconnected complement, and counting the components then givesn ≤ max(q+1, 4). For q = 3 we also confirm the bound by complete enumeration of all Booleanfunctions of degree at most 2 on Zn3for n ≤ 6, by two independent methods up to n = 5 anda solver check at n = 6. The proof of the bound is formalised in Lean 4 on top of Mathlib:main_bound is proved with no sorry and depends only on the three standard axioms, whilethe q = 3 enumeration is Python and is not part of the formal development. The theorem isYuran Xiu’s (2026), proved there together with a stronger structure theorem; this paper givesan independent proof by a graph-theoretic route, and we claim no priority for the result.

Authors

Publication Details

Journal
Zenodo (CERN European Organization for Nuclear Research)
Published
2026-12-02
DOI
https://doi.org/10.5281/zenodo.24751220
Primary Topic
Coding theory and cryptography
Type
preprint
Controls
|||
ALL TIME
JAN
FEB
MAR
APR
MAY
JUN
JUL
AUG
SEP
OCT
NOV
preprint

Boolean degree-2 functions on the q-ary cube depend on at most q + 1 variables for q ≥ 3, formalised in Lean 4

Joshua Bald
Zenodo (CERN European Organization for Nuclear Research)
Coding theory and cryptography
preprint

Boolean degree-2 functions on the q-ary cube depend on at most q + 1 variables for q ≥ 3, formalised in Lean 4

Joshua Bald
preprint en

Abstract

Let Rd,q be the largest number of relevant variables of a Boolean function of degree d onthe q-ary cube Znq, over all n. We prove that every Boolean function of degree at most 2 on Znqhas at most max(q + 1, 4) relevant variables, so R2,q = q + 1 for every q ≥ 3, while R2,2 = 4. The bound is attained by the selector function, which is the degree-two case of the decision-treelower bound. The proof studies the interaction graph of the degree-two part of the function:the graph has maximum degree at most q, it has no induced path on four vertices, and two nonadjacentvertices have at most two common neighbours. A connected graph with no inducedpath on four vertices has a disconnected complement, and counting the components then givesn ≤ max(q+1, 4). For q = 3 we also confirm the bound by complete enumeration of all Booleanfunctions of degree at most 2 on Zn3for n ≤ 6, by two independent methods up to n = 5 anda solver check at n = 6. The proof of the bound is formalised in Lean 4 on top of Mathlib:main_bound is proved with no sorry and depends only on the three standard axioms, whilethe q = 3 enumeration is Python and is not part of the formal development. The theorem isYuran Xiu’s (2026), proved there together with a stronger structure theorem; this paper givesan independent proof by a graph-theoretic route, and we claim no priority for the result.

Zenodo (CERN European Organization for Nuclear Research)
Coding theory and cryptography
AI Navigator

Ask Laika to Summarize, Analyze, and Connect papers live on the map.

Summarize Papers & Methodologies

Extract key findings, datasets, and comparative methods across publications.

Benchmark Rankings & Visual Analytics

Rank top research institutions, authors, funders, topics, and journals by Field-Weighted Citation Impact (FWCI) and paper volume with instant charts.

Connect Distant Disciplines

Bridge topological clusters on the map to find hidden collaborative intersections.

Laika access coming soon