ROL
ROL::MeanDeviationFromTarget< Real > Class Template Reference

Provides an interface for the mean plus a sum of arbitrary order deviations from targets. More...

#include <ROL_MeanDeviationFromTarget.hpp>

Inheritance diagram for ROL::MeanDeviationFromTarget< Real >:

Public Member Functions

 MeanDeviationFromTarget (const Real target, const Real order, const Real coeff, const Ptr< PositiveFunction< Real > > &pf)
 Constructor.
 MeanDeviationFromTarget (const std::vector< Real > &target, const std::vector< Real > &order, const std::vector< Real > &coeff, const Ptr< PositiveFunction< Real > > &pf)
 Constructor.
 MeanDeviationFromTarget (ROL::ParameterList &parlist)
 Constructor.
void initialize (const Vector< Real > &x)
void updateValue (Objective< Real > &obj, const Vector< Real > &x, const std::vector< Real > &xstat, Real &tol)
Real getValue (const Vector< Real > &x, const std::vector< Real > &xstat, SampleGenerator< Real > &sampler)
void updateGradient (Objective< Real > &obj, const Vector< Real > &x, const std::vector< Real > &xstat, Real &tol)
void getGradient (Vector< Real > &g, std::vector< Real > &gstat, const Vector< Real > &x, const std::vector< Real > &xstat, SampleGenerator< Real > &sampler)
void updateHessVec (Objective< Real > &obj, const Vector< Real > &v, const std::vector< Real > &vstat, const Vector< Real > &x, const std::vector< Real > &xstat, Real &tol)
void getHessVec (Vector< Real > &hv, std::vector< Real > &hvstat, const Vector< Real > &v, const std::vector< Real > &vstat, const Vector< Real > &x, const std::vector< Real > &xstat, SampleGenerator< Real > &sampler)

Private Types

typedef std::vector< Real >::size_type uint

Private Member Functions

void initializeMDT (void)
void checkInputs (void)

Private Attributes

Ptr< PositiveFunction< Real > > positiveFunction_
std::vector< Real > target_
std::vector< Real > order_
std::vector< Real > coeff_
uint NumMoments_
std::vector< Real > pval_
std::vector< Real > pgv_
std::vector< Ptr< Vector< Real > > > pg0_
std::vector< Ptr< Vector< Real > > > pg_
std::vector< Ptr< Vector< Real > > > phv_
bool firstResetMDT_

Detailed Description

template<class Real>
class ROL::MeanDeviationFromTarget< Real >

Provides an interface for the mean plus a sum of arbitrary order deviations from targets.

The mean plus deviations from targets risk measure is

\[ \mathcal{R}(X) = \mathbb{E}[X] + \sum_{k=1}^n c_k \mathbb{E}[\wp(X-t_k)^{p_k}]^{1/p_k} \]

where \(\wp:\mathbb{R}\to[0,\infty)\) is either the absolute value or \((x)_+ = \max\{0,x\}\), \(c_k > 0\) and \(p_k\in\mathbb{N}\). In general, \(\mathcal{R}\) is law-invariant, but not coherent since it violates translation equivariance.

When using derivative-based optimization, the user can provide a smooth approximation of \((\cdot)_+\) using the ROL::PositiveFunction class.

Definition at line 42 of file ROL_MeanDeviationFromTarget.hpp.

Member Typedef Documentation

◆ uint

template<class Real>
typedef std::vector<Real>::size_type ROL::MeanDeviationFromTarget< Real >::uint
private

Definition at line 43 of file ROL_MeanDeviationFromTarget.hpp.

Constructor & Destructor Documentation

◆ MeanDeviationFromTarget() [1/3]

template<class Real>
ROL::MeanDeviationFromTarget< Real >::MeanDeviationFromTarget ( const Real target,
const Real order,
const Real coeff,
const Ptr< PositiveFunction< Real > > & pf )
inline

Constructor.

Parameters
[in]targetis the target scalar value
[in]orderis the deviation order
[in]coeffis the weight for deviation term
[in]pfis the plus function or an approximation

This constructor produces a mean plus deviation from target risk measure with a single deviation.

Definition at line 113 of file ROL_MeanDeviationFromTarget.hpp.

References checkInputs(), coeff_, firstResetMDT_, NumMoments_, order_, positiveFunction_, and target_.

◆ MeanDeviationFromTarget() [2/3]

template<class Real>
ROL::MeanDeviationFromTarget< Real >::MeanDeviationFromTarget ( const std::vector< Real > & target,
const std::vector< Real > & order,
const std::vector< Real > & coeff,
const Ptr< PositiveFunction< Real > > & pf )
inline

Constructor.

Parameters
[in]targetis a vector of targets
[in]orderis a vector of deviation orders
[in]coeffis a vector of weights for the deviation terms
[in]pfis the plus function or an approximation

This constructor produces a mean plus deviation from target risk measure with an arbitrary number of deviations.

Definition at line 133 of file ROL_MeanDeviationFromTarget.hpp.

