Monomial order in Macaulay2

138 Views Asked by At

When I define the ring to work on in Macaulay2, I would like to change the order of the variables for building the Grobner basis of ideals with respect to this new order. For instance, if set R = QQ [x_1..x_5], then how may I define the lexicographic monomial order induced by x_3<x_2<x_1<x_5<x_4?

1

There are 1 best solutions below

0
On BEST ANSWER

The default ordering of the variables is whatever order you use to write them when creating the ring.

For instance, to get the order you want, you should use

R = QQ[x_3, x_2, x_1, x_5, x_4]

Indeed, on my version of Macaualy2 we can see the desired behavior:

i1 : R = QQ[x_3, x_2, x_1, x_5, x_4]

o1 = R

o1 : PolynomialRing

i2 : x_1 + x_2 + x_4

o2 = x  + x  + x
      2    1    4

o2 : R

I'm not sure if there's a way to do this automatically, though, and a quick look through the documentation makes it look like there might not be a way to do that.


I hope this helps ^_^