All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Closeness.h
Go to the documentation of this file.
1 /*
2  * Closeness.h
3  *
4  * Created on: 03.10.2014
5  * Author: nemes
6  */
7 
8 #ifndef CLOSENESS_H_
9 #define CLOSENESS_H_
10 
11 #include "Centrality.h"
12 
13 namespace NetworKit {
14 
19 public:
30  Closeness(const Graph& G, bool normalized=true, bool checkConnectedness=true);
31 
35  void run() override;
36 
37  /*
38  * Returns the maximum possible Closeness a node can have in a graph with the same amount of nodes (=a star)
39  */
40  double maximum() override;
41 };
42 
43 } /* namespace NetworKit */
44 
45 #endif /* CLOSENESS_H_ */
double maximum() override
Get the theoretical maximum of centrality score in the given graph.
Definition: Closeness.cpp:69
Definition: Closeness.h:18
bool normalized
Definition: Centrality.h:94
void run() override
Computes closeness cetrality on the graph passed in constructor.
Definition: Closeness.cpp:34
Closeness(const Graph &G, bool normalized=true, bool checkConnectedness=true)
Constructs the Closeness class for the given Graph G.
Definition: Closeness.cpp:23
const Graph & G
Definition: Centrality.h:91
Abstract base class for centrality measures.
Definition: Centrality.h:20
A graph (with optional weights) and parallel iterator methods.
Definition: Graph.h:79