OPTPP::NLP0 Class Reference

Base Class for NonLinear Programming Problem For NLP0 the only assumption on the objective function is that it be continuous. More...

Inheritance diagram for OPTPP::NLP0:
[legend]
Collaboration diagram for OPTPP::NLP0:
[legend]

List of all members.

Public Member Functions

NEWMAT::ColumnVector BDGrad (const NEWMAT::ColumnVector &, const NEWMAT::ColumnVector &, double &, NEWMAT::ColumnVector &)
NEWMAT::ColumnVector CDGrad (const NEWMAT::ColumnVector &, const NEWMAT::ColumnVector &, double &, NEWMAT::ColumnVector &)
NEWMAT::Matrix CONBDGrad (const NEWMAT::ColumnVector &)
NEWMAT::Matrix CONCDGrad (const NEWMAT::ColumnVector &)
NEWMAT::Matrix CONFDGrad (const NEWMAT::ColumnVector &)
 Finite-difference gradient and Hessian of nonlinear constraints.
virtual void eval ()=0
virtual void evalC (const NEWMAT::ColumnVector &x)=0
virtual NEWMAT::ColumnVector evalCF (const NEWMAT::ColumnVector &x)=0
 Evaluate the constraint at x.
virtual NEWMAT::Matrix evalCG (const NEWMAT::ColumnVector &x)=0
 Evaluate the constraint gradient at x.
virtual OptppArray
< NEWMAT::SymmetricMatrix > 
evalCH (NEWMAT::ColumnVector &x, int darg)=0
 Evaluate the constraint Hessian at x.
virtual NEWMAT::SymmetricMatrix evalCH (NEWMAT::ColumnVector &x)=0
virtual real evalF (const NEWMAT::ColumnVector &x)=0
virtual real evalF ()=0
virtual NEWMAT::ColumnVector evalG (const NEWMAT::ColumnVector &x)=0
virtual NEWMAT::ColumnVector evalG ()=0
 Evaluate a finite-difference gradient and Hessian.
virtual NEWMAT::SymmetricMatrix evalH (NEWMAT::ColumnVector &x)=0
virtual NEWMAT::SymmetricMatrix evalH ()=0
virtual real evalLagrangian (const NEWMAT::ColumnVector &x, NEWMAT::ColumnVector &mult, const NEWMAT::ColumnVector &type)=0
 Evaluate the Lagrangian.
virtual NEWMAT::ColumnVector evalLagrangianGradient (const NEWMAT::ColumnVector &x, const NEWMAT::ColumnVector &mult, const NEWMAT::ColumnVector &type)=0
 Evaluate the Lagrangian gradient.
NEWMAT::SymmetricMatrix FD2Hessian (NEWMAT::ColumnVector &)
NEWMAT::ColumnVector FDGrad (const NEWMAT::ColumnVector &, const NEWMAT::ColumnVector &, double &, NEWMAT::ColumnVector &)
 Finite-difference gradient and Hessian.
virtual void fPrintState (ostream *, char *)
 Print state of the function to a file.
CompoundConstraint * getConstraints ()
NEWMAT::ColumnVector getConstraintValue () const
virtual bool getDebug () const
DerivOption getDerivOption () const
virtual int getDim () const
virtual real getF () const
virtual NEWMAT::ColumnVector getFcnAccrcy () const
virtual real getFcnTime () const
virtual int getFevals () const
virtual int getIsExpensive () const
virtual bool getModeOverride () const
int getNumOfCons () const
int getNumOfNLCons () const
SpecOption getSpecOption () const
virtual NEWMAT::ColumnVector getXc () const
bool hasConstraints ()
virtual void initFcn ()=0
 NLP0 (int ndim, CompoundConstraint *constraint)
 NLP0 (int ndim, int nlncons)
 NLP0 (int ndim)
 NLP0 ()
 Default Constructor.
void printConstraints ()
 Print constraints to standard output.
virtual void printState (char *)
 Print the function.
virtual void reset ()=0
void saveState ()
 Save current state of the function.
void setConstraints (CompoundConstraint *constraintSet)
 Set a pointer to a CompoundConstraint object.
void setConstraintValue (const NEWMAT::ColumnVector &cfx)
 Set the constraint value.
