44 #ifndef ROL_RISKMEASURE_HPP
45 #define ROL_RISKMEASURE_HPP
100 ROL::Ptr<Vector<Real> >
g_;
101 ROL::Ptr<Vector<Real> >
hv_;
137 x0 = ROL::constPtrCast<Vector<Real> >(
141 g_ = (x0->dual()).clone();
142 hv_ = (x0->dual()).clone();
169 v0 = ROL::constPtrCast<Vector<Real> >(
180 virtual void update(
const Real val,
const Real weight) {
181 val_ += weight * val;
214 hv_->axpy(weight,hv);
virtual void getHessVec(Vector< Real > &hv, SampleGenerator< Real > &sampler)
Return risk measure Hessian-times-a-vector.
virtual Real getValue(SampleGenerator< Real > &sampler)
Return risk measure value.
ROL::Ptr< Vector< Real > > hv_
virtual void getGradient(Vector< Real > &g, SampleGenerator< Real > &sampler)
Return risk measure (sub)gradient.
Defines the linear algebra or vector space interface.
void sumAll(Real *input, Real *output, int dim) const
Objective_SerialSimOpt(const Ptr< Obj > &obj, const V &ui) z0_ zero()
int getComponent(void) const
ROL::Ptr< Vector< Real > > dualVector_
virtual void reset(ROL::Ptr< Vector< Real > > &x0, const Vector< Real > &x)
Reset internal risk measure storage. Called for value and gradient computation.
ROL::Ptr< Vector< Real > > g_
void setRiskVectorInfo(const int comp, const int index)
virtual void update(const Real val, const Vector< Real > &g, const Real gv, const Vector< Real > &hv, const Real weight)
Update internal risk measure storage for Hessian-time-a-vector computation.
virtual void reset(ROL::Ptr< Vector< Real > > &x0, const Vector< Real > &x, ROL::Ptr< Vector< Real > > &v0, const Vector< Real > &v)
Reset internal risk measure storage. Called for Hessian-times-a-vector computation.
virtual void update(const Real val, const Real weight)
Update internal risk measure storage for value computation.
virtual void update(const Real val, const Vector< Real > &g, const Real weight)
Update internal risk measure storage for gradient computation.
Provides the interface to implement risk measures.