4 #ifndef CONICBUNDLE_NNCBOXSUPPORTMODIFICATION_HXX 5 #define CONICBUNDLE_NNCBOXSUPPORTMODIFICATION_HXX 48 CBout(cb,incr),mdf(var_olddim,0,cb,incr,false,true,0.,0.,0.){}
52 {mdf.
clear(var_olddim,0);}
int Integer
all integer numbers in calculations and indexing are of this type
Definition: matop.hxx:40
Base class for informing oracles (or the solver) about dynamic changes in the number and sorting of t...
Definition: CBSolver.hxx:544
int add_reassign_vars(const CH_Matrix_Classes::Indexmatrix &map_to_old)
reassign the variables as given in map_to_old, calls Modification::add_reassign_vars ...
Definition: NNCBoxSupportModification.hxx:73
CH_Matrix_Classes::Integer new_vardim() const
returns the number of variables once all stored modifications have been performed ...
Definition: Modification.hxx:671
bool deleted_variables_are_zero(const CH_Matrix_Classes::Matrix &oldpoint) const
returns true if all entries deleted in oldpoint (must be a vector of length old_vardim()) are 0...
Definition: NNCBoxSupportModification.hxx:123
bool append_to_old() const
returns true if this only contains appending operations and incorporating this is done with respect t...
Definition: Modification.hxx:650
int add_delete_vars(const CH_Matrix_Classes::Indexmatrix &del_ind, CH_Matrix_Classes::Indexmatrix &map_to_old)
delete the variables indexed by del_ind; for each new index map_to_old returns the old one; calls Mod...
Definition: NNCBoxSupportModification.hxx:77
Collects modifications for NNCBoxSupport for appending, deleting or reassigning variables and respect...
Definition: NNCBoxSupportModification.hxx:32
const CH_Matrix_Classes::Indexmatrix * map_to_old_variables() const
returns null if there are no index changes, otherwise the Indexmatrix pointed to is a vector whose i-...
Definition: NNCBoxSupportModification.hxx:191
void set_cbout(const CBout *cb=0, int incr=-1)
see CBout::set_out
Definition: NNCBoxSupportModification.hxx:215
CH_Matrix_Classes::Integer old_vardim() const
returns the number of variables before modification (given on initialization)
Definition: NNCBoxSupportModification.hxx:184
Matrix class for integral values of type Integer
Definition: indexmat.hxx:195
bool no_additions_or_deletions_in_vars() const
returns true if no variables were added or deleted (allows permutations), false otherwise ...
Definition: NNCBoxSupportModification.hxx:117
const CH_Matrix_Classes::Indexmatrix * deleted_var_indices() const
returns null if there were no deletions, otherwise the Indexmatrix pointed to is a vector holding the...
Definition: NNCBoxSupportModification.hxx:195
bool new_variables_are_zero(const CH_Matrix_Classes::Matrix &newpoint) const
returns true if all entries in newpoint (must be a vector of length new_vardim()) that correspond to ...
Definition: NNCBoxSupportModification.hxx:127
base class for collecting and organizing a sequence of changes to linear data so that it can be carri...
Definition: Modification.hxx:207
int get_old_vardim() const
returns the number of variables before modification
Definition: NNCBoxSupportModification.hxx:144
Modification mdf
this class provides a restricted interface to this Modification instance where all modifications are ...
Definition: NNCBoxSupportModification.hxx:36
bool new_variables_are_zero(const CH_Matrix_Classes::Matrix &newpoint) const
returns true if all entries in newpoint (must be a vector of length new_vardim()) that correspond to ...
bool no_modification() const
returns true if no modifications need to be executed except possibly an offset change for the ground ...
Definition: NNCBoxSupportModification.hxx:106
OracleModification * new_initial_oraclemodification(int old_var_dim) const
returns a new object on the heap, that allows to incorporate this but starts off from a function whos...
Definition: NNCBoxSupportModification.hxx:163
const CH_Matrix_Classes::Indexmatrix * map_to_old_variables() const
returns null if there are no index changes, otherwise the Indexmatrix pointed to is a vector whose i-...
Definition: Modification.hxx:684
conic bundle method solver for sum of convex functions. See the ConicBundle_Manual for a quick introd...
Definition: CBSolver.hxx:22
int add_reassign_variables(int new_dim, const int *map_to_old_indices)
reorder and resize the variables as given by the first new_dim entries of map_to_old_indices; each fo...
Definition: NNCBoxSupportModification.hxx:171
bool deleted_variables_are_zero(const CH_Matrix_Classes::Matrix &oldpoint) const
returns true if all entries deleted in oldpoint (must be a vector of length old_vardim()) are 0 and f...
base class for uniform use of WARNINGS and ERRORS (at some point in time)
Definition: CBout.hxx:30
int get_new_vardim() const
returns the number of variables once all stored modifications have been performed ...
Definition: NNCBoxSupportModification.hxx:146
int add_delete_vars(const CH_Matrix_Classes::Indexmatrix &del_ind, CH_Matrix_Classes::Indexmatrix &map_to_old)
delete the variables indexed by the vector del_ind and return the index changes of the others in a ve...
CH_Matrix_Classes::Integer old_vardim() const
returns the number of variables before modification (given on initialization)
Definition: Modification.hxx:669
int apply_to_vars(CH_Matrix_Classes::Matrix *vars, CH_Matrix_Classes::Matrix *lb, CH_Matrix_Classes::Matrix *ub, CH_Matrix_Classes::Matrix *cost) const
carry out the collected modifications on the given vectors
CH_Matrix_Classes::Integer new_vardim() const
returns the number of variables once all stored modifications have been performed ...
Definition: NNCBoxSupportModification.hxx:186
Header declaring the class ConicBundle::ModificationBase.
int add_append_vars(CH_Matrix_Classes::Integer append_dim, const CH_Matrix_Classes::Matrix *append_lb, const CH_Matrix_Classes::Matrix *append_ub)
append append_dim new variables to the box function
Definition: NNCBoxSupportModification.hxx:66
CH_Matrix_Classes::Integer appended_vardim() const
returns the number of variables that are appended (due to later reassignmentds they may no longer be ...
Definition: Modification.hxx:673
int clear(CH_Matrix_Classes::Integer var_olddim, CH_Matrix_Classes::Integer row_olddim, bool ensure_start_val_box_feasibility=false, bool ensure_bounds_consistency=true, CH_Matrix_Classes::Real start_val_def=0., CH_Matrix_Classes::Real bounds_minus_infty=CB_minus_infinity, CH_Matrix_Classes::Real bounds_plus_infty=CB_plus_infinity, CH_Matrix_Classes::Real rhs_minus_infty=CB_minus_infinity, CH_Matrix_Classes::Real rhs_plus_infty=CB_plus_infinity, CH_Matrix_Classes::Real cost_def=0.)
resets all variables so that the object to be modified has starting size var_olddim (number of variab...
int add_reassign_vars(const CH_Matrix_Classes::Indexmatrix &map_to_old)
reassign the current variable indices (with modifications) as specified by map_to_old ...
virtual void set_out(std::ostream *out=0, int print_level=1)
Specifies the output level (out==NULL: no output at all, out!=NULL and level=0: errors and warnings...
int add_append_variables(int append_dim)
append append_dim further variables at the end of the argument vector (without effect on the box func...
Definition: NNCBoxSupportModification.hxx:167
int set_append_to_old(bool append_only)
if set to true, no deletions/reassignments may be present or specified in the future, only appensions are allowed
int set_append_to_old(bool append_only)
if set to true, no deletions/reassignments may be present or specified in the future, only appensions are allowed
Definition: NNCBoxSupportModification.hxx:110
Matrix class for real values of type Real
Definition: matrix.hxx:74
std::ostream * out
not output at all if out==0, otherwise use this output stream
Definition: CBout.hxx:33
void clear(CH_Matrix_Classes::Integer var_olddim)
reset modifications to an unmodified object currently having var_olddim variables, calls Modification::clear
Definition: NNCBoxSupportModification.hxx:51
NNCBoxSupportModification(CH_Matrix_Classes::Integer var_olddim=0, const CBout *cb=0, int incr=-1)
constructor, calls modification constructor
Definition: NNCBoxSupportModification.hxx:45
int print_level
nonnegative level of output, 0 should mean WARNINGS and ERRORS only, 1 should represent normal output...
Definition: CBout.hxx:37
const CH_Matrix_Classes::Indexmatrix * deleted_var_indices() const
returns null if there were no deletions, otherwise the Indexmatrix pointed to is a vector holding the...
Definition: Modification.hxx:688
CH_Matrix_Classes::Integer appended_vardim() const
returns the number of variables that are appended (due to later reassignmentds they may no longer be ...
Definition: NNCBoxSupportModification.hxx:188
bool no_modification() const
returns true if no modifications need to be executed
Integer * get_store()
returns the current address of the internal value array; use cautiously, do not use delete! ...
Definition: indexmat.hxx:427
int incorporate(const OracleModification &m)
incorporate the OracleModification m (it should only contain variable changes, but this is not checke...
Definition: NNCBoxSupportModification.hxx:155
void set_out(std::ostream *out=0, int print_level=1)
see CBout::set_out
Definition: NNCBoxSupportModification.hxx:211
bool mapped_variables_are_equal(const CH_Matrix_Classes::Matrix &newpoint, const CH_Matrix_Classes::Matrix &oldpoint) const
returns true if the values in newpoint (must be a vector of length new_vardim()) that correspond to o...
Definition: NNCBoxSupportModification.hxx:131
const CH_Matrix_Classes::Indexmatrix * new_var_indices() const
returns null if no variables were added, otherwise the Indexmatrix pointed ato is a vector holding th...
Definition: NNCBoxSupportModification.hxx:199
bool append_to_old() const
returns true if this only contains appending operations and incorporating this is done with respect t...
Definition: NNCBoxSupportModification.hxx:113
const CH_Matrix_Classes::Indexmatrix * new_var_indices() const
returns null if no variables were added, otherwise the Indexmatrix pointed to is a vector holding the...
Definition: Modification.hxx:692
void dim(Integer &_nr, Integer &_nc) const
returns the number of rows in _nr and the number of columns in _nc
Definition: indexmat.hxx:315
int apply_to_bounds(CH_Matrix_Classes::Matrix &lb, CH_Matrix_Classes::Matrix &ub) const
carry out the collected modifications on the given vectors of lower and upper bounds on the variables...
Definition: NNCBoxSupportModification.hxx:91
int add_append_vars(CH_Matrix_Classes::Integer append_dim, const CH_Matrix_Classes::Matrix *append_lb, const CH_Matrix_Classes::Matrix *append_ub, const CH_Matrix_Classes::Sparsemat *append_cols, const CH_Matrix_Classes::Matrix *append_start_val, const CH_Matrix_Classes::Matrix *append_linear_costs)
append information on new variables at the respective ends
virtual int incorporate(const Modification &m)
add the modification specified in m on top of the modifications collected so far
bool mapped_variables_are_equal(const CH_Matrix_Classes::Matrix &newpoint, const CH_Matrix_Classes::Matrix &oldpoint) const
returns true if the values in newpoint (must be a vector of length new_vardim()) that correspond to o...
const int * get_map_to_old_variables() const
returns null if there are no index changes, otherwise the Indexmatrix pointed to is a vector whose i-...
Definition: NNCBoxSupportModification.hxx:151
int get_appended_vardim() const
returns the number of variables that are appended (due to later reassignmentds they may no longer be ...
Definition: NNCBoxSupportModification.hxx:148
virtual void set_cbout(const CBout *cb, int incr=-1)
Specifies the output level relative to the given CBout class.