Ipopt::CompositeNLP Class Reference

This class creates a composite NLP from a list of NLP's. More...

#include <CompositeNLP.hpp>

Inheritance diagram for Ipopt::CompositeNLP:
Inheritance graph
[legend]
Collaboration diagram for Ipopt::CompositeNLP:
Collaboration graph
[legend]

List of all members.

Public Member Functions

Constructors/Destructors



 CompositeNLP (std::vector< SmartPtr< NLP > > nlps, SmartPtr< VectorSpace > q_space, std::vector< SmartPtr< VectorSpace > > linking_eqn_c_spaces, std::vector< SmartPtr< Matrix > > Jx_linking_eqns, std::vector< SmartPtr< Matrix > > Jq_linking_eqns)
 Default constructor.
virtual ~CompositeNLP ()
 Default destructor.
Exceptions



 DECLARE_STD_EXCEPTION (INVALID_JACOBIAN_DIMENSION_FOR_LINKING_EQUATIONS)
CompositeNLP Initialization.



virtual bool ProcessOptions (const OptionsList &options, const std::string &prefix)
 Method for creating the derived vector / matrix types (Do not delete these, the ).
virtual bool GetSpaces (SmartPtr< const VectorSpace > &x_space, SmartPtr< const VectorSpace > &c_space, SmartPtr< const VectorSpace > &d_space, SmartPtr< const VectorSpace > &x_l_space, SmartPtr< const MatrixSpace > &px_l_space, SmartPtr< const VectorSpace > &x_u_space, SmartPtr< const MatrixSpace > &px_u_space, SmartPtr< const VectorSpace > &d_l_space, SmartPtr< const MatrixSpace > &pd_l_space, SmartPtr< const VectorSpace > &d_u_space, SmartPtr< const MatrixSpace > &pd_u_space, SmartPtr< const MatrixSpace > &Jac_c_space, SmartPtr< const MatrixSpace > &Jac_d_space, SmartPtr< const SymMatrixSpace > &Hess_lagrangian_space)
 Method for creating the derived vector / matrix types (Do not delete these, the ).
virtual bool GetBoundsInformation (const Matrix &Px_L, Vector &x_L, const Matrix &Px_U, Vector &x_U, const Matrix &Pd_L, Vector &d_L, const Matrix &Pd_U, Vector &d_U)
 Method for obtaining the bounds information.
virtual bool GetStartingPoint (SmartPtr< Vector > x, bool need_x, SmartPtr< Vector > y_c, bool need_y_c, SmartPtr< Vector > y_d, bool need_y_d, SmartPtr< Vector > z_L, bool need_z_L, SmartPtr< Vector > z_U, bool need_z_U)
 Method for obtaining the starting point for all the iterates.
CompositeNLP evaluation routines.



virtual bool Eval_f (const Vector &x, Number &f)
virtual bool Eval_grad_f (const Vector &x, Vector &g_f)
virtual bool Eval_c (const Vector &x, Vector &c)
virtual bool Eval_jac_c (const Vector &x, Matrix &jac_c)
virtual bool Eval_d (const Vector &x, Vector &d)
virtual bool Eval_jac_d (const Vector &x, Matrix &jac_d)
virtual bool Eval_h (const Vector &x, Number obj_factor, const Vector &yc, const Vector &yd, SymMatrix &h)
Information about the Composite Structure



SmartPtr< SymLinearSolverCreateLinearSolver ()
 returns an appropriate linear solver for the problem structure

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.



 CompositeNLP ()
 Default Constructor.
 CompositeNLP (const CompositeNLP &)
 Copy Constructor.
void operator= (const CompositeNLP &)
 Overloaded Equals Operator.

Private Attributes

SmartPtr< const Journalistjnlst_
 Journalist.
std::vector< SmartPtr< NLP > > nlps_
 std::vector of nlps
SmartPtr< VectorSpaceq_space_
 vector space for the linking variables, q
std::vector< SmartPtr
< VectorSpace > > 
linking_eqn_c_spaces_
 std::vector of VectorSpaces for the linking equations
Data about Linking Equations. For now,

this class only allows linear linking equations.

Therefore, the jacobian of the linking equations is set only once at the beginning.



std::vector< SmartPtr< Matrix > > Jx_linking_eqns_
 std::vector of Jacobian of the linking eqns (one for each nlp) with respect to x variables
std::vector< SmartPtr< Matrix > > Jq_linking_eqns_
 std::vector of Jacobian of the linking eqns (one for each nlp) with respect to linking variables (q)

Detailed Description

This class creates a composite NLP from a list of NLP's.

This is a Composite class (Design Patterns) that creates a single NLP from a list of NLP's with some common variables. This allows users to "link" different NLP's into a single NLP easily

Definition at line 25 of file CompositeNLP.hpp.


Constructor & Destructor Documentation

Ipopt::CompositeNLP::CompositeNLP ( std::vector< SmartPtr< NLP > >  nlps,
SmartPtr< VectorSpace q_space,
std::vector< SmartPtr< VectorSpace > >  linking_eqn_c_spaces,
std::vector< SmartPtr< Matrix > >  Jx_linking_eqns,
std::vector< SmartPtr< Matrix > >  Jq_linking_eqns 
)

