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

17 行
355B

  1. from abp.fancy import GraphState
  2. from abp.util import xyz
  3. import numpy as np
  4. N = 100
  5. g = GraphState()
  6. for i in range(N):
  7. theta = 2*np.pi*i/30
  8. pos = xyz(5*np.cos(theta), 5*np.sin(theta), i/10.)
  9. g.add_node(i, position = pos, vop=0)
  10. for i in range(N):
  11. g.act_cz(i, (i+1) % N)
  12. g.act_local_rotation(i, 12)
  13. g.act_local_rotation(i, 10)