Template Class ModularityScoring

Inheritance Relationships

Base Type

Class Documentation

template<typename T>
class ModularityScoring : public NetworKit::EdgeScoring<T>

Public Functions

ModularityScoring(Graph &G, double gTotalEdgeWeight = 0.0)

Do not modify the graph while using this instance of ModularityScoring.

Parameters:

G[in] a graph instance

~ModularityScoring() override = default

Default destructor

virtual void scoreEdges(int attrId) override
inline virtual T edgeScore(node u, node v) const override

Returns an edge score for an edge (u,v) which expresses the modularity increase which can be gained by merging the clusters of u and v.

$$\Delta mod(c, d) := \frac{1}{2 \omega(E)} \left ( 2 \omega(E) \omega(c,d) - \omega(c) \omega(d) \right ) $$

Parameters:
  • u[in] source node id

  • v[out] target node id