Ipopt 3.12.10

- Main Page
- Classes
- Files

- File List
- File Members

All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
IpFilterLSAcceptor.hpp
Go to the documentation of this file.
1 // Copyright (C) 2005, 2006 International Business Machines and others.
2 // All Rights Reserved.
3 // This code is published under the Eclipse Public License.
4 //
5 // $Id: IpFilterLSAcceptor.hpp 2613 2015-11-04 14:42:02Z stefan $
6 //
7 // Authors: Andreas Waechter IBM 2005-10-13
8 // derived file from IpFilterLineSearch.hpp
9
10 #ifndef __IPFILTERLSACCEPTOR_HPP__
11 #define __IPFILTERLSACCEPTOR_HPP__
12
13 #include "IpFilter.hpp"
14 #include "IpBacktrackingLSAcceptor.hpp"
15 #include "IpPDSystemSolver.hpp"
16
17 namespace Ipopt
18 {
19
23 class FilterLSAcceptor : public BacktrackingLSAcceptor
24 {
25 public:
31 FilterLSAcceptor(const SmartPtr<PDSystemSolver>& pd_solver);
32
34 virtual ~FilterLSAcceptor();
36
38 virtual bool InitializeImpl(const OptionsList& options,
39 const std::string& prefix);
40
47 virtual void Reset();
48
52 virtual void InitThisLineSearch(bool in_watchdog);
53
58 virtual void PrepareRestoPhaseStart();
59
61 virtual Number CalculateAlphaMin();
62
68 virtual bool CheckAcceptabilityOfTrialPoint(Number alpha_primal);
69
81 virtual bool TrySecondOrderCorrection(Number alpha_primal_test,
82 Number& alpha_primal,
83 SmartPtr<IteratesVector>& actual_delta);
84
91 virtual bool TryCorrector(Number alpha_primal_test,
92 Number& alpha_primal,
93 SmartPtr<IteratesVector>& actual_delta);
94
99 virtual char UpdateForNextIteration(Number alpha_primal_test);
100
103 virtual void StartWatchDog();
104
107 virtual void StopWatchDog();
108
115 bool IsAcceptableToCurrentIterate(Number trial_barr, Number trial_theta,
116 bool called_from_restoration=false) const;
117
119 bool IsAcceptableToCurrentFilter(Number trial_barr, Number trial_theta) const;
121
124 static void RegisterOptions(SmartPtr<RegisteredOptions> roptions);
126
127 private:
137 FilterLSAcceptor(const FilterLSAcceptor&);
138
140 void operator=(const FilterLSAcceptor&);
142
146 Number theta_max_;
147 Number theta_max_fact_;
148
150 Number theta_min_;
151 Number theta_min_fact_;
153
158 bool IsFtype(Number alpha_primal_test);
159
164 bool ArmijoHolds(Number alpha_primal_test);
165
168 void AugmentFilter();
169
173 Number eta_phi_;
175 Number delta_;
177 Number s_phi_;
179 Number s_theta_;
181 Number gamma_phi_;
183 Number gamma_theta_;
185 Number alpha_min_frac_;
187 Index max_soc_;
191 Number kappa_soc_;
196 Number obj_max_inc_;
198 Index soc_method_;
199
201 enum CorrectorTypeEnum
202 {
203 NO_CORRECTOR=0,
204 AFFINE_CORRECTOR,
205 PRIMAL_DUAL_CORRECTOR
206 };
208 CorrectorTypeEnum corrector_type_;
211 Number corrector_compl_avrg_red_fact_;
214 bool skip_corr_if_neg_curv_;
217 bool skip_corr_in_monotone_mode_;
219 Index max_filter_resets_;
224 Index filter_reset_trigger_;
226
231 Number reference_theta_;
234 Number reference_barr_;
237 Number reference_gradBarrTDelta_;
239 Number watchdog_theta_;
241 Number watchdog_barr_;
243 Number watchdog_gradBarrTDelta_;
245
247 Filter filter_;
248
252 Number last_rejection_due_to_filter_;
255 Index count_successive_filter_rejections_;
257 Index n_filter_resets_;
259
262 SmartPtr<PDSystemSolver> pd_solver_;
264 };
265
266 } // namespace Ipopt
267
268 #endif
Ipopt::FilterLSAcceptor::IsAcceptableToCurrentFilter
bool IsAcceptableToCurrentFilter(Number trial_barr, Number trial_theta) const
Checks if a trial point is acceptable to the current filter.
Ipopt::FilterLSAcceptor::watchdog_theta_
Number watchdog_theta_
Constraint violation at reference point.
Definition: IpFilterLSAcceptor.hpp:239
Ipopt::FilterLSAcceptor::kappa_soc_
Number kappa_soc_
Required reduction in constraint violation before trying multiple second order correction steps ...
Definition: IpFilterLSAcceptor.hpp:191
Ipopt::FilterLSAcceptor::s_theta_
Number s_theta_
Definition: IpFilterLSAcceptor.hpp:179
Ipopt::FilterLSAcceptor::alpha_min_frac_
Number alpha_min_frac_
Definition: IpFilterLSAcceptor.hpp:185
Ipopt::FilterLSAcceptor::reference_gradBarrTDelta_
Number reference_gradBarrTDelta_
Barrier gradient transpose search direction at the point with respect to which progress is to be made...
Definition: IpFilterLSAcceptor.hpp:237
IpPDSystemSolver.hpp
Ipopt::FilterLSAcceptor::PRIMAL_DUAL_CORRECTOR
Definition: IpFilterLSAcceptor.hpp:205
Ipopt::FilterLSAcceptor::UpdateForNextIteration
virtual char UpdateForNextIteration(Number alpha_primal_test)
Method for ending the current line search.
Ipopt::FilterLSAcceptor::reference_theta_
Number reference_theta_
Constraint violation at the point with respect to which progress is to be made.
Definition: IpFilterLSAcceptor.hpp:231
Ipopt::FilterLSAcceptor::FilterLSAcceptor
FilterLSAcceptor(const SmartPtr< PDSystemSolver > &pd_solver)
Constructor.
Ipopt::FilterLSAcceptor::Reset
virtual void Reset()
Reset the acceptor.
Ipopt::Number
double Number
Type of all numbers.
Definition: IpTypes.hpp:17
Ipopt::FilterLSAcceptor::AugmentFilter
void AugmentFilter()
Augment the filter used on the current values of the barrier objective function and the contraint vio...
Ipopt::FilterLSAcceptor
Filter line search.
Definition: IpFilterLSAcceptor.hpp:23
Ipopt::FilterLSAcceptor::IsFtype
bool IsFtype(Number alpha_primal_test)
Method for checking if the current step size satisfies the f-type switching condition.
Ipopt::FilterLSAcceptor::ArmijoHolds
bool ArmijoHolds(Number alpha_primal_test)
Method for checking the Armijo condition, given a trial step size.
Ipopt::FilterLSAcceptor::max_filter_resets_
Index max_filter_resets_
maximal allowed number of filter resets.
Definition: IpFilterLSAcceptor.hpp:219
Ipopt::BacktrackingLSAcceptor
Base class for backtracking line search acceptors.
Definition: IpBacktrackingLSAcceptor.hpp:21
Ipopt::FilterLSAcceptor::theta_min_
Number theta_min_
Infeasibility switching bound.
Definition: IpFilterLSAcceptor.hpp:150
Ipopt::FilterLSAcceptor::soc_method_
Index soc_method_
Second method correction method.
Definition: IpFilterLSAcceptor.hpp:198
Ipopt::FilterLSAcceptor::StopWatchDog
virtual void StopWatchDog()
Method for setting internal data if the watchdog procedure is stopped.
Ipopt::FilterLSAcceptor::skip_corr_if_neg_curv_
bool skip_corr_if_neg_curv_
Flag indicating whether the corrector should be skipped in an iteration in which negative curvature i...
Definition: IpFilterLSAcceptor.hpp:214
Ipopt::FilterLSAcceptor::last_rejection_due_to_filter_
Number last_rejection_due_to_filter_
True, if last rejected was due to the filter.
Definition: IpFilterLSAcceptor.hpp:252
Ipopt::FilterLSAcceptor::theta_max_
Number theta_max_
Upper bound on infeasibility.
Definition: IpFilterLSAcceptor.hpp:146
Ipopt::FilterLSAcceptor::max_soc_
Index max_soc_
Maximal number of second order correction steps.
Definition: IpFilterLSAcceptor.hpp:187
Ipopt::SmartPtr
Template class for Smart Pointers.
Definition: IpSmartPtr.hpp:172
IpBacktrackingLSAcceptor.hpp
Ipopt::OptionsList
This class stores a list of user set options.
Definition: IpOptionsList.hpp:32
Ipopt::FilterLSAcceptor::corrector_type_
CorrectorTypeEnum corrector_type_
Type of corrector steps that should be tried.
Definition: IpFilterLSAcceptor.hpp:208
Ipopt::FilterLSAcceptor::InitializeImpl
virtual bool InitializeImpl(const OptionsList &options, const std::string &prefix)
InitializeImpl - overloaded from AlgorithmStrategyObject.
Ipopt::FilterLSAcceptor::gamma_phi_
Number gamma_phi_
Definition: IpFilterLSAcceptor.hpp:181
Ipopt::FilterLSAcceptor::filter_
Filter filter_
Filter with entries.
Definition: IpFilterLSAcceptor.hpp:247
Ipopt::FilterLSAcceptor::TrySecondOrderCorrection
virtual bool TrySecondOrderCorrection(Number alpha_primal_test, Number &alpha_primal, SmartPtr< IteratesVector > &actual_delta)
Try a second order correction for the constraints.
Ipopt::FilterLSAcceptor::CorrectorTypeEnum
CorrectorTypeEnum
enumeration for the corrector type
Definition: IpFilterLSAcceptor.hpp:201
Ipopt::FilterLSAcceptor::CalculateAlphaMin
virtual Number CalculateAlphaMin()
Method returning the lower bound on the trial step sizes.
Ipopt::FilterLSAcceptor::delta_
Number delta_
Definition: IpFilterLSAcceptor.hpp:175
Ipopt::Index
int Index
Type of all indices of vectors, matrices etc.
Definition: IpTypes.hpp:19
Ipopt::FilterLSAcceptor::count_successive_filter_rejections_
Index count_successive_filter_rejections_
Counter of successive iterations in which filter was reason for last rejection.
Definition: IpFilterLSAcceptor.hpp:255
Ipopt::FilterLSAcceptor::CheckAcceptabilityOfTrialPoint
virtual bool CheckAcceptabilityOfTrialPoint(Number alpha_primal)
Method for checking if current trial point is acceptable.
Ipopt::FilterLSAcceptor::reference_barr_
Number reference_barr_
Barrier objective function at the point with respect to which progress is to be made.
Definition: IpFilterLSAcceptor.hpp:234
Ipopt::FilterLSAcceptor::StartWatchDog
virtual void StartWatchDog()
Method for setting internal data if the watchdog procedure is started.
Ipopt::FilterLSAcceptor::theta_min_fact_
Number theta_min_fact_
Definition: IpFilterLSAcceptor.hpp:151
Ipopt::FilterLSAcceptor::InitThisLineSearch
virtual void InitThisLineSearch(bool in_watchdog)
Initialization for the next line search.
Ipopt::FilterLSAcceptor::watchdog_gradBarrTDelta_
Number watchdog_gradBarrTDelta_
Barrier gradient transpose search direction at reference point.
Definition: IpFilterLSAcceptor.hpp:243
Ipopt::FilterLSAcceptor::theta_max_fact_
Number theta_max_fact_
Definition: IpFilterLSAcceptor.hpp:147
Ipopt::FilterLSAcceptor::NO_CORRECTOR
Definition: IpFilterLSAcceptor.hpp:203
Ipopt::Filter
Class for the filter.
Definition: IpFilter.hpp:111
Ipopt::FilterLSAcceptor::AFFINE_CORRECTOR
Definition: IpFilterLSAcceptor.hpp:204
Ipopt::FilterLSAcceptor::watchdog_barr_
Number watchdog_barr_
Barrier objective function at reference point.
Definition: IpFilterLSAcceptor.hpp:241
Ipopt::FilterLSAcceptor::s_phi_
Number s_phi_
Definition: IpFilterLSAcceptor.hpp:177
Ipopt::FilterLSAcceptor::n_filter_resets_
Index n_filter_resets_
Counter for the filter resets done so far.
Definition: IpFilterLSAcceptor.hpp:257
Ipopt::FilterLSAcceptor::eta_phi_
Number eta_phi_
Definition: IpFilterLSAcceptor.hpp:173
Ipopt::FilterLSAcceptor::skip_corr_in_monotone_mode_
bool skip_corr_in_monotone_mode_
Flag indicating whether the corrector should be skipped during the monotone mu mode.
Definition: IpFilterLSAcceptor.hpp:217
Ipopt::FilterLSAcceptor::filter_reset_trigger_
Index filter_reset_trigger_
interation counter trigger for filter reset.
Definition: IpFilterLSAcceptor.hpp:224
Ipopt::FilterLSAcceptor::PrepareRestoPhaseStart
virtual void PrepareRestoPhaseStart()
Method that is called before the restoration phase is called.
Ipopt::FilterLSAcceptor::obj_max_inc_
Number obj_max_inc_
Maximal increase in objective function in orders of magnitute (log10).
Definition: IpFilterLSAcceptor.hpp:196
Ipopt::FilterLSAcceptor::RegisterOptions
static void RegisterOptions(SmartPtr< RegisteredOptions > roptions)
Methods for OptionsList.
Ipopt::FilterLSAcceptor::gamma_theta_
Number gamma_theta_
Definition: IpFilterLSAcceptor.hpp:183
Ipopt::FilterLSAcceptor::corrector_compl_avrg_red_fact_
Number corrector_compl_avrg_red_fact_
parameter in heurstic that determines whether corrector step should be tried.
Definition: IpFilterLSAcceptor.hpp:211
IpFilter.hpp
Ipopt::FilterLSAcceptor::operator=
void operator=(const FilterLSAcceptor &)
Overloaded Equals Operator.
Ipopt::FilterLSAcceptor::IsAcceptableToCurrentIterate
bool IsAcceptableToCurrentIterate(Number trial_barr, Number trial_theta, bool called_from_restoration=false) const
Checks if a trial point is acceptable to the current iterate.
Ipopt::FilterLSAcceptor::pd_solver_
SmartPtr< PDSystemSolver > pd_solver_
Definition: IpFilterLSAcceptor.hpp:262
Ipopt::FilterLSAcceptor::TryCorrector
virtual bool TryCorrector(Number alpha_primal_test, Number &alpha_primal, SmartPtr< IteratesVector > &actual_delta)
Try higher order corrector (for fast local convergence).
Ipopt::FilterLSAcceptor::~FilterLSAcceptor
virtual ~FilterLSAcceptor()
Default destructor.