组合对象生成与Brzozowski猜想研究
1. 平行四边形多联骨牌的生成算法
1.1 问题描述
平行四边形多联骨牌生成问题(PPG)旨在输入一个整数 $n$,输出大小为 $n$ 的平行四边形多联骨牌的有序序列。解决该问题的方法是生成与之相关的线性划分对 $(s, t)$ 的序列。
1.2 算法实现
以下是生成大小为 $n$ 的平行四边形多联骨牌的算法:
Algorithm 2. Generation of parallelogram polyominoes of size n.
1: Procedure GenParPol(n)
2: for l:=n downto 1 do
3:
for m:=(l −1)(n −l) + l downto l do
4:
t:= InitLinPart(m, l, n −l + 1);
5:
while M(t, 0) ̸= ∅do
6:
s:= MinLinPart(m + n, t);
7:
while M(s, t) ̸= ∅do
8:
s:=Next(s, t);
9:
end while
10:
t:=Next(t, 0[l]);
11:
end while
12:
end for
13: end for
算法步骤解释如下:
1. 设置高度和大小
超级会员免费看
订阅专栏 解锁全文
17

被折叠的 条评论
为什么被折叠?



