3 #ifndef CONICBUNDLE_SUMBLOCKMODEL_HXX 4 #define CONICBUNDLE_SUMBLOCKMODEL_HXX 135 virtual void clear();
int Integer
all integer numbers in calculations and indexing are of this type
Definition: matop.hxx:40
virtual const PrimalData * get_candidate_primal() const
return the PrimalData delivered by the last call of FunctionOracle::evaluate()
Definition: BundleData.hxx:264
virtual CH_Tools::Microseconds get_preeval_time() const
return time spent in total for the oracle in eval_function()
Definition: SumBlockModel.hxx:668
MinorantPointer old_model_aggregate
for testing purposes
Definition: SumBlockModel.hxx:127
virtual int set_bundle_parameters(const BundleParameters &)
set max_bundle_size and max_model_size (this may differ if the parameter is a recognized derived clas...
Definition: SumBlockModel.hxx:618
abstract interface that allows to use different -norms with a positive definite matrix in the proxi...
Definition: BundleProxObject.hxx:88
bool call_aftmodel_first(const FunObjModMap &funmdfmap)
in apply_modification this routine is needed to check whether the aftmodel is modified already ...
std::ostream & print_statistics(std::ostream &out) const
output the timing statistics
abstract interface extending BundleModel so that any such model can be used alone or within SumModel ...
Definition: SumBlockModel.hxx:102
virtual int apply_modification(bool &no_changes, const GroundsetModification &gsmdf, const FunObjModMap &funmdfmap, CH_Matrix_Classes::Integer new_center_id, const CH_Matrix_Classes::Matrix &new_center, CH_Matrix_Classes::Integer old_center_id, const CH_Matrix_Classes::Matrix &old_center)
passes on modification information about function and ground set changes
CH_Tools::Microseconds eval_time
total time spent in the oracle in eval_function() or calls to eval_function of children ...
Definition: SumBlockModel.hxx:108
double Real
all real numbers in calculations are of this type
Definition: matop.hxx:50
virtual CH_Matrix_Classes::Real lb_function(CH_Matrix_Classes::Integer y_id, const CH_Matrix_Classes::Matrix &y)
returns a quick lower bound for the function value at y (eg by a previous subgradient) ...
const AFTModel * get_aftmodel() const
returns aftmodel (as a const variant)
Definition: SumBlockModel.hxx:569
virtual const PrimalData * get_approximate_primal() const
return the PrimalData corresponding to the aggregate
Definition: BundleData.hxx:258
abstract interface for automatically generating and retrieving the qp blocks with the model data that...
Definition: QPModelDataObject.hxx:298
virtual ModifiableOracleObject * get_oracle_object()=0
return the function oracle this provides a model for, or some dummy oracle
SumBlockModel(CBout *cb=0, int cbinc=-1)
calls clear
the SumBundle/part is maybe maintained but currently not in use anywhere
Definition: SumBundle.hxx:197
Header declaring the class ConicBundle::SumBundleHandler (see ConicBundle::SumBlockModel) ...
virtual void clear_aggregates()
remove all current aggregate cutting planes, but not the other parts of the model; returns 0 on succe...
Definition: SumBlockModel.hxx:646
virtual const SumBlockModel * model(const FunctionObject *) const
returns the submodel for FunctionObject fo if it in this model, otherwise 0
Definition: SumBlockModel.hxx:170
virtual int update_model(ModelUpdate model_update, CH_Matrix_Classes::Integer center_id, const CH_Matrix_Classes::Matrix ¢er_y, CH_Matrix_Classes::Integer cand_id, const CH_Matrix_Classes::Matrix &cand_y, CH_Matrix_Classes::Real model_maxviol, BundleProxObject &H)=0
generate the next cutting model and store the center information in the case of a descent step ...
virtual void clear()
resets all data to the initial status of this class, also aftmodel and vm_selection are deleted ...
Matrix class for integral values of type Integer
Definition: indexmat.hxx:195
int get_function_minorant(CH_Matrix_Classes::Integer &function_modification_id, MinorantPointer &minorant)
see BundleModel::get_function_minorant()
virtual CH_Matrix_Classes::Integer nsubmodels() const
returns the number of submodels in this model (direct ones, not all descendants; most have none...
Definition: SumBlockModel.hxx:174
the latest function evaluation and its subgradient give rise to a descent step, preserving the aggreg...
Definition: BundleModel.hxx:151
virtual int set_variable_metric_selection(VariableMetricSelection *vms=0)
delete old selector and set a new one (0 is allowed resulting in no local selector) ...
Definition: SumBlockModel.hxx:141
CH_Tools::Microseconds metric_time
total time spent in add_variable_metric()
Definition: SumBlockModel.hxx:111
abstract interface for SumBundleHandler for the model selection and variable metric seletcion routine...
Definition: SumBundleParametersObject.hxx:50
Mode
specifies for different parts of the sumbundle whether it is active and who is responsible for handli...
Definition: SumBundle.hxx:194
virtual void clear_aggregates()
delete all kinds of aggregates but keep explicit parts of the cutting model
virtual SumBlockModel * remove_model(const FunctionObject *)
remove the submodel identified by fo from this model, this does NOT destruct the model. It returns the pointer to the model if there is one, otherwise 0
Definition: SumBlockModel.hxx:182
conic bundle method solver for sum of convex functions. See the ConicBundle_Manual for a quick introd...
Definition: CBSolver.hxx:22
virtual ~SumBlockModel()
destructor
CH_Tools::Microseconds get_updatemodel_time() const
return time spent in total for updating the model in update_model()
Definition: SumBlockModel.hxx:666
base class for uniform use of WARNINGS and ERRORS (at some point in time)
Definition: CBout.hxx:30
ModelUpdate
for informing update_model() at what stage it is called to update the bundle so that the amount of in...
Definition: BundleModel.hxx:149
virtual int set_data(BundleData *)
reinstalls the bundle date from get_data() for continuing from this previous point, see BundleData
Definition: SumBlockModel.hxx:578
virtual const PrimalData * get_center_primal() const
if primal data is provided by the oracle then the primal corresponding to the best eps-subgradient of...
Definition: SumBlockModel.hxx:592
virtual int synchronize_ids(CH_Matrix_Classes::Integer &new_center_ub_fid, CH_Matrix_Classes::Integer new_center_id, CH_Matrix_Classes::Integer old_center_id, CH_Matrix_Classes::Integer &new_cand_ub_fid, CH_Matrix_Classes::Integer new_cand_id, CH_Matrix_Classes::Integer old_cand_id, CH_Matrix_Classes::Integer &new_aggregate_id)
see BundleModel::synchronize_ids
SumBundleHandler * bundlehandler
if the sumbundle is used, this points to the handler that operates it
Definition: SumBlockModel.hxx:121
virtual SumBlockModel * remove_model(SumBlockModel *model)
remove the submodel identified by the given models FunctionObject from this model, this does NOT destruct the model. It returns the pointer to the model if there is one, otherwise 0
Definition: SumBlockModel.hxx:186
virtual int adjust_multiplier(bool &values_may_have_changed)=0
for conic subproblems with adjustable multipliers, reset the multiplier to twice the current trace an...
virtual int get_model_aggregate(CH_Matrix_Classes::Integer &model_aggregate_id, MinorantPointer &model_aggregate)
see BundleModel::get_model_aggregate
Serves for specifying parameters regarding the construction of cutting models.
Definition: CBSolver.hxx:891
CH_Tools::Clock clock
for collecting time statistics
Definition: SumBlockModel.hxx:105
virtual const BundleParameters * get_bundle_parameters() const
returns the current parameter settings; model blocks without bundle parameters return NULL...
Definition: SumBlockModel.hxx:624
virtual void clear_model(bool discard_minorants_only=false)
modifications of this specific problem were such that old subgradient data and function values have t...
Definition: SumBlockModel.hxx:642
mimicks the model of a function with an AffineFunctionTransformation (AFT) applied to it...
Definition: AFTModel.hxx:50
virtual int get_ret_code() const
for functions given by an oracle: return the return value that was produced by the last call to the f...
Definition: SumBlockModel.hxx:653
CH_Tools::Microseconds preeval_time
total time spent in eval_function() before the oracle call
Definition: SumBlockModel.hxx:109
interface class that allows a VariableMetricModel to contribute information to a VariableMetric objec...
Definition: VariableMetric.hxx:309
virtual CH_Tools::Microseconds get_eval_time() const
return time spent in total for the oracle in eval_function()
Definition: SumBlockModel.hxx:670
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...
void set_out(std::ostream *o=0, int pril=1)
set output and outputlevel of warnings and errors recursively, see CBout
Definition: SumBlockModel.hxx:680
virtual int call_primal_extender(PrimalExtender &, bool include_candidates=true)
see the last argument of FunctionOracle::evaluate()
virtual const PrimalData * get_approximate_primal() const
if primal data is provided by the oracle then the primal corresponding to the current aggregate is fo...
Definition: SumBlockModel.hxx:584
virtual CH_Tools::Microseconds get_posteval_time() const
return time spent in total for the oracle in eval_function()
Definition: SumBlockModel.hxx:672
virtual bool model_aggregate_modified(CH_Matrix_Classes::Integer old_model_aggregate_id)
see BundleModel::model_aggregate_modified
SumBundleParametersObject * sumbundle_parameters
this holds the default settings whether and how to start or contribute to a SumBundle ...
Definition: SumBlockModel.hxx:123
Header declaring the class ConicBundle::BundleData (see ConicBundle::SumBlockModel) ...
int get_center_minorant(CH_Matrix_Classes::Integer &function_modification_id, MinorantPointer &minorant)
see BundleModel::get_center_minorant()
ModifiableOracle provides all oracles with a uniform interface for a modification routine and an on/o...
Definition: MatrixCBSolver.hxx:309
Matrix class for real values of type Real
Definition: matrix.hxx:74
abstract interface, that allows to specify a routine for providing or computing a suitable variable m...
Definition: VariableMetric.hxx:237
virtual int start_sumaugmodel(QPModelDataPointer &blockp, CH_Matrix_Classes::Integer cand_id, const CH_Matrix_Classes::Matrix &cand_y, const CH_Matrix_Classes::Indexmatrix *indices=0, SumBundleHandler *bh=0, SumBundle::Mode mode=SumBundle::inactive, AffineFunctionTransformation *aft=0)=0
see BundleModel::start_augmodel() for the first four parameters; for the others see sumbundle_mode() ...
std::map< const FunctionObject *, FunctionObjectModification > FunObjModMap
In order to pass on problem modifications, FunObjModMap allows to specify a FunctionObjectModificatio...
Definition: FunctionObjectModification.hxx:104
std::ostream * out
not output at all if out==0, otherwise use this output stream
Definition: CBout.hxx:33
virtual int call_primal_extender(PrimalExtender &pext)
if the function is the Lagrangian dual and primal_data of previous calls has now to be updated due to...
Definition: SumBlockModel.hxx:611
routines for updating and handling SumBundle components, possibly by cooperating over several recursi...
Definition: SumBundleHandler.hxx:42
abstract interface for BundleSolver giving access to all objective function specific bundle routines ...
Definition: BundleModel.hxx:140
VariableMetricSelection * vm_selection
if not NULL this points to the selection routine for computing the local contribution to the metric ...
Definition: SumBlockModel.hxx:117
CH_Tools::Microseconds posteval_time
total time spent in eval_function() after the oracle call
Definition: SumBlockModel.hxx:110
virtual bool center_modified(CH_Matrix_Classes::Integer ¢er_fid, CH_Matrix_Classes::Integer center_id)
see BundleModel::center_modified
CH_Tools::Microseconds get_metric_time() const
return time spent in total for the add_variable_metric routine
Definition: SumBlockModel.hxx:674
int get_print_level() const
returns the print_level
Definition: CBout.hxx:93
virtual VariableMetricSelection * get_variable_metric_selection() const
delete old selector and set a new one (0 is allowed resulting in no local selector) ...
Definition: SumBlockModel.hxx:145
Header declaring the classes ConicBundle::MatrixCBSolver, ConicBundle::MatrixFunctionOracle, ConicBundle::PrimalMatrix, ConicBundle::MatrixMinorant, ConicBundle::ModifiableOracleObject.
CH_Tools::Microseconds evalmodel_time
total time spent in evaluating the model in eval_model()
Definition: SumBlockModel.hxx:106
basic function object (abstract class). It serves for using the same interface on distinct oracle typ...
Definition: CBSolver.hxx:236
virtual BundleData * get_data()=0
returns the essential information on the bundle date for continuing from the same point lateron...
In Lagrangean relaxation an approximate primal solution can be generated by supplying primal informat...
Definition: CBSolver.hxx:151
virtual int start_augmodel(QPModelDataPointer &blockp, CH_Matrix_Classes::Integer cand_id, const CH_Matrix_Classes::Matrix &cand_y, const CH_Matrix_Classes::Indexmatrix *indices=0)
see BundleModel::start_augmodel, here it just moves on to start_sumaugmodel
Collects modifications for the unconstrained Groundset for appending, deleting or reassigning variabl...
Definition: GroundsetModification.hxx:32
std::ostream * get_out_ptr() const
returns the pointer to the output stream
Definition: CBout.hxx:88
Header declaring and (inline) implementing the classes CH_Tools::Microseconds and CH_Tools::Clock as ...
virtual void clear_model(bool discard_minorants_only=false)
clear the cutting model and all function evaluations; for special cutting models of support functions...
Interface for extending PrimalData, e.g., in Lagrangian relaxation of column generation approaches...
Definition: CBSolver.hxx:180
virtual const PrimalData * get_center_primal() const
return the PrimalData corresponding to the aggregate
Definition: BundleData.hxx:261
CH_Tools::Microseconds get_evalmodel_time() const
return time spent in total for evaluating the model in eval_model()
Definition: SumBlockModel.hxx:664
virtual int set_sumbundle_parameters(const BundleParameters &)
set max_bundle_size and max_model_size (this may differ if the parameter is a derived class...
int initialize_aft(AffineFunctionTransformation *aft=0)
first it discards an old affine function transformation if there is one, then it sets the new one...
base class for use with SumBlockModel for storing and managing essential data of evaluations and the ...
Definition: BundleData.hxx:77
BundleModel * transform()
if an affine function transformation is defined for this model, return it, otherwise use this ...
SumBlockModel * sbm_transform()
like BundleModel::transform() this allows SumBlockModel routines to use a given transformation automa...
virtual int add_model(SumBlockModel *)
adds the model as submodel to this model (if this model may have submodels)
Definition: SumBlockModel.hxx:178
AFTModel * aftmodel
if not NULL this points to an AFTModel describing an AffineFunctionTransformation ...
Definition: SumBlockModel.hxx:114
virtual int sumbundle_mode(SumBundle::Mode &mode, SumBundleHandler *bh=0, AffineFunctionTransformation *aft=0)=0
called by start_sumaugmodel in order to suggest (or to force) *this to opt in or out of a common SumB...
CH_Tools::Microseconds updatemodel_time
total time spent in updating the bundle in update_model()
Definition: SumBlockModel.hxx:107
points to MinorantUseData that may be shared by many and allows computations with Minorants ...
Definition: MinorantPointer.hxx:34
Header declaring the class ConicBundle::BundleModel.
AFTModel * get_aftmodel()
returns aftmodel
Definition: SumBlockModel.hxx:566
void set_cbout(const CBout *cb, int incr)
set output and outputlevel of warnings and errors recursively with CBout
Definition: SumBlockModel.hxx:689
virtual const SumBundleParametersObject * get_sumbundle_parameters() const
returns the current parameter settings; model blocks without bundle parameters return NULL...
Definition: SumBlockModel.hxx:637
virtual void set_cbout(const CBout *cb, int incr=-1)
Specifies the output level relative to the given CBout class.
virtual const PrimalData * get_candidate_primal() const
if primal data is provided by the oracle then the primal corresponding to the best eps-subgradient of...
Definition: SumBlockModel.hxx:600
int add_variable_metric(VariableMetric &H, CH_Matrix_Classes::Integer y_id, const CH_Matrix_Classes::Matrix &y, bool descent_step, CH_Matrix_Classes::Real weightu, CH_Matrix_Classes::Real model_maxviol, const CH_Matrix_Classes::Indexmatrix *indices=0)
see VariableMetricModel::add_variable_metric; this implements the non local option ...