Suppose you are given an arbitrary order such as $w>x>y>z>a$ order. You can do renaming so that it becomes lex or similar errorsome renaming things to satisfy some of the more typical monomial orderings such as lex, glex and grevlex here. Is there any way to specify an arbitrary monomial ordering in Macaulay2?
Asked
Active
Viewed 151 times
1 Answers
0
You can use the Weights option to specify a given ordering:
i1 : R = QQ[w..z,a, MonomialOrder=>{Weights => {4,3,2,1,0}}];
i2 : toString (a+z+y+x+w)^2
o2 = w^2 + 2*w*x + x^2 + 2*w*y + 2*x*y + 2*w*z + y^2+2*x*z + 2*w*a + 2*y*z + 2*x*a + z^2+2*y*a + 2*z*a + a^2
If you want to produce a more or less arbitrary ordering, you can use Weights
together with random:
i1 : R = QQ[w..z,a, MonomialOrder=>{Weights => for i in 0..4 list random 20}];
i2 : (options R).MonomialOrder
o2 = {MonomialSize => 32 }
{Weights => {14, 15, 12, 9, 1}}
{GRevLex => {1, 1, 1, 1, 1} }
{Position => Up }
o2 : VerticalList
i3 : toString (a+z+y+x+w)^2
o3 = x^2+2*w*x+w^2+2*x*y+2*w*y+y^2+2*x*z+2*w*z+2*y*z+z^2+2*x*a+2*w*a+2*y*a+2*z*a+a^2

Aaron Dall
- 139
- 5