Wilber's First Lower Bound (Interleave Bound) and Bit-Reversal Separation #
This module formalizes Wilber's first lower bound (the Interleave Bound, [Wil89]) on the
cost of any binary search tree execution serving an access sequence xs, together with an explicit
bit-reversal sequence family witnessing an Ω(m log n) lower bound across all BST algorithms.
Proof overview #
Fix any static Ordered reference BST P storing the same key set as the dynamic BSTs. For each
key y ∈ elements P, partition subtreeAt y P into its strict left subtree leftRegion P y and
rightRegion P y = {y} ∪ rightSubtree(y). Both regions and their union are order-convex in
elements P. Restricting xs to keys in subtreeAt y P and labeling left-region accesses by
false and right-region accesses by true, interleave P y xs counts adjacent left/right
alternations, and wilberFirst P xs = ∑ y ∈ elements P, interleave P y xs.
For every node y with nonempty leftRegion P y and every dynamic BST T on elements P, let
v = topNode (elements (subtreeAt y P)) T be the highest node of y's reference subtree in T.
The transition point transitionPoint? P y T is the highest node in T of the opposite
region from v (topNode (rightRegion P y) T if v ∈ leftRegion P y, and
topNode (leftRegion P y) T otherwise). Three structural lemmas drive the lower bound:
- Injectivity (
transitionPoint?_inj): Distinct nodesy₁ ≠ y₂ofPhave distinct transition points inT. - Stability (
transitionPoint?_stable): As long astransitionPoint? P y Tis untouched during aTouchedStep, both the transition point and its side remain unchanged. - Forced touch (
mem_touched_of_mem_side): Any access landing on the transition point's side must touch the transition point itself.
A 1-bit credit induction along any TouchedExecution yields interleave P y xs ≤ 2 * touchCount y
without any additive loss; summing over y ∈ elements P and applying injectivity at each time
step gives wilberFirst P xs ≤ 2 * e.cost, hence wilberFirst P xs ≤ 2 * e.touchedCost and
wilberFirst P xs ≤ 2 * e.stepCost for every atomic BSTExecution.
Bit-reversal witness #
Instantiating P = completeBST 0 (d + 1) (with 2^(d + 1) - 1 keys {1, …, 2^(d + 1) - 1}) and
the r-fold repeated bit-reversal permutation bitRevLeaves 0 d of its 2^d odd leaves yields
the exact interleave sum wilberFirst = d * r * 2^d - (2^d - 1), forcing
d * m - (2^d - 1) ≤ 2 * e.stepCost (Ω(m log n)) for every BST execution on m = r * 2^d
accesses.
Main definitions #
alternations: number of adjacent flips in aList Bool.leftRegion,rightRegion,regionSides,interleave,wilberFirst: reference-tree left and right regions, projected side sequences, per-node interleaves, and Wilber's first lower bound.transitionPoint?: Wilber's transition point and its side in a dynamic BST.completeBST,zipInterleave,bitRev,bitRevLeaves: balanced reference tree and bit-reversal access sequences.
Main results #
wilberFirst_le_two_mul_cost,wilberFirst_le_two_mul_touchedCost,wilberFirst_le_two_mul_stepCost: Wilber's First Lower Bound (Interleave Bound) ([Wil89]) for all touched-subtree and pointer-and-rotation BST executions.bitRevLeaves_eq_map_bitRev: agreement ofbitRevLeaveswith the explicitbitRevpermutation.wilberFirst_completeBST_replicate_bitRevLeaves,bitRev_stepCost_lower_bound: exactd * r * 2^d - (2^d - 1)interleave evaluation andΩ(m log n)BST cost lower bound.
References #
- [Wil89] Robert Wilber, Lower Bounds for Accessing Binary Search Trees with Rotations, SIAM Journal on Computing 18(1), 56–67, 1989 (cited at topic level; journal full text not inspected).
Boolean Alternation Counts #
Number of adjacent flips (a ≠ b) in a list of booleans.
Reference-Tree Regions and Interleave Bound #
Strict left-subtree region L(y) of key y in reference tree P.
Right region R(y) = {y} ∪ rightSubtree(y) of key y in reference tree P.
Project an access sequence xs onto the left (false) and right (true) regions of y in
reference tree P, ignoring accesses outside subtreeAt y P.
Number of left/right preferred-child interleaves of xs at reference node y in P
([Wil89]).
Wilber's First Lower Bound (Interleave Bound) ([Wil89]): sum of interleave P y xs
over all nodes y of a static reference BST P.
Transition Points and Their Three Structural Lemmas #
Wilber's transition point tp(y, T) together with its region side (false for leftRegion,
true for rightRegion). Let v = topNode (elements (subtreeAt y P)) T; the transition point is
the highest node in T of the region opposite to v.
Injectivity of transition points: Distinct reference nodes y₁ ≠ y₂ cannot share the same
transition point in any ordered BST T on elements P.
1-Bit Credit Induction and Wilber's First Lower Bound #
Wilber's First Lower Bound (Interleave Bound) ([Wil89]) for any touched-subtree
execution: for every static ordered reference BST P on the same key set as T₀,
wilberFirst P xs ≤ 2 * e.cost.
Wilber's First Lower Bound (Interleave Bound) ([Wil89]) for touched-node cost of any
pointer-and-rotation BSTExecution.
Wilber's First Lower Bound (Interleave Bound) ([Wil89]) for atomic step cost of any
pointer-and-rotation BSTExecution.
Bit-Reversal Ω(m log n) Lower-Bound Witness #
Complete binary search tree of height d on keys {lo + 1, …, lo + 2 ^ d - 1}.
d-bit reversal of i (low d bits reversed into MSB-first order).
The 2 ^ d leaves of completeBST lo (d + 1) in bit-reversal order.
bitRevLeaves 0 d lists the 2 ^ d odd leaves 2 * bitRev d i + 1 for i = 0, …, 2^d - 1.
Exact evaluation of Wilber's first lower bound on the r-fold repeated bit-reversal access
sequence (List.replicate r (bitRevLeaves lo d)).flatten with reference tree
completeBST lo (d + 1) (r ≥ 1): wilberFirst = d * r * 2 ^ d - (2 ^ d - 1).
Ω(m log n) BST lower bound via bit-reversal accesses ([Wil89]): for any d ≥ 1,
r ≥ 1, any ordered initial BST T₀ on {1, …, 2^(d + 1) - 1} (n = 2^(d + 1) - 1 keys), and
any pointer-and-rotation execution e serving the m = r * 2^d bit-reversal accesses
(List.replicate r (bitRevLeaves 0 d)).flatten,
d * m - (2^d - 1) ≤ 2 * e.stepCost.