3 #ifndef CONICBUNDLE_AFTMODEL_HXX 4 #define CONICBUNDLE_AFTMODEL_HXX 153 bool in_model_is_owner=
false,
212 bool accept_only_higher_values=
false,
258 bool keep_penalty_fixed);
344 void clear_model(
bool discard_minorants_only=
false);
const CH_Matrix_Classes::Matrix & generate_aft_cand(CH_Matrix_Classes::Integer cand_id, const CH_Matrix_Classes::Matrix &cand_y)
computes and returns a reference to the transformed point (maybe the input point itself, if identity) and assigns a new aftpoint_id if necessary
int Integer
all integer numbers in calculations and indexing are of this type
Definition: matop.hxx:40
virtual CH_Tools::Microseconds get_preeval_time() const
return time spent in total for the oracle in eval_function()
Definition: SumBlockModel.hxx:668
Header declaring the class ConicBundle::SumBlockModel.
abstract interface that allows to use different -norms with a positive definite matrix in the proxi...
Definition: BundleProxObject.hxx:88
int check_function_id_change(CH_Matrix_Classes::Integer function_id)
if a call to some function evaluation returned an increased function_id, this increases data...
ModifiableOracleObject * get_oracle_object()
as AFTModel has no oracle of its own, this returns the dummy oracle
Definition: AFTModel.hxx:252
abstract interface extending BundleModel so that any such model can be used alone or within SumModel ...
Definition: SumBlockModel.hxx:102
virtual int call_primal_extender(PrimalExtender &)
an AFT has no primals, so it returns 1, see SumBlockModel::call_primal_extender
Definition: AFTModel.hxx:335
int sumbundle_mode(SumBundle::Mode &mode, SumBundleHandler *bh=0, AffineFunctionTransformation *aft=0)
see SumBlockModel::sumbundle_mode
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
void set_out(std::ostream *o=0, int pril=1)
set output and outputlevel of warnings and errors recursively, see CBout
Definition: AFTModel.hxx:399
double Real
all real numbers in calculations are of this type
Definition: matop.hxx:50
QPConeModelDataObject * block
usually not used, but if aft->get_fun_coeff()==0 an empty block may have to be returned ...
Definition: AFTModel.hxx:81
CH_Matrix_Classes::Integer ncalls
number of calls to model->eval_function or model->recompute_center
Definition: AFTModel.hxx:69
abstract interface for automatically generating and retrieving the qp blocks with the model data that...
Definition: QPModelDataObject.hxx:298
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)
see BundleModel::apply_modfication(CH_Matrix_Classes::Integer,const CH_Matrix_Classes::Matrix&,CH_Matrix_Classes::Integer,const CH_Matrix_Classes::Matrix&,const FunObjModMap&,const GroundsetModification&)
the SumBundle/part is maybe maintained but currently not in use anywhere
Definition: SumBundle.hxx:197
CH_Matrix_Classes::Indexmatrix qp_indices
if its dimension is >0 it gives the (ordered) subset of indices for which subgradient entries are nee...
Definition: AFTModel.hxx:87
Matrix class for integral values of type Integer
Definition: indexmat.hxx:195
AFTData data
the relevant data for running BundleSolver consistently
Definition: AFTModel.hxx:65
int compute_qp_data(const CH_Matrix_Classes::Indexmatrix *indices=0) const
checks whether it is necessary to precompute the qp_data and does so if required
std::ostream & output_bundle_data(std::ostream &out) const
this outputs the qp model data recursively for testing purposes
CH_Matrix_Classes::Real lb_function(CH_Matrix_Classes::Integer y_id, const CH_Matrix_Classes::Matrix &y)
see SumBlockModel::lb_function
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
const PrimalData * get_approximate_primal() const
an AFT has no primals, so it returns 1, see SumBlockModel::get_approximate_primal ...
Definition: AFTModel.hxx:325
abstract interface extension of QPModelDataObject to allow uniform generation of tuned quadratic solv...
Definition: QPModelDataObject.hxx:144
the latest function evaluation and its subgradient give rise to a descent step, preserving the aggreg...
Definition: BundleModel.hxx:151
virtual void clear()
overloads the SumBlockModel::clear calling the other clear with parameter 0
Definition: AFTModel.hxx:147
Header declaring the class ConicBundle::AFTData (needed for ConicBundle::ConvexProblem) ...
int recompute_center(CH_Matrix_Classes::Integer &new_center_ub_fid, CH_Matrix_Classes::Real &new_center_ub, CH_Matrix_Classes::Integer center_id, const CH_Matrix_Classes::Matrix &y, bool accept_only_higher_values=false, CH_Matrix_Classes::Real relprec=-1.)
see BundleModel::recompute_center
int provide_model_aggregate(CH_Matrix_Classes::Integer y_id, const CH_Matrix_Classes::Matrix &y)
see BundleModel::provide_model_aggregate
Mode
specifies for different parts of the sumbundle whether it is active and who is responsible for handli...
Definition: SumBundle.hxx:194
SumBlockModel * cond_model_trafo()
returns model if model_is_owner, and model->sbm_transform() otherwise
Definition: AFTModel.hxx:95
conic bundle method solver for sum of convex functions. See the ConicBundle_Manual for a quick introd...
Definition: CBSolver.hxx:22
int add_variable_metric(VariableMetric &H, CH_Matrix_Classes::Integer center_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 DynamicScaling
BundleParameters * get_bundle_parameters() const
an AFT has no bundle, so it returns 1, see SumBlockModel::get_bundle_parameters
Definition: AFTModel.hxx:341
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
bool model_is_owner
the following is true if the model above is the owner of this AFTModel
Definition: AFTModel.hxx:57
AFTModel(SumBlockModel *in_model, AffineFunctionTransformation *inaft=0, CH_Matrix_Classes::Integer start_modification_id=0, bool in_model_is_owner=false, CBout *cb=0)
sets model to in_model and model_is_owner to in_model_is_owner (or false if in_model==0) and calls cl...
ModifiableOracleObject dummy_oracle
the oracle object of this model
Definition: AFTModel.hxx:59
int set_data(BundleData *bd)
see SumBlockModel::set_data
Definition: AFTModel.hxx:316
int eval_model(CH_Matrix_Classes::Real &lb, CH_Matrix_Classes::Integer y_id, const CH_Matrix_Classes::Matrix &y, CH_Matrix_Classes::Real relprec)
see BundleModel::eval_model
int check_center_validity_by_candidate(bool &cand_minorant_is_below, CH_Matrix_Classes::Integer center_id, const CH_Matrix_Classes::Matrix ¢er_y)
see BundleModel::check_center_validity_by_candidate
int make_model_aggregate(bool &penalty_parameter_increased, bool keep_penalty_fixed)
see SumBlockModel::make_model_aggregate
Serves for specifying parameters regarding the construction of cutting models.
Definition: CBSolver.hxx:891
SumBlockModel * model
points to the model which this AFT works on
Definition: AFTModel.hxx:55
bool center_modified(CH_Matrix_Classes::Integer ¢er_ub_fid, CH_Matrix_Classes::Integer center_id)
see BundleModel::center_modified
virtual CH_Tools::Microseconds get_posteval_time() const
see SumBlockModel::get_posteval_time()
Definition: AFTModel.hxx:391
mimicks the model of a function with an AffineFunctionTransformation (AFT) applied to it...
Definition: AFTModel.hxx:50
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 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)
see BundleModel::start_augmodel() for the first four parameters; for the others see sumbundle_contrib...
const BundleData * get_data() const
see SumBlockModel::get_data
Definition: AFTModel.hxx:313
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 CH_Tools::Microseconds get_posteval_time() const
return time spent in total for the oracle in eval_function()
Definition: SumBlockModel.hxx:672
virtual CH_Tools::Microseconds get_preeval_time() const
see SumBlockModel::get_preeval_time()
Definition: AFTModel.hxx:376
MinorantPointer cand_minorant
the (lazy) transformed minorant in the candidate
Definition: AFTModel.hxx:73
int adjust_multiplier(bool &values_may_have_changed)
see SumBlockModel::adjust_multiplier
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)
see BundleModel::update_model
const SumBlockModel * cond_model_trafo() const
const version of cond_model_trafo
Definition: AFTModel.hxx:98
CH_Matrix_Classes::Indexmatrix old_indices
for checking whether the old results can be reused
Definition: AFTModel.hxx:89
int set_bundle_parameters(const BundleParameters &)
an AFT has no bundle, so it returns 1, see SumBlockModel::set_bundle_parameters
Definition: AFTModel.hxx:338
AffineFunctionTransformation * aft
the affine function transformation in use, must always be != NULL
Definition: AFTModel.hxx:63
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
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
routines for updating and handling SumBundle components, possibly by cooperating over several recursi...
Definition: SumBundleHandler.hxx:42
CH_Tools::Microseconds posteval_time
total time spent in eval_function() after the oracle call
Definition: SumBlockModel.hxx:110
int get_center_minorant(MinorantPointer &minorant, const AffineFunctionTransformation *aft=0)
see SumBlockModel::get_center_minorant
MinorantPointer center_minorant
the (lazy) transformed minorant in the center
Definition: AFTModel.hxx:76
const PrimalData * get_center_primal() const
an AFT has no primals, so it returns 1, see SumBlockModel::get_center_primal
Definition: AFTModel.hxx:328
int eval_function(CH_Matrix_Classes::Integer &ub_fid, CH_Matrix_Classes::Real &ub, CH_Matrix_Classes::Integer y_id, const CH_Matrix_Classes::Matrix &y, CH_Matrix_Classes::Real nullstep_bound, CH_Matrix_Classes::Real relprec)
see BundleModel::eval_function
void clear_aggregates()
see SumBlockModel::clear_aggregates
BundleData * get_data()
see SumBlockModel::get_data
Definition: AFTModel.hxx:310
void clear_model(bool discard_minorants_only=false)
see SumBlockModel::clear_model
In Lagrangean relaxation an approximate primal solution can be generated by supplying primal informat...
Definition: CBSolver.hxx:151
Collects modifications for the unconstrained Groundset for appending, deleting or reassigning variabl...
Definition: GroundsetModification.hxx:32
bool model_aggregate_modified(CH_Matrix_Classes::Integer old_model_aggregate_id)
see BundleModel::model_aggregate_modified
Interface for extending PrimalData, e.g., in Lagrangian relaxation of column generation approaches...
Definition: CBSolver.hxx:180
const PrimalData * get_candidate_primal() const
an AFT has no primals, so it returns 1, see SumBlockModel::get_candidate_primal
Definition: AFTModel.hxx:332
virtual CH_Tools::Microseconds get_eval_time() const
see SumBlockModel::get_eval_time()
Definition: AFTModel.hxx:383
int get_function_minorant(MinorantPointer &minorant, const AffineFunctionTransformation *aft=0)
see SumBlockModel::get_function_minorant
base class for use with SumBlockModel for storing and managing essential data of evaluations and the ...
Definition: BundleData.hxx:77
virtual int init(const BundleData *bd)
initialize from other BundleData
SumBlockModel * sbm_transform()
like BundleModel::transform() this allows SumBlockModel routines to use a given transformation automa...
specialized BundleData class for use with AFTModel for storing and managing essential data of evaluat...
Definition: AFTData.hxx:58
const AffineFunctionTransformation * get_aft() const
allows to inspect the current AffineFunctionTransformation
Definition: AFTModel.hxx:159
points to MinorantUseData that may be shared by many and allows computations with Minorants ...
Definition: MinorantPointer.hxx:34
void set_cbout(const CBout *cb, int incr)
set output and outputlevel of warnings and errors recursively with CBout
Definition: SumBlockModel.hxx:689
std::map< MinorantPointer, MinorantPointer > precomputed
if a MinorantPointer has already been transformed, this is stored here
Definition: AFTModel.hxx:84
virtual void set_cbout(const CBout *cb, int incr=-1)
Specifies the output level relative to the given CBout class.
int get_model_aggregate(CH_Matrix_Classes::Integer &model_aggregate_id, MinorantPointer &model_aggregate, bool all_parts=true, const AffineFunctionTransformation *aft=0)
see SumBlockModle::get_modle_aggregate(CH_Matrix_Classes::Integer&,CH_Matrix_Classes::Real&,CH_Matrix_Classes::Matrix&,bool,bool,const AffineFunctionTransformation*)