mathlib3 documentation

order.order_iso_nat

Relation embeddings from the naturals #

THIS FILE IS SYNCHRONIZED WITH MATHLIB4. Any changes to this file require a corresponding PR to mathlib4.

This file allows translation from monotone functions ℕ → α to order embeddings ℕ ↪ α and defines the limit value of an eventually-constant sequence.

Main declarations #

def rel_embedding.nat_lt {α : Type u_1} {r : α → α → Prop} [is_strict_order α r] (f : ℕ → α) (H : ∀ (n : ℕ), r (f n) (f (n + 1))) :

If f is a strictly r-increasing sequence, then this returns f as an order embedding.

Equations
@[simp]
theorem rel_embedding.coe_nat_lt {α : Type u_1} {r : α → α → Prop} [is_strict_order α r] {f : ℕ → α} {H : ∀ (n : ℕ), r (f n) (f (n + 1))} :
def rel_embedding.nat_gt {α : Type u_1} {r : α → α → Prop} [is_strict_order α r] (f : ℕ → α) (H : ∀ (n : ℕ), r (f (n + 1)) (f n)) :

If f is a strictly r-decreasing sequence, then this returns f as an order embedding.

Equations
@[simp]
theorem rel_embedding.coe_nat_gt {α : Type u_1} {r : α → α → Prop} [is_strict_order α r] {f : ℕ → α} {H : ∀ (n : ℕ), r (f (n + 1)) (f n)} :
theorem rel_embedding.exists_not_acc_lt_of_not_acc {α : Type u_1} {a : α} {r : α → α → Prop} (h : ¬acc r a) :
∃ (b : α), ¬acc r b ∧ r b a
theorem rel_embedding.acc_iff_no_decreasing_seq {α : Type u_1} {r : α → α → Prop} [is_strict_order α r] {x : α} :

A value is accessible iff it isn't contained in any infinite decreasing sequence.

theorem rel_embedding.not_acc_of_decreasing_seq {α : Type u_1} {r : α → α → Prop} [is_strict_order α r] (f : gt ↪r r) (k : ℕ) :
¬acc r (⇑f k)

A relation is well-founded iff it doesn't have any infinite decreasing sequence.

theorem rel_embedding.not_well_founded_of_decreasing_seq {α : Type u_1} {r : α → α → Prop} [is_strict_order α r] (f : gt ↪r r) :
noncomputable def nat.subtype.order_iso_of_nat (s : set ℕ) [infinite ↥s] :

nat.subtype.of_nat as an order isomorphism between ℕ and an infinite subset. See also nat.nth for a version where the subset may be finite.

Equations
theorem nat.exists_subseq_of_forall_mem_union {α : Type u_1} {s t : set α} (e : ℕ → α) (he : ∀ (n : ℕ), e n ∈ s ∪ t) :
∃ (g : ℕ ↪o ℕ), (∀ (n : ℕ), e (⇑g n) ∈ s) ∨ ∀ (n : ℕ), e (⇑g n) ∈ t
theorem exists_increasing_or_nonincreasing_subseq' {α : Type u_1} (r : α → α → Prop) (f : ℕ → α) :
∃ (g : ℕ ↪o ℕ), (∀ (n : ℕ), r (f (⇑g n)) (f (⇑g (n + 1)))) ∨ ∀ (m n : ℕ), m < n → ¬r (f (⇑g m)) (f (⇑g n))
theorem exists_increasing_or_nonincreasing_subseq {α : Type u_1} (r : α → α → Prop) [is_trans α r] (f : ℕ → α) :
∃ (g : ℕ ↪o ℕ), (∀ (m n : ℕ), m < n → r (f (⇑g m)) (f (⇑g n))) ∨ ∀ (m n : ℕ), m < n → ¬r (f (⇑g m)) (f (⇑g n))

This is the infinitary Erdős–Szekeres theorem, and an important lemma in the usual proof of Bolzano-Weierstrass for ℝ.

theorem well_founded.monotone_chain_condition' {α : Type u_1} [preorder α] :
well_founded gt ↔ ∀ (a : ℕ →o α), ∃ (n : ℕ), ∀ (m : ℕ), n ≤ m → ¬⇑a n < ⇑a m
theorem well_founded.monotone_chain_condition {α : Type u_1} [partial_order α] :
well_founded gt ↔ ∀ (a : ℕ →o α), ∃ (n : ℕ), ∀ (m : ℕ), n ≤ m → ⇑a n = ⇑a m

The "monotone chain condition" below is sometimes a convenient form of well foundedness.

noncomputable def monotonic_sequence_limit_index {α : Type u_1} [preorder α] (a : ℕ →o α) :

Given an eventually-constant monotone sequence a₀ ≤ a₁ ≤ a₂ ≤ ... in a partially-ordered type, monotonic_sequence_limit_index a is the least natural number n for which aₙ reaches the constant value. For sequences that are not eventually constant, monotonic_sequence_limit_index a is defined, but is a junk value.

Equations
noncomputable def monotonic_sequence_limit {α : Type u_1} [preorder α] (a : ℕ →o α) :
α

The constant value of an eventually-constant monotone sequence a₀ ≤ a₁ ≤ a₂ ≤ ... in a partially-ordered type.

Equations