若公式显示不正常,安装GitHub with MathJax.
当$G_1$和$G_2$是同构的,最优置换矩阵是P,其中最大tr(
- 不包括v本身
- 对于任意的节点u属于nk(v),u到v的最短RWR距离不大于k
Anchor two conditions
-
$min\lbrace d(u),d(v)\rbrace\ge\delta$ (两个节点中平均度数更大的那个)$\delta = max\left\lbrace \frac{2\times|E(G_1)|}{|V(G_1)|},\frac{2\times|E(G_2)|}{|V(G_2)|}\right\rbrace$ -
$S_l[u,v]\ge τ$ τ是阈值,往往大于0.5
Anchor:一组集合,用$\mathcal{A}$表示
Algorithm 2 anchor-selection (G1, G2)
Require: two graphs G1 and G2;
Ensure: a list of matched anchor pairs A;
1: compute the similarity matrix S;
2: A ← ∅; S1 ← ∅; S2 ← ∅;
3: for all u ∈ V(G1) and v ∈ V(G2) in decreasing order of their similarity S[u, v] do
4: if S[u, v] ≥ τ and min{d(u), d(v)} ≥ δ and u ∈/ S1 and v /∈ S2 then
5: A ← A ∪ {(u, v)}; S1 ← S1 ∪ {u}; S2 ← S2 ∪ {v};
时间复杂度$O(|V(G_1)|^2·(|V(G_1)|+|E(G_1)|) + |V(G_2)|^2 · (|V(G_2)| + |E(G_2)|))$
M:最终求的结果,初始状态为$\mathcal{A}$
Algorithm 3 anchor-expansion (G1, G2, A)
Require: two graphs, G1 and G2, and the anchor pairs A;
Ensure: a graph matching M;
1: M ← A; Q ← ∅; S1 ← ∅; S2 ← ∅;
2: for all (u, v) ∈ A do
3: S1 ← S1 ∪ {u}; S2 ← S2 ∪ {v}; Q ← Q ∪ (N(u) × N(v));
4: while Q not equl ∅ do
5: remove (u, v) from Q with the largest similarity Sl[u, v];
6: if u ∈/ S1 and v /∈ S2 then
7: M ← M ∪ {(u, v)}; S1 ← S1 ∪ {u}; S2 ← S2 ∪ {v}; Q ← Q ∪ (N(u) × N(v));
8: return M;
时间复杂度$O(|V(G_1)|·|V(G_2)| · min{|V(G_1)|, |V(G_2)|})$
τ的选择很重要,因为τ如果过大,初始匹配点过少,很难匹配,如果τ过小,初始点过多,存在错误的初始匹配的几率就越大,根据错误的匹配的匹配错误率更大。所以采用算法4步进的方法调整τ,找到一个最优值,由于这个步进的方法Anchor Selection已经完成,主要是完成Anchor-Expansion步骤,并且通过table可以看出,Anchor-Expansion的占用的时间是少数的,所以这个步进方法占用了很少的时间。
Algorithm 4 construct-opt (G1, G2)
Require: two graphs, G1 and G2;
Ensure: a graph matching between G1 and G2;
1: τ ← 0.5; Mopt ← ∅;
2: AI ←anchor-selection (G1,G2); {Algorithm 2}
3: for all τi = 0.5 + i × l such that τi ∈ [0.5, 1] do
4: A ← {(u, v)|(u, v) ∈ AI , S[u, v] ≥ τi};
5: M ← anchor-expansion (G1, G2, A); {Algorithm 3}
6: if score(M) > score(Mopt) then
7: Mopt ← M;
8: return Mopt ;
时间复杂度$O(|V(G_1)|^2 · (|V(G_1)|+|E(G_1)|) + |V(G_2)|^2 · (|V(G_2)| +|E(G_2)|))v$
M:初始匹配节点集
C:包含图G中最少的节点的集合,且对于G中的每条边,至少覆盖一个边上一个节点.
I:I=V(G)-C I是V(G)的子集,并且对于任意的两个节点属于I,这两个节点之间的边都不属于E(G)
P:P1,P2分别是G1,G2中匹配的节点的集合
F:$C \cap P $
$|\mathcal{M}| = \sum_{i=9}^{min}\frac{min!\times max!}{i!\times (min-i)!\times (max-i)!}$ $M \in \mathcal{M}$ $M^+(C) \in \mathcal{M}$ -
$M^+(C)$ 是$\mathcal{M}$中最优的匹配情况,$M^+(C)=(M \cap (F_1\times F_2))\cup M_b$
M':属于$\mathcal{M}$且$M' \cap (F_1\times F_2)$,$M' \cap ((C-F_1))= \emptyset $
寻找最小的C
对于任意的$G_1中C_1和G_2中C_2$,如果$C_1\subseteq C_2$,则$score(M^+(C_1)) \ge score(M^+(C_2))$
Algorithm 5 select-random-cover (G)
Require: a graph G;
Ensure: a randomly selected minimal cover of G;
1: L ← shuffled nodes in V (G); C ← ∅;
2: for all u ∈ L do
3: if ∃(u, v) ∈ E(G), s.t. v /∈ C then C ← C ∪ {u};
4: for all u ∈ C do
5: if C − {u} is a vertex cover of G then C ← C − {u};
6: return C;
时间复杂度$O(|E(G)|)$
对于图G的任意的极小覆盖C,至少有$|C|!\times |V(G)-C|!种排列组合可以生成C
Algorithm 6 refine (G1, G2, M)
Require: two graphs G1 and G2, and the matching M;
Ensure: a refined matching M;
1: while M is updated or it is the first iteration do
2: for i = 1 to X do
3: G ← random selection between G1 and G2;
4: C ← select-random-cover (G);
5: compute M+(C);
6: if score(M+(C)) > score(M) then M ← M+(C);
7: return M;
时间复杂度$O(m·n^3)$,$m=min{|E(G_1)|,|E(G_)|} and n=max{|V(G_1)|,|V(G_2)|}$
(
$M' \cap (F1 \times F2) = M \cap (F1 \times F2)$ -
$F_1 ∪ (V(G_1) − P1 − M'^{−1}[V(G_2) − P_2])$ is a vertex cover of$G_1$
我们一定有$score(M^{\ast}(F_1)) \ge score(M^{\ast}_{\mathcal{M}}) \ge score(M^+(C))$