OPTPP::LSQNLF Class Reference

#include <LSQNLF.h>

Inheritance diagram for OPTPP::LSQNLF:

OPTPP::NLP2 OPTPP::NLP1 OPTPP::NLP0 OPTPP::NLPBase List of all members.

Public Member Functions

 LSQNLF ()
 LSQNLF (int ndim, int lsqterms)
 LSQNLF (int ndim, int lsqterms, USERFCNLSQ0 f, INITFCN i, CompoundConstraint *constraint=0)
 LSQNLF (int ndim, int lsqterms, USERFCNLSQ1 f, INITFCN i, CompoundConstraint *constraint=0)
 LSQNLF (int ndim, int lsqterms, USERFCNLSQ0 f, INITFCN i, INITCONFCN c)
 LSQNLF (int ndim, int lsqterms, USERFCNLSQ1 f, INITFCN i, INITCONFCN c)
 LSQNLF (int ndim, int lsqterms, USERFCNLSQ0V f, INITFCN i, INITCONFCN c, void *v)
 Alternate function pointers with user-supplied void function pointer.
 LSQNLF (int ndim, int lsqterms, USERFCNLSQ1V f, INITFCN i, INITCONFCN c, void *v)
 LSQNLF ()
 LSQNLF (int ndim, int lsqterms)
 LSQNLF (int ndim, int lsqterms, USERFCNLSQ0 f, INITFCN i, CompoundConstraint *constraint=0)
 LSQNLF (int ndim, int lsqterms, USERFCNLSQ1 f, INITFCN i, CompoundConstraint *constraint=0)
 LSQNLF (int ndim, int lsqterms, USERFCNLSQ0 f, INITFCN i, INITCONFCN c)
 LSQNLF (int ndim, int lsqterms, USERFCNLSQ1 f, INITFCN i, INITCONFCN c)
 LSQNLF (int ndim, int lsqterms, USERFCNLSQ0V f, INITFCN i, INITCONFCN c, void *v)
 Alternate function pointers with user-supplied void function pointer.
 LSQNLF (int ndim, int lsqterms, USERFCNLSQ1V f, INITFCN i, INITCONFCN c, void *v)
virtual ~LSQNLF ()
void setFcnResidual (NEWMAT::ColumnVector &f)
NEWMAT::ColumnVector getFcnResidual () const
virtual void reset ()
 Reset parameters.
virtual void initFcn ()
 Initialize selected function.
virtual void eval ()
 Evaluate the function, gradient, and Hessian.
virtual real evalF ()
 Evaluate the function.
virtual real evalF (const NEWMAT::ColumnVector &x)
 Evaluate the function at x.
virtual NEWMAT::ColumnVector evalG ()
 Evaluate a finite-difference gradient.
virtual NEWMAT::ColumnVector evalG (const NEWMAT::ColumnVector &x)
 Evaluate a finite-difference gradient at x.
virtual NEWMAT::SymmetricMatrix evalH ()
 Evaluate the Hessian.
virtual real evalLagrangian (const NEWMAT::ColumnVector &x, NEWMAT::ColumnVector &mult, const NEWMAT::ColumnVector &type)
 Evaluate the Lagrangian at x.
virtual NEWMAT::ColumnVector evalLagrangianGradient (const NEWMAT::ColumnVector &x, const NEWMAT::ColumnVector &mult, const NEWMAT::ColumnVector &type)
 Evaluate the gradient of the Lagrangian at x.
virtual NEWMAT::ColumnVector evalCF (const NEWMAT::ColumnVector &x)
 Evaluate nonlinear constraints at x.
virtual NEWMAT::Matrix evalCG (const NEWMAT::ColumnVector &x)
 Evaluate gradient of nonlinear constraints at x.

Static Protected Member Functions

static void f0_helper (int n, const NEWMAT::ColumnVector &xc, NEWMAT::ColumnVector &f, int &result, void *v)
static void f1_helper (int m, int n, const NEWMAT::ColumnVector &xc, NEWMAT::ColumnVector &f, NEWMAT::Matrix &g, int &result, void *v)

