08.02.2015 Views

Sage Reference Manual: Matrices and Spaces of Matrices - Mirrors

Sage Reference Manual: Matrices and Spaces of Matrices - Mirrors

Sage Reference Manual: Matrices and Spaces of Matrices - Mirrors

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

<strong>Sage</strong> <strong>Reference</strong> <strong>Manual</strong>: <strong>Matrices</strong> <strong>and</strong> <strong>Spaces</strong> <strong>of</strong> <strong>Matrices</strong>, Release 6.1.1<br />

EXAMPLES:<br />

sage: M = Mat(ZZ,20,5,sparse=False); M.row_space()<br />

Ambient free module <strong>of</strong> rank 5 over the principal ideal domain Integer Ring<br />

zero()<br />

Returns the zero matrix in self.<br />

self must be a space <strong>of</strong> square matrices. The returned matrix is immutable. Please use copy if you want<br />

a modified copy.<br />

EXAMPLES:<br />

sage: z = MatrixSpace(GF(7),2,4).zero_matrix(); z<br />

[0 0 0 0]<br />

[0 0 0 0]<br />

sage: z.is_mutable()<br />

False<br />

TESTS:<br />

sage: MM = MatrixSpace(RDF,1,1,sparse=False); mat = MM.zero_matrix()<br />

sage: copy(mat)<br />

[0.0]<br />

sage: MM = MatrixSpace(RDF,0,0,sparse=False); mat = MM.zero_matrix()<br />

sage: copy(mat)<br />

[]<br />

sage: mat.is_mutable()<br />

False<br />

sage: MM.zero().is_mutable()<br />

False<br />

zero_matrix()<br />

Returns the zero matrix in self.<br />

self must be a space <strong>of</strong> square matrices. The returned matrix is immutable. Please use copy if you want<br />

a modified copy.<br />

EXAMPLES:<br />

sage: z = MatrixSpace(GF(7),2,4).zero_matrix(); z<br />

[0 0 0 0]<br />

[0 0 0 0]<br />

sage: z.is_mutable()<br />

False<br />

TESTS:<br />

sage: MM = MatrixSpace(RDF,1,1,sparse=False); mat = MM.zero_matrix()<br />

sage: copy(mat)<br />

[0.0]<br />

sage: MM = MatrixSpace(RDF,0,0,sparse=False); mat = MM.zero_matrix()<br />

sage: copy(mat)<br />

[]<br />

sage: mat.is_mutable()<br />

False<br />

sage: MM.zero().is_mutable()<br />

False<br />

sage.matrix.matrix_space.dict_to_list(entries, nrows, ncols)<br />

Given a dictionary <strong>of</strong> coordinate tuples, return the list given by reading <strong>of</strong>f the nrows*ncols matrix in row order.<br />

12 Chapter 1. Matrix <strong>Spaces</strong>

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!