In our use of the boost ressource constrained shortest path from
Boost BGL, we define problem specific ressource extension and
dominance function on a user defined graph type mcf_graph (source
code is posted below)
Our problem is the use of a filtered graph into the resource
function. The forfeited edge filter stated in the code below, tries
to remove some of the edges in order to speed up the algorithm. It
seems that the resource and extension functions do not know how to
deal with the filtered graph (I am guessing because they are not
template functions), although the filtered graph contains the same
Edge and Vertex definitions as the MCF graph, it is not typewise
recognised as an mcf_graph, because it also contains the filter map.
Is there any way I can work around this? I tried making the resource
and extension functions into templates, but this is a problem
because my edge bundled properties are problem specific. I would
truly appreciate any suggestions as a filter is preferable to
copying the graph.
// data structures for shortest path problem with transit time
constraints (spptt)
// ResourceContainer model
struct spp_spptt_res_cont
{
spp_spptt_res_cont( double c = 0, double t = 0 ) : cost( c ),
time( t ) {}
spp_spptt_res_cont& operator=( const spp_spptt_res_cont&
other )
{
if( this == &other )
return *this;
this->~spp_spptt_res_cont();
new( this ) spp_spptt_res_cont( other );
return *this;
}
double cost;
double time;
};