#8286 closed defect (duplicate)
sparse_rows and sparse_columns are broken for 0xn, nx0 matrices
Reported by: | jhpalmieri | Owned by: | was |
---|---|---|---|
Priority: | major | Milestone: | sage-duplicate/invalid/wontfix |
Component: | linear algebra | Keywords: | |
Cc: | Merged in: | ||
Authors: | Reviewers: | ||
Report Upstream: | N/A | Work issues: | |
Branch: | Commit: | ||
Dependencies: | Stopgaps: |
Description
sage: mat = matrix(ZZ, 0, 1, sparse=True) sage: mat.nrows() 0 sage: mat.rows() [(0)] sage: mat = matrix(ZZ, 0, 1, sparse=False) sage: mat.nrows() 0 sage: mat.rows() []
The rows
method should act the same regardless of the sparsity of the matrix, and when there are no rows, it should return an empty list.
The same thing happens with matrices defined over QQ or GF(2), so I'm guessing that the problem is with sparse_rows
and sparse_columns
in sage/matrix/matrix1.pyx.
Change History (3)
comment:1 Changed 10 years ago by
- Status changed from new to needs_review
comment:2 Changed 10 years ago by
- Resolution set to duplicate
- Status changed from needs_review to closed
Yes, it works for me now.
comment:3 Changed 10 years ago by
- Milestone changed from sage-4.6.2 to sage-duplicate/invalid/wontfix
Note: See
TracTickets for help on using
tickets.
Hi John,
I think this is an exact duplicate of #10714, which has a fix and has been merged. (I'd missed this ticket when I "rediscovered" this problem). On 4.6.2.rc0 I now get:
I think we can close this as a duplicate?
Rob