[−][src]Function dqcsim::bindings::dqcs_mat_approx_unitary
#[no_mangle]pub extern "C" fn dqcs_mat_approx_unitary(
matrix: dqcs_handle_t,
epsilon: c_double
) -> dqcs_bool_return_t
Returns whether the matrix is approximately unitary. >
matrix
is a borrowed handle to the matrix to check.epsilon
specifies the maximum element-wise root-mean-square error between the product of the matrix and its hermetian compared to the identity matrix.This function returns
DQCS_TRUE
if the matrix is approximately unitary, orDQCS_FALSE
if not.DQCS_BOOL_ERROR
is used when either handle is invalid or not a matrix.