## Feature #78

### Elim ordering and matrix ordering

**Description**

in cocoa-4 we had an easy way to use an elimination ordering:

MyRing ::= QQ[x[1..N], t], Elim(t);

and to define a matrix ordering

MyRing ::= QQ[x[1..N], t], Ord(M);

This is not currently allowed in CoCoA-5 because we are still working on the ring interface and we fear there could be ambiguities allowing "(" in a ring definition. (one should use **NewPolyRing** instead)

Even though it is quite clear how to make an elimination ordering (matrix), the construction seems quite tedious and verbose.

This "issue" is to make a decision about allowing "Elim(..)" in a ring definition or to propose "the right way" to construct an elimination matrix.

**Related issues**

### History

#### #1 Updated by Anna Maria Bigatti about 6 years ago

**Subject**changed from*Elim ordering*to*Elim ordering and matrix ordering***% Done**changed from*0*to*10*

#### #2 Updated by Anna Maria Bigatti over 5 years ago

**CompleteToOrd** gives a non-term-ordering if there are 0's in the given row.

I think it's easy to fix (in cocoalib). I'll do it.

[done: 23-nov-2012]

#### #3 Updated by Anna Maria Bigatti about 5 years ago

added **HomogElimMat** and **ElimMat**, and documented.

Remark: JAA says that in the "::=" ring contructor we should have no problems having "(" after the comma, so we could make a syntax similar to cocoa-4 `, Elim(..);`

, but with indices instead of indets.

#### #4 Updated by John Abbott about 4 years ago

**Status**changed from*New*to*In Progress***Priority**changed from*Normal*to*High*

In issue #313 I have posted an impl of `ElimOrdMat`

which creates a matrix for elimination orderings. This fn lets one create elim order matrices easily -- JAA could simply **put this in some C5 package!**

It would be handy to have the `, Ord(...)`

syntax working; the current solution for creating poly rings with orders defined by matrices is unpleasantly cumbersome. Any chance of having this working before next term?

#### #5 Updated by John Abbott about 4 years ago

**% Done**changed from*10*to*50*

Just an idea... it might be nice if the matrix created contained only non-negative entries (*e.g.* it is easy to have a non-neg matrix for degrevlex).

If I recall well, CoCoALib always arranges for the internal matrix to be non-negative.

What do you think?

#### #6 Updated by Anna Maria Bigatti about 4 years ago

**Target version**set to*CoCoA-5.1.0 Easter14*

#### #7 Updated by Anna Maria Bigatti about 4 years ago

**Target version**changed from*CoCoA-5.1.0 Easter14*to*CoCoA-5.1.1 Seoul14*

#### #8 Updated by John Abbott over 3 years ago

**Target version**changed from*CoCoA-5.1.1 Seoul14*to*CoCoA-5.1.2 summer 2015*

#### #9 Updated by Anna Maria Bigatti almost 3 years ago

**Assignee**set to*Anna Maria Bigatti***Estimated time**set to*6.00 h*

One problem is how to make it easy to use an elimination ordering.

Currently one has to write:

OrdM := ElimMat(3, [1]); -- elim the first out of 3 indets X := <list of names/symbols>; P := NewPolyRing(QQ, AllIndetNames, OrdM, 0); Use P;

How to make this easier? Here is a possible shortcut:

P := NewPolyRingElim(QQ, ElimIndetNames, OtherIndetNames); Use P;

this has the advantage that it can be similarly implemented in CoCoALib.

Another shortcut is this (but I'm not 100% sure it can be done):

Ord := record[M := ..., GrDim := ..]; Use P ::= QQ[<indets>], Ord;

#### #10 Updated by Anna Maria Bigatti almost 3 years ago

**Target version**changed from*CoCoA-5.1.2 summer 2015*to*CoCoA-5.1.3/4 Jan 2016*

#### #11 Updated by Anna Maria Bigatti almost 3 years ago

Probably we can implement this:

M:=Mat([[0,0,0,1,1,1,1]]); Ord:= record[M := CompleteOrd(M), GradDim := 0]; P::=QQ[x,y,z, a[1..3], t]],Ord;

investigate

#### #12 Updated by Anna Maria Bigatti about 2 years ago

**Target version**changed from*CoCoA-5.1.3/4 Jan 2016*to*CoCoA-5.?.?*

#### #13 Updated by Anna Maria Bigatti 5 months ago

**Target version**changed from*CoCoA-5.?.?*to*CoCoA-5.2.4*