#5974: [with patch; needs work] the generic linear_combination_of_rows and
linear_combination_of_columns functions for matrices are very stupidly
slotch
----------------------------+-----------------------------------------------
 Reporter:  was             |       Owner:  was     
     Type:  defect          |      Status:  new     
 Priority:  major           |   Milestone:  sage-4.0
Component:  linear algebra  |    Keywords:          
----------------------------+-----------------------------------------------

Comment(by jhpalmieri):

 In trac_5974.patch, I like the new code better than the old and I see the
 speed up (not quite 10 times on my machine, but close).  However, should
 you raise an error if the length of v is longer than the number of rows of
 the matrix, the way the old code did?  With the new code, I get an error
 about sizes of matrices being wrong, which is a little opaque:
 {{{
 sage: A = random_matrix(QQ,50)
 sage: v = [1..52]
 sage: A.linear_combination_of_rows(v)
 ---------------------------------------------------------------------------
 TypeError                                 Traceback (most recent call
 last)
 ...
 TypeError: unsupported operand parent(s) for '*': 'Full MatrixSpace of 1
 by 52 dense matrices over Integer Ring' and 'Full MatrixSpace of 50 by 50
 dense matrices over Rational Field'
 }}}
 Also, this is a little silly, but if A is a matrix with 0 rows, then
 {{{A.linear_combination_of_rows(range(3000))}}} works just fine.

 Otherwise, looks good.  All tests pass on sage.math.

-- 
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/5974#comment:4>
Sage <http://sagemath.org/>
Sage - Open Source Mathematical Software: Building the Car Instead of 
Reinventing the Wheel

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"sage-trac" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/sage-trac?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to