Monomial orderings are specified when defining a polynomial ring.
global orderings
The default order is the graded (degree) reverse lexicographic order.
i1 : A2 = QQ[x,y,z];
|
i2 : A2 = QQ[x,y,z,MonomialOrder=>GRevLex];
|
i3 : f = x^3*y*z+y^5+z^4+x^3+x*y^2
5 3 4 3 2
o3 = y + x y*z + z + x + x*y
o3 : A2
|
Lexicographic order.
i4 : A1 = QQ[x,y,z,MonomialOrder=>Lex];
|
i5 : substitute(f,A1)
3 3 2 5 4
o5 = x y*z + x + x*y + y + z
o5 : A1
|
Graded (degree) lexicographic order.
i6 : A3 = QQ[x,y,z,MonomialOrder=>{Weights=>{1,1,1},Lex}];
|
i7 : substitute(f,A3)
3 5 4 3 2
o7 = x y*z + y + z + x + x*y
o7 : A3
|
Graded (degree) lexicographic order, with nonstandard weights.
i8 : A4 = QQ[x,y,z,MonomialOrder=>{Weights=>{5,3,2},Lex}];
|
i9 : substitute(f,A4)
3 3 5 2 4
o9 = x y*z + x + y + x*y + z
o9 : A4
|
A product order, with each block being GRevLex.
i10 : A = QQ[x,y,z,MonomialOrder=>{1,2}];
|
i11 : substitute(f,A)
3 3 2 5 4
o11 = x y*z + x + x*y + y + z
o11 : A
|
local orderings
Negative lexicographic order.
i12 : A = QQ[x,y,z,MonomialOrder=>{Weights=>{-1,0,0},Weights=>{0,-1,0},Weights=>{0,0,-1}},Global=>false];
|
i13 : substitute(f,A)
4 5 2 3 3
o13 = z + y + x*y + x + x y*z
o13 : A
|
Negative graded reverse lexicographic order.
i14 : A = QQ[x,y,z,MonomialOrder=>{Weights=>{-1,-1,-1},GRevLex},Global=>false];
|
i15 : substitute(f,A)
3 2 4 5 3
o15 = x + x*y + z + y + x y*z
o15 : A
|