Aleph-w 7.10.0
A C++ Library for Data Structures and Algorithms
Loading...
Searching...
No Matches
Weighted_Graph Struct Reference
Collaboration diagram for Weighted_Graph:
[legend]

Public Member Functions

 Weighted_Graph (const size_t num_nodes, const size_t num_arcs, const unsigned seed)
 
long weight (IGT::Arc *a) const
 
std::map< IGT::Node *, long > distances_from (IGT::Node *s)
 
long cost_of (const Path< IGT > &path, IGT::Node *s, IGT::Node *t) const
 
long weight_of (IGT &tree) const
 

Public Attributes

IGT g
 
std::vector< IGT::Node * > nodes
 
std::vector< long > weights
 

Detailed Description

Definition at line 1058 of file test_dijkstra.cc.

Constructor & Destructor Documentation

◆ Weighted_Graph()

Weighted_Graph::Weighted_Graph ( const size_t  num_nodes,
const size_t  num_arcs,
const unsigned  seed 
)
inline

Member Function Documentation

◆ cost_of()

long Weighted_Graph::cost_of ( const Path< IGT > &  path,
IGT::Node *  s,
IGT::Node *  t 
) const
inline

◆ distances_from()

std::map< IGT::Node *, long > Weighted_Graph::distances_from ( IGT::Node *  s)
inline

◆ weight()

long Weighted_Graph::weight ( IGT::Arc *  a) const
inline

Definition at line 1090 of file test_dijkstra.cc.

References GTArcCommon< ArcInfo >::get_info(), and weights.

Referenced by Weighted_Graph(), cost_of(), distances_from(), and weight_of().

◆ weight_of()

long Weighted_Graph::weight_of ( IGT &  tree) const
inline

Definition at line 1131 of file test_dijkstra.cc.

References weight().

Member Data Documentation

◆ g

IGT Weighted_Graph::g

Definition at line 1060 of file test_dijkstra.cc.

Referenced by Weighted_Graph(), and distances_from().

◆ nodes

std::vector<IGT::Node *> Weighted_Graph::nodes

Definition at line 1061 of file test_dijkstra.cc.

Referenced by Weighted_Graph().

◆ weights

std::vector<long> Weighted_Graph::weights

Definition at line 1062 of file test_dijkstra.cc.

Referenced by Weighted_Graph(), and weight().


The documentation for this struct was generated from the following file: