Ipopt  3.12.9
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros
Public Types | Public Member Functions | Protected Member Functions | List of all members
Ipopt::IterativeSolverTerminationTester Class Referenceabstract

This base class is for the termination tests for the iterative linear solver in the inexact version of Ipopt. More...

#include <IpIterativeSolverTerminationTester.hpp>

+ Inheritance diagram for Ipopt::IterativeSolverTerminationTester:

Public Types

enum  ETerminationTest {
  CONTINUE, TEST_1_SATISFIED, TEST_2_SATISFIED, TEST_3_SATISFIED,
  MODIFY_HESSIAN, OTHER_SATISFIED
}
 Enum to report result of termination test. More...
 

Public Member Functions

virtual bool InitializeImpl (const OptionsList &options, const std::string &prefix)=0
 Implementation of the initialization method that has to be overloaded by for each derived class. More...
 
virtual bool InitializeSolve ()=0
 Method for initializing for the next iterative solve. More...
 
virtual ETerminationTest TestTermination (Index ndim, const Number *sol, const Number *resid, Index iter, Number norm2_rhs)=0
 This method checks if the current soltion of the iterative linear solver is good enough (by returning the corresponding satisfied termination test), or if the Hessian should be modified. More...
 
virtual void Clear ()=0
 This method can be called after the Solve is over and we can delete anything that has been allocated to free memory. More...
 
const JournalistGetJnlst () const
 An easy way to get the journalist if accessed from the outside. More...
 
virtual Index GetSolverIterations () const =0
 Return the number of iterative solver iteration from the most recent solve. More...
 
/Destructor
 IterativeSolverTerminationTester ()
 Default constructor. More...
 
virtual ~IterativeSolverTerminationTester ()
 Default destructor. More...
 
- Public Member Functions inherited from Ipopt::AlgorithmStrategyObject
bool Initialize (const Journalist &jnlst, IpoptNLP &ip_nlp, IpoptData &ip_data, IpoptCalculatedQuantities &ip_cq, const OptionsList &options, const std::string &prefix)
 This method is called every time the algorithm starts again - it is used to reset any internal state. More...
 
bool ReducedInitialize (const Journalist &jnlst, const OptionsList &options, const std::string &prefix)
 Reduced version of the Initialize method, which does not require special Ipopt information. More...
 
 AlgorithmStrategyObject ()
 Default Constructor. More...
 
virtual ~AlgorithmStrategyObject ()
 Default Destructor. More...
 
- Public Member Functions inherited from Ipopt::ReferencedObject
 ReferencedObject ()
 
virtual ~ReferencedObject ()
 
Index ReferenceCount () const
 
void AddRef (const Referencer *referencer) const
 
void ReleaseRef (const Referencer *referencer) const
 

Protected Member Functions

void GetVectors (Index ndim, const Number *array, SmartPtr< const Vector > &comp_x, SmartPtr< const Vector > &comp_s, SmartPtr< const Vector > &comp_c, SmartPtr< const Vector > &comp_d)
 Method for copying a long augmented system array into Vectors in Ipopt notation. More...
 
InexactDataInexData ()
 Method to easily access Inexact data. More...
 
InexactCqInexCq ()
 Method to easily access Inexact calculated quantities. More...
 
- Protected Member Functions inherited from Ipopt::AlgorithmStrategyObject
const JournalistJnlst () const
 
IpoptNLPIpNLP () const
 
IpoptDataIpData () const
 
IpoptCalculatedQuantitiesIpCq () const
 
bool HaveIpData () const
 

Private Member Functions

Default Compiler Generated Methods

(Hidden to avoid implicit creation/calling).

These methods are not implemented and we do not want the compiler to implement them for us, so we declare them private and do not define them. This ensures that they will not be implicitly created/called.

IterativeSolverTerminationTesteroperator= (const IterativeSolverTerminationTester &)
 Overloaded Equals Operator. More...
 

Detailed Description

This base class is for the termination tests for the iterative linear solver in the inexact version of Ipopt.

Definition at line 21 of file IpIterativeSolverTerminationTester.hpp.

