Read-r and fan-in-two formula compilation to multiparty NOF protocols #
Every fan-in-two Boolean formula F : Formula σ n in which each variable appears at most r times
(Formula.ReadAtMost r) compiles to a low-depth deterministic (r + 1)-party number-on-forehead
(NOF.Protocol) protocol on balanced disjoint blocks of variables, yielding Ω(n log n) leaf-size
lower bounds for general fan-in-two Boolean formulas from balanced multiparty NOF discrepancy
(Cslib.Communication.NOF.discrepancy) as well as unconditionally via Hoeffding's inequality.
The development combines four ingredients:
Exact Hall balance theorem (
exists_nof_partition_of_bag_card_le,exists_disjoint_blocks_avoiding_bags). Givenr + 1bagsW_0, …, W_r ⊆ Fin nsuch that every variableilies in at mostrbags and each bag has size at most(r * n) / (r + 1), Hall's marriage theorem assigns every variableito a playerowner iwithi ∉ W_{owner i}and guarantees every player at leastn / (r * (r + 1))variables (tight for everyr ≥ 1).Bottom-up binary-tree chopping and greedy bag packing (
exists_nof_protocol_of_readAtMost,exists_nof_protocol_of_formula). Chopping deepest subtrees exceeding leaf budgetB ≥ 1decomposesFintod ≤ F.leafSize / (B + 1)subtrees of leaf weight in[B + 1, 2 B]plus a residual root of weight≤ 2 B, communicating≤ F.leafSize / (B + 1) + 1bits. Greedily assigning each piece to the lightest ofr + 1bags keeps every bag below(F.leafSize + 2 r B) / (r + 1).General fan-in-two Boolean formulas and balanced NOF discrepancy (
exists_nof_protocol_of_formula,one_le_two_pow_mul_nof_discrepancy_of_formula,two_mul_le_two_pow_mul_nof_discrepancy_of_formula,mul_log_le_leafSize_of_balanced_discrepancy). For an arbitrary fan-in-two formulaFover any signatureσand Boolean interpretationI, settingr = 4 * F.leafSize / n + 1leaves at least(3 n + 1) / 4inputs read at mostrtimes, while chopping atB = n / 8compilesFto an(r + 1)-party NOF protocol of≤ 2 r + 1(O(r)) bits on pairwise disjoint blocks of sizen / (4 r). Conditionally on the Babai–Nisan–Szegedy cube discrepancy bound across the balanced regime1 ≤ r,4 r + 6 ≤ log₂ n(q = n / (4 r)), this forcesn * (Nat.log 2 n - 12) ≤ 16 * F.leafSize.Probabilistic existence and unconditional
Ω(n log n)formula lower bound (exists_balanced_nof_discrepancy,exists_function_mul_log_le_leafSize). Applying Hoeffding's inequality (Cslib.BitString.card_filter_le_abs_sum_mul_signVal_le) and a union bound over all balanced block tuples and cylinder intersections establishes that for everyn, a Boolean functionf : (Fin n → Bool) → Boolsatisfies the balanced BNS cube discrepancy bound and therefore requiresn * (Nat.log 2 n - 12) ≤ 16 * F.leafSizefor every fan-in-two Boolean formula over any signatureσ.
Main definitions #
Cslib.Circuits.Formula.ReadAtMost: every input variable appears at mostrtimes as a leaf.Cslib.Circuits.Frontier.embedBlocks: embeds multiparty block inputs∀ j, X j → UintoFin n → Uusing a background assignment outside⋃ j, X j.
Main results #
Cslib.Circuits.Frontier.exists_nof_partition_of_bag_card_le: exactn / (r * (r + 1))Hall balance theorem for(r + 1)-party NOF input assignment.Cslib.Circuits.Frontier.exists_nof_protocol_of_readAtMost: read-rfan-in-two Boolean formula to(r + 1)-partyNOF.Protocolcompiler.Cslib.Circuits.Frontier.exists_nof_protocol_of_formula: general fan-in-two Boolean formula compilation to a(2 r + 1)-bit(r + 1)-partyNOF.Protocolatr = 4 * F.leafSize / n + 1.Cslib.Circuits.Frontier.one_le_two_pow_mul_nof_discrepancy_of_formula,Cslib.Circuits.Frontier.two_mul_le_two_pow_mul_nof_discrepancy_of_formula: exact and distributional discrepancy bounds wired intoCslib.Communication.NOF.discrepancy.Cslib.Circuits.Frontier.mul_log_le_leafSize_of_balanced_discrepancy: conditionalΩ(n log n)fan-in-two Boolean formula leaf-size lower bound from balanced NOF cube discrepancy.Cslib.Circuits.Frontier.exists_balanced_nof_discrepancy,Cslib.Circuits.Frontier.exists_function_mul_log_le_leafSize: probabilistic existence of balanced NOF-hard functions and unconditionalΩ(n log n)fan-in-two Boolean formula lower bound.
The exact n / (r * (r + 1)) Hall balance theorem, the greedy (r + 1)-bag subtree-chopping
compiler for arbitrary fan-in-two Boolean formulas, and the balanced NOF cube discrepancy reduction
and Hoeffding existence bound over arbitrary basis signatures are original to this library, building
on multiparty NOF discrepancy [CFL83], [BNS92], [Juk12],
Hoeffding's inequality [Hoe63], and classical formula lower bounds [Khr71a].
References #
- L. Babai, N. Nisan and M. Szegedy, Multiparty protocols, pseudorandom generators for logspace, and time-space trade-offs
- A. K. Chandra, M. L. Furst and R. J. Lipton, Multi-party protocols
- W. Hoeffding, Probability inequalities for sums of bounded random variables
- S. Jukna, Boolean Function Complexity: Advances and Frontiers
- V. M. Khrapchenko, Complexity of the realization of a linear function in the class of Π-schemes
A read-r formula on n variables has at most r * n leaves.
Part 1: Exact Hall balance theorem for (r + 1)-party NOF partitions #
Subset-restricted Hall balance. Given a pool L : Finset (Fin n) of candidate inputs and
r + 1 bags bags : Fin (r + 1) → Finset (Fin n) such that every i ∈ L belongs to at most r
bags and each bag contains at most cap elements of L, whenever (r + 1) * q ≤ L.card and
cap + r * q ≤ L.card there exist r + 1 pairwise disjoint blocks X j ⊆ L of exact size q
with Disjoint (X j) (bags j) for every player j.
Exact Hall balance theorem for (r + 1)-party NOF partitions
(min_j |X_j| ≥ n / (r(r+1))). Given 1 ≤ r and r + 1 bags
bags : Fin (r + 1) → Finset (Fin n) such that every variable i belongs to at most r bags and
each bag has size at most (r * n) / (r + 1), there exists a total assignment
owner : Fin n → Fin (r + 1) such that every variable avoids its owner's bag
(i ∉ bags (owner i)) and every player owns at least n / (r * (r + 1)) variables.
Part 2: Embedding multiparty block inputs and player views #
Embed multiparty block inputs y : ∀ j : Fin k, X j → U into Fin n → U, filling coordinates
outside ⋃ j, X j from the background assignment z (selecting the block index via
Classical.choose; for pairwise disjoint X, use embedBlocks_of_mem and
embedBlocks_of_notMem).
On i ∈ X j (for pairwise disjoint X), embedBlocks X z y i reads player j's input.
Outside ⋃ j, X j, embedBlocks X z y i equals the background assignment z i.
Part 3: Bottom-up binary formula chopping and greedy bag compilation #
Core compilation lemma on a light-variable subset L : Finset (Fin n): given F.FanInAtMost 2,
every i ∈ L read at most r times, chopping budget 1 ≤ B, and block size q satisfying
(r + 1) * q ≤ L.card and (F.leafSize + 2 * r * B) / (r + 1) + r * q ≤ L.card, F compiles to a
deterministic (r + 1)-party NOF.Protocol of depth ≤ F.leafSize / (B + 1) + 1.
Part 4: Read-r formula compilation, general O(r)-bit formula compilation, and #
Ω(n log n) discrepancy lower bounds
Read-r formula to (r + 1)-party NOF protocol. Every fan-in-two, read-r formula F
on n variables (1 ≤ r, 4 * r ≤ n) compiles on pairwise disjoint blocks of size
n / (2 * r * (r + 1)) to a deterministic (r + 1)-party NOF.Protocol of depth at most
F.leafSize / (n / (4 * r) + 1) + 1 ≤ 4 * r ^ 2 + 1 (O(r) bits when F.leafSize = O(n), and
O(1) bits for fixed r).
General fan-in-two formula compilation to an O(r)-bit (r + 1)-party NOF protocol.
For any fan-in-two formula F : Formula σ n (8 ≤ n, no read bound assumed), setting
r = 4 * F.leafSize / n + 1, there exist r + 1 pairwise disjoint blocks X j each of size
n / (4 * r) such that for every background assignment z : Fin n → Bool, F compiles to a
deterministic (r + 1)-party NOF.Protocol of depth at most 2 * r + 1.
Exact formula discrepancy bound wired directly into Cslib.Communication.NOF.discrepancy:
for any fan-in-two formula F computing f (8 ≤ n, r = 4 * F.leafSize / n + 1), some
(r + 1)-tuple of pairwise disjoint blocks X j of size n / (4 * r) satisfies
1 ≤ 2 ^ (2 * r + 1) * NOF.discrepancy uniform (fun y => f (embedBlocks X z y)) for every z.
Distributional / average-case formula discrepancy bound wired directly into
Cslib.Communication.NOF.discrepancy: if a fan-in-two formula F (8 ≤ n,
r = 4 * F.leafSize / n + 1) has signed correlation at least 2 * γ with f under the uniform
distribution on Fin n → Bool, then there exist pairwise disjoint blocks X j of size
n / (4 * r) and a background fixing z : Fin n → Bool such that
2 * γ ≤ 2 ^ (2 * r + 1) * NOF.discrepancy uniform (fun y => f (embedBlocks X z y)).
Conditional Ω(n log n) formula leaf-size lower bound from balanced NOF cube discrepancy.
Let f : (Fin n → Bool) → Bool satisfy the Babai–Nisan–Szegedy cube discrepancy bound
disc(f|_{X, false}) ^ (2 ^ (r + 1)) ≤ (1 - 2 / 2 ^ (r + 1)) ^ (n / (4 * r)) across the balanced
regime 1 ≤ r, 4 * r + 6 ≤ Nat.log 2 n on pairwise disjoint variable blocks X of size
n / (4 * r). Then every fan-in-two Boolean formula F : Formula σ n over any signature σ and
interpretation I computing f satisfies n * (Nat.log 2 n - 12) ≤ 16 * F.leafSize.
Part 5: Probabilistic existence of balanced NOF-hard Boolean functions via Hoeffding #
Probabilistic existence of Boolean functions with exponentially small balanced NOF
discrepancy. By Hoeffding's inequality (Cslib.BitString.card_filter_le_abs_sum_mul_signVal_le)
and a union bound over balanced block tuples X : Fin (r + 1) → Finset (Fin n) and (r + 1)-party
cylinder tests φ, for every n : ℕ there exists f : (Fin n → Bool) → Bool satisfying the
Babai–Nisan–Szegedy cube discrepancy bound across the balanced regime 1 ≤ r,
4 * r + 6 ≤ Nat.log 2 n.
Unconditional Ω(n log n) fan-in-two Boolean formula leaf-size lower bound. For every
n : ℕ, there exists f : (Fin n → Bool) → Bool such that every fan-in-two Boolean formula
F : Formula σ n over any signature σ and interpretation I computing f satisfies
n * (Nat.log 2 n - 12) ≤ 16 * F.leafSize.