|
| 1 | +/- |
| 2 | +Copyright (c) 2026 Violeta Hernández Palacios. All rights reserved. |
| 3 | +Released under Apache 2.0 license as described in the file LICENSE. |
| 4 | +Authors: Violeta Hernández Palacios |
| 5 | +-/ |
| 6 | +module |
| 7 | + |
| 8 | +public import Mathlib.Order.Filter.EventuallyConst |
| 9 | +public import Mathlib.SetTheory.Cardinal.Aleph |
| 10 | + |
| 11 | +/-! |
| 12 | +# Eventually constant monotone functions |
| 13 | +
|
| 14 | +This file proves variations of the following theorem: if `α` is a linear order and `β` is a partial |
| 15 | +order with `#β < cof α`, then any monotone function `f : α → β` must be eventually constant. In |
| 16 | +particular, this applies for functions from `Cardinal.{u}` or `Ordinal.{u}` into a `Small.{u}` type. |
| 17 | +-/ |
| 18 | + |
| 19 | +public section |
| 20 | + |
| 21 | +universe u v |
| 22 | + |
| 23 | +variable {α : Type u} {β : Type v} [LinearOrder α] [PartialOrder β] |
| 24 | + |
| 25 | +open Cardinal Filter Order Set |
| 26 | + |
| 27 | +namespace Filter.EventuallyConst |
| 28 | +variable {f : α → β} |
| 29 | + |
| 30 | +theorem of_not_isCofinal_rangeSplitting [Nonempty α] (hf : Monotone f) |
| 31 | + (hf' : ¬ IsCofinal (range (rangeSplitting f))) : atTop.EventuallyConst f := by |
| 32 | + rw [eventuallyConst_atTop] |
| 33 | + obtain ⟨i, hi⟩ := not_isCofinal_iff.1 hf' |
| 34 | + refine ⟨i, fun j hij ↦ (hf hij).antisymm' <| (hf (hi _ ⟨⟨f j, j, rfl⟩, rfl⟩).le).trans' ?_⟩ |
| 35 | + rw [apply_rangeSplitting f] |
| 36 | + |
| 37 | +theorem of_monotone_of_lt_cof (hf : Monotone f) (hα : lift.{u} #β < lift.{v} (cof α)) : |
| 38 | + atTop.EventuallyConst f := by |
| 39 | + have : Nonempty α := by by_contra!; simp at hα |
| 40 | + refine .of_not_isCofinal_rangeSplitting hf ?_ |
| 41 | + contrapose! hα |
| 42 | + classical let := hf.isChain_range.linearOrder |
| 43 | + rw [← lift_cof_congr_of_strictMono (rangeSplitting_strictMono hf) hα, lift_le] |
| 44 | + exact (cof_le_cardinalMk _).trans (mk_set_le _) |
| 45 | + |
| 46 | +theorem of_antitone_of_lt_cof (hf : Antitone f) (hα : lift.{u} #β < lift.{v} (cof α)) : |
| 47 | + atTop.EventuallyConst f := |
| 48 | + .of_monotone_of_lt_cof (β := βᵒᵈ) hf.dual_right hα |
| 49 | + |
| 50 | +end Filter.EventuallyConst |
| 51 | + |
| 52 | +namespace Cardinal |
| 53 | +variable {f : Cardinal.{v} → β} [Small.{v} β] |
| 54 | + |
| 55 | +theorem eventuallyConst_of_monotone (hf : Monotone f) : atTop.EventuallyConst f := by |
| 56 | + refine .of_monotone_of_lt_cof hf ?_ |
| 57 | + simpa [← small_iff_lift_mk_lt_univ] |
| 58 | + |
| 59 | +theorem eventuallyConst_of_antitone (hf : Antitone f) : atTop.EventuallyConst f := |
| 60 | + eventuallyConst_of_monotone (β := βᵒᵈ) hf |
| 61 | + |
| 62 | +end Cardinal |
| 63 | + |
| 64 | +namespace Ordinal |
| 65 | +variable {f : Ordinal.{v} → β} [Small.{v} β] |
| 66 | + |
| 67 | +theorem eventuallyConst_of_monotone (hf : Monotone f) : atTop.EventuallyConst f := by |
| 68 | + refine .of_monotone_of_lt_cof hf ?_ |
| 69 | + simpa [← small_iff_lift_mk_lt_univ] |
| 70 | + |
| 71 | +theorem eventuallyConst_of_antitone (hf : Antitone f) : atTop.EventuallyConst f := |
| 72 | + eventuallyConst_of_monotone (β := βᵒᵈ) hf |
| 73 | + |
| 74 | +end Ordinal |
0 commit comments