R = QQ[a..d, MonomialOrder=>GRevLex] f= 3 + 8*a^2*b + 7*b*c^2 leadTerm (3 + 8*a^2*b + 7*b*c^2) leadTerm(f) leadCoefficient f leadMonomial f g= 3 + 5*a - 8*a^2*b + 7*b*c^2 leadTerm g leadTerm(f+g) leadTerm(f*g) ---------------------------------------- R=ZZ/101[x,y, MonomialOrder=>GLex] S=ZZ/101[x,y, MonomialOrder=>GRevLex] i=ideal vars R j=ideal vars S i2=i^2 j2=j^2 leadTerm(i2) leadTerm(j2) i3=i^3 j3=j^3 leadTerm(i3) leadTerm(j3) -- There is in fact only one order in two vars that refines -- the order by degree and the convention that x > y --------------------------------------- R=ZZ/101[x,y,z, MonomialOrder=>GLex] S=ZZ/101[x,y,z, MonomialOrder=>GRevLex] i=ideal vars R j=ideal vars S i2=i^2 j2=j^2 leadTerm(i2) leadTerm(j2) -- Quadratic monomials in 3 vars in the first time -- the two orders (GLex and GRevLex) are different R=ZZ/101[a,b,c,x,y,z,MonomialOrder=>ProductOrder{3,3}] f= 3 + 8*a^2*b + 7*b*c^2 g= 3 + 8*x^2*y*z + 7*b*c^2 h= z + x leadTerm(f) leadTerm(g) leadTerm(f+g) leadTerm(f*g) leadTerm(h) leadTerm(f*h) leadTerm(f+h)