ROL
Public Member Functions | Private Member Functions | Private Attributes | List of all members
ROL::MoreauYosidaPenalty< Real > Class Template Reference

Provides the interface to evaluate the Moreau-Yosida penalty function. More...

#include <ROL_MoreauYosidaPenalty.hpp>

+ Inheritance diagram for ROL::MoreauYosidaPenalty< Real >:

Public Member Functions

 ~MoreauYosidaPenalty ()
 
 MoreauYosidaPenalty (Objective< Real > &obj, BoundConstraint< Real > &con, const ROL::Vector< Real > &x, const Real mu=1.0)
 
void updateMultipliers (Real mu, const ROL::Vector< Real > &x)
 
Real getObjectiveValue (void) const
 
Teuchos::RCP< Vector< Real > > getGradient (void) const
 
int getNumberFunctionEvaluations (void)
 
int getNumberGradientEvaluations (void)
 
void update (const Vector< Real > &x, bool flag=true, int iter=-1)
 Update Moreau-Yosida penalty function. More...
 
Real value (const Vector< Real > &x, Real &tol)
 Compute value. More...
 
void gradient (Vector< Real > &g, const Vector< Real > &x, Real &tol)
 Compute gradient. More...
 
void hessVec (Vector< Real > &hv, const Vector< Real > &v, const Vector< Real > &x, Real &tol)
 Apply Hessian approximation to vector. More...
 
- Public Member Functions inherited from ROL::Objective< Real >
virtual ~Objective ()
 
virtual Real dirDeriv (const Vector< Real > &x, const Vector< Real > &d, Real &tol)
 Compute directional derivative. More...
 
virtual void invHessVec (Vector< Real > &hv, const Vector< Real > &v, const Vector< Real > &x, Real &tol)
 Apply inverse Hessian approximation to vector. More...
 
virtual void precond (Vector< Real > &Pv, const Vector< Real > &v, const Vector< Real > &x, Real &tol)
 Apply preconditioner to vector. More...
 
virtual std::vector< std::vector< Real > > checkGradient (const Vector< Real > &x, const Vector< Real > &d, const bool printToStream=true, std::ostream &outStream=std::cout, const int numSteps=ROL_NUM_CHECKDERIV_STEPS, const int order=1)
 Finite-difference gradient check. More...
 
virtual std::vector< std::vector< Real > > checkGradient (const Vector< Real > &x, const Vector< Real > &g, const Vector< Real > &d, const bool printToStream=true, std::ostream &outStream=std::cout, const int numSteps=ROL_NUM_CHECKDERIV_STEPS, const int order=1)
 Finite-difference gradient check. More...
 
virtual std::vector< std::vector< Real > > checkGradient (const Vector< Real > &x, const Vector< Real > &d, const std::vector< Real > &steps, const bool printToStream=true, std::ostream &outStream=std::cout, const int order=1)
 Finite-difference gradient check with specified step sizes. More...
 
virtual std::vector< std::vector< Real > > checkGradient (const Vector< Real > &x, const Vector< Real > &g, const Vector< Real > &d, const std::vector< Real > &steps, const bool printToStream=true, std::ostream &outStream=std::cout, const int order=1)
 Finite-difference gradient check with specified step sizes. More...
 
virtual std::vector< std::vector< Real > > checkHessVec (const Vector< Real > &x, const Vector< Real > &v, const bool printToStream=true, std::ostream &outStream=std::cout, const int numSteps=ROL_NUM_CHECKDERIV_STEPS, const int order=1)
 Finite-difference Hessian-applied-to-vector check. More...
 
virtual std::vector< std::vector< Real > > checkHessVec (const Vector< Real > &x, const Vector< Real > &hv, const Vector< Real > &v, const bool printToStream=true, std::ostream &outStream=std::cout, const int numSteps=ROL_NUM_CHECKDERIV_STEPS, const int order=1)
 Finite-difference Hessian-applied-to-vector check. More...
 
virtual std::vector< std::vector< Real > > checkHessVec (const Vector< Real > &x, const Vector< Real > &v, const std::vector< Real > &steps, const bool printToStream=true, std::ostream &outStream=std::cout, const int order=1)
 Finite-difference Hessian-applied-to-vector check with specified step sizes. More...
 
virtual std::vector< std::vector< Real > > checkHessVec (const Vector< Real > &x, const Vector< Real > &hv, const Vector< Real > &v, const std::vector< Real > &steps, const bool printToStream=true, std::ostream &outStream=std::cout, const int order=1)
 Finite-difference Hessian-applied-to-vector check with specified step sizes. More...
 
virtual std::vector< Real > checkHessSym (const Vector< Real > &x, const Vector< Real > &v, const Vector< Real > &w, const bool printToStream=true, std::ostream &outStream=std::cout)
 Hessian symmetry check. More...
 
