Monotonicity theorem
ProvedMonotonicity_Theorem.monotonicity_theorem2Let an o-minimal structure M be given on a dense linear order without endpoints. For a definable function f on an infinite definable interval I, and ordered endpoints a and b, there are finitely many cut points from a to b. On each intervening open interval, f is constant, or strictly increasing and continuous, or strictly decreasing and continuous, with continuity expressed by ContinuousPoints.
import Definitions.Def_Monotonicity_Theorem_Framework2
theorem Monotonicity_Theorem.monotonicity_theorem2
{R : Type} [LinearOrder R] [DenselyOrdered R] [NoMaxOrder R] [NoMinOrder R]
(M : OMinimalStructure R)
{a b : Power R 1} (hab : Lt1 a b)
(f : DefinableFunction M
(openInterval (Endpoint.finite (Power.coord1 a))
(Endpoint.finite (Power.coord1 b)))
(Set.univ : Set (Power R 1))) :
exists (k : Nat), exists (p : Fin (k + 1) -> Power R 1),
p 0 = a /\
p (Fin.last k) = b /\
(forall (i : Fin k), Lt1 (p i.castSucc) (p i.succ)) /\
(forall (i : Fin k),
let J : Set (Power R 1) :=
openInterval
(Endpoint.finite ((p i.castSucc) 0))
(Endpoint.finite ((p i.succ) 0))
(forall (x : {x : Power R 1 //
(openInterval (Endpoint.finite (Power.coord1 a))
(Endpoint.finite (Power.coord1 b))) x}),
forall (y : {y : Power R 1 //
(openInterval (Endpoint.finite (Power.coord1 a))
(Endpoint.finite (Power.coord1 b))) y}),
J x.1 -> J y.1 ->
f.toFun x = f.toFun y)
\/
((forall (x : {x : Power R 1 //
(openInterval (Endpoint.finite (Power.coord1 a))
(Endpoint.finite (Power.coord1 b))) x}),
forall (y : {y : Power R 1 //
(openInterval (Endpoint.finite (Power.coord1 a))
(Endpoint.finite (Power.coord1 b))) y}),
J x.1 -> J y.1 -> Lt1 x.1 y.1 ->
Lt1 (f.toFun x).1 (f.toFun y).1)
\/
(forall (x : {x : Power R 1 //
(openInterval (Endpoint.finite (Power.coord1 a))
(Endpoint.finite (Power.coord1 b))) x}),
forall (y : {y : Power R 1 //
(openInterval (Endpoint.finite (Power.coord1 a))
(Endpoint.finite (Power.coord1 b))) y}),
J x.1 -> J y.1 -> Lt1 x.1 y.1 ->
Lt1 (f.toFun y).1 (f.toFun x).1))
/\ J.Subset
(ContinuousPoints
(openInterval (Endpoint.finite (Power.coord1 a))
(Endpoint.finite (Power.coord1 b)))
(FunctionGraph (R := R) (m := 1) (n := 1)
(A := openInterval (Endpoint.finite (Power.coord1 a))
(Endpoint.finite (Power.coord1 b)))
(B := Set.univ)
f.toFun))) := by sorryRead-back
What the Lean code literally says, in plain math · muse-spark
Fix a type equipped with a linear order that is densely ordered and has neither a maximum nor a minimum, let be an o-minimal structure over , let and be unary tuples over with the hypothesis that is strictly less than in the strict order on unary tuples, and let be an -definable function whose domain is the open interval with finite endpoints at the single coordinates of and and whose codomain is the universal set of unary tuples over ; then the claim is that there exist a natural number and a sequence of unary tuples over such that and and each consecutive pair is strictly increasing, i.e. for every the -th term is strictly less than the -st term, and for every , writing for the open interval with finite endpoints at the -th entries of the -th and -st terms, one of the following holds: either is constant on in the sense that for all belonging to the large interval from to , if their underlying tuples lie in then the values of at and are equal, or both of the following hold jointly, namely is contained as a set in the set obtained by applying the construction to the large interval and to the set obtained by applying the construction with dimensions , domain set the large interval, codomain set the universal set, and function the underlying function of , and at least one of two order-behaviors holds on , namely either is strictly increasing on in the sense that for all in the large interval whose underlying tuples lie in , if is strictly less than then the value of at is strictly less than the value at , or is strictly decreasing on in the sense that for all such , if is strictly less than then the value at is strictly less than the value at ; in the degenerate case there is no so the requirements on consecutive pairs and on each are vacuously true while and together force , which is incompatible with the strict inequality hypothesis if that order is irreflexive, and for any with empty the implications assuming membership in are vacuously true.
Confirmed by the mission captain (proposal self-audit).