Skip to content

Commit

Permalink
Truncate input from MCB (last vertex is the same which was not expect…
Browse files Browse the repository at this point in the history
…ed by new Path()).

Signed-off-by: Egon Willighagen <egonw@users.sourceforge.net>
  • Loading branch information
johnmay authored and egonw committed Oct 14, 2013
1 parent f344f7d commit 9bf8f73
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/main/org/openscience/cdk/graph/TripletShortCycles.java
Expand Up @@ -264,7 +264,7 @@ public TripletShortCycles(final MinimumCycleBasis mcb, final boolean canonical)

// all minimum cycle basis paths belong to the set
for (final int[] path : mcb.paths())
basis.add(new Path(path));
basis.add(new Path(Arrays.copyOf(path, path.length - 1)));

// count the number of cycles each vertex belongs to and try to find a
// cycle though the triple of 'v' and two of it's neighbors
Expand Down

0 comments on commit 9bf8f73

Please sign in to comment.