virtual std::vector< Real > checkHessSym (const Vector< Real > &x, const Vector< Real > &hv, const Vector< Real > &v, const Vector< Real > &w, const bool printToStream=true, std::ostream &outStream=std::cout)
 Hessian symmetry check. More...
 

Private Member Functions

void computePenalty (const Vector< Real > &x)
 

Private Attributes

Teuchos::RCP< Objective< Real > > obj_
 
Teuchos::RCP< BoundConstraint< Real > > con_
 
Teuchos::RCP< Vector< Real > > g_
 
Teuchos::RCP< Vector< Real > > l_
 
Teuchos::RCP< Vector< Real > > u_
 
Teuchos::RCP< Vector< Real > > l1_
 
Teuchos::RCP< Vector< Real > > u1_
 
Teuchos::RCP< Vector< Real > > dl1_
 
Teuchos::RCP< Vector< Real > > du1_
 
Teuchos::RCP< Vector< Real > > xlam_
 
Teuchos::RCP< Vector< Real > > v_
 
Teuchos::RCP< Vector< Real > > dv_
 
Teuchos::RCP< Vector< Real > > dv2_
 
Teuchos::RCP< Vector< Real > > lam_
 
Teuchos::RCP< Vector< Real > > tmp_
 
Real mu_
 
Real fval_
 
bool isConEvaluated_
 
int nfval_
 
int ngval_
 

Detailed Description

template<class Real>
class ROL::MoreauYosidaPenalty< Real >

Provides the interface to evaluate the Moreau-Yosida penalty function.


Definition at line 65 of file ROL_MoreauYosidaPenalty.hpp.

Constructor & Destructor Documentation

template<class Real>
ROL::MoreauYosidaPenalty< Real >::~MoreauYosidaPenalty ( )
inline

Definition at line 130 of file ROL_MoreauYosidaPenalty.hpp.

template<class Real>
ROL::MoreauYosidaPenalty< Real >::MoreauYosidaPenalty ( Objective< Real > &  obj,
BoundConstraint< Real > &  con,
const ROL::Vector< Real > &  x,
const Real  mu = 1.0 
)
inline

Member Function Documentation

template<class Real>
void ROL::MoreauYosidaPenalty< Real >::computePenalty ( const Vector< Real > &  x)
inlineprivate
template<class Real>
void ROL::MoreauYosidaPenalty< Real >::updateMultipliers ( Real  mu,
const ROL::Vector< Real > &  x 
)
inline
template<class Real>
Real ROL::MoreauYosidaPenalty< Real >::getObjectiveValue ( void  ) const
inline
template<class Real>
Teuchos::RCP<Vector<Real> > ROL::MoreauYosidaPenalty< Real >::getGradient ( void  ) const
inline

Definition at line 182 of file ROL_MoreauYosidaPenalty.hpp.

References ROL::MoreauYosidaPenalty< Real >::g_.

template<class Real>
int ROL::MoreauYosidaPenalty< Real >::getNumberFunctionEvaluations ( void  )
inline
template<class Real>
int ROL::MoreauYosidaPenalty< Real >::getNumberGradientEvaluations ( void  )
inline
template<class Real>
void ROL::MoreauYosidaPenalty< Real >::update ( const Vector< Real > &  x,
bool  flag = true,
int  iter = -1 
)
inlinevirtual

Update Moreau-Yosida penalty function.

This function updates the Moreau-Yosida penalty function at new iterations.

Parameters
[in]xis the new iterate.
[in]flagis true if the iterate has changed.
[in]iteris the outer algorithm iterations count.

Reimplemented from ROL::Objective< Real >.

Definition at line 201 of file ROL_MoreauYosidaPenalty.hpp.

template<class Real>
Real ROL::MoreauYosidaPenalty< Real >::value ( const Vector< Real > &  x,
Real &  tol 
)
inlinevirtual

Compute value.

This function returns the Moreau-Yosida penalty value.

Parameters
[in]xis the current iterate.
[in]tolis a tolerance for inexact Moreau-Yosida penalty computation.

Implements ROL::Objective< Real >.

Definition at line 213 of file ROL_MoreauYosidaPenalty.hpp.

References ROL::MoreauYosidaPenalty< Real >::computePenalty(), and ROL::MoreauYosidaPenalty< Real >::fval_.

template<class Real>
void ROL::MoreauYosidaPenalty< Real >::gradient ( Vector< Real > &  g,
const Vector< Real > &  x,
Real &  tol 
)
inlinevirtual

Compute gradient.

This function returns the Moreau-Yosida penalty gradient.

Parameters
[out]gis the gradient.
[in]xis the current iterate.
[in]tolis a tolerance for inexact Moreau-Yosida penalty computation.

Reimplemented from ROL::Objective< Real >.