Protected Attributes

USERFCNLSQ0 fcn0
 User-defined objective function.
USERFCNLSQ0V fcn0_v
 User-defined objective function w/ void ptr.
USERFCNLSQ1 fcn1
 User-defined objective function.
USERFCNLSQ1V fcn1_v
 User-defined objective function w/ void ptr.
USERNLNCON1 confcn
 User-defined nonlinear constraints.
INITFCN init_fcn
 User-defined initfcn for the obj. function.
INITCONFCN init_confcn
 User-defined initfcn for the constraints.
bool init_flag
 Has the function been initialized?
bool Jacobian_current
 Has the function been updated?
int lsqterms_
 Number of least square terms in objective.
NEWMAT::ColumnVector fvector
 Vector of objective function values.
NEWMAT::Matrix Jacobian_
 Jacobian_ of objective function residuals.
NEWMAT::Matrix partial_jac
void * vptr
 Void pointer.

Private Member Functions

virtual NEWMAT::SymmetricMatrix evalH (NEWMAT::ColumnVector &x)
 Evaluate hessian at x.
virtual NEWMAT::SymmetricMatrix evalCH (NEWMAT::ColumnVector &x)
 Evaluate constraint hessian at x.
virtual OptppArray< NEWMAT::SymmetricMatrix > evalCH (NEWMAT::ColumnVector &x, int darg)
 Evaluate the constraint Hessian at x.
virtual void evalC (const NEWMAT::ColumnVector &x)
NEWMAT::Matrix LSQFDJac (const NEWMAT::ColumnVector &sx, const NEWMAT::ColumnVector &xc, NEWMAT::ColumnVector &fx, NEWMAT::Matrix &partial_jac)
 Construct forward finite-difference Jacobian of objective funtion.
NEWMAT::Matrix LSQBDJac (const NEWMAT::ColumnVector &sx, const NEWMAT::ColumnVector &xc, NEWMAT::ColumnVector &fx, NEWMAT::Matrix &partial_jac)
 Construct backward finite-difference Jacobian of objective funtion.
NEWMAT::Matrix LSQCDJac (const NEWMAT::ColumnVector &sx, const NEWMAT::ColumnVector &xc, NEWMAT::ColumnVector &fx, NEWMAT::Matrix &partial_jac)
 Construct central finite-difference Jacobian of objective funtion.

Private Attributes

NEWMAT::ColumnVector tempF
 Vector of objective function residuals.
NEWMAT::ColumnVector specLSQF
 Vector of objective function residuals.

Detailed Description

LSQNLF is a derived class of NLP2. The LSQNLF class implements the function, gradient, and Hessian evaluator for a least square objective.

Author:
P. J. Williams, Sandia National Laboratories
Date:
Last modified 11/2005


Constructor & Destructor Documentation

OPTPP::LSQNLF::LSQNLF (  )  [inline]

OPTPP::LSQNLF::LSQNLF ( int  ndim,
int  lsqterms 
) [inline]

OPTPP::LSQNLF::LSQNLF ( int  ndim,
int  lsqterms,
USERFCNLSQ0  f,
INITFCN  i,
CompoundConstraint constraint = 0 
) [inline]

OPTPP::LSQNLF::LSQNLF ( int  ndim,
int  lsqterms,
USERFCNLSQ1  f,
INITFCN  i,
CompoundConstraint constraint = 0 
) [inline]

OPTPP::LSQNLF::LSQNLF ( int  ndim,
int  lsqterms,
USERFCNLSQ0  f,
INITFCN  i,
INITCONFCN  c 
) [inline]

OPTPP::LSQNLF::LSQNLF ( int  ndim,
int  lsqterms,
USERFCNLSQ1  f,
INITFCN  i,
INITCONFCN  c 
) [inline]

OPTPP::LSQNLF::LSQNLF ( int  ndim,
int  lsqterms,
USERFCNLSQ0V  f,
INITFCN  i,
INITCONFCN  c,
void *  v 
) [inline]

