fact
stringlengths
6
3.84k
type
stringclasses
11 values
library
stringclasses
32 values
imports
listlengths
1
14
filename
stringlengths
20
95
symbolic_name
stringlengths
1
90
docstring
stringlengths
7
20k
ωSup_zip (c₀ : Chain α) (c₁ : Chain β) : ωSup (c₀.zip c₁) = (ωSup c₀, ωSup c₁) := rfl
theorem
Order
[ "Mathlib.Control.Monad.Basic", "Mathlib.Dynamics.FixedPoints.Basic", "Mathlib.Order.CompleteLattice.Basic", "Mathlib.Order.Iterate", "Mathlib.Order.Part", "Mathlib.Order.Preorder.Chain", "Mathlib.Order.ScottContinuity" ]
Mathlib/Order/OmegaCompletePartialOrder.lean
ωSup_zip
null
@[simps] protected ωSup (c : Chain (α →o β)) : α →o β where toFun a := ωSup (c.map (OrderHom.apply a)) monotone' _ _ h := ωSup_le_ωSup_of_le ((Chain.map_le_map _) fun a => a.monotone h) @[simps! ωSup_coe]
def
Order
[ "Mathlib.Control.Monad.Basic", "Mathlib.Dynamics.FixedPoints.Basic", "Mathlib.Order.CompleteLattice.Basic", "Mathlib.Order.Iterate", "Mathlib.Order.Part", "Mathlib.Order.Preorder.Chain", "Mathlib.Order.ScottContinuity" ]
Mathlib/Order/OmegaCompletePartialOrder.lean
ωSup
Any complete lattice has an `ω`-CPO structure where the countable supremum is a special case of arbitrary suprema. -/ instance (priority := 100) [CompleteLattice α] : OmegaCompletePartialOrder α where ωSup c := ⨆ i, c i ωSup_le := fun ⟨c, _⟩ s hs => by simpa only [iSup_le_iff] le_ωSup := fun ⟨c, _⟩ i => le_iSup_o...
omegaCompletePartialOrder : OmegaCompletePartialOrder (α →o β) := OmegaCompletePartialOrder.lift OrderHom.coeFnHom OrderHom.ωSup (fun _ _ h => h) fun _ => rfl
instance
Order
[ "Mathlib.Control.Monad.Basic", "Mathlib.Dynamics.FixedPoints.Basic", "Mathlib.Order.CompleteLattice.Basic", "Mathlib.Order.Iterate", "Mathlib.Order.Part", "Mathlib.Order.Preorder.Chain", "Mathlib.Order.ScottContinuity" ]
Mathlib/Order/OmegaCompletePartialOrder.lean
omegaCompletePartialOrder
null
ContinuousHom extends OrderHom α β where /-- The underlying function of a `ContinuousHom` is continuous, i.e. it preserves `ωSup` -/ protected map_ωSup' (c : Chain α) : toFun (ωSup c) = ωSup (c.map toOrderHom) attribute [nolint docBlame] ContinuousHom.toOrderHom @[inherit_doc] infixr:25 " →𝒄 " => ContinuousHom -- ...
structure
Order
[ "Mathlib.Control.Monad.Basic", "Mathlib.Dynamics.FixedPoints.Basic", "Mathlib.Order.CompleteLattice.Basic", "Mathlib.Order.Iterate", "Mathlib.Order.Part", "Mathlib.Order.Preorder.Chain", "Mathlib.Order.ScottContinuity" ]
Mathlib/Order/OmegaCompletePartialOrder.lean
ContinuousHom
A monotone function on `ω`-continuous partial orders is said to be continuous if for every chain `c : chain α`, `f (⊔ i, c i) = ⊔ i, f (c i)`. This is just the bundled version of `OrderHom.continuous`.
protected ωScottContinuous (f : α →𝒄 β) : ωScottContinuous f := ωScottContinuous.of_map_ωSup_of_orderHom f.map_ωSup'
lemma
Order
[ "Mathlib.Control.Monad.Basic", "Mathlib.Dynamics.FixedPoints.Basic", "Mathlib.Order.CompleteLattice.Basic", "Mathlib.Order.Iterate", "Mathlib.Order.Part", "Mathlib.Order.Preorder.Chain", "Mathlib.Order.ScottContinuity" ]
Mathlib/Order/OmegaCompletePartialOrder.lean
ωScottContinuous
null
toOrderHom_eq_coe (f : α →𝒄 β) : f.1 = f := rfl @[simp] theorem coe_mk (f : α →o β) (hf) : ⇑(mk f hf) = f := rfl @[simp] theorem coe_toOrderHom (f : α →𝒄 β) : ⇑f.1 = f := rfl
theorem
Order
[ "Mathlib.Control.Monad.Basic", "Mathlib.Dynamics.FixedPoints.Basic", "Mathlib.Order.CompleteLattice.Basic", "Mathlib.Order.Iterate", "Mathlib.Order.Part", "Mathlib.Order.Preorder.Chain", "Mathlib.Order.ScottContinuity" ]
Mathlib/Order/OmegaCompletePartialOrder.lean
toOrderHom_eq_coe
null
Simps.apply (h : α →𝒄 β) : α → β := h initialize_simps_projections ContinuousHom (toFun → apply)
def
Order
[ "Mathlib.Control.Monad.Basic", "Mathlib.Dynamics.FixedPoints.Basic", "Mathlib.Order.CompleteLattice.Basic", "Mathlib.Order.Iterate", "Mathlib.Order.Part", "Mathlib.Order.Preorder.Chain", "Mathlib.Order.ScottContinuity" ]
Mathlib/Order/OmegaCompletePartialOrder.lean
Simps.apply
See Note [custom simps projection]. We specify this explicitly because we don't have a DFunLike instance.
protected congr_fun {f g : α →𝒄 β} (h : f = g) (x : α) : f x = g x := DFunLike.congr_fun h x
theorem
Order
[ "Mathlib.Control.Monad.Basic", "Mathlib.Dynamics.FixedPoints.Basic", "Mathlib.Order.CompleteLattice.Basic", "Mathlib.Order.Iterate", "Mathlib.Order.Part", "Mathlib.Order.Preorder.Chain", "Mathlib.Order.ScottContinuity" ]
Mathlib/Order/OmegaCompletePartialOrder.lean
congr_fun
null
protected congr_arg (f : α →𝒄 β) {x y : α} (h : x = y) : f x = f y := congr_arg f h
theorem
Order
[ "Mathlib.Control.Monad.Basic", "Mathlib.Dynamics.FixedPoints.Basic", "Mathlib.Order.CompleteLattice.Basic", "Mathlib.Order.Iterate", "Mathlib.Order.Part", "Mathlib.Order.Preorder.Chain", "Mathlib.Order.ScottContinuity" ]
Mathlib/Order/OmegaCompletePartialOrder.lean
congr_arg
null
protected monotone (f : α →𝒄 β) : Monotone f := f.monotone' @[mono]
theorem
Order
[ "Mathlib.Control.Monad.Basic", "Mathlib.Dynamics.FixedPoints.Basic", "Mathlib.Order.CompleteLattice.Basic", "Mathlib.Order.Iterate", "Mathlib.Order.Part", "Mathlib.Order.Preorder.Chain", "Mathlib.Order.ScottContinuity" ]
Mathlib/Order/OmegaCompletePartialOrder.lean
monotone
null
apply_mono {f g : α →𝒄 β} {x y : α} (h₁ : f ≤ g) (h₂ : x ≤ y) : f x ≤ g y := OrderHom.apply_mono (show (f : α →o β) ≤ g from h₁) h₂
theorem
Order
[ "Mathlib.Control.Monad.Basic", "Mathlib.Dynamics.FixedPoints.Basic", "Mathlib.Order.CompleteLattice.Basic", "Mathlib.Order.Iterate", "Mathlib.Order.Part", "Mathlib.Order.Preorder.Chain", "Mathlib.Order.ScottContinuity" ]
Mathlib/Order/OmegaCompletePartialOrder.lean
apply_mono
null
ωSup_bind {β γ : Type v} (c : Chain α) (f : α →o Part β) (g : α →o β → Part γ) : ωSup (c.map (f.partBind g)) = ωSup (c.map f) >>= ωSup (c.map g) := by apply eq_of_forall_ge_iff; intro x simp only [ωSup_le_iff, Part.bind_le] constructor <;> intro h''' · intro b hb apply ωSup_le _ _ _ rintro i y hy ...
theorem
Order
[ "Mathlib.Control.Monad.Basic", "Mathlib.Dynamics.FixedPoints.Basic", "Mathlib.Order.CompleteLattice.Basic", "Mathlib.Order.Iterate", "Mathlib.Order.Part", "Mathlib.Order.Preorder.Chain", "Mathlib.Order.ScottContinuity" ]
Mathlib/Order/OmegaCompletePartialOrder.lean
ωSup_bind
null
ωScottContinuous.bind {β γ} {f : α → Part β} {g : α → β → Part γ} (hf : ωScottContinuous f) (hg : ωScottContinuous g) : ωScottContinuous fun x ↦ f x >>= g x := ωScottContinuous.of_monotone_map_ωSup ⟨hf.monotone.partBind hg.monotone, fun c ↦ by rw [hf.map_ωSup, hg.map_ωSup, ← ωSup_bind]; rfl⟩
lemma
Order
[ "Mathlib.Control.Monad.Basic", "Mathlib.Dynamics.FixedPoints.Basic", "Mathlib.Order.CompleteLattice.Basic", "Mathlib.Order.Iterate", "Mathlib.Order.Part", "Mathlib.Order.Preorder.Chain", "Mathlib.Order.ScottContinuity" ]
Mathlib/Order/OmegaCompletePartialOrder.lean
ωScottContinuous.bind
null
ωScottContinuous.map {β γ} {f : β → γ} {g : α → Part β} (hg : ωScottContinuous g) : ωScottContinuous fun x ↦ f <$> g x := by simpa only [map_eq_bind_pure_comp] using ωScottContinuous.bind hg ωScottContinuous.const
lemma
Order
[ "Mathlib.Control.Monad.Basic", "Mathlib.Dynamics.FixedPoints.Basic", "Mathlib.Order.CompleteLattice.Basic", "Mathlib.Order.Iterate", "Mathlib.Order.Part", "Mathlib.Order.Preorder.Chain", "Mathlib.Order.ScottContinuity" ]
Mathlib/Order/OmegaCompletePartialOrder.lean
ωScottContinuous.map
null
ωScottContinuous.seq {β γ} {f : α → Part (β → γ)} {g : α → Part β} (hf : ωScottContinuous f) (hg : ωScottContinuous g) : ωScottContinuous fun x ↦ f x <*> g x := by simp only [seq_eq_bind_map] exact ωScottContinuous.bind hf <| ωScottContinuous.of_apply₂ fun _ ↦ ωScottContinuous.map hg
lemma
Order
[ "Mathlib.Control.Monad.Basic", "Mathlib.Dynamics.FixedPoints.Basic", "Mathlib.Order.CompleteLattice.Basic", "Mathlib.Order.Iterate", "Mathlib.Order.Part", "Mathlib.Order.Preorder.Chain", "Mathlib.Order.ScottContinuity" ]
Mathlib/Order/OmegaCompletePartialOrder.lean
ωScottContinuous.seq
null
continuous (F : α →𝒄 β) (C : Chain α) : F (ωSup C) = ωSup (C.map F) := F.ωScottContinuous.map_ωSup _
theorem
Order
[ "Mathlib.Control.Monad.Basic", "Mathlib.Dynamics.FixedPoints.Basic", "Mathlib.Order.CompleteLattice.Basic", "Mathlib.Order.Iterate", "Mathlib.Order.Part", "Mathlib.Order.Preorder.Chain", "Mathlib.Order.ScottContinuity" ]
Mathlib/Order/OmegaCompletePartialOrder.lean
continuous
null
@[simps!] copy (f : α → β) (g : α →𝒄 β) (h : f = g) : α →𝒄 β where toOrderHom := g.1.copy f h map_ωSup' := by rw [OrderHom.copy_eq]; exact g.map_ωSup'
def
Order
[ "Mathlib.Control.Monad.Basic", "Mathlib.Dynamics.FixedPoints.Basic", "Mathlib.Order.CompleteLattice.Basic", "Mathlib.Order.Iterate", "Mathlib.Order.Part", "Mathlib.Order.Preorder.Chain", "Mathlib.Order.ScottContinuity" ]
Mathlib/Order/OmegaCompletePartialOrder.lean
copy
Construct a continuous function from a bare function, a continuous function, and a proof that they are equal.
@[simps!] id : α →𝒄 α := ⟨OrderHom.id, ωScottContinuous.id.map_ωSup⟩
def
Order
[ "Mathlib.Control.Monad.Basic", "Mathlib.Dynamics.FixedPoints.Basic", "Mathlib.Order.CompleteLattice.Basic", "Mathlib.Order.Iterate", "Mathlib.Order.Part", "Mathlib.Order.Preorder.Chain", "Mathlib.Order.ScottContinuity" ]
Mathlib/Order/OmegaCompletePartialOrder.lean
id
The identity as a continuous function.
@[simps!] comp (f : β →𝒄 γ) (g : α →𝒄 β) : α →𝒄 γ := ⟨.comp f.1 g.1, (f.ωScottContinuous.comp g.ωScottContinuous).map_ωSup⟩ @[ext]
def
Order
[ "Mathlib.Control.Monad.Basic", "Mathlib.Dynamics.FixedPoints.Basic", "Mathlib.Order.CompleteLattice.Basic", "Mathlib.Order.Iterate", "Mathlib.Order.Part", "Mathlib.Order.Preorder.Chain", "Mathlib.Order.ScottContinuity" ]
Mathlib/Order/OmegaCompletePartialOrder.lean
comp
The composition of continuous functions.
protected ext (f g : α →𝒄 β) (h : ∀ x, f x = g x) : f = g := DFunLike.ext f g h
theorem
Order
[ "Mathlib.Control.Monad.Basic", "Mathlib.Dynamics.FixedPoints.Basic", "Mathlib.Order.CompleteLattice.Basic", "Mathlib.Order.Iterate", "Mathlib.Order.Part", "Mathlib.Order.Preorder.Chain", "Mathlib.Order.ScottContinuity" ]
Mathlib/Order/OmegaCompletePartialOrder.lean
ext
null
protected coe_inj (f g : α →𝒄 β) (h : (f : α → β) = g) : f = g := DFunLike.ext' h @[simp]
theorem
Order
[ "Mathlib.Control.Monad.Basic", "Mathlib.Dynamics.FixedPoints.Basic", "Mathlib.Order.CompleteLattice.Basic", "Mathlib.Order.Iterate", "Mathlib.Order.Part", "Mathlib.Order.Preorder.Chain", "Mathlib.Order.ScottContinuity" ]
Mathlib/Order/OmegaCompletePartialOrder.lean
coe_inj
null
comp_id (f : β →𝒄 γ) : f.comp id = f := rfl @[simp]
theorem
Order
[ "Mathlib.Control.Monad.Basic", "Mathlib.Dynamics.FixedPoints.Basic", "Mathlib.Order.CompleteLattice.Basic", "Mathlib.Order.Iterate", "Mathlib.Order.Part", "Mathlib.Order.Preorder.Chain", "Mathlib.Order.ScottContinuity" ]
Mathlib/Order/OmegaCompletePartialOrder.lean
comp_id
null
id_comp (f : β →𝒄 γ) : id.comp f = f := rfl @[simp]
theorem
Order
[ "Mathlib.Control.Monad.Basic", "Mathlib.Dynamics.FixedPoints.Basic", "Mathlib.Order.CompleteLattice.Basic", "Mathlib.Order.Iterate", "Mathlib.Order.Part", "Mathlib.Order.Preorder.Chain", "Mathlib.Order.ScottContinuity" ]
Mathlib/Order/OmegaCompletePartialOrder.lean
id_comp
null
comp_assoc (f : γ →𝒄 δ) (g : β →𝒄 γ) (h : α →𝒄 β) : f.comp (g.comp h) = (f.comp g).comp h := rfl @[simp]
theorem
Order
[ "Mathlib.Control.Monad.Basic", "Mathlib.Dynamics.FixedPoints.Basic", "Mathlib.Order.CompleteLattice.Basic", "Mathlib.Order.Iterate", "Mathlib.Order.Part", "Mathlib.Order.Preorder.Chain", "Mathlib.Order.ScottContinuity" ]
Mathlib/Order/OmegaCompletePartialOrder.lean
comp_assoc
null
coe_apply (a : α) (f : α →𝒄 β) : (f : α →o β) a = f a := rfl
theorem
Order
[ "Mathlib.Control.Monad.Basic", "Mathlib.Dynamics.FixedPoints.Basic", "Mathlib.Order.CompleteLattice.Basic", "Mathlib.Order.Iterate", "Mathlib.Order.Part", "Mathlib.Order.Preorder.Chain", "Mathlib.Order.ScottContinuity" ]
Mathlib/Order/OmegaCompletePartialOrder.lean
coe_apply
null
@[simps!] const (x : β) : α →𝒄 β := ⟨.const _ x, ωScottContinuous.const.map_ωSup⟩
def
Order
[ "Mathlib.Control.Monad.Basic", "Mathlib.Dynamics.FixedPoints.Basic", "Mathlib.Order.CompleteLattice.Basic", "Mathlib.Order.Iterate", "Mathlib.Order.Part", "Mathlib.Order.Preorder.Chain", "Mathlib.Order.ScottContinuity" ]
Mathlib/Order/OmegaCompletePartialOrder.lean
const
`Function.const` is a continuous function.
@[simps] toMono : (α →𝒄 β) →o α →o β where toFun f := f monotone' _ _ h := h
def
Order
[ "Mathlib.Control.Monad.Basic", "Mathlib.Dynamics.FixedPoints.Basic", "Mathlib.Order.CompleteLattice.Basic", "Mathlib.Order.Iterate", "Mathlib.Order.Part", "Mathlib.Order.Preorder.Chain", "Mathlib.Order.ScottContinuity" ]
Mathlib/Order/OmegaCompletePartialOrder.lean
toMono
The map from continuous functions to monotone functions is itself a monotone function.
@[simp] forall_forall_merge (c₀ : Chain (α →𝒄 β)) (c₁ : Chain α) (z : β) : (∀ i j : ℕ, (c₀ i) (c₁ j) ≤ z) ↔ ∀ i : ℕ, (c₀ i) (c₁ i) ≤ z := by constructor <;> introv h · apply h · apply le_trans _ (h (max i j)) trans c₀ i (c₁ (max i j)) · apply (c₀ i).monotone apply c₁.monotone apply le_max...
theorem
Order
[ "Mathlib.Control.Monad.Basic", "Mathlib.Dynamics.FixedPoints.Basic", "Mathlib.Order.CompleteLattice.Basic", "Mathlib.Order.Iterate", "Mathlib.Order.Part", "Mathlib.Order.Preorder.Chain", "Mathlib.Order.ScottContinuity" ]
Mathlib/Order/OmegaCompletePartialOrder.lean
forall_forall_merge
When proving that a chain of applications is below a bound `z`, it suffices to consider the functions and values being selected from the same index in the chains. This lemma is more specific than necessary, i.e. `c₀` only needs to be a chain of monotone functions, but it is only used with continuous functions.
forall_forall_merge' (c₀ : Chain (α →𝒄 β)) (c₁ : Chain α) (z : β) : (∀ j i : ℕ, (c₀ i) (c₁ j) ≤ z) ↔ ∀ i : ℕ, (c₀ i) (c₁ i) ≤ z := by rw [forall_swap, forall_forall_merge]
theorem
Order
[ "Mathlib.Control.Monad.Basic", "Mathlib.Dynamics.FixedPoints.Basic", "Mathlib.Order.CompleteLattice.Basic", "Mathlib.Order.Iterate", "Mathlib.Order.Part", "Mathlib.Order.Preorder.Chain", "Mathlib.Order.ScottContinuity" ]
Mathlib/Order/OmegaCompletePartialOrder.lean
forall_forall_merge'
null
@[simps!] protected ωSup (c : Chain (α →𝒄 β)) : α →𝒄 β where toOrderHom := ωSup <| c.map toMono map_ωSup' c' := eq_of_forall_ge_iff fun a ↦ by simp [(c _).ωScottContinuous.map_ωSup] @[simps ωSup]
def
Order
[ "Mathlib.Control.Monad.Basic", "Mathlib.Dynamics.FixedPoints.Basic", "Mathlib.Order.CompleteLattice.Basic", "Mathlib.Order.Iterate", "Mathlib.Order.Part", "Mathlib.Order.Preorder.Chain", "Mathlib.Order.ScottContinuity" ]
Mathlib/Order/OmegaCompletePartialOrder.lean
ωSup
The `ωSup` operator for continuous functions, which takes the pointwise countable supremum of the functions in the `ω`-chain.
@[simps] apply : (α →𝒄 β) × α →𝒄 β where toFun f := f.1 f.2 monotone' x y h := by dsimp trans y.fst x.snd <;> [apply h.1; apply y.1.monotone h.2] map_ωSup' c := by apply le_antisymm · apply ωSup_le intro i dsimp rw [(c _).fst.continuous] apply ωSup_le intro j ...
def
Order
[ "Mathlib.Control.Monad.Basic", "Mathlib.Dynamics.FixedPoints.Basic", "Mathlib.Order.CompleteLattice.Basic", "Mathlib.Order.Iterate", "Mathlib.Order.Part", "Mathlib.Order.Preorder.Chain", "Mathlib.Order.ScottContinuity" ]
Mathlib/Order/OmegaCompletePartialOrder.lean
apply
The application of continuous functions as a continuous function.
ωSup_apply_ωSup (c₀ : Chain (α →𝒄 β)) (c₁ : Chain α) : ωSup c₀ (ωSup c₁) = Prod.apply (ωSup (c₀.zip c₁)) := by simp [Prod.apply_apply, Prod.ωSup_zip]
theorem
Order
[ "Mathlib.Control.Monad.Basic", "Mathlib.Dynamics.FixedPoints.Basic", "Mathlib.Order.CompleteLattice.Basic", "Mathlib.Order.Iterate", "Mathlib.Order.Part", "Mathlib.Order.Preorder.Chain", "Mathlib.Order.ScottContinuity" ]
Mathlib/Order/OmegaCompletePartialOrder.lean
ωSup_apply_ωSup
null
@[simps] flip {α : Type*} (f : α → β →𝒄 γ) : β →𝒄 α → γ where toFun x y := f y x monotone' _ _ h a := (f a).monotone h map_ωSup' _ := by ext x; change f _ _ = _; rw [(f _).continuous]; rfl
def
Order
[ "Mathlib.Control.Monad.Basic", "Mathlib.Dynamics.FixedPoints.Basic", "Mathlib.Order.CompleteLattice.Basic", "Mathlib.Order.Iterate", "Mathlib.Order.Part", "Mathlib.Order.Preorder.Chain", "Mathlib.Order.ScottContinuity" ]
Mathlib/Order/OmegaCompletePartialOrder.lean
flip
A family of continuous functions yields a continuous family of functions.
@[simps! apply] noncomputable bind {β γ : Type v} (f : α →𝒄 Part β) (g : α →𝒄 β → Part γ) : α →𝒄 Part γ := .mk (OrderHom.partBind f g.toOrderHom) fun c => by rw [ωSup_bind, ← f.continuous, g.toOrderHom_eq_coe, ← g.continuous] rfl
def
Order
[ "Mathlib.Control.Monad.Basic", "Mathlib.Dynamics.FixedPoints.Basic", "Mathlib.Order.CompleteLattice.Basic", "Mathlib.Order.Iterate", "Mathlib.Order.Part", "Mathlib.Order.Preorder.Chain", "Mathlib.Order.ScottContinuity" ]
Mathlib/Order/OmegaCompletePartialOrder.lean
bind
`Part.bind` as a continuous function.
@[simps! apply] noncomputable map {β γ : Type v} (f : β → γ) (g : α →𝒄 Part β) : α →𝒄 Part γ := .copy (fun x => f <$> g x) (bind g (const (pure ∘ f))) <| by ext1 simp only [map_eq_bind_pure_comp, bind, coe_mk, OrderHom.partBind_coe, coe_apply, coe_toOrderHom, const_apply, Part.bind_eq_bind]
def
Order
[ "Mathlib.Control.Monad.Basic", "Mathlib.Dynamics.FixedPoints.Basic", "Mathlib.Order.CompleteLattice.Basic", "Mathlib.Order.Iterate", "Mathlib.Order.Part", "Mathlib.Order.Preorder.Chain", "Mathlib.Order.ScottContinuity" ]
Mathlib/Order/OmegaCompletePartialOrder.lean
map
`Part.map` as a continuous function.
@[simps! apply] noncomputable seq {β γ : Type v} (f : α →𝒄 Part (β → γ)) (g : α →𝒄 Part β) : α →𝒄 Part γ := .copy (fun x => f x <*> g x) (bind f <| flip <| _root_.flip map g) <| by ext simp only [seq_eq_bind_map, Part.bind_eq_bind, Part.mem_bind_iff, flip_apply, _root_.flip, map_apply, bind_app...
def
Order
[ "Mathlib.Control.Monad.Basic", "Mathlib.Dynamics.FixedPoints.Basic", "Mathlib.Order.CompleteLattice.Basic", "Mathlib.Order.Iterate", "Mathlib.Order.Part", "Mathlib.Order.Preorder.Chain", "Mathlib.Order.ScottContinuity" ]
Mathlib/Order/OmegaCompletePartialOrder.lean
seq
`Part.seq` as a continuous function.
iterateChain (f : α →o α) (x : α) (h : x ≤ f x) : Chain α := ⟨fun n => f^[n] x, f.monotone.monotone_iterate_of_le_map h⟩ variable (f : α →𝒄 α) (x : α)
def
Order
[ "Mathlib.Control.Monad.Basic", "Mathlib.Dynamics.FixedPoints.Basic", "Mathlib.Order.CompleteLattice.Basic", "Mathlib.Order.Iterate", "Mathlib.Order.Part", "Mathlib.Order.Preorder.Chain", "Mathlib.Order.ScottContinuity" ]
Mathlib/Order/OmegaCompletePartialOrder.lean
iterateChain
Iteration of a function on an initial element interpreted as a chain.
ωSup_iterate_mem_fixedPoint (h : x ≤ f x) : ωSup (iterateChain f x h) ∈ fixedPoints f := by rw [mem_fixedPoints, IsFixedPt, f.continuous] apply le_antisymm · apply ωSup_le intro n simp only [Chain.map_coe, OrderHomClass.coe_coe, comp_apply] have : iterateChain f x h (n.succ) = f (iterateChain f x ...
theorem
Order
[ "Mathlib.Control.Monad.Basic", "Mathlib.Dynamics.FixedPoints.Basic", "Mathlib.Order.CompleteLattice.Basic", "Mathlib.Order.Iterate", "Mathlib.Order.Part", "Mathlib.Order.Preorder.Chain", "Mathlib.Order.ScottContinuity" ]
Mathlib/Order/OmegaCompletePartialOrder.lean
ωSup_iterate_mem_fixedPoint
The supremum of iterating a function on x arbitrary often is a fixed point
ωSup_iterate_le_prefixedPoint (h : x ≤ f x) {a : α} (h_a : f a ≤ a) (h_x_le_a : x ≤ a) : ωSup (iterateChain f x h) ≤ a := by apply ωSup_le intro n induction n with | zero => exact h_x_le_a | succ n h_ind => have : iterateChain f x h (n.succ) = f (iterateChain f x h n) := Function.iterate_suc...
theorem
Order
[ "Mathlib.Control.Monad.Basic", "Mathlib.Dynamics.FixedPoints.Basic", "Mathlib.Order.CompleteLattice.Basic", "Mathlib.Order.Iterate", "Mathlib.Order.Part", "Mathlib.Order.Preorder.Chain", "Mathlib.Order.ScottContinuity" ]
Mathlib/Order/OmegaCompletePartialOrder.lean
ωSup_iterate_le_prefixedPoint
The supremum of iterating a function on x arbitrary often is smaller than any prefixed point. A prefixed point is a value `a` with `f a ≤ a`.
ωSup_iterate_le_fixedPoint (h : x ≤ f x) {a : α} (h_a : a ∈ fixedPoints f) (h_x_le_a : x ≤ a) : ωSup (iterateChain f x h) ≤ a := by rw [mem_fixedPoints] at h_a obtain h_a := Eq.le h_a exact ωSup_iterate_le_prefixedPoint f x h h_a h_x_le_a
theorem
Order
[ "Mathlib.Control.Monad.Basic", "Mathlib.Dynamics.FixedPoints.Basic", "Mathlib.Order.CompleteLattice.Basic", "Mathlib.Order.Iterate", "Mathlib.Order.Part", "Mathlib.Order.Preorder.Chain", "Mathlib.Order.ScottContinuity" ]
Mathlib/Order/OmegaCompletePartialOrder.lean
ωSup_iterate_le_fixedPoint
The supremum of iterating a function on x arbitrary often is smaller than any fixed point.
LeftOrdContinuous [Preorder α] [Preorder β] (f : α → β) := ∀ ⦃s : Set α⦄ ⦃x⦄, IsLUB s x → IsLUB (f '' s) (f x)
def
Order
[ "Mathlib.Order.ConditionallyCompleteLattice.Basic", "Mathlib.Order.RelIso.Basic" ]
Mathlib/Order/OrdContinuous.lean
LeftOrdContinuous
A function `f` between preorders is left order continuous if it preserves all suprema. We define it using `IsLUB` instead of `sSup` so that the proof works both for complete lattices and conditionally complete lattices.
RightOrdContinuous [Preorder α] [Preorder β] (f : α → β) := ∀ ⦃s : Set α⦄ ⦃x⦄, IsGLB s x → IsGLB (f '' s) (f x)
def
Order
[ "Mathlib.Order.ConditionallyCompleteLattice.Basic", "Mathlib.Order.RelIso.Basic" ]
Mathlib/Order/OrdContinuous.lean
RightOrdContinuous
A function `f` between preorders is right order continuous if it preserves all infima. We define it using `IsGLB` instead of `sInf` so that the proof works both for complete lattices and conditionally complete lattices.
protected id : LeftOrdContinuous (id : α → α) := fun s x h => by simpa only [image_id] using h variable {α}
theorem
Order
[ "Mathlib.Order.ConditionallyCompleteLattice.Basic", "Mathlib.Order.RelIso.Basic" ]
Mathlib/Order/OrdContinuous.lean
id
null
protected rightOrdContinuous_dual : LeftOrdContinuous f → RightOrdContinuous (toDual ∘ f ∘ ofDual) := id @[deprecated (since := "2025-04-08")] protected alias order_dual := LeftOrdContinuous.rightOrdContinuous_dual
theorem
Order
[ "Mathlib.Order.ConditionallyCompleteLattice.Basic", "Mathlib.Order.RelIso.Basic" ]
Mathlib/Order/OrdContinuous.lean
rightOrdContinuous_dual
null
map_isGreatest (hf : LeftOrdContinuous f) {s : Set α} {x : α} (h : IsGreatest s x) : IsGreatest (f '' s) (f x) := ⟨mem_image_of_mem f h.1, (hf h.isLUB).1⟩
theorem
Order
[ "Mathlib.Order.ConditionallyCompleteLattice.Basic", "Mathlib.Order.RelIso.Basic" ]
Mathlib/Order/OrdContinuous.lean
map_isGreatest
null
mono (hf : LeftOrdContinuous f) : Monotone f := fun a₁ a₂ h => have : IsGreatest {a₁, a₂} a₂ := ⟨Or.inr rfl, by simp [*]⟩ (hf.map_isGreatest this).2 <| mem_image_of_mem _ (Or.inl rfl)
theorem
Order
[ "Mathlib.Order.ConditionallyCompleteLattice.Basic", "Mathlib.Order.RelIso.Basic" ]
Mathlib/Order/OrdContinuous.lean
mono
null
comp (hg : LeftOrdContinuous g) (hf : LeftOrdContinuous f) : LeftOrdContinuous (g ∘ f) := fun s x h => by simpa only [image_image] using hg (hf h)
theorem
Order
[ "Mathlib.Order.ConditionallyCompleteLattice.Basic", "Mathlib.Order.RelIso.Basic" ]
Mathlib/Order/OrdContinuous.lean
comp
null
protected iterate {f : α → α} (hf : LeftOrdContinuous f) (n : ℕ) : LeftOrdContinuous f^[n] := match n with | 0 => LeftOrdContinuous.id α | (n + 1) => (LeftOrdContinuous.iterate hf n).comp hf
theorem
Order
[ "Mathlib.Order.ConditionallyCompleteLattice.Basic", "Mathlib.Order.RelIso.Basic" ]
Mathlib/Order/OrdContinuous.lean
iterate
null
map_sup (hf : LeftOrdContinuous f) (x y : α) : f (x ⊔ y) = f x ⊔ f y := (hf isLUB_pair).unique <| by simp only [image_pair, isLUB_pair]
theorem
Order
[ "Mathlib.Order.ConditionallyCompleteLattice.Basic", "Mathlib.Order.RelIso.Basic" ]
Mathlib/Order/OrdContinuous.lean
map_sup
null
le_iff (hf : LeftOrdContinuous f) (h : Injective f) {x y} : f x ≤ f y ↔ x ≤ y := by simp only [← sup_eq_right, ← hf.map_sup, h.eq_iff]
theorem
Order
[ "Mathlib.Order.ConditionallyCompleteLattice.Basic", "Mathlib.Order.RelIso.Basic" ]
Mathlib/Order/OrdContinuous.lean
le_iff
null
lt_iff (hf : LeftOrdContinuous f) (h : Injective f) {x y} : f x < f y ↔ x < y := by simp only [lt_iff_le_not_ge, hf.le_iff h] variable (f)
theorem
Order
[ "Mathlib.Order.ConditionallyCompleteLattice.Basic", "Mathlib.Order.RelIso.Basic" ]
Mathlib/Order/OrdContinuous.lean
lt_iff
null
toOrderEmbedding (hf : LeftOrdContinuous f) (h : Injective f) : α ↪o β := ⟨⟨f, h⟩, hf.le_iff h⟩ variable {f} @[simp]
def
Order
[ "Mathlib.Order.ConditionallyCompleteLattice.Basic", "Mathlib.Order.RelIso.Basic" ]
Mathlib/Order/OrdContinuous.lean
toOrderEmbedding
Convert an injective left order continuous function to an order embedding.
coe_toOrderEmbedding (hf : LeftOrdContinuous f) (h : Injective f) : ⇑(hf.toOrderEmbedding f h) = f := rfl
theorem
Order
[ "Mathlib.Order.ConditionallyCompleteLattice.Basic", "Mathlib.Order.RelIso.Basic" ]
Mathlib/Order/OrdContinuous.lean
coe_toOrderEmbedding
null
map_sSup' (hf : LeftOrdContinuous f) (s : Set α) : f (sSup s) = sSup (f '' s) := (hf <| isLUB_sSup s).sSup_eq.symm
theorem
Order
[ "Mathlib.Order.ConditionallyCompleteLattice.Basic", "Mathlib.Order.RelIso.Basic" ]
Mathlib/Order/OrdContinuous.lean
map_sSup'
null
map_sSup (hf : LeftOrdContinuous f) (s : Set α) : f (sSup s) = ⨆ x ∈ s, f x := by rw [hf.map_sSup', sSup_image]
theorem
Order
[ "Mathlib.Order.ConditionallyCompleteLattice.Basic", "Mathlib.Order.RelIso.Basic" ]
Mathlib/Order/OrdContinuous.lean
map_sSup
null
map_iSup (hf : LeftOrdContinuous f) (g : ι → α) : f (⨆ i, g i) = ⨆ i, f (g i) := by simp only [iSup, hf.map_sSup', ← range_comp] rfl
theorem
Order
[ "Mathlib.Order.ConditionallyCompleteLattice.Basic", "Mathlib.Order.RelIso.Basic" ]
Mathlib/Order/OrdContinuous.lean
map_iSup
null
map_csSup (hf : LeftOrdContinuous f) {s : Set α} (sne : s.Nonempty) (sbdd : BddAbove s) : f (sSup s) = sSup (f '' s) := ((hf <| isLUB_csSup sne sbdd).csSup_eq <| sne.image f).symm
theorem
Order
[ "Mathlib.Order.ConditionallyCompleteLattice.Basic", "Mathlib.Order.RelIso.Basic" ]
Mathlib/Order/OrdContinuous.lean
map_csSup
null
map_ciSup (hf : LeftOrdContinuous f) {g : ι → α} (hg : BddAbove (range g)) : f (⨆ i, g i) = ⨆ i, f (g i) := by simp only [iSup, hf.map_csSup (range_nonempty _) hg, ← range_comp] rfl
theorem
Order
[ "Mathlib.Order.ConditionallyCompleteLattice.Basic", "Mathlib.Order.RelIso.Basic" ]
Mathlib/Order/OrdContinuous.lean
map_ciSup
null
protected id : RightOrdContinuous (id : α → α) := fun s x h => by simpa only [image_id] using h variable {α}
theorem
Order
[ "Mathlib.Order.ConditionallyCompleteLattice.Basic", "Mathlib.Order.RelIso.Basic" ]
Mathlib/Order/OrdContinuous.lean
id
null
protected orderDual : RightOrdContinuous f → LeftOrdContinuous (toDual ∘ f ∘ ofDual) := id
theorem
Order
[ "Mathlib.Order.ConditionallyCompleteLattice.Basic", "Mathlib.Order.RelIso.Basic" ]
Mathlib/Order/OrdContinuous.lean
orderDual
null
map_isLeast (hf : RightOrdContinuous f) {s : Set α} {x : α} (h : IsLeast s x) : IsLeast (f '' s) (f x) := hf.orderDual.map_isGreatest h
theorem
Order
[ "Mathlib.Order.ConditionallyCompleteLattice.Basic", "Mathlib.Order.RelIso.Basic" ]
Mathlib/Order/OrdContinuous.lean
map_isLeast
null
mono (hf : RightOrdContinuous f) : Monotone f := hf.orderDual.mono.dual
theorem
Order
[ "Mathlib.Order.ConditionallyCompleteLattice.Basic", "Mathlib.Order.RelIso.Basic" ]
Mathlib/Order/OrdContinuous.lean
mono
null
comp (hg : RightOrdContinuous g) (hf : RightOrdContinuous f) : RightOrdContinuous (g ∘ f) := hg.orderDual.comp hf.orderDual
theorem
Order
[ "Mathlib.Order.ConditionallyCompleteLattice.Basic", "Mathlib.Order.RelIso.Basic" ]
Mathlib/Order/OrdContinuous.lean
comp
null
protected iterate {f : α → α} (hf : RightOrdContinuous f) (n : ℕ) : RightOrdContinuous f^[n] := hf.orderDual.iterate n
theorem
Order
[ "Mathlib.Order.ConditionallyCompleteLattice.Basic", "Mathlib.Order.RelIso.Basic" ]
Mathlib/Order/OrdContinuous.lean
iterate
null
map_inf (hf : RightOrdContinuous f) (x y : α) : f (x ⊓ y) = f x ⊓ f y := hf.orderDual.map_sup x y
theorem
Order
[ "Mathlib.Order.ConditionallyCompleteLattice.Basic", "Mathlib.Order.RelIso.Basic" ]
Mathlib/Order/OrdContinuous.lean
map_inf
null
le_iff (hf : RightOrdContinuous f) (h : Injective f) {x y} : f x ≤ f y ↔ x ≤ y := hf.orderDual.le_iff h
theorem
Order
[ "Mathlib.Order.ConditionallyCompleteLattice.Basic", "Mathlib.Order.RelIso.Basic" ]
Mathlib/Order/OrdContinuous.lean
le_iff
null
lt_iff (hf : RightOrdContinuous f) (h : Injective f) {x y} : f x < f y ↔ x < y := hf.orderDual.lt_iff h variable (f)
theorem
Order
[ "Mathlib.Order.ConditionallyCompleteLattice.Basic", "Mathlib.Order.RelIso.Basic" ]
Mathlib/Order/OrdContinuous.lean
lt_iff
null
toOrderEmbedding (hf : RightOrdContinuous f) (h : Injective f) : α ↪o β := ⟨⟨f, h⟩, hf.le_iff h⟩ variable {f} @[simp]
def
Order
[ "Mathlib.Order.ConditionallyCompleteLattice.Basic", "Mathlib.Order.RelIso.Basic" ]
Mathlib/Order/OrdContinuous.lean
toOrderEmbedding
Convert an injective left order continuous function to an `OrderEmbedding`.
coe_toOrderEmbedding (hf : RightOrdContinuous f) (h : Injective f) : ⇑(hf.toOrderEmbedding f h) = f := rfl
theorem
Order
[ "Mathlib.Order.ConditionallyCompleteLattice.Basic", "Mathlib.Order.RelIso.Basic" ]
Mathlib/Order/OrdContinuous.lean
coe_toOrderEmbedding
null
map_sInf' (hf : RightOrdContinuous f) (s : Set α) : f (sInf s) = sInf (f '' s) := hf.orderDual.map_sSup' s
theorem
Order
[ "Mathlib.Order.ConditionallyCompleteLattice.Basic", "Mathlib.Order.RelIso.Basic" ]
Mathlib/Order/OrdContinuous.lean
map_sInf'
null
map_sInf (hf : RightOrdContinuous f) (s : Set α) : f (sInf s) = ⨅ x ∈ s, f x := hf.orderDual.map_sSup s
theorem
Order
[ "Mathlib.Order.ConditionallyCompleteLattice.Basic", "Mathlib.Order.RelIso.Basic" ]
Mathlib/Order/OrdContinuous.lean
map_sInf
null
map_iInf (hf : RightOrdContinuous f) (g : ι → α) : f (⨅ i, g i) = ⨅ i, f (g i) := hf.orderDual.map_iSup g
theorem
Order
[ "Mathlib.Order.ConditionallyCompleteLattice.Basic", "Mathlib.Order.RelIso.Basic" ]
Mathlib/Order/OrdContinuous.lean
map_iInf
null
map_csInf (hf : RightOrdContinuous f) {s : Set α} (sne : s.Nonempty) (sbdd : BddBelow s) : f (sInf s) = sInf (f '' s) := hf.orderDual.map_csSup sne sbdd
theorem
Order
[ "Mathlib.Order.ConditionallyCompleteLattice.Basic", "Mathlib.Order.RelIso.Basic" ]
Mathlib/Order/OrdContinuous.lean
map_csInf
null
map_ciInf (hf : RightOrdContinuous f) {g : ι → α} (hg : BddBelow (range g)) : f (⨅ i, g i) = ⨅ i, f (g i) := hf.orderDual.map_ciSup hg
theorem
Order
[ "Mathlib.Order.ConditionallyCompleteLattice.Basic", "Mathlib.Order.RelIso.Basic" ]
Mathlib/Order/OrdContinuous.lean
map_ciInf
null
leftOrdContinuous (gc : GaloisConnection f g) : LeftOrdContinuous f := fun _ _ ↦ gc.isLUB_l_image
lemma
Order
[ "Mathlib.Order.ConditionallyCompleteLattice.Basic", "Mathlib.Order.RelIso.Basic" ]
Mathlib/Order/OrdContinuous.lean
leftOrdContinuous
A left adjoint in a Galois connection is left-continuous in the order-theoretic sense.
rightOrdContinuous (gc : GaloisConnection f g) : RightOrdContinuous g := fun _ _ ↦ gc.isGLB_u_image
lemma
Order
[ "Mathlib.Order.ConditionallyCompleteLattice.Basic", "Mathlib.Order.RelIso.Basic" ]
Mathlib/Order/OrdContinuous.lean
rightOrdContinuous
A right adjoint in a Galois connection is right-continuous in the order-theoretic sense.
protected leftOrdContinuous : LeftOrdContinuous e := e.to_galoisConnection.leftOrdContinuous
lemma
Order
[ "Mathlib.Order.ConditionallyCompleteLattice.Basic", "Mathlib.Order.RelIso.Basic" ]
Mathlib/Order/OrdContinuous.lean
leftOrdContinuous
null
protected rightOrdContinuous : RightOrdContinuous e := e.symm.to_galoisConnection.rightOrdContinuous
lemma
Order
[ "Mathlib.Order.ConditionallyCompleteLattice.Basic", "Mathlib.Order.RelIso.Basic" ]
Mathlib/Order/OrdContinuous.lean
rightOrdContinuous
null
natLT (f : ℕ → α) (H : ∀ n : ℕ, r (f n) (f (n + 1))) : ((· < ·) : ℕ → ℕ → Prop) ↪r r := ofMonotone f <| Nat.rel_of_forall_rel_succ_of_lt r H @[simp]
def
Order
[ "Mathlib.Data.Nat.Lattice", "Mathlib.Logic.Denumerable", "Mathlib.Logic.Function.Iterate", "Mathlib.Order.Hom.Basic", "Mathlib.Data.Set.Subsingleton" ]
Mathlib/Order/OrderIsoNat.lean
natLT
If `f` is a strictly `r`-increasing sequence, then this returns `f` as an order embedding.
coe_natLT {f : ℕ → α} {H : ∀ n : ℕ, r (f n) (f (n + 1))} : ⇑(natLT f H) = f := rfl
theorem
Order
[ "Mathlib.Data.Nat.Lattice", "Mathlib.Logic.Denumerable", "Mathlib.Logic.Function.Iterate", "Mathlib.Order.Hom.Basic", "Mathlib.Data.Set.Subsingleton" ]
Mathlib/Order/OrderIsoNat.lean
coe_natLT
null
natGT (f : ℕ → α) (H : ∀ n : ℕ, r (f (n + 1)) (f n)) : ((· > ·) : ℕ → ℕ → Prop) ↪r r := haveI := IsStrictOrder.swap r RelEmbedding.swap (natLT f H) @[simp]
def
Order
[ "Mathlib.Data.Nat.Lattice", "Mathlib.Logic.Denumerable", "Mathlib.Logic.Function.Iterate", "Mathlib.Order.Hom.Basic", "Mathlib.Data.Set.Subsingleton" ]
Mathlib/Order/OrderIsoNat.lean
natGT
If `f` is a strictly `r`-decreasing sequence, then this returns `f` as an order embedding.
coe_natGT {f : ℕ → α} {H : ∀ n : ℕ, r (f (n + 1)) (f n)} : ⇑(natGT f H) = f := rfl @[deprecated (since := "2025-08-08")] alias exists_not_acc_lt_of_not_acc := exists_not_acc_lt_of_not_acc
theorem
Order
[ "Mathlib.Data.Nat.Lattice", "Mathlib.Logic.Denumerable", "Mathlib.Logic.Function.Iterate", "Mathlib.Order.Hom.Basic", "Mathlib.Data.Set.Subsingleton" ]
Mathlib/Order/OrderIsoNat.lean
coe_natGT
null
acc_iff_isEmpty_subtype_mem_range {x} : Acc r x ↔ IsEmpty { f : ((· > ·) : ℕ → ℕ → Prop) ↪r r // x ∈ Set.range f } where mp acc := .mk fun ⟨f, k, hk⟩ ↦ not_acc_iff_exists_descending_chain.mpr ⟨(f <| k + ·), hk, fun _n ↦ f.map_rel_iff.2 (Nat.lt_succ_self _)⟩ acc mpr h := of_not_not fun nacc ↦ have ⟨f, hf...
theorem
Order
[ "Mathlib.Data.Nat.Lattice", "Mathlib.Logic.Denumerable", "Mathlib.Logic.Function.Iterate", "Mathlib.Order.Hom.Basic", "Mathlib.Data.Set.Subsingleton" ]
Mathlib/Order/OrderIsoNat.lean
acc_iff_isEmpty_subtype_mem_range
A value is accessible iff it isn't contained in any infinite decreasing sequence.
not_acc (f : ((· > ·) : ℕ → ℕ → Prop) ↪r r) (k : ℕ) : ¬Acc r (f k) := by rw [acc_iff_isEmpty_subtype_mem_range, not_isEmpty_iff] exact ⟨⟨f, k, rfl⟩⟩
theorem
Order
[ "Mathlib.Data.Nat.Lattice", "Mathlib.Logic.Denumerable", "Mathlib.Logic.Function.Iterate", "Mathlib.Order.Hom.Basic", "Mathlib.Data.Set.Subsingleton" ]
Mathlib/Order/OrderIsoNat.lean
not_acc
null
wellFounded_iff_isEmpty : WellFounded r ↔ IsEmpty (((· > ·) : ℕ → ℕ → Prop) ↪r r) where mp := fun ⟨h⟩ ↦ ⟨fun f ↦ f.not_acc 0 (h _)⟩ mpr _ := ⟨fun _x ↦ acc_iff_isEmpty_subtype_mem_range.2 inferInstance⟩
theorem
Order
[ "Mathlib.Data.Nat.Lattice", "Mathlib.Logic.Denumerable", "Mathlib.Logic.Function.Iterate", "Mathlib.Order.Hom.Basic", "Mathlib.Data.Set.Subsingleton" ]
Mathlib/Order/OrderIsoNat.lean
wellFounded_iff_isEmpty
A strict order relation is well-founded iff it doesn't have any infinite descending chain. See `wellFounded_iff_isEmpty_descending_chain` for a version which works on any relation.
not_wellFounded (f : ((· > ·) : ℕ → ℕ → Prop) ↪r r) : ¬WellFounded r := by rw [wellFounded_iff_isEmpty, not_isEmpty_iff] exact ⟨f⟩ @[deprecated (since := "2025-08-10")] alias acc_iff_no_decreasing_seq := acc_iff_isEmpty_subtype_mem_range @[deprecated (since := "2025-08-10")] alias not_acc_of_decreasing_seq := not_a...
theorem
Order
[ "Mathlib.Data.Nat.Lattice", "Mathlib.Logic.Denumerable", "Mathlib.Logic.Function.Iterate", "Mathlib.Order.Hom.Basic", "Mathlib.Data.Set.Subsingleton" ]
Mathlib/Order/OrderIsoNat.lean
not_wellFounded
null
not_strictAnti_of_wellFoundedLT [Preorder α] [WellFoundedLT α] (f : ℕ → α) : ¬ StrictAnti f := fun hf ↦ (RelEmbedding.natGT f (fun n ↦ hf (by simp))).not_wellFounded wellFounded_lt
theorem
Order
[ "Mathlib.Data.Nat.Lattice", "Mathlib.Logic.Denumerable", "Mathlib.Logic.Function.Iterate", "Mathlib.Order.Hom.Basic", "Mathlib.Data.Set.Subsingleton" ]
Mathlib/Order/OrderIsoNat.lean
not_strictAnti_of_wellFoundedLT
null
not_strictMono_of_wellFoundedGT [Preorder α] [WellFoundedGT α] (f : ℕ → α) : ¬ StrictMono f := not_strictAnti_of_wellFoundedLT (α := αᵒᵈ) f
theorem
Order
[ "Mathlib.Data.Nat.Lattice", "Mathlib.Logic.Denumerable", "Mathlib.Logic.Function.Iterate", "Mathlib.Order.Hom.Basic", "Mathlib.Data.Set.Subsingleton" ]
Mathlib/Order/OrderIsoNat.lean
not_strictMono_of_wellFoundedGT
null
orderEmbeddingOfSet [DecidablePred (· ∈ s)] : ℕ ↪o ℕ := (RelEmbedding.orderEmbeddingOfLTEmbedding (RelEmbedding.natLT (Nat.Subtype.ofNat s) fun _ => Nat.Subtype.lt_succ_self _)).trans (OrderEmbedding.subtype s)
def
Order
[ "Mathlib.Data.Nat.Lattice", "Mathlib.Logic.Denumerable", "Mathlib.Logic.Function.Iterate", "Mathlib.Order.Hom.Basic", "Mathlib.Data.Set.Subsingleton" ]
Mathlib/Order/OrderIsoNat.lean
orderEmbeddingOfSet
An order embedding from `ℕ` to itself with a specified range
noncomputable Subtype.orderIsoOfNat : ℕ ≃o s := by classical exact RelIso.ofSurjective (RelEmbedding.orderEmbeddingOfLTEmbedding (RelEmbedding.natLT (Nat.Subtype.ofNat s) fun n => Nat.Subtype.lt_succ_self _)) Nat.Subtype.ofNat_surjective variable {s} @[simp]
def
Order
[ "Mathlib.Data.Nat.Lattice", "Mathlib.Logic.Denumerable", "Mathlib.Logic.Function.Iterate", "Mathlib.Order.Hom.Basic", "Mathlib.Data.Set.Subsingleton" ]
Mathlib/Order/OrderIsoNat.lean
Subtype.orderIsoOfNat
`Nat.Subtype.ofNat` as an order isomorphism between `ℕ` and an infinite subset. See also `Nat.Nth` for a version where the subset may be finite.
coe_orderEmbeddingOfSet [DecidablePred (· ∈ s)] : ⇑(orderEmbeddingOfSet s) = (↑) ∘ Subtype.ofNat s := rfl
theorem
Order
[ "Mathlib.Data.Nat.Lattice", "Mathlib.Logic.Denumerable", "Mathlib.Logic.Function.Iterate", "Mathlib.Order.Hom.Basic", "Mathlib.Data.Set.Subsingleton" ]
Mathlib/Order/OrderIsoNat.lean
coe_orderEmbeddingOfSet
null
orderEmbeddingOfSet_apply [DecidablePred (· ∈ s)] {n : ℕ} : orderEmbeddingOfSet s n = Subtype.ofNat s n := rfl @[simp]
theorem
Order
[ "Mathlib.Data.Nat.Lattice", "Mathlib.Logic.Denumerable", "Mathlib.Logic.Function.Iterate", "Mathlib.Order.Hom.Basic", "Mathlib.Data.Set.Subsingleton" ]
Mathlib/Order/OrderIsoNat.lean
orderEmbeddingOfSet_apply
null
Subtype.orderIsoOfNat_apply [dP : DecidablePred (· ∈ s)] {n : ℕ} : Subtype.orderIsoOfNat s n = Subtype.ofNat s n := by simp [orderIsoOfNat]; congr! variable (s)
theorem
Order
[ "Mathlib.Data.Nat.Lattice", "Mathlib.Logic.Denumerable", "Mathlib.Logic.Function.Iterate", "Mathlib.Order.Hom.Basic", "Mathlib.Data.Set.Subsingleton" ]
Mathlib/Order/OrderIsoNat.lean
Subtype.orderIsoOfNat_apply
null
orderEmbeddingOfSet_range [DecidablePred (· ∈ s)] : Set.range (Nat.orderEmbeddingOfSet s) = s := Subtype.coe_comp_ofNat_range
theorem
Order
[ "Mathlib.Data.Nat.Lattice", "Mathlib.Logic.Denumerable", "Mathlib.Logic.Function.Iterate", "Mathlib.Order.Hom.Basic", "Mathlib.Data.Set.Subsingleton" ]
Mathlib/Order/OrderIsoNat.lean
orderEmbeddingOfSet_range
null
exists_subseq_of_forall_mem_union {s t : Set α} (e : ℕ → α) (he : ∀ n, e n ∈ s ∪ t) : ∃ g : ℕ ↪o ℕ, (∀ n, e (g n) ∈ s) ∨ ∀ n, e (g n) ∈ t := by classical have : Infinite (e ⁻¹' s) ∨ Infinite (e ⁻¹' t) := by simp only [Set.infinite_coe_iff, ← Set.infinite_union, ← Set.preimage_union, Set.eq_univ_...
theorem
Order
[ "Mathlib.Data.Nat.Lattice", "Mathlib.Logic.Denumerable", "Mathlib.Logic.Function.Iterate", "Mathlib.Order.Hom.Basic", "Mathlib.Data.Set.Subsingleton" ]
Mathlib/Order/OrderIsoNat.lean
exists_subseq_of_forall_mem_union
null
exists_increasing_or_nonincreasing_subseq' (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)) := by classical let bad : Set ℕ := { m | ∀ n, m < n → ¬r (f m) (f n) } by_cases hbad : Infinite bad · refine ⟨Nat.orderEmbe...
theorem
Order
[ "Mathlib.Data.Nat.Lattice", "Mathlib.Logic.Denumerable", "Mathlib.Logic.Function.Iterate", "Mathlib.Order.Hom.Basic", "Mathlib.Data.Set.Subsingleton" ]
Mathlib/Order/OrderIsoNat.lean
exists_increasing_or_nonincreasing_subseq'
null
exists_increasing_or_nonincreasing_subseq (r : α → α → Prop) [IsTrans α 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)) := by obtain ⟨g, hr | hnr⟩ := exists_increasing_or_nonincreasing_subseq' r f · refine ⟨g, Or.intro_left _ fun m n mn...
theorem
Order
[ "Mathlib.Data.Nat.Lattice", "Mathlib.Logic.Denumerable", "Mathlib.Logic.Function.Iterate", "Mathlib.Order.Hom.Basic", "Mathlib.Data.Set.Subsingleton" ]
Mathlib/Order/OrderIsoNat.lean
exists_increasing_or_nonincreasing_subseq
This is the infinitary Erdős–Szekeres theorem, and an important lemma in the usual proof of Bolzano-Weierstrass for `ℝ`.
wellFoundedGT_iff_monotone_chain_condition' [Preorder α] : WellFoundedGT α ↔ ∀ a : ℕ →o α, ∃ n, ∀ m, n ≤ m → ¬a n < a m := by refine ⟨fun h a => ?_, fun h => ?_⟩ · obtain ⟨x, ⟨n, rfl⟩, H⟩ := h.wf.has_min _ (Set.range_nonempty a) exact ⟨n, fun m _ => H _ (Set.mem_range_self _)⟩ · rw [WellFoundedGT, isWellF...
theorem
Order
[ "Mathlib.Data.Nat.Lattice", "Mathlib.Logic.Denumerable", "Mathlib.Logic.Function.Iterate", "Mathlib.Order.Hom.Basic", "Mathlib.Data.Set.Subsingleton" ]
Mathlib/Order/OrderIsoNat.lean
wellFoundedGT_iff_monotone_chain_condition'
The **monotone chain condition**: a preorder is co-well-founded iff every increasing sequence contains two non-increasing indices. See `wellFoundedGT_iff_monotone_chain_condition` for a stronger version on partial orders.
WellFoundedGT.monotone_chain_condition' [Preorder α] [h : WellFoundedGT α] (a : ℕ →o α) : ∃ n, ∀ m, n ≤ m → ¬a n < a m := wellFoundedGT_iff_monotone_chain_condition'.1 h a
theorem
Order
[ "Mathlib.Data.Nat.Lattice", "Mathlib.Logic.Denumerable", "Mathlib.Logic.Function.Iterate", "Mathlib.Order.Hom.Basic", "Mathlib.Data.Set.Subsingleton" ]
Mathlib/Order/OrderIsoNat.lean
WellFoundedGT.monotone_chain_condition'
null
wellFoundedGT_iff_monotone_chain_condition [PartialOrder α] : WellFoundedGT α ↔ ∀ a : ℕ →o α, ∃ n, ∀ m, n ≤ m → a n = a m := wellFoundedGT_iff_monotone_chain_condition'.trans <| by congrm ∀ a, ∃ n, ∀ m h, ?_ rw [lt_iff_le_and_ne] simp [a.mono h]
theorem
Order
[ "Mathlib.Data.Nat.Lattice", "Mathlib.Logic.Denumerable", "Mathlib.Logic.Function.Iterate", "Mathlib.Order.Hom.Basic", "Mathlib.Data.Set.Subsingleton" ]
Mathlib/Order/OrderIsoNat.lean
wellFoundedGT_iff_monotone_chain_condition
A stronger version of the **monotone chain** condition for partial orders. See `wellFoundedGT_iff_monotone_chain_condition'` for a version on preorders.