Definition at line 233 of file ROL_MoreauYosidaPenalty.hpp.

References ROL::Vector< Real >::axpy(), ROL::MoreauYosidaPenalty< Real >::computePenalty(), and ROL::Vector< Real >::set().

template<class Real>
void ROL::MoreauYosidaPenalty< Real >::hessVec ( Vector< Real > &  hv,
const Vector< Real > &  v,
const Vector< Real > &  x,
Real &  tol 
)
inlinevirtual

Apply Hessian approximation to vector.

This function applies the Hessian of the Moreau-Yosida penalty to the vector \(v\).

Parameters
[out]hvis the the action of the Hessian on \(v\).
[in]vis the direction vector.
[in]xis the current iterate.
[in]tolis a tolerance for inexact Moreau-Yosida penalty computation.

Reimplemented from ROL::Objective< Real >.

Definition at line 254 of file ROL_MoreauYosidaPenalty.hpp.

References ROL::Vector< Real >::axpy(), and ROL::MoreauYosidaPenalty< Real >::computePenalty().

Member Data Documentation

template<class Real>
Teuchos::RCP<Objective<Real> > ROL::MoreauYosidaPenalty< Real >::obj_
private

Definition at line 67 of file ROL_MoreauYosidaPenalty.hpp.

template<class Real>
Teuchos::RCP<BoundConstraint<Real> > ROL::MoreauYosidaPenalty< Real >::con_
private

Definition at line 68 of file ROL_MoreauYosidaPenalty.hpp.

template<class Real>
Teuchos::RCP<Vector<Real> > ROL::MoreauYosidaPenalty< Real >::g_
private
template<class Real>
Teuchos::RCP<Vector<Real> > ROL::MoreauYosidaPenalty< Real >::l_
private

Definition at line 71 of file ROL_MoreauYosidaPenalty.hpp.

template<class Real>
Teuchos::RCP<Vector<Real> > ROL::MoreauYosidaPenalty< Real >::u_
private

Definition at line 72 of file ROL_MoreauYosidaPenalty.hpp.

template<class Real>
Teuchos::RCP<Vector<Real> > ROL::MoreauYosidaPenalty< Real >::l1_
private

Definition at line 73 of file ROL_MoreauYosidaPenalty.hpp.

template<class Real>
Teuchos::RCP<Vector<Real> > ROL::MoreauYosidaPenalty< Real >::u1_
private

Definition at line 74 of file ROL_MoreauYosidaPenalty.hpp.

template<class Real>
Teuchos::RCP<Vector<Real> > ROL::MoreauYosidaPenalty< Real >::dl1_
private

Definition at line 75 of file ROL_MoreauYosidaPenalty.hpp.

template<class Real>
Teuchos::RCP<Vector<Real> > ROL::MoreauYosidaPenalty< Real >::du1_
private

Definition at line 76 of file ROL_MoreauYosidaPenalty.hpp.

template<class Real>
Teuchos::RCP<Vector<Real> > ROL::MoreauYosidaPenalty< Real >::xlam_
private

Definition at line 77 of file ROL_MoreauYosidaPenalty.hpp.

template<class Real>
Teuchos::RCP<Vector<Real> > ROL::MoreauYosidaPenalty< Real >::v_
private

Definition at line 78 of file ROL_MoreauYosidaPenalty.hpp.

template<class Real>
Teuchos::RCP<Vector<Real> > ROL::MoreauYosidaPenalty< Real >::dv_
private

Definition at line 79 of file ROL_MoreauYosidaPenalty.hpp.

template<class Real>
Teuchos::RCP<Vector<Real> > ROL::MoreauYosidaPenalty< Real >::dv2_
private

Definition at line 80 of file ROL_MoreauYosidaPenalty.hpp.

template<class Real>
Teuchos::RCP<Vector<Real> > ROL::MoreauYosidaPenalty< Real >::lam_
private

Definition at line 81 of file ROL_MoreauYosidaPenalty.hpp.

template<class Real>
Teuchos::RCP<Vector<Real> > ROL::MoreauYosidaPenalty< Real >::tmp_
private

Definition at line 82 of file ROL_MoreauYosidaPenalty.hpp.

template<class Real>
Real ROL::MoreauYosidaPenalty< Real >::mu_
private

Definition at line 84 of file ROL_MoreauYosidaPenalty.hpp.

template<class Real>
Real ROL::MoreauYosidaPenalty< Real >::fval_
private
template<class Real>
bool ROL::MoreauYosidaPenalty< Real >::isConEvaluated_
private

Definition at line 86 of file ROL_MoreauYosidaPenalty.hpp.

template<class Real>
int ROL::MoreauYosidaPenalty< Real >::nfval_
private
template<class Real>
int ROL::MoreauYosidaPenalty< Real >::ngval_
private

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