[Networkit] Feedback req'd: Multi-edges
henning.meyerhenke at kit.edu
Wed Aug 12 09:42:30 CEST 2015
Arie, thanks for pointing this out.
Right now multi-edges are inserted, but the search for a particular edge
stops at its first occurrence. This behavior should be changed.
These are the obvious options:
- Disallow multi-edges, i.e. checking during insertion if an edge
- Proper iteration (likely to slow down numerous algorithms)
- Separate handling of multi-graphs (may require a lot of additional code)
All, could we please get some feedback if and when you need multi-edges?
Thanks a lot,
Am 06.08.15 um 16:54 schrieb Arie Slobbe:
> Hi all,
> Please take a look at the following ipython notebook session.
> G = Graph(2, True, True)
> G.addEdge(0, 1, 2.71)
> G.addEdge(0, 1, 3.14)
> print(G.edges(), " ", G.weight(0, 1))
> [(0, 1), (0, 1)] 2.71
> I'm not completely sure if this multi-edge behavior is intended. In
> particular, there is a method in Graph.cpp called checkConsistency which
> checks for multiedges, suggesting that multiedges are a natural
> extension of NetworKit's Graph object. If that is the case, then should
> G.weight(u, v) return the weight of each occurrence of the edge u->v ?
> Any ideas and suggestions would be much appreciated!
> NetworKit mailing list
> NetworKit at ira.uni-karlsruhe.de
Karlsruhe Institute of Technology (KIT)
Institute of Theoretical Informatics (ITI)
Juniorprof. Dr. Henning Meyerhenke
Theoret. Informatics / Parallel Computing
KIT - University of the State of Baden-Wuerttemberg and
National Research Center of the Helmholtz Association
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 5399 bytes
Desc: S/MIME Cryptographic Signature
More information about the NetworKit