SpinCircuitSolver.operator_to_mat¶ SpinCircuitSolver.operator_to_mat(operator)[source]¶ Convert a SpinOp describing a gate generator to a sparse matrix. Parameters: operator (SpinOp) – spin operator of which to compute the matrix representation Return type: csc_matrix Returns: scipy.sparse matrix of the Hamiltonian