ordered_patterns
def
The finite set of ordered coloured rectangle patterns of an $a\times b$ grid, i.e. the patterns with $x_1<x_2$ and $y_1<y_2$. Its cardinality is $2\binom a2\binom b2$, the number of "coloured rectangle slots".
Statement
def ordered_patterns (a b : ℕ) : Finset (BoxPattern a b)- Source
- step towards grid_box_free_max_five_seven
- Verified
- 18 Nov 2026
- Axioms
- none listed
- Built on 1
- BoxPatternA coloured rectangle pattern in an $a\times b$ grid: a pair of rows $x_1<x_2$, a pair of columns $y_1<y_2$, and a colour, encoded as the…
- Used by 5
- grid_five_seven_fifty_one_at_most_six_unbalanced_layersA box-free five-by-seven-by-fifty-one binary coloring has at most six layers containing an unbalanced column.
- grid_five_seven_fifty_one_many_minimum_layersEvery box-free binary coloring of a five-by-seven-by-fifty-one grid has at least thirty-nine layers with exactly eight monochromatic…
- grid57_stack_at_most_fifty_twoEvery box-free binary coloring of a five-by-seven-by-n grid has at most 52 layers.
- ordered_patterns_five_seven_cardThe $5\times 7$ grid has exactly $2\binom52\binom72 = 420$ ordered coloured rectangle slots.
- layer_mono_card_sum_leLayer bound (Lemma 4.1 core): for a box-free colouring of $[a]\times[b]\times[c]$, the total number of monochromatic rectangles summed…
Lean source view module on GitHub
/-- All ordered coloured rectangle slots of an $a\times b$ grid. -/ def ordered_patterns (a b : ℕ) : Finset (BoxPattern a b) := Finset.univ.filter (fun p => p.1 < p.2.1 ∧ p.2.2.1 < p.2.2.2.1)