Alternate function pointers with user-supplied void function pointer.

OPTPP::LSQNLF::LSQNLF ( int  ndim,
int  lsqterms,
USERFCNLSQ1V  f,
INITFCN  i,
INITCONFCN  c,
void *  v 
) [inline]

OPTPP::LSQNLF::LSQNLF (  )  [inline]

OPTPP::LSQNLF::LSQNLF ( int  ndim,
int  lsqterms 
) [inline]

OPTPP::LSQNLF::LSQNLF ( int  ndim,
int  lsqterms,
USERFCNLSQ0  f,
INITFCN  i,
CompoundConstraint constraint = 0 
) [inline]

OPTPP::LSQNLF::LSQNLF ( int  ndim,
int  lsqterms,
USERFCNLSQ1  f,
INITFCN  i,
CompoundConstraint constraint = 0 
) [inline]

OPTPP::LSQNLF::LSQNLF ( int  ndim,
int  lsqterms,
USERFCNLSQ0  f,
INITFCN  i,
INITCONFCN  c 
) [inline]

OPTPP::LSQNLF::LSQNLF ( int  ndim,
int  lsqterms,
USERFCNLSQ1  f,
INITFCN  i,
INITCONFCN  c 
) [inline]

OPTPP::LSQNLF::LSQNLF ( int  ndim,
int  lsqterms,
USERFCNLSQ0V  f,
INITFCN  i,
INITCONFCN  c,
void *  v 
) [inline]

Alternate function pointers with user-supplied void function pointer.

OPTPP::LSQNLF::LSQNLF ( int  ndim,
int  lsqterms,
USERFCNLSQ1V  f,
INITFCN  i,
INITCONFCN  c,
void *  v 
) [inline]

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


Member Function Documentation

virtual void OPTPP::LSQNLF::eval (  )  [virtual]

Evaluate the function, gradient, and Hessian.

Implements OPTPP::NLP2.

virtual void OPTPP::LSQNLF::evalC ( const NEWMAT::ColumnVector &  x  )  [private, virtual]

Implements OPTPP::NLP2.

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

Evaluate nonlinear constraints at x.

Implements OPTPP::NLP2.

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

Evaluate gradient of nonlinear constraints at x.

Implements OPTPP::NLP2.

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

Evaluate the constraint Hessian at x.

Implements OPTPP::NLP2.

virtual NEWMAT::SymmetricMatrix OPTPP::LSQNLF::evalCH ( NEWMAT::ColumnVector &  x  )  [private, virtual]

Evaluate constraint hessian at x.

Implements OPTPP::NLP2.

virtual real OPTPP::LSQNLF::evalF ( const NEWMAT::ColumnVector &  x  )  [virtual]

Evaluate the function at x.

Implements OPTPP::NLP2.

virtual real OPTPP::LSQNLF::evalF (  )  [virtual]

Evaluate the function.

Implements OPTPP::NLP2.

virtual NEWMAT::ColumnVector OPTPP::LSQNLF::evalG ( const NEWMAT::ColumnVector &  x  )  [virtual]

Evaluate a finite-difference gradient at x.

Implements OPTPP::NLP2.

virtual NEWMAT::ColumnVector OPTPP::LSQNLF::evalG (  )  [virtual]

Evaluate a finite-difference gradient.

Implements OPTPP::NLP2.

virtual NEWMAT::SymmetricMatrix OPTPP::LSQNLF::evalH ( NEWMAT::ColumnVector &  x  )  [private, virtual]

Evaluate hessian at x.

Implements OPTPP::NLP2.

virtual NEWMAT::SymmetricMatrix OPTPP::LSQNLF::evalH (  )  [virtual]

Evaluate the Hessian.

Implements OPTPP::NLP2.

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

Evaluate the Lagrangian at x.

Implements OPTPP::NLP2.

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

Evaluate the gradient of the Lagrangian at x.

Implements OPTPP::NLP2.

