#5208: Differing behavior for matrix left_kernel vs. right_kernel [with patch,
needs review]
-----------------------------------------------+----------------------------
Reporter: rbeezer | Owner: rbeezer
Type: defect | Status: new
Priority: minor | Milestone: sage-3.4.1
Component: linear algebra | Resolution:
Keywords: matrix, left_kernel, right_kernel |
-----------------------------------------------+----------------------------
Changes (by rbeezer):
* summary: Differing behavior for matrix left_kernel vs. right_kernel =>
Differing behavior for matrix left_kernel vs.
right_kernel [with patch, needs review]
Comment:
High-level code has been renamed from left_kernel() to simply kernel() to
maintain consistency with derived classes. So kernel() is no longer an
alias for left_kernel().
right_kernel() is mostly unchanged, calls kernel() on transpose.
left_kernel() now just calls kernel(). This should all ensure the proper
versions of kernel() in derived classes are reached.
Doctests for kernel() and left_kernel() are identical except for names
used in explanations and the actual calls. Doctests for right_kernel now
have "right" in explantions, otherwise unchanged.
Each of the three versions has a doctest with a symmetric 500 x 500 matrix
of rational entries, which requires about 3 seconds of overhead and 1
second for the actual kernel call when patched. Unpatched version 3.2.3
will take 589 seconds for left_kernel() on this example. Runtimes seem to
be O(n-cubed) if a smaller (faster) example is better.
Timings on patched versions suggest that for rational matrices, the
overhead in right_kernel() of transposing the matrix twice has the effect
of doubling the runtime versus left_kernel.
--
Ticket URL: <http://trac.sagemath.org/sage_trac/ticket/5208#comment:1>
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
-~----------~----~----~----~------~----~------~--~---