Tracore
KShortestPaths4.h
1 //
2 // Created by wrede on 24.06.16.
3 //
4 
5 #ifndef GBMOT_KSHORTESTPATHS4_H
6 #define GBMOT_KSHORTESTPATHS4_H
7 
8 #include "../graph/Definitions.h"
9 
10 namespace algo
11 {
13  {
14  private:
15  DirectedGraph graph_;
16  Vertex source_;
17  Vertex sink_;
18  VertexDistanceMap vertex_labels_;
19  VertexDistanceMap vertex_distances_;
20  VertexVertexMap vertex_predecessors_;
21  std::vector<Vertex> vertex_candidates_;
22 
23  std::vector<std::list<Vertex>> i_shortest_paths_;
24 
25  size_t max_paths_count_;
26 
27  size_t total_paths_count_;
28  double total_paths_distance_;
29 
30  void Initialization();
31  void InterlacingConstruction();
32  void NeighborDistanceTest(Vertex r);
33  void NegativeInterlacing(Vertex input);
34  void FeasibleTermination();
35  void NonFeasibleTermination();
36 
37  bool Contains(std::vector<Vertex>& vector, Vertex& element);
38  bool Contains(std::list<Vertex>& list, Vertex& element);
39  public:
40  KShortestPaths4(DirectedGraph graph, Vertex source, Vertex sink, size_t max_paths_count);
41  void Run();
42  };
43 }
44 
45 #endif //GBMOT_KSHORTESTPATHS4_H
Definition: KShortestPaths4.h:12
Definition: Berclaz.cpp:13