Bounds for the balanced family
ProvedRhoMin.T_boundsPositions are natural numbers and a permutation is given by its value function . The digraph on has an arc when and is even (a P-edge leaving its even end), or when and is odd (a V-edge leaving its odd end). A path is a sequence of distinct positions in which each step is an arc.
For a set of positions with corners : bounds the paths of if every path inside has at most vertices; bounds the corner paths if every path inside with an end at or at has at most vertices; bounds the corner pairs if any two vertex-disjoint paths inside , the first with an end at and the second with an end at , have at most vertices in total.
For odd let be the interior of size defined recursively: is the identity for , and for it is the chain , where is the balanced split of into two odd numbers.
Let and let be odd with . Then, for a block carrying a copy of ,
Formalization Note The block is for an even offset , with corners and , in the digraph of any with for ; the three inequalities are the predicates BoundR, BoundL, BoundM.
import Definitions.Def_RhoMin_Defs import Definitions.Def_RhoMin_Dir import Definitions.Def_RhoMin_Piece import Definitions.Def_RhoMin_Orient import Definitions.Def_RhoMin_Gadget import Definitions.Def_RhoMin_Every import Mathlib.Data.Nat.Log import Mathlib.Order.Interval.Finset.Nat import Mathlib.Data.Fintype.Perm import Mathlib.Data.Fintype.Card import Mathlib.Data.List.Nodup import Mathlib.Data.Nat.Find import Mathlib.Data.List.FinRange import Mathlib.Data.Finset.Lattice.Fold import Mathlib.Data.Finset.Card import Mathlib.Data.List.Count import Mathlib.Algebra.BigOperators.Group.Finset.Basic import Mathlib.Algebra.Order.BigOperators.Group.Finset import Mathlib.Data.Fintype.Inv open RhoMin
theorem RhoMin.T_bounds : ∀ (k r : ℕ) (f : ℕ → ℕ) (q : ℕ), r % 2 = 1 → r < 2 ^ (k + 3) → q % 2 = 0 →
(∀ i < r, f (q + i) = q + T r i) →
Bnd f (Finset.Ico q (q + r)) q (q + r - 1) (14 * k + 14) (7 * k + 7) (14 * k + 14) := by sorryRead-back
What the Lean code literally says, in plain math · claude-fable-5-2
Statement. For all natural numbers , , and every function : if
- is odd,
- ,
- is even, and
- for every (where is the function defined below),
then the three bounds (defined below) hold for the block with corners and and constants , , :
The directed relation determined by . For , say there is an arc if
(precisely: or in the first case; or in the second). Only the parity of the source matters.
Meaning of . A list is a finite sequence of natural numbers, possibly empty. It is repetition-free if its entries are pairwise distinct, and a walk if is an arc for every (empty and one-element lists are walks). A number is an end of if is non-empty and or . The conclusion, with (the half-open interval ), is the conjunction of:
- (R) every repetition-free walk with all entries in has length (number of entries) ;
- (L) every repetition-free walk with all entries in that has as an end or as an end has length ;
- (M) for every two repetition-free walks with all entries in , sharing no entry, with an end of and an end of :
The function . It is defined for every natural number by recursion on :
- If , then is the identity: for all .
- If , put , , and
(the subtraction is truncated at ). Then, for all ,
where, for a natural number , a function and ,
The recursion uses and with . For odd (the only admitted by the hypotheses), is even and , and are odd with , so : the first two cases cover and the third gives .
Edge cases.
- is defined for even too, but the statement only concerns odd . Since is odd, , so the block is non-empty and the corner (written with truncated subtraction) is the genuine last element of the block.
- If (i.e. ), Hypothesis 4 says for all .
- If , the two corners coincide (both equal ), and part (M) is vacuously true, since two walks sharing no entry cannot both contain .
- enters only through and the constants; for given the statement holds for every such , the smallest admissible giving the strongest bounds. For the hypotheses force .
- A repetition-free list inside the block has length at most , so (R) and (M) hold automatically whenever , which is the case for all admissible when ( against ); similarly (L) is automatic when , in particular for .
- is unconstrained outside , and is not assumed injective there.