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: A = matrix(QQbar, [[ 1 + I, 1 - 6*I, -1 - I],<br />

... [-3 - I, -4*I, -2],<br />

... [-1 + I, -2 - 8*I, 2 + I]])<br />

sage: A.is_hermitian()<br />

False<br />

sage: B = A*A.conjugate_transpose()<br />

sage: B.is_hermitian()<br />

True<br />

<strong>Sage</strong> has several fields besides the entire complex numbers where conjugation is non-trivial.<br />

sage: F. = QuadraticField(-7)<br />

sage: C = matrix(F, [[-2*b - 3, 7*b - 6, -b + 3],<br />

... [-2*b - 3, -3*b + 2, -2*b],<br />

... [ b + 1, 0, -2]])<br />

sage: C.is_hermitian()<br />

False<br />

sage: C = C*C.conjugate_transpose()<br />

sage: C.is_hermitian()<br />

True<br />

A matrix that is nearly Hermitian, but for a non-real diagonal entry.<br />

sage: A = matrix(QQbar, [[ 2, 2-I, 1+4*I],<br />

... [ 2+I, 3+I, 2-6*I],<br />

... [1-4*I, 2+6*I, 5]])<br />

sage: A.is_hermitian()<br />

False<br />

sage: A[1,1] = 132<br />

sage: A.is_hermitian()<br />

True<br />

Rectangular matrices are never Hermitian.<br />

sage: A = matrix(QQbar, 3, 4)<br />

sage: A.is_hermitian()<br />

False<br />

A square, empty matrix is trivially Hermitian.<br />

sage: A = matrix(QQ, 0, 0)<br />

sage: A.is_hermitian()<br />

True<br />

is_immutable()<br />

Return True if this matrix is immutable.<br />

See the documentation for self.set_immutable for more details about mutability.<br />

EXAMPLES:<br />

sage: A = Matrix(QQ[’t’,’s’], 2, 2, range(4))<br />

sage: A.is_immutable()<br />

False<br />

sage: A.set_immutable()<br />

sage: A.is_immutable()<br />

True<br />

is_invertible()<br />

Return True if this matrix is invertible.<br />

74 Chapter 5. Base class for matrices, part 0

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

Saved successfully!

Ooh no, something went wrong!