42 #ifndef CHECK_CONVERGENCE_STRATEGY_H
43 #define CHECK_CONVERGENCE_STRATEGY_H
45 #include "MoochoPack_Types.hpp"
47 #include "OptionsFromStreamPack_SetOptionsFromStreamNode.hpp"
48 #include "OptionsFromStreamPack_SetOptionsToTargetBase.hpp"
50 namespace MoochoPack {
66 OPT_ERROR_REDUCED_GRADIENT_LAGR,
67 OPT_ERROR_GRADIENT_LAGR
107 EOptErrorCheck opt_error_check = OPT_ERROR_REDUCED_GRADIENT_LAGR,
108 EScaleKKTErrorBy scale_opt_error_by = SCALE_BY_ONE,
109 EScaleKKTErrorBy scale_feas_error_by = SCALE_BY_ONE,
110 EScaleKKTErrorBy scale_comp_error_by = SCALE_BY_ONE,
111 bool scale_opt_error_by_Gf =
true
118 virtual void print_step(
const Algorithm& _algo, std::ostream& out,
const std::string& L )
const =0;
157 CheckConvergence_Strategy >
164 ,
const char opt_grp_name[] =
"CheckConvergenceStrategy" );
169 void setOption(
int option_num,
const std::string& option_value );
176 #endif // CHECK_CONVERGENCE_STRATEGY_H
CheckConvergence_StrategySetOptions(CheckConvergence_Strategy *target=0, const char opt_grp_name[]="CheckConvergenceStrategy")
virtual void print_step(const Algorithm &_algo, std::ostream &out, const std::string &L) const =0
void setOption(int option_num, const std::string &option_value)
Overridden from SetOptionsFromStreamNode.
Strategy interface for performing convergence checks.
CheckConvergence_Strategy(EOptErrorCheck opt_error_check=OPT_ERROR_REDUCED_GRADIENT_LAGR, EScaleKKTErrorBy scale_opt_error_by=SCALE_BY_ONE, EScaleKKTErrorBy scale_feas_error_by=SCALE_BY_ONE, EScaleKKTErrorBy scale_comp_error_by=SCALE_BY_ONE, bool scale_opt_error_by_Gf=true)
Set options for CheckConvergence_Strategy from an OptionsFromStream object.
STANDARD_MEMBER_COMPOSITION_MEMBERS(EOptErrorCheck, opt_error_check)
<<std member="" comp>="">> members for whether to check the reduced or full gradient of the Lagrangia...
virtual bool Converged(Algorithm &_algo)=0