Opened 9 years ago

Closed 9 years ago

Last modified 9 years ago

#673 closed bug (fixed)

rank incorrect over integers

Reported by: kroeker@… Owned by: somebody
Priority: minor Milestone: 4-1-0 and higher
Component: singular-kernel Version: 4-0-1
Keywords: rank integers incorrect Cc:

Description

Observed by Simon Brandhorst:

  1. the rank function is incorrect over integers

Failing example:

ring QQ = 0,x,dp;
intmat m[2][2] = 4, 6, -10, -15;
rank(m); // =1, ok?
ring ZZ = integer,x,dp;
rank(m); //=2, wrong!!! expected 1, hint: (4 ,-10)-(6,-15) = (-2, 5) ; (4,-10)= -2*(-2,5);  (6,-15)=-3*(-2,5);
def stdm = matrix(std(module(matrix(m))));
stdm;
ncols(stdm); //=1


output:

> ring QQ = 0,x,dp;
> intmat m[2][2] = 4, 6, -10, -15;
> rank(m); // =1, ok?
 1
> ring ZZ = integer,x,dp;
> rank(m); //=2, wrong!!!
2
> def stdm = matrix(std(module(matrix(m))));
> stdm;
stdm[1,1]=-2
stdm[2,1]=5
> ncols(stdm); //=1
1
> 

Remark: 'ludecomp()' is disabled over rings, but 'rank()' is not

  1. it is unexpected that rank(m) depends on current ring instead on type of matrix m (intmat vs matrix).

Change History (1)

comment:1 Changed 9 years ago by hannes

Resolution: fixed
Status: newclosed

fixed with a62aaf77249f98fad26ba201fd0f646f392e5fcc concerning 2: (beside that it contradicts the condition for this tracker (only one issue per ticket)),no.

Last edited 9 years ago by hannes (previous) (diff)
Note: See TracTickets for help on using tickets.