virtual void setDebug ()
void setDerivOption (DerivOption d)
virtual void setF (const real &fx)
virtual void setFcnAccrcy (const NEWMAT::ColumnVector &accrcy)
virtual void setFcnAccrcy (const int i, const real &accrcy)
virtual void setIsExpensive (const int e)
virtual void setModeOverride (bool override_mode)
void setSpecOption (SpecOption SpecEval)
virtual void setX (const NEWMAT::ColumnVector &x)
virtual void setX (const int i, const real &x)
 Functions for setting various properties of this NLP problem.
virtual ~NLP0 ()
 Destructor.

Protected Attributes

Appl_Data application
CompoundConstraint * constraint_
 Pointer to constraints.
NEWMAT::ColumnVector constraint_value
 Constraint residual.
bool debug_
 Print debug statements.
int dim
 Dimension of the problem.
DerivOption finitediff
 User-specified derivative option.
double function_time
 Function compute time.
real fvalue
 Objective function value at mem_xc.
int is_expensive
 Is this an expensive function?
NEWMAT::ColumnVector mem_fcn_accrcy
 Accuracy available from function.
NEWMAT::ColumnVector mem_xc
 Current point.
bool modeOverride
int ncnln
 Number of nonlinear constraints.
int nfevals
 Number of function evaluations.
char nlp_name [80]
 Optional identifying name.
NEWMAT::ColumnVector partial_grad
double specF
SpecOption SpecFlag
 Speculative gradient information.

Detailed Description

Base Class for NonLinear Programming Problem For NLP0 the only assumption on the objective function is that it be continuous.

No derivative information is available. Note that NLP0-2 are abstract data types

Author:
J.C. Meza, Sandia National Laboratories, meza@ca.sandia.gov

Definition at line 28 of file NLP0.h.


Constructor & Destructor Documentation

OPTPP::NLP0::NLP0 (  )  [inline]
OPTPP::NLP0::NLP0 ( int  ndim  )  [inline]
Parameters:
ndim an int
See also:
NLP0()
NLP0(int dim, int nlncons)
NLP0(int dim, CompoundConstraint* constraint)

Definition at line 127 of file NLP0.h.

References finitediff, mem_fcn_accrcy, mem_xc, and SpecFlag.

OPTPP::NLP0::NLP0 ( int  ndim,
int  nlncons 
) [inline]
Parameters:
ndim an int
nlncons an int
See also:
NLP0()
NLP0(int dim)
NLP0(int dim, CompoundConstraint* constraint)

Definition at line 140 of file NLP0.h.

References constraint_value, finitediff, mem_fcn_accrcy, mem_xc, and SpecFlag.

OPTPP::NLP0::NLP0 ( int  ndim,
CompoundConstraint *  constraint 
) [inline]
Parameters:
ndim an int
constraint pointer to a CompoundConstraint
See also:
NLP0()
NLP0(int dim)
NLP0(int dim, int nlncons)

Definition at line 154 of file NLP0.h.

References finitediff, mem_fcn_accrcy, mem_xc, and SpecFlag.

virtual OPTPP::NLP0::~NLP0 (  )  [inline, virtual]

Destructor.

Definition at line 263 of file NLP0.h.


Member Function Documentation

NEWMAT::Matrix OPTPP::NLP0::CONFDGrad ( const NEWMAT::ColumnVector &   ) 

Finite-difference gradient and Hessian of nonlinear constraints.

virtual NEWMAT::ColumnVector OPTPP::NLP0::evalCF ( const NEWMAT::ColumnVector &  x  )  [pure virtual]

Evaluate the constraint at x.

Implements OPTPP::NLPBase.

Implemented in OPTPP::LSQNLF, OPTPP::NLF0, OPTPP::NLF1, OPTPP::FDNLF1, OPTPP::NLF0APP, and OPTPP::FDNLF1APP.

virtual NEWMAT::Matrix OPTPP::NLP0::evalCG ( const NEWMAT::ColumnVector &  x  )  [pure virtual]

Evaluate the constraint gradient at x.

Implements OPTPP::NLPBase.

Implemented in OPTPP::LSQNLF, OPTPP::NLF1, OPTPP::FDNLF1, and OPTPP::FDNLF1APP.

virtual OptppArray<NEWMAT::SymmetricMatrix> OPTPP::NLP0::evalCH ( NEWMAT::ColumnVector &  x,
int  darg 
) [pure virtual]

