| 248 | |
| 249 | |
| 250 | bool isApproxUnitary(qmatrix m) { |
| 251 | |
| 252 | // should be identity |
| 253 | qmatrix md = m * getConjugateTranspose(m); |
| 254 | qmatrix id = getIdentityMatrix(m.size()); |
| 255 | return doMatricesAgree(md, id); |
| 256 | } |
| 257 | |
| 258 | |
| 259 | qcomp getTrace(qmatrix m) { |
no test coverage detected