Module: cirq.linalg.predicates

Utility methods for checking properties of matrices.

Functions

allclose_up_to_global_phase(...): Determines if a ~= b * exp(i t) for some t.

is_diagonal(...): Determines if a matrix is a approximately diagonal.

is_hermitian(...): Determines if a matrix is approximately Hermitian.

is_normal(...): Determines if a matrix is approximately normal.

is_orthogonal(...): Determines if a matrix is approximately orthogonal.

is_special_orthogonal(...): Determines if a matrix is approximately special orthogonal.

is_special_unitary(...): Determines if a matrix is approximately unitary with unit determinant.

is_unitary(...): Determines if a matrix is approximately unitary.

matrix_commutes(...): Determines if two matrices approximately commute.

slice_for_qubits_equal_to(...): Returns an index corresponding to a desired subset of an np.ndarray.