↰ Return to documentation for file (include/networkit/scd/ApproximatePageRank.hpp
)
/*
* ApproximatePageRank.hpp
*
* Created on: 26.02.2014
* Author: Henning
*/
#ifndef NETWORKIT_SCD_APPROXIMATE_PAGE_RANK_HPP_
#define NETWORKIT_SCD_APPROXIMATE_PAGE_RANK_HPP_
#include <set>
#include <unordered_map>
#include <vector>
#include <networkit/graph/Graph.hpp>
namespace NetworKit {
class ApproximatePageRank final {
const Graph *g;
double alpha;
double eps;
std::unordered_map<node, std::pair<double, double>> prRes;
public:
ApproximatePageRank(const Graph &g, double alpha, double epsilon = 1e-12);
std::vector<std::pair<node, double>> run(const std::set<node> &seeds);
std::vector<std::pair<node, double>> run(node seed);
};
} /* namespace NetworKit */
#endif // NETWORKIT_SCD_APPROXIMATE_PAGE_RANK_HPP_