Default constructor.

virtual Ipopt::CompositeNLP::~CompositeNLP (  )  [virtual]

Default destructor.

Ipopt::CompositeNLP::CompositeNLP (  )  [private]

Default Constructor.

Ipopt::CompositeNLP::CompositeNLP ( const CompositeNLP  )  [private]

Copy Constructor.


Member Function Documentation

Ipopt::CompositeNLP::DECLARE_STD_EXCEPTION ( INVALID_JACOBIAN_DIMENSION_FOR_LINKING_EQUATIONS   ) 
virtual bool Ipopt::CompositeNLP::ProcessOptions ( const OptionsList options,
const std::string &  prefix 
) [virtual]

Method for creating the derived vector / matrix types (Do not delete these, the ).

Reimplemented from Ipopt::NLP.

virtual bool Ipopt::CompositeNLP::GetSpaces ( SmartPtr< const VectorSpace > &  x_space,
SmartPtr< const VectorSpace > &  c_space,
SmartPtr< const VectorSpace > &  d_space,
SmartPtr< const VectorSpace > &  x_l_space,
SmartPtr< const MatrixSpace > &  px_l_space,
SmartPtr< const VectorSpace > &  x_u_space,
SmartPtr< const MatrixSpace > &  px_u_space,
SmartPtr< const VectorSpace > &  d_l_space,
SmartPtr< const MatrixSpace > &  pd_l_space,
SmartPtr< const VectorSpace > &  d_u_space,
SmartPtr< const MatrixSpace > &  pd_u_space,
SmartPtr< const MatrixSpace > &  Jac_c_space,
SmartPtr< const MatrixSpace > &  Jac_d_space,
SmartPtr< const SymMatrixSpace > &  Hess_lagrangian_space 
) [virtual]

Method for creating the derived vector / matrix types (Do not delete these, the ).

Implements Ipopt::NLP.

virtual bool Ipopt::CompositeNLP::GetBoundsInformation ( const Matrix Px_L,
Vector x_L,
const Matrix Px_U,
Vector x_U,
const Matrix Pd_L,
Vector d_L,
const Matrix Pd_U,
Vector d_U 
) [virtual]

Method for obtaining the bounds information.

Implements Ipopt::NLP.

virtual bool Ipopt::CompositeNLP::GetStartingPoint ( SmartPtr< Vector x,
bool  need_x,
SmartPtr< Vector y_c,
bool  need_y_c,
SmartPtr< Vector y_d,
bool  need_y_d,
SmartPtr< Vector z_L,
bool  need_z_L,
SmartPtr< Vector z_U,
bool  need_z_U 
) [virtual]

Method for obtaining the starting point for all the iterates.

Implements Ipopt::NLP.

virtual bool Ipopt::CompositeNLP::Eval_f ( const Vector x,
Number f 
) [virtual]

Implements Ipopt::NLP.

virtual bool Ipopt::CompositeNLP::Eval_grad_f ( const Vector x,
Vector g_f 
) [virtual]

Implements Ipopt::NLP.

virtual bool Ipopt::CompositeNLP::Eval_c ( const Vector x,
Vector c 
) [virtual]

Implements Ipopt::NLP.

virtual bool Ipopt::CompositeNLP::Eval_jac_c ( const Vector x,
Matrix jac_c 
) [virtual]

Implements Ipopt::NLP.

virtual bool Ipopt::CompositeNLP::Eval_d ( const Vector x,
Vector d 
) [virtual]

Implements Ipopt::NLP.

virtual bool Ipopt::CompositeNLP::Eval_jac_d ( const Vector x,
Matrix jac_d 
) [virtual]

Implements Ipopt::NLP.

virtual bool Ipopt::CompositeNLP::Eval_h ( const Vector x,
Number  obj_factor,
const Vector yc,
const Vector yd,
SymMatrix h 
) [virtual]

Implements Ipopt::NLP.

SmartPtr<SymLinearSolver> Ipopt::CompositeNLP::CreateLinearSolver (  ) 

returns an appropriate linear solver for the problem structure

void Ipopt::CompositeNLP::operator= ( const CompositeNLP  )  [private]

Overloaded Equals Operator.

Reimplemented from Ipopt::NLP.


Member Data Documentation

Journalist.

Definition at line 139 of file CompositeNLP.hpp.

std::vector<SmartPtr<NLP> > Ipopt::CompositeNLP::nlps_ [private]

std::vector of nlps

Definition at line 142 of file CompositeNLP.hpp.

vector space for the linking variables, q

Definition at line 145 of file CompositeNLP.hpp.

std::vector of VectorSpaces for the linking equations

Definition at line 148 of file CompositeNLP.hpp.

std::vector of Jacobian of the linking eqns (one for each nlp) with respect to x variables

Definition at line 157 of file CompositeNLP.hpp.

std::vector of Jacobian of the linking eqns (one for each nlp) with respect to linking variables (q)

Definition at line 161 of file CompositeNLP.hpp.


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

Generated on 15 Mar 2015 for Coin-All by  doxygen 1.6.1