这更像是评论而不是答案,因为我似乎错过了您的问题中的某些内容。
首先,这样的图有可能是非循环的吗?
我也想知道你的对称约束。这不是使所有这些图彼此对称吗?是否允许置换连接矩阵的行和列?
例如,如果我们在图中允许自连接,那么以下连接矩阵是否满足您的条件?
1 1 0 0 0 0 0 1
1 1 1 0 0 0 0 0
0 1 1 1 0 0 0 0
0 0 1 1 1 0 0 0
0 0 0 1 1 1 0 0
0 0 0 0 1 1 1 0
0 0 0 0 0 1 1 1
1 0 0 0 0 0 1 1
从这个矩阵开始,是否不可能排列它的行和列以获得所有行和列的总和为 3 的所有此类图?
A
可以通过以下方式(使用 MATLAB)从上述矩阵中获得此类矩阵的一个示例。
>> A(randperm(8),randperm(8))
ans =
0 1 0 0 0 1 1 0
0 0 1 0 1 0 1 0
1 1 0 1 0 0 0 0
1 1 0 0 0 1 0 0
1 0 0 1 0 0 0 1
0 0 1 1 0 0 0 1
0 0 1 0 1 0 0 1
0 0 0 0 1 1 1 0
PS。在这种情况下,我重复了几次该命令,以获得对角线中只有零的矩阵。:)
编辑
Ah, I see from your comments that I was not correct. Of course the permutation index must be the same for rows and columns. I at least should have noticed it when I started out with a graph with self-connections and obtained one without them after the permutation.
A random isomorphic permutation would instead look like this:
idx = randperm(8);
A(idx,idx);
which will keep all the self-connections.
Perhaps this could be of some use when the matrices are generated, but it is not at all as useful as I thought it would be.