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

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

<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 />

[||13||17 19 23 29]<br />

[++--++-----------]<br />

[++--++-----------]<br />

[||31||37 41 43 47]<br />

[++--++-----------]<br />

[||53||59 61 67 71]<br />

[||73||79 83 89 97]<br />

sage: M.subdivision(0,0)<br />

[]<br />

sage: M.subdivision(2,4)<br />

[37 41 43 47]<br />

AUTHORS:<br />

•Robert Bradshaw (2007-06-14)<br />

subdivision(i, j)<br />

Returns an immutable copy <strong>of</strong> the (i,j)th submatrix <strong>of</strong> self, according to a previously set subdivision.<br />

Before a subdivision is set, the only valid arguments are (0,0) which returns self.<br />

EXAMPLE:<br />

sage: M = matrix(3, 4, range(12))<br />

sage: M.subdivide(1,2); M<br />

[ 0 1| 2 3]<br />

[-----+-----]<br />

[ 4 5| 6 7]<br />

[ 8 9|10 11]<br />

sage: M.subdivision(0,0)<br />

[0 1]<br />

sage: M.subdivision(0,1)<br />

[2 3]<br />

sage: M.subdivision(1,0)<br />

[4 5]<br />

[8 9]<br />

It h<strong>and</strong>les size-zero subdivisions as well.<br />

sage: M = matrix(3, 4, range(12))<br />

sage: M.subdivide([0],[0,2,2,4]); M<br />

[+-----++-----+]<br />

[| 0 1|| 2 3|]<br />

[| 4 5|| 6 7|]<br />

[| 8 9||10 11|]<br />

sage: M.subdivision(0,0)<br />

[]<br />

sage: M.subdivision(1,1)<br />

[0 1]<br />

[4 5]<br />

[8 9]<br />

sage: M.subdivision(1,2)<br />

[]<br />

sage: M.subdivision(1,0)<br />

[]<br />

sage: M.subdivision(0,1)<br />

[]<br />

subdivision_entry(i, j, x, y)<br />

Returns the x,y entry <strong>of</strong> the i,j submatrix <strong>of</strong> self.<br />

258 Chapter 7. Base class for matrices, part 2

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

Saved successfully!

Ooh no, something went wrong!