Transferred from: http://zc634579757.blog.163.com/blog/static/12449746220098272176148/
1. The maximum number of matches in a binary graph is equal to the minimum point overlay in the graph.
The "Matirx67" König theorem is an important theorem in a binary graph, meaning that the maximum number of matches in a binary graph is equal to the minimum number of points covered in the graph. If you don't know what the minimum coverage is, here's what I'm going to say: If you pick a point that's equivalent to covering all the edges with it as the end point, you need to select the fewest points to cover all the edges. For example, the maximum and minimum point overrides in the figure below have been labeled in blue and red, respectively. They are all equal to 3. This theorem is believed to be known by most people, but the evidence given on the web is rare. There are some common "proofs" on the web that are obviously wrong. Therefore, I am here to write a proof of this theorem, I hope to be helpful to everyone.
If we have obtained the maximum match by the Hungarian algorithm (assuming it is equal to M), the method given below can tell us which m points can be selected to cover all the edges.
The Hungarian algorithm takes us from one of the no matching points on the right, out of a way that makes "one not matched, one has been matched, and the next does not match so alternately" (staggered rail, augmented road). But now that we've found the biggest match, there's no such way anymore. In other words, we can find a lot of possible augmented paths, but in the end we fail to find the "end point is not yet matched". We mark all of these points: from all the points on the right that are not matched, all the points that can be reached by the "alternating presence" of the augmented road (the last path is a number of incomplete augmented paths). Then these points make up the minimum set of coverage points: all the points on the right that are not marked, plus the points on the left that have been marked. Looking at the picture, the right image shows two such paths, marking a total of 6 points (denoted by "√"). So, the three dots that are circled in red are our minimum set of coverage points.
First of all, why do you get the number of point set points that are exactly m? The answer is simple, because each point is one of the endpoints of a matching edge. If the point on the right is not matched, it is already marked as a starting point, and if there is no match on the left, then it will not go (otherwise a complete augmented path is found). It is not possible for a matching edge to be marked with the left endpoint, while the right end is unmarked (otherwise the right point can be reached by this edge). So, at the end, the points we circled correspond to the matching edges one by one.
Second, why do you get a set of points that can cover all the edges? The answer is equally simple. An edge cannot exist, its left end is unmarked, and the right endpoint is marked. The reasons are as follows: If this side does not belong to our matching edge, then the left end point can be reached through this edge (thereby getting marked); If this edge belongs to our matching edge, then the right endpoint cannot be the start of a path, so its marker can only come from the left end of the edge (think of the matching definition), The left point should have a mark.
Finally, why is this the smallest point covering set? This is, of course, the smallest, and it is impossible to have a smaller point cover set than M, since to overwrite this m-match edge requires at least M-points (again back to the matching definition).
It's done.
2. Minimum path override = Minimum path overlay =|g|-maximum number of matches
In a n*n graph, the path overlay is to find some way through the diagram, so that it covers all the vertices in the graph,
And any one vertex has and only one path associated with it, (if each path in these paths goes from its starting point to its end,
Then you can go through each vertex of the diagram once and only once, and if you do not consider the existence of loops in the diagram, then each path is a weakly connected subset.
eg. Figure 4*4 the smallest path overlay of Figure g, containing 2 paths: P1->P3, P2->P4
From the above can be drawn:
1. A single vertex is a path;
2. If there is a path p1,p2,...... PK, where P1 is the starting point, PK is the end point, then in the overlay map, vertex p1,p2,...... PK no longer with the other
There are forward edges between vertices.
The minimum path overlay is to find the smallest number of path bars, making it a path overlay of G.
The relationship between the path overlay and the binary graph matching: The minimum path overlay =|g|-maximum match number;
The maximum matching number is calculated by dividing each vertex pi in G into two vertex pi ' and pi ', if there is a pi to PJ's side in P, then
In the second Figure G ', there is a non-direction link between pi ' and PJ ', where Pi ' is the out side of pi in P, PJ ' is an entry edge of PJ in P;
For the formula: the minimum path overrides the maximum number of =|g|-, which can be understood;
If the match number is zero, then there is no forward edge in P, so there is obviously:
The minimum path coverage =|g|-maximum match number =|g|-0=|g|; that is, the minimum path coverage number of P is |g|;
G ' is not in the matching edge, the number of path coverage is |g|;
If you add a matching edge pi '->pj ' in G ', then there is a PI connection to PJ's in the path overlay of figure p, which means pi and PJ
One path, so the number of paths can be reduced by one, so continue to increase the matching edge, each added one, the number of path coverage is reduced by one;
Until the matching edge cannot continue to increase, the number of path overlays can no longer be reduced, there is the preceding formula; but it's just talking. Each matching edge
Corresponds to a forward edge between two points on a path in a path overlay, and the following describes the two vertices of each connection in a path overlay.
Corresponds to a matching edge between the two sides.
3. Maximum independent set of two graphs = number of vertices-two maximum matching
Independent set: A collection of vertices that are not connected to any of the two vertices in the graph.