On Apr 8, 12:56 pm, "Justin C. Walker" <jus...@mac.com> wrote:
> On Apr 8, 2009, at 12:07 , gerhard wrote:
>
> > Print methods for matrices with subdivisions
>
> > let M be a matrix over QQ:
> > subdivisions are printed fine
> > over GF(2):
> > M.get_subdivisions() shows the subdivisions are defined,
> > but the print method does not know about them.
>
> Yup. Most matrix classes seem to use a common method for printing,
> while the 'mod 2' matrix implementation has its own "stringify" method.
>
> There may be a good explanation for this, but commenting out the mod2
> method seems to have the right effect without damaging anything else.
> At least with minimal testing.
Another workaround: if M is a matrix over GF(2), then do this:
sage: MS = M.sparse_matrix()
sage: MS.subdivide(2,3)
The subdivisions in MS should appear: the problem is only in dense
matrices over GF(2).
> > The show methods cannot handle subdivisions altogether.
>
> I'm not sure I understand. For other than the mod 2 elements, show(X)
> produces an image of a subdivided matrix. Do you mean just in the mod
> 2 case?
>
> > Are there any plans to enhance these printing methods?
>
> I think it qualifies as a bug, and I've created a Trac report for the
> problem:
> <http://trac.sagemath.org/sage_trac/ticket/5714>
Hi Justin,
I also created a ticket, <http://trac.sagemath.org/sage_trac/ticket/
5715>, with a patch, deleting the str method for dense mod 2
matrices.
--~--~---------~--~----~------------~-------~--~----~
To post to this group, send email to sage-support@googlegroups.com
To unsubscribe from this group, send email to
sage-support-unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/sage-support
URLs: http://www.sagemath.org
-~----------~----~----~----~------~----~------~--~---