Colexicographic order #
We define the colex order for finite sets, and give a couple of important lemmas and properties relating to it.
The colex ordering likes to avoid large values: If the biggest element of t is bigger than all
elements of s, then s < t.
In the special case of ℕ, it can be thought of as the "binary" ordering. That is, order s based
on $∑_{i ∈ s} 2^i$. It's defined here on Finset α for any linear order α.
In the context of the Kruskal-Katona theorem, we are interested in how colex behaves for sets of a
fixed size. For example, for size 3, the colex order on ℕ starts
012, 013, 023, 123, 014, 024, 124, 034, 134, 234, ...
Main statements #
- Colex order properties - linearity, decidability and so on.
Finset.Colex.forall_lt_mono: ifs < tin colex, and everything intis< a, then everything insis< a. This confirms the idea that an enumeration under colex will exhaust all sets using elements< abefore allowingato be included.Finset.toColex_image_le_toColex_image: Strictly monotone functions preserve colex.Finset.geomSum_le_geomSum_iff_toColex_le_toColex: Colex for α = ℕ is the same as binary. This also proves binary expansions are unique.
See also #
Related files are:
Data.List.Lex: Lexicographic order on lists.Data.Pi.Lex: Lexicographic order onΠₗ i, α i.Data.PSigma.Order: Lexicographic order onΣ' i, α i.Data.Sigma.Order: Lexicographic order onΣ i, α i.Data.Prod.Lex: Lexicographic order onα × β.
TODO #
- Generalise
Colex.initSegso that it applies toℕ.
References #
Tags #
colex, colexicographic, binary
If s ⊆ t, then s ≤ t in the colex order. Note the converse does not hold, as inclusion does
not form a linear order.
If s ⊂ t, then s < t in the colex order. Note the converse does not hold, as inclusion does
not form a linear order.
If s ⊆ t, then s ≤ t in the colex order. Note the converse does not hold, as inclusion does
not form a linear order.
If s ⊂ t, then s < t in the colex order. Note the converse does not hold, as inclusion does
not form a linear order.
Equations
- Finset.Colex.instDecidableLE s t = decidable_of_iff' (∀ ⦃a : α⦄, a ∈ ofColex s → a ∉ ofColex t → ∃ b ∈ ofColex t, b ∉ ofColex s ∧ a ≤ b) ⋯
The colexicographic order is insensitive to removing the same elements from both sets.
The colexicographic order is insensitive to removing the same elements from both sets.
Equations
- One or more equations did not get rendered due to their size.
Strictly monotone functions preserve the colex ordering.
Strictly monotone functions preserve the colex ordering.
Equations
- Finset.Colex.instBoundedOrder = { top := toColex Finset.univ, le_top := ⋯, toOrderBot := Finset.Colex.instOrderBot }
Initial segments #
𝒜 is an initial segment of the colexicographic order on sets of r, and that if t is below
s in colex where t has size r and s is in 𝒜, then t is also in 𝒜. In effect, 𝒜 is
downwards closed with respect to colex among sets of size r.
Equations
Instances For
Initial segments are nested in some way. In particular, if they're the same size they're equal.
The initial segment of the colexicographic order on sets with #s elements and ending at
s.
Instances For
Colex on ℕ #
The colexicographic order agrees with the order induced by interpreting a set of naturals as a
n-ary expansion.
Alias of Finset.toFinset_bitIndices_sum_two_pow.
Alias of Finset.sum_toFinset_bitIndices_two_pow.
The equivalence Nat.equivBitIndices enumerates Finset ℕ in colexicographic order.
Equations
- One or more equations did not get rendered due to their size.