#17658: Incorrect densification of polynomial matrix
------------------------------+----------------------------
   Reporter:  gagern          |            Owner:
       Type:  defect          |           Status:  new
   Priority:  critical        |        Milestone:  sage-6.5
  Component:  linear algebra  |         Keywords:
  Merged in:                  |          Authors:
  Reviewers:                  |  Report Upstream:  N/A
Work issues:                  |           Branch:
     Commit:                  |     Dependencies:
   Stopgaps:                  |
------------------------------+----------------------------
 I found this strange bug, trying to turn a sparse matrix into a dense one.

 {{{
 sage: R1.<a,b> = QQ[]
 sage: R2.<c,d> = R1[]
 sage: p = a*c+b*d
 sage: d = dict(zip([i.degrees() for i in p.monomials()],
 p.coefficients()))
 sage: m = matrix(R1, 2, 2, d)
 sage: m
 [0 b]
 [a 0]
 sage: m.dense_matrix()
 [0 0]
 [0 0]
 }}}

 For some reason the source of the matrix entries seems to play a role here
 as well: if I simply type in the dict `d` directly, the result works as
 expected. So I'm not at all sure what actual component is to blame for
 this behavior. Omitting the two levels of polynomials, and using QQ for
 the coefficients, doesn't exhibit this problem either.

 Since this can lead to silent wrong answers, I consider this a critical
 problem.

--
Ticket URL: <http://trac.sagemath.org/ticket/17658>
Sage <http://www.sagemath.org>
Sage: Creating a Viable Open Source Alternative to Magma, Maple, Mathematica, 
and MATLAB

-- 
You received this message because you are subscribed to the Google Groups 
"sage-trac" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/sage-trac.
For more options, visit https://groups.google.com/d/optout.

Reply via email to