Flowlessly  0.1
Minimum cost maximum cost solver
 All Classes Functions Pages
utils.h
1 // The Flowlessly project
2 // Copyright (c) 2013-2016 Ionel Gog <ionel.gog@cl.cam.ac.uk>
3 
4 #ifndef FLOWLESSLY_UTILS_H
5 #define FLOWLESSLY_UTILS_H
6 
7 #include <glog/logging.h>
8 #include <gflags/gflags.h>
9 #include <unistd.h>
10 #include <set>
11 #include <vector>
12 
13 #include "graphs/adjacency_map_graph.h"
14 
15 namespace flowlessly {
16 
23 void BellmanFord(AdjacencyMapGraph* graph, const set<uint32_t>& active_node_ids,
24  vector<uint32_t>* predecessor);
25 void BellmanFordWithoutPotentials(AdjacencyMapGraph* graph,
26  const set<uint32_t>& active_node_ids,
27  vector<uint32_t>* predecessor);
28 
39 uint32_t DijkstraOptimized(AdjacencyMapGraph* graph,
40  const set<uint32_t>& active_node_ids,
41  vector<uint32_t>* predecessor);
42 
50 void DijkstraSimple(AdjacencyMapGraph* graph,
51  const set<uint32_t>& active_node_ids,
52  vector<uint32_t>* predecessor);
53 
63 void MaxFlow(AdjacencyMapGraph* graph);
64 
70 void ReverseMaxFlow(AdjacencyMapGraph* graph);
71 
72 } // namespace flowlessly
73 #endif // FLOWLESSLY_UTILS_H