Opened 9 years ago

Closed 9 years ago

# where is the bug; does intersect() not respect monomial ordering?

Reported by: Owned by: kroeker@… somebody major 4-1-0 and higher dontKnow 4-0-0 intersect isSB attrib ordering

### Description

intersect sets attribute "isSB" while it is not true?

Here is the example:

```ring rng = 0,(xp,xl,xh),dp;

ideal I=
-4*xp*xh+3*xl^2,
4*xp^2*xh-9*xl*xh,
xp^2*xl-3*xp*xh;

def J = intersect(I,I);
J;
//J=3*xl^2-4*xp*xh
//J=4*xp^2*xh-9*xl*xh
//J=xp^2*xl-3*xp*xh

attrib(J); // attr:isSB, type int
attrib(J,"isSB"); // =1,
groebner(J);
//_=3*xl^2-4*xp*xh
//_=4*xp^2*xh-9*xl*xh
//_=xp^2*xl-3*xp*xh

ring rng = 0,(xp,xl,xh),lp;

ideal I= -4*xp*xh+3*xl^2, 4*xp^2*xh-9*xl*xh, xp^2*xl-3*xp*xh;

def J = intersect(I,I);
J;
//J=-4*xp*xh+3*xl^2
//J=4*xp^2*xh-9*xl*xh
//J=xp^2*xl-3*xp*xh

attrib(J); // attr:isSB, type int
attrib(J,"isSB"); // =1, incorrect ?

groebner(J);
//_=xl^4-4*xl*xh^2
//_=4*xp*xh-3*xl^2
//_=xp*xl^2-3*xl*xh
//_=xp^2*xl-3*xp*xh

reduce(groebner(J),J);
//_=y^4-4*y*z^2
//_=0
//_=x*y^2-3*y*z
//_=0

```

### comment:1 Changed 9 years ago by kroeker@…

Remark: bug was found by throwing random ideals at radEHV and looking at the primary decomposition of the result (of course not by hand!) Since the `isSB` attrib (set by `intersect` in `radEHV`) is probably incorrect (didn't check) , `primdecGTZ` gives an invalid and unexpected result: (  <>  )

```> ring rng = 0,(xp,xl,xh),lp;
// ** redefining rng **
>
. ideal I= -4*xp*xh+3*xl^2, 4*xp^2*xh-9*xl*xh, xp^2*xl-3*xp*xh;
//options: redSB intStrategy redefine loadLib usage prompt
//options: redSB intStrategy redefine loadLib usage prompt
> primdecGTZ(rIehv);
// ** redefining gnir1 **
:
:
_=xh
_=xl
:
_=xh
_=xl
:
:
_=xl^3-4*xh^2
_=4*xp*xh-3*xl^2
_=xp*xl-3*xh
_=4*xp^2-9*xl
:
_=xl^3-4*xh^2
_=4*xp*xh-3*xl^2
_=xp*xl-3*xh
_=4*xp^2-9*xl
:
:
_=xl
_=xp
:
_=xl
_=xp
:
:
_=xh
_=xl^2
_=xp
:
_=xp
_=xl
_=xh
>

```

### comment:2 Changed 9 years ago by hannes

Resolution: → fixed new → closed

the result of intersect is a generating set. see 0a6bb08c6f0682a52c5e101d9181d755a4c063c9

Note: See TracTickets for help on using tickets.