Skip to content

Commit 802abd2

Browse files
committed
add notes for kb-qap
1 parent 4b8ef00 commit 802abd2

File tree

1 file changed

+16
-1
lines changed

1 file changed

+16
-1
lines changed

pygmtools/classic_solvers.py

+16-1
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,27 @@
22
Classic (learning-free) **two-graph matching** solvers. These two-graph matching solvers are recommended to solve
33
matching problems with two explicit graphs, or problems formulated as Quadratic Assignment Problem (QAP).
44
5-
The two-graph matching problem considers both nodes and edges, formulated as a QAP (Lawler's):
5+
The two-graph matching problem considers both nodes and edges, formulated as Lawler's QAP:
66
77
.. math::
88
99
&\max_{\mathbf{X}} \ \texttt{vec}(\mathbf{X})^\top \mathbf{K} \texttt{vec}(\mathbf{X})\\
1010
s.t. \quad &\mathbf{X} \in \{0, 1\}^{n_1\times n_2}, \ \mathbf{X}\mathbf{1} = \mathbf{1}, \ \mathbf{X}^\top\mathbf{1} \leq \mathbf{1}
11+
12+
All our solvers are designed to solve the Lawler's QAP, which is the most general form of the problem.
13+
14+
.. note::
15+
16+
There are also many real-world problems being formulated as the so-called Koopmans-Beckmann's QAP:
17+
18+
.. math::
19+
20+
&\max_{\mathbf{X}} \ \text{tr}(\mathbf{X}^\top\mathbf{F}_1\mathbf{X}\mathbf{F}_2)+\text{tr}(\mathbf{K}_p^\top\mathbf{X})\\
21+
s.t. \quad &\mathbf{X} \in \{0, 1\}^{n_1\times n_2}, \ \mathbf{X}\mathbf{1} = \mathbf{1}, \ \mathbf{X}^\top\mathbf{1} \leq \mathbf{1}
22+
23+
Its connection to Lawler's QAP is :math:`\mathbf{K} = \mathbf{F}_2\otimes\mathbf{F}_1^\top + \text{diag}(\mathbf{K}_p)`,
24+
where :math:`\otimes` means Kronecker product.
25+
1126
"""
1227

1328
# Copyright (c) 2022 Thinklab@SJTU

0 commit comments

Comments
 (0)