Evaluate the constraint Hessian at x.

Implements OPTPP::NLPBase.

Implemented in OPTPP::NLF1.

virtual NEWMAT::ColumnVector OPTPP::NLP0::evalG (  )  [pure virtual]

Evaluate a finite-difference gradient and Hessian.

Implements OPTPP::NLPBase.

Implemented in OPTPP::LSQNLF, OPTPP::NLF0, OPTPP::NLF1, OPTPP::NLF2, OPTPP::FDNLF1, OPTPP::NLF0APP, and OPTPP::FDNLF1APP.

virtual real OPTPP::NLP0::evalLagrangian ( const NEWMAT::ColumnVector &  x,
NEWMAT::ColumnVector &  mult,
const NEWMAT::ColumnVector &  type 
) [pure virtual]

Evaluate the Lagrangian.

Implemented in OPTPP::LSQNLF, OPTPP::NLF0, OPTPP::NLF1, OPTPP::FDNLF1, OPTPP::NLF0APP, and OPTPP::FDNLF1APP.

virtual NEWMAT::ColumnVector OPTPP::NLP0::evalLagrangianGradient ( const NEWMAT::ColumnVector &  x,
const NEWMAT::ColumnVector &  mult,
const NEWMAT::ColumnVector &  type 
) [pure virtual]

Evaluate the Lagrangian gradient.

Implemented in OPTPP::LSQNLF, OPTPP::NLF0, OPTPP::NLF1, OPTPP::FDNLF1, OPTPP::NLF0APP, and OPTPP::FDNLF1APP.

NEWMAT::ColumnVector OPTPP::NLP0::FDGrad ( const NEWMAT::ColumnVector &  ,
const NEWMAT::ColumnVector &  ,
double &  ,
NEWMAT::ColumnVector &   
)

Finite-difference gradient and Hessian.

virtual void OPTPP::NLP0::fPrintState ( ostream *  ,
char *   
) [virtual]

Print state of the function to a file.

Implements OPTPP::NLPBase.

Reimplemented in OPTPP::FDNLF1, and OPTPP::FDNLF1APP.

CompoundConstraint* OPTPP::NLP0::getConstraints (  )  [inline]
Returns:
Pointer to a CompoundConstraint object

Definition at line 257 of file NLP0.h.

References constraint_.

NEWMAT::ColumnVector OPTPP::NLP0::getConstraintValue (  )  const [inline]
Returns:
Constraint value

Definition at line 243 of file NLP0.h.

References constraint_value.

virtual int OPTPP::NLP0::getDim (  )  const [inline, virtual]
Returns:
Problem Dimension

Implements OPTPP::NLPBase.

Definition at line 178 of file NLP0.h.

References dim.

virtual real OPTPP::NLP0::getF (  )  const [inline, virtual]
Returns:
The function value

Implements OPTPP::NLPBase.

Definition at line 194 of file NLP0.h.

References fvalue.

virtual NEWMAT::ColumnVector OPTPP::NLP0::getFcnAccrcy (  )  const [inline, virtual]
Returns:
NEWMAT::ColumnVector of the function accuracy with respect to each variable

Implements OPTPP::NLPBase.

Definition at line 198 of file NLP0.h.

References mem_fcn_accrcy.

virtual real OPTPP::NLP0::getFcnTime (  )  const [inline, virtual]
Returns:
Function compute time

Implements OPTPP::NLPBase.

Definition at line 206 of file NLP0.h.

References function_time.

virtual int OPTPP::NLP0::getFevals (  )  const [inline, virtual]
Returns:
Number of Function Evaluations

Implements OPTPP::NLPBase.

Definition at line 182 of file NLP0.h.

References nfevals.

virtual int OPTPP::NLP0::getIsExpensive (  )  const [inline, virtual]
Returns:
Is the function expensive?

Implements OPTPP::NLPBase.

Definition at line 186 of file NLP0.h.

References is_expensive.

int OPTPP::NLP0::getNumOfCons (  )  const [inline, virtual]
Returns:
Total number of constraints

Implements OPTPP::NLPBase.

Definition at line 235 of file NLP0.h.

References constraint_.

int OPTPP::NLP0::getNumOfNLCons (  )  const [inline, virtual]
Returns:
Number of nonlinear constraints

