# tNextMon -- give the t-lex successor of a given t-spread monomial

## Synopsis

• Usage:
tNextMon(u,t)
• Inputs:
• u, a t-spread monomial of a polynomial ring
• t, a positive integer that idenfies the t-spread contest
• Optional inputs:
• FixedMax => ..., default value false, optional boolean argument for tNextMon
• Outputs:
• , the greatest t-spread monomial less than u, with respect to lexcografic order

## Description

the function tNextMon(u,t) gives the t-lex successor of t, that is, the greatest t-spread monomial less than u with respect to $>_\mathrm{slex}.$
If FixedMax is true the function tNextMon(u,t,FixedMax=>true) gives the t-lex successor for which the maximum of the support is $\max\textrm{supp}(\texttt{u}).$
Given a $t$-spread monomial $u=x_{i_1}x_{i_2}\cdots x_{i_d}$, we define $\textrm{supp}(u)=\{i_1,i_2,\ldots, i_d\}$.

Examples:

 i1 : S=QQ[x_1..x_16] o1 = S o1 : PolynomialRing i2 : tNextMon(x_2*x_6*x_10*x_13,3) o2 = x x x x 2 6 10 14 o2 : S i3 : tNextMon(x_2*x_6*x_10*x_13,3,FixedMax=>true) o3 = x x x x 2 7 10 13 o3 : S