static void OPTPP::LSQNLF::f0_helper ( int  n,
const NEWMAT::ColumnVector &  xc,
NEWMAT::ColumnVector &  f,
int &  result,
void *  v 
) [inline, static, protected]

static void OPTPP::LSQNLF::f1_helper ( int  m,
int  n,
const NEWMAT::ColumnVector &  xc,
NEWMAT::ColumnVector &  f,
NEWMAT::Matrix &  g,
int &  result,
void *  v 
) [inline, static, protected]

NEWMAT::ColumnVector OPTPP::LSQNLF::getFcnResidual (  )  const [inline]

virtual void OPTPP::LSQNLF::initFcn (  )  [virtual]

Initialize selected function.

Implements OPTPP::NLP2.

NEWMAT::Matrix OPTPP::LSQNLF::LSQBDJac ( const NEWMAT::ColumnVector &  sx,
const NEWMAT::ColumnVector &  xc,
NEWMAT::ColumnVector &  fx,
NEWMAT::Matrix &  partial_jac 
) [private]

Construct backward finite-difference Jacobian of objective funtion.

NEWMAT::Matrix OPTPP::LSQNLF::LSQCDJac ( const NEWMAT::ColumnVector &  sx,
const NEWMAT::ColumnVector &  xc,
NEWMAT::ColumnVector &  fx,
NEWMAT::Matrix &  partial_jac 
) [private]

Construct central finite-difference Jacobian of objective funtion.

NEWMAT::Matrix OPTPP::LSQNLF::LSQFDJac ( const NEWMAT::ColumnVector &  sx,
const NEWMAT::ColumnVector &  xc,
NEWMAT::ColumnVector &  fx,
NEWMAT::Matrix &  partial_jac 
) [private]

Construct forward finite-difference Jacobian of objective funtion.

virtual void OPTPP::LSQNLF::reset (  )  [virtual]

Reset parameters.

Implements OPTPP::NLP2.

void OPTPP::LSQNLF::setFcnResidual ( NEWMAT::ColumnVector &  f  )  [inline]


Member Data Documentation

USERNLNCON1 OPTPP::LSQNLF::confcn [protected]

User-defined nonlinear constraints.

USERFCNLSQ0 OPTPP::LSQNLF::fcn0 [protected]

User-defined objective function.

USERFCNLSQ0V OPTPP::LSQNLF::fcn0_v [protected]

User-defined objective function w/ void ptr.

USERFCNLSQ1 OPTPP::LSQNLF::fcn1 [protected]

User-defined objective function.

USERFCNLSQ1V OPTPP::LSQNLF::fcn1_v [protected]

User-defined objective function w/ void ptr.

NEWMAT::ColumnVector OPTPP::LSQNLF::fvector [protected]

Vector of objective function values.

INITCONFCN OPTPP::LSQNLF::init_confcn [protected]

User-defined initfcn for the constraints.

INITFCN OPTPP::LSQNLF::init_fcn [protected]

User-defined initfcn for the obj. function.

bool OPTPP::LSQNLF::init_flag [protected]

Has the function been initialized?

NEWMAT::Matrix OPTPP::LSQNLF::Jacobian_ [protected]

Jacobian_ of objective function residuals.

bool OPTPP::LSQNLF::Jacobian_current [protected]

Has the function been updated?

int OPTPP::LSQNLF::lsqterms_ [protected]

Number of least square terms in objective.

NEWMAT::Matrix OPTPP::LSQNLF::partial_jac [protected]

NEWMAT::ColumnVector OPTPP::LSQNLF::specLSQF [private]

Vector of objective function residuals.

NEWMAT::ColumnVector OPTPP::LSQNLF::tempF [private]

Vector of objective function residuals.

void* OPTPP::LSQNLF::vptr [protected]

Void pointer.


The documentation for this class was generated from the following file:
Bug Reports    OPT++ Developers    Copyright Information    GNU Lesser General Public License
Documentation, generated by , last revised August 30, 2006.