Hi Martin, What about Sage implementation for
1. weighting vector(s) "a(w1, w2...wn)", 2. free module orderings (e.g. c/C) mixed somewhere in between? Does Sage have such a concept? In Sage i'd imagine something like: {{{ TermOrder = WeightVector(2,5) + ModuleOrder('c') + WeightVector(-1,-2) + MatrixOrder(1,1,0,-1) }}} corresponding to: {{{ > ring R =0,(x, y), (a(2,5), c, a(-1,-2), M(1,1,0,-1)); R; // characteristic : 0 // number of vars : 2 // block 1 : ordering a // : names x y // : weights 2 5 // block 2 : ordering c // block 3 : ordering a // : names x y // : weights -1 -2 // block 4 : ordering M // : names x y // : weights 1 1 // : weights 0 -1 > deg(x); // note that the 1st "a"/"M"/weighted ordering is used for "deg" 2 > deg(y); 5 }}} Best regards, Oleksandr On Sep 4, 1:33 pm, Martin Albrecht <m...@informatik.uni-bremen.de> wrote: > > Currently, the ordering of a ring is determined by a string "name": > > TermOrder.__init__(self, name='lex', n = 0, blocks=True) > > respectively "order": PolynomialRing(base_ring, arg1=None, arg2=None, > > sparse=False, order='degrevlex', names=None, name=None, > > implementation=None) > > Of course, it seems natural to define a matrix ordering by passing a > > matrix: > > sage: M = Matrix(2,2, [1,3,1,0]) > > sage: R.<x,y> = PolynomialRing(QQ,2,order=M) > > > But it is perhaps not so nice to break compatibility with the current > > way of defining an ordering by strings. > > > Closer to Singular syntax would be > > sage: R.<x,y> = PolynomialRing(QQ,2,order='M(1,3,1,0)') > > Think this would be rather un-pythonic: converting an object into a string > instead of using it directly. > > > But what about block orderings? If one allows a matrix ordering to be > > defined by a matrix, then I guess the blocks should be listed: > > sage: P.<a,b,c,d,e> = PolynomialRing(QQ,5,order=[M,'degrevlex']) > > Have you seen this? > > sage: TermOrder('deglex',3) + TermOrder('degrevlex',2) > deglex(3),degrevlex(2) term order > > > Or, if one goes with strings: > > sage: P.<a,b,c,d,e> = PolynomialRing(QQ,5,order='M(1,3,1,0),degrevlex > > (3)']) > > I would like to avoid this string business as much as possible. I find it > rather ugly (that's personal taste of course) > > Cheers, > Martin > > -- > name: Martin Albrecht > _pgp:http://pgp.mit.edu:11371/pks/lookup?op=get&search=0x8EF0DC99 > _otr: 47F43D1A 5D68C36F 468BAEBA 640E8856 D7951CCF > _www:http://www.informatik.uni-bremen.de/~malb > _jab: martinralbre...@jabber.ccc.de --~--~---------~--~----~------------~-------~--~----~ To post to this group, send an email to sage-devel@googlegroups.com To unsubscribe from this group, send an email to sage-devel-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/sage-devel URLs: http://www.sagemath.org -~----------~----~----~----~------~----~------~--~---