Documentation

LeanPool.NashWilliams.Order.WellQuasiOrder.Basic

Perfect/bad dichotomy and monotone subsequences in a well-quasi-order #

The infinite Ramsey theorem for pairs gives a clean "perfect or bad" dichotomy for sequences in any relation, from which the monotone subsequence property of a well-quasi-order follows without any transitivity assumption.

Main results #

The second result answers a question of Leo Shine on the Mathlib Zulip: the monotone-subsequence property of a WQO does not need the preorder (in particular transitivity) hypothesis carried by the current Mathlib WellQuasiOrdered.exists_monotone_subseq.

def Sequences.IsBad {α : Type u_1} (r : ααProp) (f : α) :

A sequence is bad for r if no earlier term is r-below a later one.

Equations
Instances For
    def Sequences.IsPerfect {α : Type u_1} (r : ααProp) (f : α) :

    A sequence is perfect for r if every earlier term is r-below every later one.

    Equations
    Instances For
      theorem Sequences.perfect_or_bad {α : Type u_1} (r : ααProp) (f : α) :
      ∃ (e : ), StrictMono e (IsPerfect r (f e) IsBad r (f e))

      Perfect/bad dichotomy. Every sequence f : ℕ → α has a strictly increasing reindexing f ∘ e that is either perfect or bad for r. Immediate from the infinite Ramsey theorem for pairs applied to the 2-colouring (m, n) ↦ ¬ r (f m) (f n); no order axioms are used.

      theorem WellQuasiOrdered.exists_monotone_subseq_lt {α : Type u_1} {r : ααProp} (h : WellQuasiOrdered r) (f : α) :
      ∃ (e : ), StrictMono e ∀ (m n : ), m < nr (f (e m)) (f (e n))

      Monotone subsequences from a WQO, without transitivity. In a well-quasi-order, every sequence has a strictly increasing reindexing e along which r (f (e m)) (f (e n)) holds for all m < n. Follows directly from the perfect/bad dichotomy: a bad subsequence would contradict the WQO. No typeclass assumptions on r.