Repository navigation
v0.8.2
This release fixes four bugs. No functions or types changed, so upgrading needs no code changes:
go get github.com/hmdsefi/gograph@v0.8.2
Bug fixes
GirvanNewmanremoved every edge tied for the highest betweenness at once, so it could split the graph into more than k communities. It now removes one edge per step and returns exactly k communities when the graph has at least k vertices and at most k connected components. Reported in #101, fixed in #178.RandomizedKCutkept only one cut edge between two supernodes, and returned no cut edges when k was the number of vertices. It now returns every edge between two different supernodes. Reported in #102, fixed in #179.Gabowran the same search asTarjan. It now runs Gabow's path-based algorithm. The result is the same as before, including the order of the components. Reported in #105, fixed in #180.TransitiveReductionreturned a graph withoutAcyclic()even when the input was created with it, soAddEdgeon the result accepted edges that create a cycle. Reported in #148, fixed in #197.
Behavior changes
- When several edges tie for the highest betweenness,
GirvanNewmancan split the graph differently than before. Its communities now keep the vertex and edge weights, and are weighted when the input graph is. RandomizedKCutlists every edge between two supernodes, so its cut can have more edges than before. Its supernodes follow the order ofGetAllVertices().- For an acyclic input,
AddEdgeon the result ofTransitiveReductionnow returns an error for an edge that would create a cycle.
Docs
- Doc comments that were out of date or copied from other functions are fixed, including the closest-first iterator, which was described as a random walk (#150, #184).
Thanks to @pollychen-lab and @HarshRajSinghania for their first contributions.
Full Changelog: v0.8.1...v0.8.2