Member Enumeration Documentation

Enum to report result of termination test.

Enumerator
CONTINUE 

The current solution is not yet good enough.

TEST_1_SATISFIED 

Termination Test 1 is satisfied.

TEST_2_SATISFIED 

Termination Test 2 is satisfied.

TEST_3_SATISFIED 

Termination Test 3 is satisfied.

MODIFY_HESSIAN 

Hessian matrix should be modified.

OTHER_SATISFIED 

Some other termination criterion satisfied.

Definition at line 25 of file IpIterativeSolverTerminationTester.hpp.

Constructor & Destructor Documentation

Ipopt::IterativeSolverTerminationTester::IterativeSolverTerminationTester ( )
inline

Default constructor.

Definition at line 44 of file IpIterativeSolverTerminationTester.hpp.

virtual Ipopt::IterativeSolverTerminationTester::~IterativeSolverTerminationTester ( )
inlinevirtual

Default destructor.

Definition at line 48 of file IpIterativeSolverTerminationTester.hpp.

Member Function Documentation

virtual bool Ipopt::IterativeSolverTerminationTester::InitializeImpl ( const OptionsList options,
const std::string &  prefix 
)
pure virtual

Implementation of the initialization method that has to be overloaded by for each derived class.

Implements Ipopt::AlgorithmStrategyObject.

Implemented in Ipopt::InexactNormalTerminationTester, and Ipopt::InexactPDTerminationTester.

virtual bool Ipopt::IterativeSolverTerminationTester::InitializeSolve ( )
pure virtual

Method for initializing for the next iterative solve.

This must be call before the test methods are called.

Implemented in Ipopt::InexactNormalTerminationTester, and Ipopt::InexactPDTerminationTester.

virtual ETerminationTest Ipopt::IterativeSolverTerminationTester::TestTermination ( Index  ndim,
const Number sol,
const Number resid,
Index  iter,
Number  norm2_rhs 
)
pure virtual

This method checks if the current soltion of the iterative linear solver is good enough (by returning the corresponding satisfied termination test), or if the Hessian should be modified.

The input is the dimension of the augmented system, the current solution vector of the augmented system, the current residual vector.

Implemented in Ipopt::InexactNormalTerminationTester, and Ipopt::InexactPDTerminationTester.

virtual void Ipopt::IterativeSolverTerminationTester::Clear ( )
pure virtual

This method can be called after the Solve is over and we can delete anything that has been allocated to free memory.

Implemented in Ipopt::InexactNormalTerminationTester, and Ipopt::InexactPDTerminationTester.

const Journalist& Ipopt::IterativeSolverTerminationTester::GetJnlst ( ) const
inline

An easy way to get the journalist if accessed from the outside.

Definition at line 76 of file IpIterativeSolverTerminationTester.hpp.

virtual Index Ipopt::IterativeSolverTerminationTester::GetSolverIterations ( ) const
pure virtual

Return the number of iterative solver iteration from the most recent solve.

Implemented in Ipopt::InexactNormalTerminationTester, and Ipopt::InexactPDTerminationTester.

void Ipopt::IterativeSolverTerminationTester::GetVectors ( Index  ndim,
const Number array,
SmartPtr< const Vector > &  comp_x,
SmartPtr< const Vector > &  comp_s,
SmartPtr< const Vector > &  comp_c,
SmartPtr< const Vector > &  comp_d 
)
protected

Method for copying a long augmented system array into Vectors in Ipopt notation.

InexactData& Ipopt::IterativeSolverTerminationTester::InexData ( )
inlineprotected

Method to easily access Inexact data.

Definition at line 95 of file IpIterativeSolverTerminationTester.hpp.

InexactCq& Ipopt::IterativeSolverTerminationTester::InexCq ( )
inlineprotected

Method to easily access Inexact calculated quantities.

Definition at line 104 of file IpIterativeSolverTerminationTester.hpp.

IterativeSolverTerminationTester& Ipopt::IterativeSolverTerminationTester::operator= ( const IterativeSolverTerminationTester )
private

Overloaded Equals Operator.


The documentation for this class was generated from the following file: