-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdnh.h
45 lines (33 loc) · 1.55 KB
/
dnh.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
/***************************************************************************
dnh.h - description
-------------------
begin : Mon Oct 3 2005
copyright : (C) 2005 by Knut-Helge Vik
email : knuthelv@ifi.uio.no
***************************************************************************/
#ifndef GRAPHALGO_DISTANCE_NETWORK_HEURISTIC_KHV
#define GRAPHALGO_DISTANCE_NETWORK_HEURISTIC_KHV
// My Includes
#include "steiner_class.h"
#include "../treealgs/treestructure.h"
using namespace boost;
using namespace TreeAlgorithms;
class DistanceNetworkHeuristic : SteinerHeuristic
{
private:
TreeStructure &T_dnh; // Stores the DNH tree
public:
DistanceNetworkHeuristic(const TreeStructure &in, TreeStructure &out) : SteinerHeuristic(in), T_dnh(out) {}
~DistanceNetworkHeuristic() { }
// Distance Network Heuristic main function
void Algorithm(vertex_descriptorN zsource);
// Distance Network Heuristic helper functions
void ConstructDNGraph(GraphN &DNGraph, vertex_descriptorN zsource, vertex_descriptorN &dngzsource);
void FindMST(GraphN &DNGraph, vertex_descriptorN zsource, ShortestPathKeeper &spk);
void ConstructSPGraph(const GraphN &dn_graph, GraphN &sp_graph, const ShortestPathKeeper &spk);
void ConstructDNHeuristicGraph(GraphN &dnh_graph, GraphN &temp_sp_graph);
void ConstructDNHTree(GraphN &dnh_graph, const ShortestPathKeeper &dnh_mst);
// Tiny test
//void DNHTest(GraphN &dnh_graph);
};
#endif /* GRAPHALGO_DISTANCE_NETWORK_HEURISTIC_KHV */