9 #ifndef __IPIPOPTDATA_HPP__
10 #define __IPIPOPTDATA_HPP__
47 const std::string& prefix) = 0;
109 const std::string& prefix);
679 #if COIN_IPOPT_CHECKLEVEL > 0
733 #if COIN_IPOPT_CHECKLEVEL > 0
736 debug_curr_tag_ =
curr_->GetTag();
737 debug_curr_tag_sum_ =
curr_->GetTagSum();
741 debug_curr_tag_sum_ = 0;
752 #if COIN_IPOPT_CHECKLEVEL > 0
756 debug_trial_tag_ = trial->GetTag();
757 debug_trial_tag_sum_ = trial->GetTagSum();
760 debug_trial_tag_ = 0;
761 debug_trial_tag_sum_ = 0;
772 #if COIN_IPOPT_CHECKLEVEL > 0
775 debug_delta_tag_ = delta->GetTag();
776 debug_delta_tag_sum_ = delta->GetTagSum();
779 debug_delta_tag_ = 0;
780 debug_delta_tag_sum_ = 0;
791 #if COIN_IPOPT_CHECKLEVEL > 0
794 debug_delta_tag_ = delta->GetTag();
795 debug_delta_tag_sum_ = delta->GetTagSum();
798 debug_delta_tag_ = 0;
799 debug_delta_tag_sum_ = 0;
810 #if COIN_IPOPT_CHECKLEVEL > 0
813 debug_delta_aff_tag_ = delta_aff->GetTag();
814 debug_delta_aff_tag_sum_ = delta_aff->GetTagSum();
817 debug_delta_aff_tag_ = 0;
818 debug_delta_aff_tag_sum_ = delta_aff->GetTagSum();
const std::string & info_string() const
bool IsValid(const SmartPtr< U > &smart_ptr)
char info_alpha_primal_char() const
void SetTrialBoundMultipliersFromStep(Number alpha, const Vector &delta_z_L, const Vector &delta_z_U, const Vector &delta_v_L, const Vector &delta_v_U)
Set the value of the trial values for the bound multipliers (z_L, z_U, v_L, v_U) from provided step w...
void Set_info_regu_x(Number regu_x)
void set_delta(SmartPtr< IteratesVector > &delta)
Set the current delta - like the trial point, this method copies the pointer for efficiency (no copy ...
Number info_regu_x_
Size of regularization for the Hessian.
int info_iters_since_header_
number of iteration summaries actually printed since last summary header was printed ...
void Append_info_string(const std::string &add_str)
void getPDPert(Number &pd_pert_x, Number &pd_pert_s, Number &pd_pert_c, Number &pd_pert_d)
Get the current perturbation of the primal-dual system.
Number curr_tau_
current fraction to the boundary parameter
Number info_last_output()
gives time when the last summary output line was printed
void SetHaveAffineDeltas(bool have_affine_deltas)
Method for setting the HaveDeltas flag.
Number curr_mu_
current barrier parameter
SmartPtr< IpoptAdditionalData > add_data_
Object for the data specific for the Chen-Goldfarb penalty method algorithm.
void ResetInfo()
Reset all info fields.
Number info_alpha_dual() const
void Set_info_alpha_dual(Number alpha_dual)
Number cpu_time_start() const
Cpu time counter at the beginning of the optimization.
void set_delta_aff(SmartPtr< IteratesVector > &delta_aff)
Set the affine delta - like the trial point, this method copies the pointer for efficiency (no copy a...
IpoptAdditionalData()
Default Constructor.
static void RegisterOptions(const SmartPtr< RegisteredOptions > &roptions)
Methods for IpoptType.
bool HaveAffineDeltas() const
Returns true, if the affine-scaling step have been already computed for the current iteration...
void Set_info_ls_count(Index ls_count)
TimingStatistics timing_statistics_
TimingStatistics object collecting all Ipopt timing statistics.
double Number
Type of all numbers.
void Set_tiny_step_flag(bool flag)
Setting the flag that indicates if a tiny step (below machine precision) has been detected...
bool IsNull(const SmartPtr< U > &smart_ptr)
void Set_info_last_output(Number info_last_output)
sets time when the last summary output line was printed
void Set_iter_count(Index iter_count)
int info_iters_since_header()
gives number of iteration summaries actually printed since last summary header was printed ...
Number cpu_time_start_
CPU time counter at begin of optimization.
Number info_last_output_
time when the last summary output line was printed
void Set_info_alpha_primal_char(char info_alpha_primal_char)
SmartPtr< const SymMatrix > W()
Hessian or Hessian approximation (do not hold on to it, it might be changed)
void SetFreeMuMode(bool free_mu_mode)
SmartPtr< const IteratesVector > delta() const
ToDo: I may need to add versions of set_trial like the following, but I am not sure.
bool HaveAddData()
Check if additional data has been set.
void Set_W(SmartPtr< const SymMatrix > W)
Set Hessian approximation.
Number info_alpha_primal_
Primal step size.
virtual ~IpoptData()
Default destructor.
TimingStatistics & TimingStats()
Return Timing Statistics Object.
SmartPtr< const IteratesVector > trial() const
Get the current point in a copied container that is non-const.
SmartPtr< const IteratesVector > curr_
Main iteration variables (current iteration)
This class collects all timing statistics for Ipopt.
std::string info_string_
any string of characters for the end of the output line
Template class for Smart Pointers.
This class stores a list of user set options.
bool info_skip_output_
true, if next summary output line should not be printed (eg after restoration phase.
virtual bool Initialize(const Journalist &jnlst, const OptionsList &options, const std::string &prefix)=0
This method is called to initialize the global algorithmic parameters.
VectorSpace base class, corresponding to the Vector base class.
bool have_affine_deltas_
The following flag is set to true, if some other part of the algorithm (like the method for computing...
void operator=(const IpoptAdditionalData &)
Overloaded Equals Operator.
SmartPtr< const IteratesVector > delta_aff_
U * GetRawPtr(const SmartPtr< U > &smart_ptr)
bool info_skip_output() const
Number tol_
Overall convergence tolerance.
SmartPtr< const IteratesVector > delta_
virtual ~IpoptAdditionalData()
Default destructor.
void SetTrialPrimalVariablesFromStep(Number alpha, const Vector &delta_x, const Vector &delta_s)
Set the values of the primal trial variables (x and s) from provided Step with step length alpha...
bool Initialize(const Journalist &jnlst, const OptionsList &options, const std::string &prefix)
This method must be called to initialize the global algorithmic parameters.
bool have_prototypes_
flag for debugging whether we have already curr_ values available (from which new Vectors can be gene...
void Inc_info_iters_since_header()
increases number of iteration summaries actually printed since last summary header was printed ...
Number CpuTime()
method determining CPU time
IpoptAdditionalData & AdditionalData()
Get access to additional data object.
Class to organize all the data required by the algorithm.
bool InitializeDataStructures(IpoptNLP &ip_nlp, bool want_x, bool want_y_c, bool want_y_d, bool want_z_L, bool want_z_U)
Initialize Data Structures.
int Index
Type of all indices of vectors, matrices etc.
virtual void AcceptTrialPoint()=0
Do whatever is necessary to accept a trial point as current iterate.
SmartPtr< const IteratesVector > curr() const
Current point.
Number info_alpha_dual_
Dual step size.
bool tiny_step_flag_
flag indicating if a tiny step has been detected
void SetHaveDeltas(bool have_deltas)
Method for setting the HaveDeltas flag.
SmartPtr< IteratesVectorSpace > iterates_space_
VectorSpace for all the iterates.
unsigned int Tag
Type for the Tag values.
IpoptData(SmartPtr< IpoptAdditionalData > add_data=NULL, Number cpu_time_start=-1.)
Constructor.
void Set_info_skip_output(bool info_skip_output)
Set this to true, if the next time when output is written, the summary line should not be printed...
SmartPtr< const U > ConstPtr(const SmartPtr< U > &smart_ptr)
Index info_ls_count() const
Index iter_count_
iteration count
SmartPtr< const IteratesVector > delta_aff() const
Affine Delta.
void ResetCpuStartTime()
Resetting CPU Start Time.
void SetTrialEqMultipliersFromStep(Number alpha, const Vector &delta_y_c, const Vector &delta_y_d)
Set the values of the trial values for the equality constraint multipliers (y_c and y_d) from provide...
void Set_info_iters_since_header(int info_iters_since_header)
sets number of iteration summaries actually printed since last summary header was printed ...
void Set_tol(Number tol)
Set a new value for the tolerance.
Class responsible for all message output.
bool free_mu_mode_
flag indicating whether the algorithm is in the free mu mode
char info_alpha_primal_char_
Info character for primal step size.
bool TauInitialized() const
void operator=(const IpoptData &)
Overloaded Equals Operator.
SmartPtr< const SymMatrix > W_
Hessian (approximation) - might be changed elsewhere!
bool initialize_called_
flag indicating if Initialize method has been called (for debugging)
bool MuInitialized() const
void AcceptTrialPoint()
Set the current iterate values from the trial values.
void SetAddData(SmartPtr< IpoptAdditionalData > add_data)
Set a new pointer for additional Ipopt data.
void setPDPert(Number pd_pert_x, Number pd_pert_s, Number pd_pert_c, Number pd_pert_d)
Set the perturbation of the primal-dual system.
This is the abstract base class for classes that map the traditional NLP into something that is more ...
Base class for additional data that is special to a particular type of algorithm, such as the CG pena...
bool have_deltas_
The following flag is set to true, if some other part of the algorithm (like the method for computing...
Number info_regu_x() const
virtual bool InitializeDataStructures()=0
Initialize Data Structures at the beginning.
Number info_alpha_primal() const
bool HaveDeltas() const
Returns true, if the primal-dual step have been already computed for the current iteration.
void Set_info_alpha_primal(Number alpha_primal)
void set_trial(SmartPtr< IteratesVector > &trial)
Get Trial point in a copied container that is non-const.
Number tol() const
Overall convergence tolerance.
void CopyTrialToCurrent()
Copy the trial values to the current values.
SmartPtr< const IteratesVector > trial_
Main iteration variables (trial calculations)
Index info_ls_count_
Number of backtracking trial steps.