from sympy.combinatorics.named_groups import DihedralGroup
from collections import Counter

n = 12
G = DihedralGroup(n)
a = list(G.generate_dimino())
for perm in a:
ks = []

for k in perm.cyclic_form:
ks.append(len(k))
c = Counter(ks)
print

 

黄世宇/Shiyu Huang's Personal Page:​​https://huangshiyu13.github.io/​