Opened 9 years ago

Closed 9 years ago

# bug in syz for ideal in quotient ring

Reported by: Owned by: kroeker@… hannes minor 3-2-0 and higher singular-kernel 3-1-6 syz quotient ring ideal over integers

### Description (last modified by Oleksandr )

Hello,

the following example works in ver. 3.1.6, but neither in spiewiese nor in master-branch from gitHub. I'm not sure if priority is major or not; at least in our package for resolution of singularities it is an issue.

Code:

```ring r = integer,(x,y,z),dp;
ideal i = x4+y2+z2;
qring q = i;
ideal s = 2z,-4z2,-4yz,-4xz,-2x2z-2yz-2z2,-x4-y2-z2;
syz(s);
```

### comment:1 Changed 9 years ago by Oleksandr

Component: dontKnow → singular-kernel modified (diff) Release 4-0-0 → 3-2-0 and higher changed from somebody to hannes → 3-1-6

Sorry but i cannot confirm your bug report: all the Singular versions i tried (including `x86_64-Linux version 3-1-6 (3160) Jan 9 2013 06:51:17`) produce the following output, which seems correct to me:

```integer_syz.tst   2>
integer_syz.tst   3. ring r = integer,(x,y,z),dp;
integer_syz.tst   4> ideal i = x4+y2+z2;
integer_syz.tst   5>
integer_syz.tst   6. option();
//options: redTail redThrough intStrategy redefine usage prompt
integer_syz.tst   7> qring q = std(i);
integer_syz.tst   8> q;
//   coeff. ring is : Integers
//   number of vars : 3
//        block   1 : ordering dp
//                  : names    x y z
//        block   2 : ordering C
// quotient ring from ideal
_=x4+y2+z2
integer_syz.tst   9>
integer_syz.tst  10. ideal s = 2z,-4z2,-4yz,-4xz,-2x2z-2yz-2z2,-x4-y2-z2;
integer_syz.tst  11>
integer_syz.tst  12. option();
//options: redTail redThrough intStrategy redefine usage prompt
integer_syz.tst  13> std(s);
_=2z
integer_syz.tst  14>
integer_syz.tst  15. syz(_);
_=0
integer_syz.tst  16>
integer_syz.tst  17. option();
//options: redTail redThrough intStrategy redefine usage prompt
integer_syz.tst  18> module a=syz(s); print(a);
0,2z,2y,2x,x2+y+z,
0,1, 0, 0, 0,
0,0, 1, 0, 0,
0,0, 0, 1, 0,
0,0, 0, 0, 1,
1,0, 0, 0, 0
integer_syz.tst  19>
integer_syz.tst  20. print( module(transpose(a)*transpose(s)) );
-x4-y2-z2,
0,
0,
0,
0
```

What Singular output would you expect?

Which Singular produced different output (please paste all the output of `Singular -v`)?

### Changed 9 years ago by Oleksandr

Syzygy over a quotient over ZZ

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

What Singular output would you expect? Which Singular produced different output (please paste all the output of Singular -v)?

My fault; It seems my report is incomplete. I ran the computation for spielwiese on a 32 bit linux notebook with an older fedora (gcc 4.4.5?) and the computation runs forever.

I guess it is a library or a build issue, because on my home desktop computer (fc17; gcc 4.7.2 ) the computation succeeds.

I will first update the OS on the notebook and if the error disappears it is probably not worth to track down the issue and the ticket can be closed.

If the error still persists after the update (I hope not), I 'm considering to track down the error (maybe with your help).

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

It seems, that minimal requirement for GMV is version 4.3.2,

otherwise the syz computation hangs. Not sure what minimal version requirement for mpfr is; I succeeded with 3.0.0-4 and 3.1.2

Can somebody confirm this?

If yes, the config files should be updated and minimal version for gmp should changed from 3.1.1 to 4.3.2

Best,

Jakob

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

Resolution: → fixed new → closed

factory uses mpz_addmul/mpz_submul which appeared in gmp 4.0 (or before) gfanlib uses mp_get_memory_functions which appeared in gmp 4.2 (or before) The example above works on a current Singular with gmp 4.2. Problems with gmp are usually not a problem of the gmp version but one of the gcc and/or the build/optimizing options.

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

Resolution: fixed closed → reopened

Can someone confirm following failing example using recent spielwiese (my gmp is 4.3.2) ?

using v3.1.6 seems ok.

```ring r=integer,(x, y),dp;

ideal I=81*y^6-162*y^5-27*y^4-x^2-9*y^2+18*y+3;

qring qr=I;

ideal s=6,
-36,
-12*x,
-18*y^3-18*y^2-18*x-18*y-18,
-6*x*y^3-18*x*y^2-18*x^2-18*x*y-18*x,
-81*y^6+162*y^5+27*y^4+x^2+9*y^2-18*y-3;

syz(s); //takes forever and eats up all memory
```

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

simple failing example for spielwiese (deos not eat all memory):

```ring r=integer,(x, y),dp;
ideal I=81*y^6-162*y^5;
qring qr=I;
ideal s=6;
syz(s);
```

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

Keywords: over integers added → fixed reopened → closed

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

Resolution: fixed closed → reopened

the simple example works now, but the little bit harder not:

```ring r = integer,(x, y),dp;
ideal I=81*y^6-162*y^5-27*y^4-x^2-9*y^2+18*y+3;

qring qr=I;

ideal s=6,
-36,
-12*x,
-18*y^3-18*y^2-18*x-18*y-18,
-6*x*y^3-18*x*y^2-18*x^2-18*x*y-18*x;

def syzS =syz(s); // runs 'forever' and eats up all mem
size(std( transpose(syzS)*  transpose(s) ) );

```

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

`syz` seems completely broken over integers, not necessarily qrings; another failing example (succeeds e.g. in Macaulay2 in seconds without problems) :

```ring r=(integer),(x,y,z),(dp(3),C);

ideal I = x*y-3,
3*y^6+18*y^5*z-9*y^4*z^2-27*y^2*z^4-162*y*z^5+81*z^6-y^4,
27*x*z^6+3*y^5+18*y^4*z-9*y^3*z^2-27*y*z^4-162*z^5-y^3,
9*x^2*z^6-54*x*z^5+3*y^4+18*y^3*z-9*y^2*z^2-27*z^4-y^2,
3*x^3*z^6-18*x^2*z^5-9*x*z^4+3*y^3+18*y^2*z-9*y*z^2-y,
x^4*z^6-6*x^3*z^5-3*x^2*z^4+3*y^2+18*y*z-9*z^2-1;

syz(I); // ok

ideal s =x*y+1,
-4,
-2*x*y-2,
-2*y^3-2*y^2*z-2*y*z^2-2*z^3-2*y^2,
-2*x*z^3+2*y^2+2*y*z+2*z^2+2*y,
-x*y+3,
-3*y^6-18*y^5*z+9*y^4*z^2+27*y^2*z^4+162*y*z^5-81*z^6+y^4,
-27*x*z^6-3*y^5-18*y^4*z+9*y^3*z^2+27*y*z^4+162*z^5+y^3,
-9*x^2*z^6+54*x*z^5-3*y^4-18*y^3*z+9*y^2*z^2+27*z^4+y^2;

syz(s); // eats up all mem, does not finish on a machine with 4GB RAM

```

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

Resolution: → fixed reopened → closed

module std over ring coeffs fixed

Note: See TracTickets for help on using tickets.