Max - Maple Help

Ordinals

 Max
 maximum of ordinals
 Min
 minimum of ordinals

 Calling Sequence Max(a, b, ...) Min(a, b, ...)

Parameters

 a, b, ... - ordinal numbers, that is, ordinals, non-negative integers, or polynomials with positive integer coefficients, or (possibly nested) lists of ordinal numbers

Description

 • If all arguments are ordinal numbers, the Max(a, b, ...) calling sequence returns the largest of the arguments with respect to the ordering of ordinals, and the Min(a, b, ...) calling sequence returns the smallest of the arguments.
 • Any of the arguments can be a (possibly nested) list, and the argument sequence is converted into a non-nested, flat sequence of ordinal numbers first.
 • Max() returns 0, and Min() returns $\mathrm{NULL}$.
 • Parametric ordinals are accepted. If the left difference of two ordinal numbers cannot be determined in the parametric case, an error will be raised.

Examples

 > $\mathrm{with}\left(\mathrm{Ordinals}\right):$
 > $a≔\mathrm{Ordinal}\left(\left[\left[\mathrm{\omega },3\right],\left[3,5\right],\left[1,1\right],\left[0,4\right]\right]\right)$
 ${a}{≔}{{\mathbf{\omega }}}^{{\mathbf{\omega }}}{\cdot }{3}{+}{{\mathbf{\omega }}}^{{3}}{\cdot }{5}{+}{\mathbf{\omega }}{+}{4}$ (1)
 > $b≔\mathrm{Ordinal}\left(\left[\left[\mathrm{\omega },3\right],\left[3,3\right],\left[2,2\right]\right]\right)$
 ${b}{≔}{{\mathbf{\omega }}}^{{\mathbf{\omega }}}{\cdot }{3}{+}{{\mathbf{\omega }}}^{{3}}{\cdot }{3}{+}{{\mathbf{\omega }}}^{{2}}{\cdot }{2}$ (2)
 > $\mathrm{Max}\left(3,a,\mathrm{\omega },b\right)$
 ${{\mathbf{\omega }}}^{{\mathbf{\omega }}}{\cdot }{3}{+}{{\mathbf{\omega }}}^{{3}}{\cdot }{5}{+}{\mathbf{\omega }}{+}{4}$ (3)
 > $\mathrm{Min}\left(\left[3,\left[a,\mathrm{\omega }\right]\right],b\right)=\mathrm{Min}\left(3,a,\mathrm{\omega },b\right)$
 ${3}{=}{3}$ (4)
 > $\mathrm{sort}\left(\left[3,a,\mathrm{\omega },b\right],\mathrm{LessThan}\right)$
 $\left[{3}{,}{\mathbf{\omega }}{,}{{\mathbf{\omega }}}^{{\mathbf{\omega }}}{\cdot }{3}{+}{{\mathbf{\omega }}}^{{3}}{\cdot }{3}{+}{{\mathbf{\omega }}}^{{2}}{\cdot }{2}{,}{{\mathbf{\omega }}}^{{\mathbf{\omega }}}{\cdot }{3}{+}{{\mathbf{\omega }}}^{{3}}{\cdot }{5}{+}{\mathbf{\omega }}{+}{4}\right]$ (5)
 > $\mathrm{Max}\left(\left[\right]\right)$
 ${0}$ (6)

Parametric examples.

 > $c≔\mathrm{Ordinal}\left(\left[\left[1,x\right],\left[0,2\right]\right]\right)$
 ${c}{≔}{\mathbf{\omega }}{\cdot }{x}{+}{2}$ (7)
 > $\mathrm{Max}\left(b,3,c\right)$
 ${{\mathbf{\omega }}}^{{\mathbf{\omega }}}{\cdot }{3}{+}{{\mathbf{\omega }}}^{{3}}{\cdot }{3}{+}{{\mathbf{\omega }}}^{{2}}{\cdot }{2}$ (8)
 > $\mathrm{Min}\left(b,3,c\right)$
 > $\mathrm{Min}\left(b,3,\mathrm{Eval}\left(c,x=x+1\right)\right)$
 ${3}$ (9)
 > $\mathrm{Max}\left(\mathrm{Eval}\left(c,x=x+1\right),\mathrm{Eval}\left(c,x={x}^{2}+1\right)\right)$

Compatibility

 • The Ordinals[Max] and Ordinals[Min] commands were introduced in Maple 2015.
 • For more information on Maple 2015 changes, see Updates in Maple 2015.