58 template<
typename Real>
74 class isGreater :
public Elementwise::BinaryFunction<Real> {
77 Real
apply(
const Real &x,
const Real &y)
const {
78 return (x > y) ?
static_cast<Real
>(1) : static_cast<Real>(0);
82 class Active :
public Elementwise::BinaryFunction<Real> {
85 Real
apply(
const Real &x,
const Real &y )
const {
86 return ((y <=
offset_) ? 0 : x);
95 Real
apply(
const Real &x,
const Real &y )
const {
105 Real
apply(
const Real &x,
const Real &y )
const {
114 Real
apply(
const Real &x,
const Real &y )
const {
115 return ((y == 1) ? x : 0);
119 class BuildC :
public Elementwise::UnaryFunction<Real> {
122 const Real zeta(0.5), kappa(1);
123 return std::min(zeta * x, kappa);
129 Real
apply(
const Real &x,
const Real &y)
const {
131 return (x==zero ? y : x);
142 Real feasTol = std::sqrt(ROL_EPSILON<Real>()));
146 const Real scale = 1,
147 const Real feasTol = std::sqrt(ROL_EPSILON<Real>()));
LowerBinding(Real xeps, Real geps)
UpperBinding(Real xeps, Real geps)
Real apply(const Real &x, const Real &y) const
void pruneUpperActive(Vector< Real > &v, const Vector< Real > &x, Real eps=Real(0)) override
Set variables to zero if they correspond to the upper -active set.
Real apply(const Real &x, const Real &y) const
Defines the linear algebra or vector space interface.
Real apply(const Real &x, const Real &y) const
ROL::Bounds::isGreater isGreater_
Objective_SerialSimOpt(const Ptr< Obj > &obj, const V &ui) z0_ zero()
void project(Vector< Real > &x) override
Project optimization variables onto the bounds.
Elementwise::ReductionMin< Real > minimum_
ROL::Bounds::BuildC buildC_
Bounds(const Vector< Real > &x, bool isLower=true, Real scale=1, Real feasTol=std::sqrt(ROL_EPSILON< Real >()))
Real apply(const Real &x) const
Provides the elementwise interface to apply upper and lower bound constraints.
void buildScalingFunction(Vector< Real > &d, const Vector< Real > &x, const Vector< Real > &g) const
bool isFeasible(const Vector< Real > &v) override
Check if the vector, v, is feasible.
ROL::Bounds::PruneBinding prune_
Provides the interface to apply upper and lower bound constraints.
Real apply(const Real &x, const Real &y) const
ROL::Bounds::SetZeroEntry setZeroEntry_
Real apply(const Real &x, const Real &y) const
Real apply(const Real &x, const Real &y) const
void applyInverseScalingFunction(Vector< Real > &dv, const Vector< Real > &v, const Vector< Real > &x, const Vector< Real > &g) const override
Apply inverse scaling function.
Elementwise::ReductionMax< Real > maximum_
Ptr< Vector< Real > > mask_
void projectInterior(Vector< Real > &x) override
Project optimization variables into the interior of the feasible set.
void pruneLowerActive(Vector< Real > &v, const Vector< Real > &x, Real eps=Real(0)) override
Set variables to zero if they correspond to the lower -active set.
void applyScalingFunctionJacobian(Vector< Real > &dv, const Vector< Real > &v, const Vector< Real > &x, const Vector< Real > &g) const override
Apply scaling function Jacobian.