42 #ifndef NLP_SERIAL_PREPROCESS_EXPL_JAC_H
43 #define NLP_SERIAL_PREPROCESS_EXPL_JAC_H
54 namespace NLPInterfacePack {
117 const basis_sys_fcty_ptr_t &basis_sys_fcty =
Teuchos::rcp(
new BasisSystemFactoryStd())
185 const Vector& x,
bool newx
229 typedef std::valarray<value_type>
val_t;
248 ,
Gf(obj_grad.
Gf),
f(obj_grad.
f),
c(obj_grad.
c),
h(obj_grad.
h)
431 ,
const Vector& x,
bool newx
475 #endif // NLP_SERIAL_PREPROCESS_EXPL_JAC_H
void set_basis(const Permutation &P_var, const Range1D &var_dep, const Permutation *P_equ, const Range1D *equ_decomp)
AbstractLinAlgPack::size_type size_type
virtual void calc_Gc(const Vector &x, bool newx=true) const
Update the matrix for Gc at the point x and put it in the stored reference.
NLP node subclass complementing NLPSerialPreprocess for explicit Jacobians.
Abstract interface for immutable, finite dimensional, coordinate vectors {abstract}.
RTOp_index_type index_type
const Permutation & P_var() const
const basis_sys_ptr_t basis_sys() const
Calls basis_sys_fcty()->create()
void set_factory_Gc_full(const factory_mat_ptr_t &factory_Gc_full)
Initialize with matrix factory for original matrices Gc.
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.
Range1D equ_decomp() const
const Permutation & P_equ() const
FirstOrderExplInfo::ivect_t Gh_ivect_orig_
const FirstOrderExplInfo first_order_expl_info() const
const mat_fcty_ptr_t factory_Gc() const
bool get_next_basis(Permutation *P_var, Range1D *var_dep, Permutation *P_equ, Range1D *equ_decomp)
const FirstOrderInfo first_order_info() const
Return objective gradient and zero order information.
void imp_fill_jacobian_entries(size_type n, size_type n_full, bool load_struct, const index_type col_offset, const value_type *val_full, const value_type *val_full_end, const index_type *ivect_full, const index_type *jvect_full, index_type *nz, value_type *val_itr, index_type *ivect_itr, index_type *jvect_itr) const
NLP node implementation subclass for preprocessing and basis manipulation.
DVectorSlice x_full() const
Give reference to current x_full.
const ObjGradInfoSerial obj_grad_orig_info() const
std::valarray< value_type > val_t
bool is_initialized() const
bool Gc_perm_new_basis_updated_
mat_fcty_ptr_t factory_Gc_
FirstOrderExplInfo(index_type *Gc_nz_in, val_t *Gc_val_in, ivect_t *Gc_ivect_in, jvect_t *Gc_jvect_in, index_type *Gh_nz_in, val_t *Gh_val_in, ivect_t *Gh_ivect_in, jvect_t *Gh_jvect_in, const ObjGradInfoSerial &obj_grad)
FirstOrderExplInfo::jvect_t Gh_jvect_orig_
TEUCHOS_DEPRECATED RCP< T > rcp(T *p, Dealloc_T dealloc, bool owns_mem)
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...
const options_ptr_t & get_options() const
Struct for zero and first order quantities (pointers)
Teuchos::RCP< const OptionsFromStreamPack::OptionsFromStream > options_ptr_t
Teuchos::RCP< const Teuchos::AbstractFactory< MatrixOp > > factory_mat_ptr_t
factory_mat_ptr_t factory_Gc_full_
Struct for zero and explicit first order quantities that subclass must fill in.
virtual size_type imp_Gh_nz_orig() const =0
Return the number of nonzero elements in Gh before elements are removed for fixed variables...
std::valarray< index_type > jvect_t
FirstOrderExplInfo::jvect_t Gc_jvect_orig_
void set_Gc(MatrixOp *Gc)
Validates the type of Gc is correct.
NLP first order information interface class {abstract}.
std::valarray< index_type > ivect_t
Teuchos::RCP< const Teuchos::AbstractFactory< MatrixOp > > mat_fcty_ptr_t
DenseLinAlgPack::VectorSliceTmpl< value_type > DVectorSlice
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 size_type imp_Gc_nz_orig() const =0
Return the number of nonzero elements in Gc before elements are removed for fixed variables...
virtual MatrixOp & Gc()
Returns non-const *this->get_Gc().
FirstOrderExplInfo::ivect_t Gc_ivect_orig_
void set_options(const options_ptr_t &options)
Passes these options on to this->basis_sys_fcty().set_options(options).
AbstractLinAlgPack::value_type value_type
void assert_initialized() const
Assert if we have been initizlized (throws UnInitialized)
Struct for serial gradient (objective), objective and constriants (pointers)
void imp_calc_Gc_or_Gh(bool calc_Gc, const Vector &x, bool newx, const FirstOrderInfo &first_order_info) const
void imp_calc_Gc(const Vector &x, bool newx, const FirstOrderInfo &first_order_info) const
STANDARD_COMPOSITION_MEMBERS(BasisSystemFactory, basis_sys_fcty)
Set the BasisSystemFactory object used to create the basis system.
RangePack::Range1D Range1D
FirstOrderExplInfo::val_t Gh_val_orig_
void initialize(bool test_setup)
FirstOrderExplInfo::val_t Gc_val_orig_