Call an index a peak if its term is strictly greater than every later term. If peaks occur beyond every index, enumerating them increasingly by recursion gives a strictly decreasing subsequence; otherwise, past the last peak each term has a later term at least as large, and recursion gives a nondecreasing subsequence. Every step picks a least index, so no choice axiom is used.
Each result cited below is universally quantified over the data in its own statement, and is applied to the data named where it is cited.
The total order on is as in Sets and Maps: Ordinary Notation §orders, which the setting The Natural Numbers and the Natural Numbers with Zero: Arithmetic, Order, Induction and Recursion of the statement carries; let be its strict relation. As in Subsequences §subsequence, carries its order , a total order whose strict relation is ; by Arithmetic and Order of the Natural Numbers §partial-order, holds if and only if or , and is transitive on . By Arithmetic and Order of the Natural Numbers §well-order and Uniqueness of Least and Greatest Elements, Properties of the Strict Order, and Trichotomy for Total Orders §least-unique, every subset of with at least one element has exactly one least element . Every choice below is of such a least element, so no axiom of choice is used. For a map , the terms of are by Basic Properties of Functions: Equality, Composition, Identity, Inverse and Restriction §composition.
Call a peak if for every with , and let
a subset of by Sets and Maps: Ordinary Notation §set-builder; every set written below is likewise a subset of by that clause. By the law of excluded middle, either for every there is with (Case 1), or there is such that no satisfies (Case 2).
Dichotomy, Case 1. For let ; it has an element by the case assumption, so exists, lies in , and satisfies . By Maps and Relations Given by Formulas §binary there is a map with . As has an element, exists. By Recursion on the Natural Numbers Starting at One §recursion, applied to the set , the element and , there is a map with and for every . Every value of lies in : , and if , then for some by Arithmetic and Order of the Natural Numbers §predecessor, so . For every , , so is strictly increasing and is a subsequence of . Since is a peak and , for every , so is strictly decreasing.
Dichotomy, Case 2. Fix such a , let and , a subset of containing . Let . Since by Arithmetic and Order of the Natural Numbers §successor and , we have , so by the case assumption. Hence there is with for which fails, that is, by Uniqueness of Least and Greatest Elements, Properties of the Strict Order, and Trichotomy for Total Orders §total-negation, the order on being total. So has an element, exists, and ; moreover gives . By Maps and Relations Given by Formulas §binary there is a map with , and by Recursion on the Natural Numbers Starting at One §recursion, applied to the set , the element and , there is a map with and for every . As , is also a map from to by Functions, Values of a Function, and Functions from One Class to Another §map. For every , and . Thus is strictly increasing, and is a subsequence of that is nondecreasing.
In Case 1 the sequence has a strictly decreasing subsequence, and in Case 2 a nondecreasing one, which proves the dichotomy clause.
Monotone. By the dichotomy clause there is a subsequence that is nondecreasing, hence monotone, or strictly decreasing. In the latter case gives by Uniqueness of Least and Greatest Elements, Properties of the Strict Order, and Trichotomy for Total Orders §strict-characterization, for every , so is nonincreasing and hence monotone by Monotone Sequences §monotone.
Loading…