Opened 10 years ago
Closed 10 years ago
#7845 closed Bugs (fixed)
[BGL] Bug in isomorphism when the two graphs are of different types
Reported by: | Owned by: | Jeremiah Willcock | |
---|---|---|---|
Milestone: | To Be Determined | Component: | graph |
Version: | Boost 1.52.0 | Severity: | Problem |
Keywords: | isomorphism, bgl | Cc: |
Description
The isomorphism implementation checks for the source and target (i, j) of the edge being considered in G2, where it clearly should be G1:
recur: if (iter != ordered_edges.end()) { i = source(*iter, G1); j = target(*iter, G2);
In the last line, G2 should be G1, otherwise it will not even compile if the graphs have different types of edge descriptors (not to mention it does not make any sense). Note that this is also wrong in the 'literate' documentation provided on the website.
Furthermore the use of "num_vertices" when checking the size of both graphs makes it impossible to use with filtered graphs.
I'm attaching a patch which fixes both these issues.
Attachments (1)
Change History (2)
by , 10 years ago
Attachment: | isomorphism.patch added |
---|
comment:1 by , 10 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
Proposed patch