L0 combinatorics: iterated extraction of fully paired subintervals #
Endpoint-extraction layer for Def 3.1 of Deng–Shen (arXiv:2607.10105), node D-RI (DESIGN §5.7bis): the renormalization iteratively removes the smallest-then-leftmost fully paired subinterval, where after removals a "subinterval" is contiguous in the remaining index order.
Design #
- We never change the index type: the remaining indices are a shrinking
active : Finset (Fin m). The trace of[a, b]onactiveisrelIcc;IsRelFullyPaired κ active a bis the relative variant ofIsFullyPairedOn κ (Finset.Icc a b). - The Def 3.1(2) selector on the relative structure,
selectRel, picks the candidate(a, b)minimizing the lexicographic triple((relIcc active a b).card, a, b), encoded intoℕby the mixed-radix keycandKey active a b = card * ((m+1) * (m+1)) + (a * (m+1) + b)and selected viaFinset.min'on the key image (minCandKey) plusFinset.choose(the key is injective,candKey_inj). - The extraction recursion
extractAuxruns on fuel; each step removes the selected trace fromactive, which shrinksactiveby at least2(IsRelFullyPaired.two_le_card), so fuelmalways reaches the no-candidate state (extract_fuel_sufficient, via the stateful variantextractAuxS).
Relative intervals #
The trace of the interval [a, b] on the set active of remaining
indices: for the Def 3.1 iteration, "subinterval" means contiguous in the
remaining index order, i.e. a set of this form.
Equations
- Anderson4D.relIcc active a b = {i ∈ active | a ≤ i ∧ i ≤ b}
Instances For
Relative form of paper Def 2.3 / Def 3.1(2). The trace of [a, b] on
active is a fully paired subinterval of the remaining index order: both
endpoints are still active, a ≤ b, and the trace is fully paired.
Equations
- Anderson4D.IsRelFullyPaired κ active a b = (a ∈ active ∧ b ∈ active ∧ a ≤ b ∧ Anderson4D.IsFullyPairedOn κ (Anderson4D.relIcc active a b))
Instances For
Equations
- Anderson4D.instDecidableIsRelFullyPaired κ active a b = decidable_of_iff (a ∈ active ∧ b ∈ active ∧ a ≤ b ∧ Anderson4D.IsFullyPairedOn κ (Anderson4D.relIcc active a b)) ⋯
A relative fully paired interval contains at least one whole pair: its trace has at least two elements. This is the engine of the fuel bound for the extraction recursion.
The relative selector #
Among all (a, b) with IsRelFullyPaired κ active a b, select the one with
lexicographically minimal ((relIcc active a b).card, a, b), via the
mixed-radix embedding candKey into ℕ and Finset.min'.
The mixed-radix selection key of a candidate (a, b):
(relIcc active a b).card * ((m+1) * (m+1)) + (a * (m+1) + b), i.e. the
lexicographic triple (card, a, b) in base m + 1.
Equations
Instances For
The candidates of the relative selector: endpoint pairs of relative fully
paired intervals of active.
Equations
- Anderson4D.relCands κ active = {p : Fin m × Fin m | Anderson4D.IsRelFullyPaired κ active p.1 p.2}
Instances For
The minimal selection key over all candidates.
Equations
- Anderson4D.minCandKey κ active h = (Finset.image (fun (p : Fin m × Fin m) => Anderson4D.candKey active p.1 p.2) (Anderson4D.relCands κ active)).min' ⋯
Instances For
Relative Def 3.1(2) selector. The candidate (a, b) with
lexicographically minimal ((relIcc active a b).card, a, b).
Equations
- Anderson4D.selectRel κ active h = Finset.choose (fun (a : Fin m × Fin m) => Anderson4D.candKey active a.1 a.2 = Anderson4D.minCandKey κ active h) (Anderson4D.relCands κ active) ⋯
Instances For
The selected pair is a genuine candidate.
Key minimality of the selected pair over all candidates.
Selector spec, first component of the lexicographic order: the selected trace has minimal cardinality among all candidates.
Selector spec, second component: among candidates of the minimal trace cardinality, the selected left endpoint is leftmost.
Selector spec, third component: among candidates of minimal trace cardinality and minimal left endpoint, the selected right endpoint is minimal.
The extraction recursion (paper Def 3.1, node D-RI) #
Fuel recursion implementing the Def 3.1 iteration: while a relative fully
paired interval exists in active, extract the selected endpoint pair and
remove its trace from active.
Equations
- One or more equations did not get rendered due to their size.
- Anderson4D.extractAux κ 0 x✝ = []
Instances For
Raw recursion equation at successor fuel.
Recursion equation, candidate case.
Recursion equation, no-candidate case.
Paper Def 3.1 (node D-RI). The list of endpoint pairs of the
successively removed fully paired subintervals, starting from all of Fin m;
fuel m always suffices (extract_fuel_sufficient).
Equations
Instances For
Step invariant: every extracted pair has both endpoints in the active set of its step (hence in the initial one), and is ordered.
Each extraction step shrinks the active set by at least two elements.
The stateful recursion and fuel adequacy #
Stateful variant of extractAux, additionally returning the final active
set; used to state fuel adequacy (extract_fuel_sufficient).
Equations
Instances For
Recursion equation for extractAuxS, candidate case.
Recursion equation for extractAuxS, no-candidate case.
The extracted list of the stateful recursion is extractAux.
Fuel adequacy, general form: if active.card ≤ 2 * fuel + 1 then the
recursion reaches the no-candidate state (each step removes at least two
elements, card_sdiff_relIcc_add_two_le).
The active set remaining after the extraction loop (fuel m,
initial state Finset.univ).
Equations
Instances For
Fuel adequacy. Fuel m reaches the terminal state of the Def 3.1
iteration: no relative fully paired interval survives in finalActive.
Endpoint sets for the closed formulas #
The selected right endpoint lies in the removed trace, so it never reappears: the extracted right endpoints are pairwise distinct.
Left analogue: the extracted left endpoints are pairwise distinct.
The right endpoints b_i of the extracted intervals (input to the closed
formulas of §4.1).
Equations
Instances For
The left endpoints a_i of the extracted intervals.