$extrastylesheet
Dakota  Version 6.2
Public Member Functions | Private Member Functions | Static Private Member Functions | Private Attributes | Static Private Attributes
NPSOLOptimizer Class Reference

Wrapper class for the NPSOL optimization library. More...

Inheritance diagram for NPSOLOptimizer:
Optimizer SOLBase Minimizer Iterator

List of all members.

Public Member Functions

 NPSOLOptimizer (ProblemDescDB &problem_db, Model &model)
 standard constructor
 NPSOLOptimizer (Model &model)
 alternate constructor for Iterator instantiations by name
 NPSOLOptimizer (Model &model, const int &derivative_level, const Real &conv_tol)
 alternate constructor for instantiations "on the fly"
 NPSOLOptimizer (const RealVector &initial_point, const RealVector &var_lower_bnds, const RealVector &var_upper_bnds, const RealMatrix &lin_ineq_coeffs, const RealVector &lin_ineq_lower_bnds, const RealVector &lin_ineq_upper_bnds, const RealMatrix &lin_eq_coeffs, const RealVector &lin_eq_targets, const RealVector &nonlin_ineq_lower_bnds, const RealVector &nonlin_ineq_upper_bnds, const RealVector &nonlin_eq_targets, void(*user_obj_eval)(int &, int &, double *, double &, double *, int &), void(*user_con_eval)(int &, int &, int &, int &, int *, double *, double *, double *, int &), const int &derivative_level, const Real &conv_tol)
 alternate constructor for instantiations "on the fly"
 ~NPSOLOptimizer ()
 destructor
void find_optimum ()
 Used within the optimizer branch for computing the optimal solution. Redefines the run virtual function for the optimizer branch.

Private Member Functions

void find_optimum_on_model ()
 called by find_optimum for setUpType == "model"
void find_optimum_on_user_functions ()
 called by find_optimum for setUpType == "user_functions"

Static Private Member Functions

static void objective_eval (int &mode, int &n, double *x, double &f, double *gradf, int &nstate)
 OBJFUN in NPSOL manual: computes the value and first derivatives of the objective function (passed by function pointer to NPSOL).

Private Attributes

String setUpType
 controls iteration mode: "model" (normal usage) or "user_functions" (user-supplied functions mode for "on the fly" instantiations). NonDReliability currently uses the user_functions mode.
RealVector initialPoint
 holds initial point passed in for "user_functions" mode.
RealVector lowerBounds
 holds variable lower bounds passed in for "user_functions" mode.
RealVector upperBounds
 holds variable upper bounds passed in for "user_functions" mode.
void(* userObjectiveEval )(int &, int &, double *, double &, double *, int &)
 holds function pointer for objective function evaluator passed in for "user_functions" mode.
void(* userConstraintEval )(int &, int &, int &, int &, int *, double *, double *, double *, int &)
 holds function pointer for constraint function evaluator passed in for "user_functions" mode.

Static Private Attributes

static NPSOLOptimizernpsolInstance
 pointer to the active object instance used within the static evaluator functions in order to avoid the need for static data

Detailed Description

Wrapper class for the NPSOL optimization library.

The NPSOLOptimizer class provides a wrapper for NPSOL, a Fortran 77 sequential quadratic programming library from Stanford University marketed by Stanford Business Associates. It uses a function pointer approach for which passed functions must be either global functions or static member functions. Any attribute used within static member functions must be either local to that function or accessed through a static pointer.

The user input mappings are as follows: max_function_evaluations is implemented directly in NPSOLOptimizer's evaluator functions since there is no NPSOL parameter equivalent, and max_iterations, convergence_tolerance, output verbosity, verify_level, function_precision, and linesearch_tolerance are mapped into NPSOL's "Major Iteration Limit", "Optimality Tolerance", "Major Print Level" (verbose: Major Print Level = 20; quiet: Major Print Level = 10), "Verify Level", "Function Precision", and "Linesearch Tolerance" parameters, respectively, using NPSOL's npoptn() subroutine (as wrapped by npoptn2() from the npoptn_wrapper.f file). Refer to [Gill, P.E., Murray, W., Saunders, M.A., and Wright, M.H., 1986] for information on NPSOL's optional input parameters and the npoptn() subroutine.


Constructor & Destructor Documentation

NPSOLOptimizer ( ProblemDescDB problem_db,
Model model 
)
NPSOLOptimizer ( Model model)

alternate constructor for Iterator instantiations by name

This is an alternate constructor which accepts a Model but does not have a supporting method specification from the ProblemDescDB.

References Minimizer::constraintTol, Iterator::convergenceTol, Model::fd_gradient_step_size(), Model::gradient_type(), Iterator::iteratedModel, Iterator::maxIterations, Iterator::outputLevel, SOLBase::set_options(), Minimizer::speculativeFlag, and Minimizer::vendorNumericalGradFlag.

NPSOLOptimizer ( Model model,
const int &  derivative_level,
const Real &  conv_tol 
)

alternate constructor for instantiations "on the fly"

This is an alternate constructor for instantiations on the fly using a Model but no ProblemDescDB.

NPSOLOptimizer ( const RealVector &  initial_point,
const RealVector &  var_lower_bnds,
const RealVector &  var_upper_bnds,
const RealMatrix &  lin_ineq_coeffs,
const RealVector &  lin_ineq_lower_bnds,
const RealVector &  lin_ineq_upper_bnds,
const RealMatrix &  lin_eq_coeffs,
const RealVector &  lin_eq_targets,
const RealVector &  nonlin_ineq_lower_bnds,
const RealVector &  nonlin_ineq_upper_bnds,
const RealVector &  nonlin_eq_targets,
void(*)(int &, int &, double *, double &, double *, int &)  user_obj_eval,
void(*)(int &, int &, int &, int &, int *, double *, double *, double *, int &)  user_con_eval,
const int &  derivative_level,
const Real &  conv_tol 
)

alternate constructor for instantiations "on the fly"

This is an alternate constructor for performing an optimization using the passed in objective function and constraint function pointers.

References SOLBase::allocate_arrays(), SOLBase::allocate_workspace(), SOLBase::augment_bounds(), NPSOLOptimizer::lowerBounds, Minimizer::numContinuousVars, Minimizer::numLinearConstraints, Minimizer::numNonlinearConstraints, and NPSOLOptimizer::upperBounds.


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