References checkInputs(), coeff_, firstResetMDT_, NumMoments_, order_, positiveFunction_, and target_.

◆ MeanDeviationFromTarget() [3/3]

template<class Real>
ROL::MeanDeviationFromTarget< Real >::MeanDeviationFromTarget ( ROL::ParameterList & parlist)
inline

Constructor.

Parameters
[in]parlistis a parameter list specifying inputs

parlist should contain sublists "SOL"->"Risk Measure"->"Mean Plus Deviation From Target" and within the "Mean Plus Deviation From Target" sublist should have the following parameters

  • "Targets" (array of scalars)
  • "Orders" (array of unsigned integers)
  • "Coefficients" (array of positive scalars)
  • "Deviation Type" (eighter "Upper" or "Absolute")
  • A sublist for positive function information.

Definition at line 164 of file ROL_MeanDeviationFromTarget.hpp.

References checkInputs(), coeff_, firstResetMDT_, NumMoments_, order_, positiveFunction_, and target_.

Member Function Documentation

◆ initializeMDT()

template<class Real>
void ROL::MeanDeviationFromTarget< Real >::initializeMDT ( void )
inlineprivate

Definition at line 74 of file ROL_MeanDeviationFromTarget.hpp.

References NumMoments_, pg0_, pg_, pgv_, phv_, and pval_.

Referenced by checkInputs().

◆ checkInputs()

template<class Real>
void ROL::MeanDeviationFromTarget< Real >::checkInputs ( void )
inlineprivate

◆ initialize()

template<class Real>
void ROL::MeanDeviationFromTarget< Real >::initialize ( const Vector< Real > & x)
inline

◆ updateValue()

template<class Real>
void ROL::MeanDeviationFromTarget< Real >::updateValue ( Objective< Real > & obj,
const Vector< Real > & x,
const std::vector< Real > & xstat,
Real & tol )
inline

Definition at line 210 of file ROL_MeanDeviationFromTarget.hpp.

References NumMoments_, order_, positiveFunction_, pval_, and target_.

◆ getValue()

template<class Real>
Real ROL::MeanDeviationFromTarget< Real >::getValue ( const Vector< Real > & x,
const std::vector< Real > & xstat,
SampleGenerator< Real > & sampler )
inline

◆ updateGradient()

template<class Real>
void ROL::MeanDeviationFromTarget< Real >::updateGradient ( Objective< Real > & obj,
const Vector< Real > & x,
const std::vector< Real > & xstat,
Real & tol )
inline

Definition at line 238 of file ROL_MeanDeviationFromTarget.hpp.

References NumMoments_, order_, pg_, positiveFunction_, pval_, and target_.

◆ getGradient()

template<class Real>
void ROL::MeanDeviationFromTarget< Real >::getGradient ( Vector< Real > & g,
std::vector< Real > & gstat,
const Vector< Real > & x,
const std::vector< Real > & xstat,
SampleGenerator< Real > & sampler )
inline

◆ updateHessVec()

template<class Real>
void ROL::MeanDeviationFromTarget< Real >::updateHessVec ( Objective< Real > & obj,
const Vector< Real > & v,
const std::vector< Real > & vstat,
const Vector< Real > & x,
const std::vector< Real > & xstat,
Real & tol )
inline

Definition at line 274 of file ROL_MeanDeviationFromTarget.hpp.

References NumMoments_, order_, pg0_, pg_, pgv_, phv_, positiveFunction_, pval_, and target_.

◆ getHessVec()

template<class Real>
void ROL::MeanDeviationFromTarget< Real >::getHessVec ( Vector< Real > & hv,
std::vector< Real > & hvstat,
const Vector< Real > & v,
const std::vector< Real > & vstat,
const Vector< Real > & x,
const std::vector< Real > & xstat,
SampleGenerator< Real > & sampler )
inline

Member Data Documentation

◆ positiveFunction_

◆ target_

◆ order_

◆ coeff_

template<class Real>
std::vector<Real> ROL::MeanDeviationFromTarget< Real >::coeff_
private

◆ NumMoments_

◆ pval_

template<class Real>
std::vector<Real> ROL::MeanDeviationFromTarget< Real >::pval_
private

◆ pgv_

template<class Real>
std::vector<Real> ROL::MeanDeviationFromTarget< Real >::pgv_
private

◆ pg0_

template<class Real>
std::vector<Ptr<Vector<Real> > > ROL::MeanDeviationFromTarget< Real >::pg0_
private

◆ pg_

template<class Real>
std::vector<Ptr<Vector<Real> > > ROL::MeanDeviationFromTarget< Real >::pg_
private

◆ phv_

template<class Real>
std::vector<Ptr<Vector<Real> > > ROL::MeanDeviationFromTarget< Real >::phv_
private

◆ firstResetMDT_

template<class Real>
bool ROL::MeanDeviationFromTarget< Real >::firstResetMDT_
private

The documentation for this class was generated from the following file: