Revision history [back]

Any way to make Sage display large matrices all in 1 line?

Hi all,

Currently I have this code that generates large matrices.

B = BooleanPolynomialRing(25,'x', order = 'degneglex')
from sage.rings.polynomial.toy_variety import coefficient_matrix
from brial import *
v = BooleanPolynomialVector()
l = [B.random_element(degree = 3, terms = 4) for j in range(25)]
_ = [v.append(e) for e in l]

from sage.rings.polynomial.toy_variety import coefficient_matrix
print l
%time A, v = Sequence(l,B).coefficient_matrix()
print A
print v


The matrix generated is big, so big that it takes 2 lines to display all of it. It is hard to visualise. Is there some way of making each row of the matrix inline together such that they are not separated into different lines?