Lemma 8.5 — every index lies in highly periodic runs ([BGS24, Lemma 8])
ProvedDynLZ77.Main.lemma_8_5combinatorics-on-wordslz77strings
Let be a string of length . A run with period is a maximal periodic substring: , and (a comparison with a position outside counts as unequal). The run is highly periodic if . There is a universal constant such that every index of lies in at most
highly periodic runs.
In the proof of Lemma 1.2 ("Bounding "), this lemma bounds the set of the two leftmost Lyndon-root positions of the highly periodic runs that contain a phrase start: .
Formalization Note. Runs are counted as pairs with IsRun S a b (per (sub S a b)) and HighlyPeriodic (sub S a b) (definitions of DynLZ77_Main_Structure); the period of a run is determined by . is written as with fixed before the alphabet, and .
Preamble
import Mathlib.Analysis.SpecialFunctions.Log.Base import Definitions.Def_DynLZ77_Main_Strings import Definitions.Def_DynLZ77_Main_Structure set_option autoImplicit false
Formal statement
namespace DynLZ77.Main
open Classical in
/-- **Lemma 8.5** ([BGS24, Lemma 8]). There is a universal constant `C` such that every position
`i` of a string `S` of length `n` lies in at most `C·(1 + log₂ n)` highly periodic runs, i.e. runs
`S[a..b]` with period `p = per(S[a..b])` and `b − a + 1 ≥ 3p`. -/
theorem lemma_8_5 : ∃ C : ℝ, ∀ {α : Type} [DecidableEq α] (S : List α) (i : ℕ),
(((Finset.Icc 1 S.length ×ˢ Finset.Icc 1 S.length).filter (fun r : ℕ × ℕ =>
IsRun S r.1 r.2 (per (sub S r.1 r.2)) ∧ HighlyPeriodic (sub S r.1 r.2) ∧
r.1 ≤ i ∧ i ≤ r.2)).card : ℝ) ≤
C * (1 + Real.logb 2 (S.length : ℝ)) := by sorry
end DynLZ77.Main
Source
Boneh, Fried, Golan, Kraus, Dynamic LZ77: No Space for Improvement, STOC 2027 submission (manuscript sha256 2a15e146…, https://github.com/sigact-stoc/stoc2027/releases/download/papers-2/1131.pdf), §8.1 Highly periodic words, Lyndon roots, Lemma 8.5, p. 49 (PDF 51), citing [BGS24, Lemma 8] = Boneh, Golan, Shur, String 2-Covers with No Length Restrictions, ESA 2024