10 #ifndef ROL_CONSTRAINT_ASSEMBLER_H
11 #define ROL_CONSTRAINT_ASSEMBLER_H
15 #include <unordered_map>
26 template<
typename Real>
41 template<
typename Real>
44 Ptr<Constraint<Real>>
con_;
52 Ptr<BoundConstraint<Real>>
bnd_;
54 std::vector<Ptr<Constraint<Real>>>
cvec_;
55 std::vector<Ptr<Vector<Real>>>
lvec_;
56 std::vector<Ptr<Vector<Real>>>
rvec_;
57 std::vector<Ptr<Constraint<Real>>>
lcvec_;
58 std::vector<Ptr<Vector<Real>>>
llvec_;
59 std::vector<Ptr<Vector<Real>>>
lrvec_;
60 std::vector<Ptr<Vector<Real>>>
psvec_;
61 std::vector<Ptr<Vector<Real>>>
dsvec_;
62 std::vector<Ptr<BoundConstraint<Real>>>
sbnd_;
Ptr< Vector< Real > > multiplier
std::vector< Ptr< Constraint< Real > > > lcvec_
std::vector< Ptr< Vector< Real > > > lvec_
std::vector< Ptr< BoundConstraint< Real > > > sbnd_
const Ptr< BoundConstraint< Real > > & getBoundConstraint() const
Ptr< Vector< Real > > linear_res_
Ptr< Vector< Real > > xprim_
const Ptr< Constraint< Real > > & getConstraint() const
std::vector< bool > isInequality_
Defines the linear algebra or vector space interface.
ConstraintData(const Ptr< Constraint< Real >> &con, const Ptr< Vector< Real >> &mul, const Ptr< Vector< Real >> &res=nullPtr, const Ptr< BoundConstraint< Real >> &bnd=nullPtr)
const Ptr< Vector< Real > > & getLinearResidual() const
void initializeSlackVariable(const Ptr< Constraint< Real >> &con, const Ptr< BoundConstraint< Real >> &cbnd, const Ptr< Vector< Real >> &s, const Ptr< Vector< Real >> &x) const
Ptr< Vector< Real > > linear_mul_
Ptr< Vector< Real > > res_
std::vector< bool > isLinearInequality_
std::vector< Ptr< Vector< Real > > > lrvec_
ConstraintAssembler(const std::unordered_map< std::string, ConstraintData< Real >> &con, const Ptr< Vector< Real >> &xprim, const Ptr< Vector< Real >> &xdual, const Ptr< BoundConstraint< Real >> &bnd=nullPtr)
std::vector< Ptr< Vector< Real > > > rvec_
void resetSlackVariables()
std::vector< Ptr< Vector< Real > > > dsvec_
std::vector< Ptr< Constraint< Real > > > cvec_
Ptr< BoundConstraint< Real > > bounds
Ptr< Vector< Real > > mul_
Ptr< BoundConstraint< Real > > bnd_
Ptr< Vector< Real > > residual
Provides a wrapper for multiple constraints.
Ptr< Vector< Real > > xdual_
const Ptr< Vector< Real > > & getMultiplier() const
Provides the interface to apply upper and lower bound constraints.
virtual ~ConstraintAssembler()
const Ptr< Vector< Real > > & getDualOptVector() const
void initialize(const std::unordered_map< std::string, ConstraintData< Real >> &input_con, const Ptr< Vector< Real >> &xprim, const Ptr< Vector< Real >> &xdual, const Ptr< BoundConstraint< Real >> &bnd)
Ptr< Constraint< Real > > constraint
Ptr< Constraint< Real > > con_
std::vector< Ptr< Vector< Real > > > psvec_
Ptr< Constraint< Real > > linear_con_
const Ptr< Vector< Real > > & getOptVector() const
const Ptr< Constraint< Real > > & getLinearConstraint() const
const Ptr< Vector< Real > > & getLinearMultiplier() const
std::vector< Ptr< Vector< Real > > > llvec_
const Ptr< Vector< Real > > & getResidual() const
Defines the general constraint operator interface.
bool hasInequality() const