Camargue
Public Member Functions | Protected Member Functions | Private Attributes | List of all members
CMR::ABC::QprefBrancher< q_pref > Class Template Reference

Class template for branching with priority queue via some preference rule. More...

#include <qpref_brancher.hpp>

Inheritance diagram for CMR::ABC::QprefBrancher< q_pref >:
Inheritance graph
[legend]
Collaboration diagram for CMR::ABC::QprefBrancher< q_pref >:
Collaboration graph
[legend]

Public Member Functions

 QprefBrancher (const Data::Instance &inst, const Data::BestGroup &best_data, const Graph::CoreGraph &core_graph, LP::CoreLP &core_lp)
 
BranchHistory::iterator next_prob ()
 Return the next subproblem to be examined.
 
- Public Member Functions inherited from CMR::ABC::BaseBrancher
 BaseBrancher (const Data::Instance &inst, const Data::BestGroup &bestdata, const Graph::CoreGraph &coregraph, LP::CoreLP &core)
 
void split_prob (BranchHistory::iterator &current)
 Split the current problem, adding the subproblems to branch_history.
 
void do_branch (const BranchNode &B)
 Branch on B, enforcing its constraint and instating its tour.
 
void do_unbranch (const BranchNode &B)
 Unbranch on B and all applicable ancestors to prep next problem.
 
const BranchHistory & get_history ()
 

Protected Member Functions

void fetch_next ()
 Set next_itr to the next subproblem to be examined. More...
 
void enqueue_split (BranchNode::Split prob_array)
 Adding child subproblems to branch_history. More...
 
- Protected Member Functions inherited from CMR::ABC::BaseBrancher
void common_prep_next (const BranchNode &done, const BranchNode &next)
 Execute variable changes if done was just done and next is next. More...
 
bool prune_btour_edges (const BranchNode &done, const BranchNode &next, const BranchNode &common_anc)
 Should branch tour edges be pruned before going to the next problem. More...
 

Private Attributes

std::priority_queue< BranchHistory::iterator, std::vector< BranchHistory::iterator >, BranchNode::Pref > prob_q
 

Additional Inherited Members

- Public Attributes inherited from CMR::ABC::BaseBrancher
int verbose = 0
 
- Protected Attributes inherited from CMR::ABC::BaseBrancher
const Data::Instanceinstance
 
const Data::BestGroupbest_data
 
const Graph::CoreGraphcore_graph
 
LP::CoreLPcore_lp
 
BranchTourFind btour_find
 
Executor exec
 
BranchHistory branch_history
 
BranchHistory::iterator next_itr
 

Detailed Description

template<BranchNode::Pref q_pref>
class CMR::ABC::QprefBrancher< q_pref >

Class template for branching with priority queue via some preference rule.

Template Parameters
q_prefthe ranking function used to instantiate branching relative to a specific node selection criterion.

Member Function Documentation

template<BranchNode::Pref q_pref>
void CMR::ABC::QprefBrancher< q_pref >::enqueue_split ( BranchNode::Split  prob_array)
protectedvirtual

Adding child subproblems to branch_history.

Parameters
prob_arraythe pair of child subproblems to be added. This function shall be implemented to add child subproblems to the list of problems to be processed in a way that preserves the ordering criteria of the node selection rule.

Implements CMR::ABC::BaseBrancher.

template<BranchNode::Pref q_pref>
void CMR::ABC::QprefBrancher< q_pref >::fetch_next ( )
protectedvirtual

Set next_itr to the next subproblem to be examined.

This is effectively the implementation of the node selection rule.

Implements CMR::ABC::BaseBrancher.


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