A finite obstruction to storing predecessors after seeing a query batch
ProvedThreeSumFuture.adaptive_cache_batch_obstruction3sumalgorithmscombinatorics
Let be a finite set of queries and a finite set of predecessor values. Each predecessor is incident to at most queries. If
then some batch of queries meets the neighborhood of every predecessor in fewer than points. Consequently, for this same batch, any stored set , even one chosen after the batch is known, can cover at most query–predecessor incidences. At least the total incidence count minus incidences remain uncovered.
This formulation uses integer cardinalities throughout. It applies to exact enumeration of needed predecessor values in a fixed joint-type class of 3SUM queries.
Preamble
import Mathlib.Algebra.Order.BigOperators.Group.Finset import Mathlib.Algebra.BigOperators.Ring.Finset import Mathlib.Data.Finset.Powerset import Mathlib.Data.Fintype.BigOperators import Mathlib.Data.Fintype.Card open scoped BigOperators
Formal statement
theorem ThreeSumFuture.adaptive_cache_batch_obstruction {Q P : Type} [Fintype Q] [Fintype P] [DecidableEq Q] [DecidableEq P]
(neighbors : P → Finset Q) (m t D : ℕ)
(hdeg : ∀ p, (neighbors p).card ≤ D)
(hchoose : Fintype.card P * (D.choose t * (Fintype.card Q - t).choose (m - t)) <
(Fintype.card Q).choose m) :
∃ batch : Finset Q, batch.card = m ∧
(∀ p, ((neighbors p) ∩ batch).card < t) ∧
∀ store : Finset P,
(∑ p : P, ((neighbors p) ∩ batch).card) ≤
(∑ p ∈ Finset.univ \ store, ((neighbors p) ∩ batch).card) + store.card * t := by sorrySource
Original finite counting lemma for adaptive banks in ternary 3SUM reconstruction. Algorithmic context: Jionghan Wang, A refined deterministic 3SUM bound with a certified weighted-cache optimization limit, PROOF.md §1–2, https://github.com/Wang-jiong-han/3sum-weighted-cache/blob/e1ae71db2231f172c6541820e2ce0a54aa14fc64/PROOF.md