A presolved branching object candidate. More...
#include <BCP_lp_branch.hpp>
Public Member Functions | |
Constructor and destructor | |
BCP_presolved_lp_brobj (BCP_lp_branching_object *candidate) | |
The only one way to construct a presolved branching object is to create it from a regular branching object. | |
~BCP_presolved_lp_brobj () | |
The destructor simply deletes every member (deletes every lpres in the vector). | |
Query methods | |
BCP_lp_branching_object * | candidate () |
Return a pointer to the candidate. | |
const BCP_lp_branching_object * | candidate () const |
Return a const pointer to the candidate. | |
const BCP_lp_result & | lpres (const int child_ind) const |
Return a const reference to the presolved results of the child_ind -th child. | |
BCP_vec< BCP_child_action > & | action () |
Return a reference to the actions to be taken. | |
const BCP_vec< BCP_child_action > & | action () const |
Return a const reference to the actions to be taken. | |
BCP_vec< BCP_user_data * > & | user_data () |
Return a reference to the user data vector. | |
const BCP_vec< BCP_user_data * > & | user_data () const |
Return a const reference to the user data vector. | |
const bool | fathomable (const double objval_limit) const |
Return true if every children can be fathomed. | |
const bool | had_numerical_problems () const |
Return true if at least one child had numerical difficulties while presolving. | |
Modifying methods | |
void | initialize_lower_bound (const double val) |
Fill up obj with the lower bound on each child. | |
void | keep_no_child () |
Fill up obj with the lower bound on each child. | |
bool | is_pruned () const |
Fill up obj with the lower bound on each child. | |
void | get_lower_bounds (BCP_vec< double > &obj) |
Fill up obj with the lower bound on each child. | |
void | set_lower_bounds (const BCP_vec< double > &obj) |
Fill up the lower bounds on the children with the content of obj . | |
void | get_results (OsiSolverInterface &lp, const int child_ind) |
Extract the lp results from the LP solver for the child_ind -th child. | |
void | fake_objective_values (const double itlim_objval) |
Examine the termination codes for the children and for those that do not have a valid lower bound fake the objective value depending on the termination code:. | |
void | swap (BCP_presolved_lp_brobj &rhs) |
swap the two presolved branching object | |
BCP_vec< BCP_vec< BCP_cut * > > & | get_new_cuts () |
Fill up obj with the lower bound on each child. | |
BCP_vec< BCP_vec< BCP_row * > > & | get_new_rows () |
Fill up obj with the lower bound on each child. | |
Private Member Functions | |
Disabled methods | |
BCP_presolved_lp_brobj (const BCP_presolved_lp_brobj &) | |
The copy constructor is declared but not defined to disable it. | |
BCP_presolved_lp_brobj & | operator= (const BCP_presolved_lp_brobj &) |
The assignment operator is declared but not defined to disable it. | |
Private Attributes | |
Data members | |
BCP_lp_branching_object * | _candidate |
A pointer to the branching object (created internally or by the user) whose presolved data is stored in this object. | |
BCP_vec< BCP_lp_result * > | _lpres |
A vector of lp results holding the actual presolved data. | |
BCP_vec< BCP_child_action > | _child_action |
The action to be taken for each child (send back to the TM, keep for diving, prune it). | |
BCP_vec< BCP_user_data * > | _user_data |
The user data to be passed around with the child nodes. | |
BCP_vec< BCP_vec< BCP_cut * > > | _new_cuts |
A pointer to the branching object (created internally or by the user) whose presolved data is stored in this object. | |
BCP_vec< BCP_vec< BCP_row * > > | _new_rows |
A pointer to the branching object (created internally or by the user) whose presolved data is stored in this object. |
A presolved branching object candidate.
During strong branching all children of a branching object (of class [BCP_lp_branching_object
]{BCP_lp_branching_object.html}) are presolved to gain some insight how good it would be to branch on that particular branching object. The results of the presolved children are stored in an object of this type as well as the instructions what to do with each child in case this object is selected for branching.
Definition at line 274 of file BCP_lp_branch.hpp.
BCP_presolved_lp_brobj::BCP_presolved_lp_brobj | ( | const BCP_presolved_lp_brobj & | ) | [private] |
The copy constructor is declared but not defined to disable it.
BCP_presolved_lp_brobj::BCP_presolved_lp_brobj | ( | BCP_lp_branching_object * | candidate | ) | [inline, explicit] |
The only one way to construct a presolved branching object is to create it from a regular branching object.
Definition at line 311 of file BCP_lp_branch.hpp.
BCP_presolved_lp_brobj::~BCP_presolved_lp_brobj | ( | ) | [inline] |
The destructor simply deletes every member (deletes every lpres in the vector).
Definition at line 326 of file BCP_lp_branch.hpp.
BCP_presolved_lp_brobj& BCP_presolved_lp_brobj::operator= | ( | const BCP_presolved_lp_brobj & | ) | [private] |
The assignment operator is declared but not defined to disable it.
BCP_lp_branching_object* BCP_presolved_lp_brobj::candidate | ( | ) | [inline] |
Return a pointer to the candidate.
THINK* : is it necessary to have a non-const version???
Definition at line 341 of file BCP_lp_branch.hpp.
const BCP_lp_branching_object* BCP_presolved_lp_brobj::candidate | ( | ) | const [inline] |
Return a const pointer to the candidate.
Definition at line 345 of file BCP_lp_branch.hpp.
const BCP_lp_result& BCP_presolved_lp_brobj::lpres | ( | const int | child_ind | ) | const [inline] |
Return a const reference to the presolved results of the child_ind
-th child.
Definition at line 350 of file BCP_lp_branch.hpp.
BCP_vec<BCP_child_action>& BCP_presolved_lp_brobj::action | ( | ) | [inline] |
Return a reference to the actions to be taken.
A non-const method is needed, since this is the easiest way to set the entries. Maybe it'd be cleaner to have a separate set method...
Definition at line 356 of file BCP_lp_branch.hpp.
const BCP_vec<BCP_child_action>& BCP_presolved_lp_brobj::action | ( | ) | const [inline] |
Return a const reference to the actions to be taken.
Definition at line 360 of file BCP_lp_branch.hpp.
BCP_vec<BCP_user_data*>& BCP_presolved_lp_brobj::user_data | ( | ) | [inline] |
Return a reference to the user data vector.
A non-const method is needed, since this is the easiest way to set the entries. Maybe it'd be cleaner to have a separate set method...
Definition at line 367 of file BCP_lp_branch.hpp.
const BCP_vec<BCP_user_data*>& BCP_presolved_lp_brobj::user_data | ( | ) | const [inline] |
Return a const reference to the user data vector.
Definition at line 371 of file BCP_lp_branch.hpp.
const bool BCP_presolved_lp_brobj::fathomable | ( | const double | objval_limit | ) | const |
Return true if every children can be fathomed.
(The lower bound for each is above objval_limit
.)
const bool BCP_presolved_lp_brobj::had_numerical_problems | ( | ) | const |
Return true if at least one child had numerical difficulties while presolving.
void BCP_presolved_lp_brobj::initialize_lower_bound | ( | const double | val | ) | [inline] |
Fill up obj
with the lower bound on each child.
Definition at line 385 of file BCP_lp_branch.hpp.
void BCP_presolved_lp_brobj::keep_no_child | ( | ) | [inline] |
Fill up obj
with the lower bound on each child.
Definition at line 390 of file BCP_lp_branch.hpp.
bool BCP_presolved_lp_brobj::is_pruned | ( | ) | const [inline] |
Fill up obj
with the lower bound on each child.
Definition at line 398 of file BCP_lp_branch.hpp.
void BCP_presolved_lp_brobj::get_lower_bounds | ( | BCP_vec< double > & | obj | ) | [inline] |
Fill up obj
with the lower bound on each child.
Definition at line 406 of file BCP_lp_branch.hpp.
void BCP_presolved_lp_brobj::set_lower_bounds | ( | const BCP_vec< double > & | obj | ) | [inline] |
Fill up the lower bounds on the children with the content of obj
.
Definition at line 415 of file BCP_lp_branch.hpp.
void BCP_presolved_lp_brobj::get_results | ( | OsiSolverInterface & | lp, | |
const int | child_ind | |||
) | [inline] |
Extract the lp results from the LP solver for the child_ind
-th child.
This is done immediately after presolving the child.
Definition at line 423 of file BCP_lp_branch.hpp.
void BCP_presolved_lp_brobj::fake_objective_values | ( | const double | itlim_objval | ) |
Examine the termination codes for the children and for those that do not have a valid lower bound fake the objective value depending on the termination code:.
BCP_DBL_MAX
itlim_objval
itlim_objval
void BCP_presolved_lp_brobj::swap | ( | BCP_presolved_lp_brobj & | rhs | ) | [inline] |
swap the two presolved branching object
Definition at line 439 of file BCP_lp_branch.hpp.
Fill up obj
with the lower bound on each child.
Definition at line 447 of file BCP_lp_branch.hpp.
Fill up obj
with the lower bound on each child.
Definition at line 448 of file BCP_lp_branch.hpp.
A pointer to the branching object (created internally or by the user) whose presolved data is stored in this object.
Definition at line 289 of file BCP_lp_branch.hpp.
BCP_vec<BCP_lp_result*> BCP_presolved_lp_brobj::_lpres [private] |
A vector of lp results holding the actual presolved data.
Definition at line 291 of file BCP_lp_branch.hpp.
The action to be taken for each child (send back to the TM, keep for diving, prune it).
Note that this member is created if and only if the object is selected for branching.
Definition at line 296 of file BCP_lp_branch.hpp.
BCP_vec<BCP_user_data*> BCP_presolved_lp_brobj::_user_data [private] |
The user data to be passed around with the child nodes.
Note that this member is created if and only if the object is selected for branching.
Definition at line 300 of file BCP_lp_branch.hpp.
BCP_vec< BCP_vec<BCP_cut*> > BCP_presolved_lp_brobj::_new_cuts [private] |
A pointer to the branching object (created internally or by the user) whose presolved data is stored in this object.
Definition at line 302 of file BCP_lp_branch.hpp.
BCP_vec< BCP_vec<BCP_row*> > BCP_presolved_lp_brobj::_new_rows [private] |
A pointer to the branching object (created internally or by the user) whose presolved data is stored in this object.
Definition at line 303 of file BCP_lp_branch.hpp.