Anders and Briegel in Python
您最多选择25个主题 主题必须以字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符

13 行
332B

  1. import clifford as lc
  2. from numpy import *
  3. def test_identify_pauli():
  4. assert lc.identify_pauli(lc.px) == (1, "x")
  5. assert lc.identify_pauli(-lc.px) == (-1, "x")
  6. assert lc.identify_pauli(-lc.pz) == (-1, "z")
  7. def test_crap():
  8. assert allclose(lc.vop_unitaries[0], lc.i)
  9. assert allclose(lc.vop_unitaries[10], lc.h)