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

True<br />

sage: matrix([[0,6],[0,0]]).is_symmetrizable(return_diag=True)<br />

False<br />

sage: matrix([2]).is_symmetrizable(positive=True)<br />

True<br />

sage: matrix([[1,2],[3,4]]).is_symmetrizable(return_diag=true)<br />

[1, 2/3]<br />

REFERENCES:<br />

•[FZ2001] S. Fomin, A. Zelevinsky. Cluster Algebras 1: Foundations, arXiv:math/0104151 (2001).<br />

iterates(v, n, rows=True)<br />

Let A be this matrix <strong>and</strong> v be a free module element. If rows is True, return a matrix whose rows are the<br />

entries <strong>of</strong> the following vectors:<br />

v, vA, vA 2 , . . . , vA n−1 .<br />

If rows is False, return a matrix whose columns are the entries <strong>of</strong> the following vectors:<br />

INPUT:<br />

•v - free module element<br />

•n - nonnegative integer<br />

EXAMPLES:<br />

sage: A = matrix(ZZ,2, [1,1,3,5]); A<br />

[1 1]<br />

[3 5]<br />

sage: v = vector([1,0])<br />

sage: A.iterates(v,0)<br />

[]<br />

sage: A.iterates(v,5)<br />

[ 1 0]<br />

[ 1 1]<br />

[ 4 6]<br />

[ 22 34]<br />

[124 192]<br />

Another example:<br />

sage: a = matrix(ZZ,3,range(9)); a<br />

[0 1 2]<br />

[3 4 5]<br />

[6 7 8]<br />

sage: v = vector([1,0,0])<br />

sage: a.iterates(v,4)<br />

[ 1 0 0]<br />

[ 0 1 2]<br />

[ 15 18 21]<br />

[180 234 288]<br />

sage: a.iterates(v,4,rows=False)<br />

[ 1 0 15 180]<br />

[ 0 3 42 558]<br />

[ 0 6 69 936]<br />

v, Av, A 2 v, . . . , A n−1 v.<br />

79

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

Saved successfully!

Ooh no, something went wrong!