Class DynAPSP

Inheritance Relationships

Base Types

Class Documentation

class DynAPSP : public NetworKit::APSP, public NetworKit::DynAlgorithm

Dynamic APSP.

Public Functions

DynAPSP(const Graph &G)

Creates the object for G.

Parameters:

G – The graph.

virtual void run() override

initialize distances and Pred by repeatedly running the Dijkstra2 algorithm

virtual void update(GraphEvent e) override

Updates the pairwise distances after an edge insertions on the graph. Notice: it works only with edge insertions.

Parameters:

e – The edge insertions.

virtual void updateBatch(const std::vector<GraphEvent> &batch) override

Updates the pairwise distances after a batch of edge insertions on the graph. Notice: it works only with edge insertions.

Parameters:

batch – The batch of edge insertions.

count visPairs()

Returns number of visited pairs

std::vector<node> getPath(node u, node v)

Returns a vector containing a shortest path from node u to node v, and an empty path if u and v are not connected.