Implements OPTPP::NLPBase.

Definition at line 239 of file NLP0.h.

References constraint_.

virtual NEWMAT::ColumnVector OPTPP::NLP0::getXc (  )  const [inline, virtual]
Returns:
Current point

Implements OPTPP::NLPBase.

Definition at line 202 of file NLP0.h.

References mem_xc.

bool OPTPP::NLP0::hasConstraints (  )  [virtual]
Returns:
1 - if problem has constraints, 0 - otherwise

Implements OPTPP::NLPBase.

void OPTPP::NLP0::printConstraints (  )  [virtual]

Print constraints to standard output.

Implements OPTPP::NLPBase.

virtual void OPTPP::NLP0::printState ( char *   )  [virtual]

Print the function.

Implements OPTPP::NLPBase.

Reimplemented in OPTPP::FDNLF1, and OPTPP::FDNLF1APP.

void OPTPP::NLP0::saveState (  ) 

Save current state of the function.

void OPTPP::NLP0::setConstraints ( CompoundConstraint *  constraintSet  )  [inline]

Set a pointer to a CompoundConstraint object.

Definition at line 259 of file NLP0.h.

References constraint_.

void OPTPP::NLP0::setConstraintValue ( const NEWMAT::ColumnVector &  cfx  )  [inline]

Set the constraint value.

Definition at line 245 of file NLP0.h.

References constraint_value.

virtual void OPTPP::NLP0::setX ( const int  i,
const real &  x 
) [inline, virtual]

Functions for setting various properties of this NLP problem.

Implements OPTPP::NLPBase.

Definition at line 165 of file NLP0.h.

References mem_xc.


Member Data Documentation

CompoundConstraint* OPTPP::NLP0::constraint_ [protected]

Pointer to constraints.

Definition at line 41 of file NLP0.h.

Referenced by getConstraints(), getNumOfCons(), getNumOfNLCons(), and setConstraints().

NEWMAT::ColumnVector OPTPP::NLP0::constraint_value [protected]

Constraint residual.

Definition at line 42 of file NLP0.h.

Referenced by getConstraintValue(), NLP0(), and setConstraintValue().

bool OPTPP::NLP0::debug_ [protected]

Print debug statements.

Definition at line 38 of file NLP0.h.

int OPTPP::NLP0::dim [protected]

Dimension of the problem.

Definition at line 31 of file NLP0.h.

Referenced by getDim().

DerivOption OPTPP::NLP0::finitediff [protected]

User-specified derivative option.

Definition at line 45 of file NLP0.h.

Referenced by NLP0().

double OPTPP::NLP0::function_time [protected]

Function compute time.

Definition at line 40 of file NLP0.h.

Referenced by getFcnTime().

real OPTPP::NLP0::fvalue [protected]

Objective function value at mem_xc.

Definition at line 33 of file NLP0.h.

Referenced by getF().

int OPTPP::NLP0::is_expensive [protected]

Is this an expensive function?

Definition at line 37 of file NLP0.h.

Referenced by getIsExpensive().

NEWMAT::ColumnVector OPTPP::NLP0::mem_fcn_accrcy [protected]

Accuracy available from function.

Definition at line 35 of file NLP0.h.

Referenced by getFcnAccrcy(), and NLP0().

NEWMAT::ColumnVector OPTPP::NLP0::mem_xc [protected]

Current point.

Definition at line 32 of file NLP0.h.

Referenced by getXc(), NLP0(), and setX().

int OPTPP::NLP0::ncnln [protected]

Number of nonlinear constraints.

Definition at line 43 of file NLP0.h.

int OPTPP::NLP0::nfevals [protected]

Number of function evaluations.

Definition at line 36 of file NLP0.h.

Referenced by getFevals().

char OPTPP::NLP0::nlp_name[80] [protected]

Optional identifying name.

Definition at line 34 of file NLP0.h.

SpecOption OPTPP::NLP0::SpecFlag [protected]

Speculative gradient information.

Definition at line 46 of file NLP0.h.

Referenced by OPTPP::LSQNLF::LSQNLF(), and NLP0().


The documentation for this class was generated from the following file:
Generated on Mon Jan 24 12:04:41 2011 for FASTlib by  doxygen 1.6.3