NLPSerialPreprocess
for explicit Jacobians.
More...
#include <NLPInterfacePack_NLPSerialPreprocessExplJac.hpp>
Inheritance diagram for NLPInterfacePack::NLPSerialPreprocessExplJac:
Public types  
typedef Teuchos::RefCountPtr< const Teuchos::AbstractFactory< MatrixOp > >  factory_mat_ptr_t 
 
Constructors / initializers  
void  set_basis_sys_fcty (const Teuchos::RefCountPtr< BasisSystemFactory > &basis_sys_fcty) 
Set the BasisSystemFactory object used to create the basis system.  
NLPSerialPreprocessExplJac (const basis_sys_fcty_ptr_t &basis_sys_fcty=Teuchos::rcp(new BasisSystemFactoryStd()), const factory_mat_ptr_t &factory_Gc_full=Teuchos::null)  
Calls this>set_basis_sys_fcty() and this>set_mat_factories() methods.  
void  set_factory_Gc_full (const factory_mat_ptr_t &factory_Gc_full) 
Initialize with matrix factory for original matrices Gc .  
Overridden public members from NLP  
void  set_options (const options_ptr_t &options) 
Passes these options on to this>basis_sys_fcty().set_options(options) .  
const options_ptr_t &  get_options () const 
 
void  initialize (bool test_setup) 
 
bool  is_initialized () const 
 
Overridden public members from NLPFirstOrder  
const mat_fcty_ptr_t  factory_Gc () const 
 
const basis_sys_ptr_t  basis_sys () const 
Calls basis_sys_fcty()>create() .  
void  set_Gc (MatrixOp *Gc) 
Validates the type of Gc is correct.  
Overridden public members from NLPVarReductPerm  
bool  get_next_basis (Permutation *P_var, Range1D *var_dep, Permutation *P_equ, Range1D *equ_decomp) 
 
void  set_basis (const Permutation &P_var, const Range1D &var_dep, const Permutation *P_equ, const Range1D *equ_decomp) 
 
Overridden protected members from NLPFirstOrder  
void  imp_calc_Gc (const Vector &x, bool newx, const FirstOrderInfo &first_order_info) const 
 
Pure virtual template methods to be defined by subclasses  
virtual size_type  imp_Gc_nz_orig () const =0 
Return the number of nonzero elements in Gc before elements are removed for fixed variables.  
virtual size_type  imp_Gh_nz_orig () const =0 
Return the number of nonzero elements in Gh before elements are removed for fixed variables.  
virtual void  imp_calc_Gc_orig (const DVectorSlice &x_full, bool newx, const FirstOrderExplInfo &first_order_expl_info) const =0 
Calculate the COOR matrix for the gradient for all of the c(x) constaints in the original NLP.  
virtual void  imp_calc_Gh_orig (const DVectorSlice &x_full, bool newx, const FirstOrderExplInfo &first_order_expl_info) const =0 
Calculate the COOR matrix for the gradient for all of the h(x) constaints in the original NLP.  
Protected member functions for subclasses to use  
void  assert_initialized () const 
Assert if we have been initizlized (throws UnInitialized).  
const FirstOrderExplInfo  first_order_expl_info () const 

NLPSerialPreprocess
for explicit Jacobians.
This subclass does a lot of work. It has to consider several different types of variability. The matrices Gc
and Gh
that are computed must take into consideration whether or not inequalities are converted to equalities (convert_inequ_to_equ
) and the permutation of the entries according to the current basis selection.
Gc = P_var * [ Gc_orig Gh_orig ] * P_equ' [ 0 I ]
BasisSystemPerm
object which is created by a BasisSystemPermFactory
object that the client (or the subclass) can specify. The default implementation for this factory object is from BasisSystemPermFactoryStd
which uses the AbstractLinAlgPack::BasisSystemPermDirectSparse
subclass and supports several different linear solvers by default. The client (or subclass) can augment the list of supported linear solvers easily.ToDo: Finish documentation!
Subclass developers
Subclass developer's don't have to worry about slack variables or basis permutations. A concreate subclass just has to override the functions that defined the original NLP (see the tutorial example NLP ???).
In addition to the methods that must be overridden in NLPSerialPreprocess
(see) the following methods must be overridden as well: imp_Gc_nz_orig()
, imp_Gh_nz_orig()
, imp_calc_Gc_orig()
, imp_calc_Gh_orig()
.
Definition at line 80 of file NLPInterfacePack_NLPSerialPreprocessExplJac.hpp.

Definition at line 91 of file NLPInterfacePack_NLPSerialPreprocessExplJac.hpp. 

Calls
Definition at line 55 of file NLPInterfacePack_NLPSerialPreprocessExplJac.cpp. 

Set the
Definition at line 99 of file NLPInterfacePack_NLPSerialPreprocessExplJac.hpp. 

Initialize with matrix factory for original matrices
This matrix type will be used for
Definition at line 65 of file NLPInterfacePack_NLPSerialPreprocessExplJac.cpp. 

Passes these options on to
Reimplemented from NLPInterfacePack::NLP. Definition at line 79 of file NLPInterfacePack_NLPSerialPreprocessExplJac.cpp. 

Reimplemented from NLPInterfacePack::NLP. Definition at line 85 of file NLPInterfacePack_NLPSerialPreprocessExplJac.cpp. 

Reimplemented from NLPInterfacePack::NLPFirstOrder. Definition at line 90 of file NLPInterfacePack_NLPSerialPreprocessExplJac.cpp. 

Reimplemented from NLPInterfacePack::NLPSerialPreprocess. Definition at line 124 of file NLPInterfacePack_NLPSerialPreprocessExplJac.cpp. 

Implements NLPInterfacePack::NLPFirstOrder. Definition at line 131 of file NLPInterfacePack_NLPSerialPreprocessExplJac.cpp. 

Calls
Reimplemented from NLPInterfacePack::NLPFirstOrder. Definition at line 137 of file NLPInterfacePack_NLPSerialPreprocessExplJac.cpp. 

Validates the type of Gc is correct.
Reimplemented from NLPInterfacePack::NLPFirstOrder. Definition at line 144 of file NLPInterfacePack_NLPSerialPreprocessExplJac.cpp. 

Reimplemented from NLPInterfacePack::NLPSerialPreprocess. Definition at line 156 of file NLPInterfacePack_NLPSerialPreprocessExplJac.cpp. 

Reimplemented from NLPInterfacePack::NLPSerialPreprocess. Definition at line 170 of file NLPInterfacePack_NLPSerialPreprocessExplJac.cpp. 

Implements NLPInterfacePack::NLPFirstOrder. Definition at line 183 of file NLPInterfacePack_NLPSerialPreprocessExplJac.cpp. 

Return the number of nonzero elements in
The value returned from this method before the first time 

Return the number of nonzero elements in
The value returned from this method before the first time 

Calculate the COOR matrix for the gradient for all of the
Postconditions:
Note that duplicate entires with the same row and column indexes are allowed. In this case, the matrix entries are considered to be summed. 

Calculate the COOR matrix for the gradient for all of the
Postconditions:
Note that duplicate entires with the same row and column indexes are allowed. In this case, the matrix entries are considered to be summed. 

Assert if we have been initizlized (throws UnInitialized).
Reimplemented from NLPInterfacePack::NLPSerialPreprocess. Definition at line 435 of file NLPInterfacePack_NLPSerialPreprocessExplJac.cpp. 

Definition at line 445 of file NLPInterfacePack_NLPSerialPreprocessExplJac.hpp. 