47 namespace MoochoPack {
50 const decomp_sys_handler_ptr_t &decomp_sys_handler
52 :decomp_sys_handler_(decomp_sys_handler)
65 if( !get_decomp_sys_handler().
get() ) {
67 out <<
"\nWe are asked to select a new basis but there is no\n"
68 "decomposition system set so we have no choice but to terminiate\n"
70 <<
" (k = " << algo.
state().
k() <<
")\n";
78 if( s.
k() >= algo.algo_cntr().
max_iter() ) {
80 out <<
"\nThe maximum number of rSQP iterations\n"
81 <<
" have been exceeded so quit "
82 <<
" (k = " << algo.
state().
k() <<
")\n";
89 decomp_sys_handler().select_new_decomposition(
true);
91 out <<
"x_kp1 = x_k\n"
93 <<
"goto EvalNewPoint\n";
95 s.x().set_k(1) = s.x().get_k(0);
96 s.alpha().set_k(0) = 0.0;
106 ,std::ostream&
out,
const std::string& L
110 << L <<
"if k > max_iter then\n"
111 << L <<
" terminate the algorithm\n"
113 << L <<
"Select a new basis at current point\n"
114 << L <<
"x_kp1 = x_k\n"
115 << L <<
"alpha_k = 0\n"
117 << L <<
"goto EvalNewPoint\n";
NewDecompositionSelectionStd_Strategy()
virtual void max_iter(size_t max_iter)
bool new_decomposition(NLPAlgo &algo, Algorithm::poss_type step_poss, IterationPack::EDoStepType type, Algorithm::poss_type assoc_step_poss)
rSQP Algorithm control class.
virtual void terminate(bool success)
Called by step objects to terminate the algorithm.
virtual std::ostream & journal_out() const
Return a reference to a std::ostream to be used to output debug information and the like...
void print_new_decomposition(const NLPAlgo &algo, Algorithm::poss_type step_poss, IterationPack::EDoStepType type, Algorithm::poss_type assoc_step_poss, std::ostream &out, const std::string &leading_str) const
EJournalOutputLevel
enum for journal output.
Reduced space SQP state encapsulation interface.
virtual void do_step_next(const std::string &step_name)
Called by step objects to set the step (given its name) that this will envoke the next time this call...
const std::string EvalNewPoint_name
AlgorithmTracker & track()
virtual void output_iteration(const Algorithm &algo) const
Output information about an iteration just completed.
NLPAlgoState & rsqp_state()
<<std aggr>="">> members for algo_cntr
virtual void next_iteration(bool incr_k=true)
iteration quantity forwarding.