Zulip Chat Archive

Stream: Is there code for X?

Topic: Iteration of a function which doesn't decrease values


Daniel Weber (Aug 26 2024 at 02:57):

Is this lemma in Mathlib?

lemma le_iterate_of_forall_le {α : Type*} [Preorder α] (f : α  α)
    (hf :  x, x  f x) (x : α) (n : ) :
    x  f^[n] x := by
  induction n generalizing x
  · simp
  · trans f x
    · apply hf
    · simp only [iterate_succ, comp_apply, *]

I also need the corollary

lemma monotone_iterate_of_forall_le {α : Type*} [Preorder α] (f : α  α)
    (hf :  x, x  f x) (x : α) :
    Monotone (fun n  f^[n] x)

Yury G. Kudryashov (Aug 26 2024 at 04:11):

@loogle Monotone, Nat.iterate, "id_le"

loogle (Aug 26 2024 at 04:11):

:search: Function.monotone_iterate_of_id_le

Daniel Weber (Aug 26 2024 at 04:12):

Thanks


Last updated: May 02 2025 at 03:31 UTC