Argmax of a List under a Total Preorder
For a function f : α → β valued in a TotalPreorder β and a non-empty
list head :: tail : List α, some element of the list maximizes f:
$$
\exists m \in \operatorname{head} :: \operatorname{tail},\;
\forall x \in \operatorname{head} :: \operatorname{tail},\; f(x) \le f(m).
$$
The proof is by induction on tail, comparing the current maximum against
the new head via TotalPreorder.le_total.
From the existence statement a noncomputable choice
List.argMaxOn f head tail picks a witnessing maximizer. Its API:
argMaxOn_mem-- the chosen element lies in the list.argMaxOn_ge-- the chosen element is≥every list element inf-value.le_argMaxOn_head-- specialization: the head's value is≤the chosen element's value.
The variant exists because Mathlib's List.argmax is computable but requires
[LinearOrder], which is too strong for ranking outcomes that may be
indifferent (the typical situation when a player's payoffs are equal across
distinct continuations). The intended consumer is
ExtensiveGame.BackwardInduction, where finite game trees are evaluated by
recursively picking an argmax of children.
References
- [MSZ, Chapter 3] Maschler, Solan, and Zamir, Game Theory. Backward induction on finite extensive games.