ROL
ROL::TypeB::ColemanLiAlgorithm< Real > Class Template Reference

Provides an interface to run the affine-scaling trust-region algorithm of Coleman and Li. More...

#include <ROL_TypeB_ColemanLiAlgorithm.hpp>

Inheritance diagram for ROL::TypeB::ColemanLiAlgorithm< Real >:

Public Member Functions

 ColemanLiAlgorithm (ParameterList &list, const Ptr< Secant< Real > > &secant=nullPtr)
void run (Vector< Real > &x, const Vector< Real > &g, Objective< Real > &obj, BoundConstraint< Real > &bnd, std::ostream &outStream=std::cout) override
 Run algorithm on bound constrained problems (Type-B). This general interface supports the use of dual optimization vector spaces, where the user does not define the dual() method.
void writeHeader (std::ostream &os) const override
 Print iterate header.
void writeName (std::ostream &os) const override
 Print step name.
void writeOutput (std::ostream &os, const bool write_header=false) const override
 Print iterate status.
Public Member Functions inherited from ROL::TypeB::Algorithm< Real >
virtual ~Algorithm ()
 Algorithm ()
 Constructor, given a step and a status test.
void setStatusTest (const Ptr< StatusTest< Real > > &status, const bool combineStatus=false)
virtual void run (Problem< Real > &problem, std::ostream &outStream=std::cout)
 Run algorithm on bound constrained problems (Type-B). This is the primary Type-B interface.
virtual void run (Vector< Real > &x, Objective< Real > &obj, BoundConstraint< Real > &bnd, std::ostream &outStream=std::cout)
 Run algorithm on bound constrained problems (Type-B). This is the primary Type-B interface.
virtual void run (Vector< Real > &x, Objective< Real > &obj, BoundConstraint< Real > &bnd, Constraint< Real > &linear_econ, Vector< Real > &linear_emul, std::ostream &outStream=std::cout)
 Run algorithm on bound constrained problems with explicit linear constraints (Type-B). This is the primary Type-B with explicit linear constraints interface.
virtual void run (Vector< Real > &x, const Vector< Real > &g, Objective< Real > &obj, BoundConstraint< Real > &bnd, Constraint< Real > &linear_econ, Vector< Real > &linear_emul, const Vector< Real > &linear_eres, std::ostream &outStream=std::cout)
 Run algorithm on bound constrained problems with explicit linear constraints (Type-B). This general interface supports the use of dual optimization vector spaces, where the user does not define the dual() method.
virtual void run (Vector< Real > &x, Objective< Real > &obj, BoundConstraint< Real > &bnd, Constraint< Real > &linear_icon, Vector< Real > &linear_imul, BoundConstraint< Real > &linear_ibnd, std::ostream &outStream=std::cout)
 Run algorithm on bound constrained problems with explicit linear constraints (Type-B). This is the primary Type-B with explicit linear constraints interface.
virtual void run (Vector< Real > &x, const Vector< Real > &g, Objective< Real > &obj, BoundConstraint< Real > &bnd, Constraint< Real > &linear_icon, Vector< Real > &linear_imul, BoundConstraint< Real > &linear_ibnd, const Vector< Real > &linear_ires, std::ostream &outStream=std::cout)
 Run algorithm on bound constrained problems with explicit linear constraints (Type-B). This general interface supports the use of dual optimization vector spaces, where the user does not define the dual() method.
virtual void run (Vector< Real > &x, Objective< Real > &obj, BoundConstraint< Real > &bnd, Constraint< Real > &linear_econ, Vector< Real > &linear_emul, Constraint< Real > &linear_icon, Vector< Real > &linear_imul, BoundConstraint< Real > &linear_ibnd, std::ostream &outStream=std::cout)
 Run algorithm on bound constrained problems with explicit linear constraints (Type-B). This is the primary Type-B with explicit linear constraints interface.
virtual void run (Vector< Real > &x, const Vector< Real > &g, Objective< Real > &obj, BoundConstraint< Real > &bnd, Constraint< Real > &linear_econ, Vector< Real > &linear_emul, const Vector< Real > &linear_eres, Constraint< Real > &linear_icon, Vector< Real > &linear_imul, BoundConstraint< Real > &linear_ibnd, const Vector< Real > &linear_ires, std::ostream &outStream=std::cout)
 Run algorithm on bound constrained problems with explicit linear constraints (Type-B). This general interface supports the use of dual optimization vector spaces, where the user does not define the dual() method.
virtual void writeExitStatus (std::ostream &os) const
Ptr< const AlgorithmState< Real > > getState () const
void reset ()

Private Member Functions

void initialize (Vector< Real > &x, const Vector< Real > &g, Objective< Real > &obj, BoundConstraint< Real > &bnd, std::ostream &outStream=std::cout)
Real dgpstep (Vector< Real > &s, const Vector< Real > &w, const Vector< Real > &x, const Real alpha, std::ostream &outStream=std::cout) const
Real dtrqsol (const Real xtx, const Real ptp, const Real ptx, const Real del) const
Real dtrpcg (Vector< Real > &w, int &iflag, int &iter, const Vector< Real > &g, const Vector< Real > &x, const Vector< Real > &gdual, const Real del, TrustRegionModel_U< Real > &model, BoundConstraint< Real > &bnd, const Real tol, const Real stol, Vector< Real > &p, Vector< Real > &q, Vector< Real > &r, Vector< Real > &t, Vector< Real > &pwa1, Vector< Real > &pwa2, Vector< Real > &dwa, std::ostream &outStream=std::cout) const
void applyC (Vector< Real > &Cv, const Vector< Real > &v, const Vector< Real > &x, const Vector< Real > &g, BoundConstraint< Real > &bnd, Vector< Real > &pwa) const
void applyHessian (Vector< Real > &hv, const Vector< Real > &v, const Vector< Real > &x, const Vector< Real > &g, TrustRegionModel_U< Real > &model, BoundConstraint< Real > &bnd, Real &tol, Vector< Real > &pwa1, Vector< Real > &pwa2) const
void applyPrecond (Vector< Real > &hv, const Vector< Real > &v, const Vector< Real > &x, const Vector< Real > &g, TrustRegionModel_U< Real > &model, BoundConstraint< Real > &bnd, Real &tol, Vector< Real > &dwa, Vector< Real > &pwa) const

Private Attributes

Ptr< TrustRegionModel_U< Real > > model_
 Container for trust-region model.
Real delMax_
 Maximum trust-region radius (default: ROL_INF).
Real eta0_
 Step acceptance threshold (default: 0.05).
Real eta1_
 Radius decrease threshold (default: 0.05).
Real eta2_
 Radius increase threshold (default: 0.9).
Real gamma0_
 Radius decrease rate (negative rho) (default: 0.0625).
Real gamma1_
 Radius decrease rate (positive rho) (default: 0.25).
Real gamma2_
 Radius increase rate (default: 2.5).
Real TRsafe_
 Safeguard size for numerically evaluating ratio (default: 1e2).
Real eps_
 Safeguard for numerically evaluating ratio.
bool interpRad_
 Interpolate the trust-region radius if ratio is negative (default: false).
bool useNM_
int storageNM_
TRUtils::ETRFlag TRflag_
 Trust-region exit flag.
int SPflag_
 Subproblem solver termination flag.
int SPiter_
 Subproblem solver iteration count.
ESecant esec_
 Secant type (default: Limited-Memory BFGS).
bool useSecantPrecond_
 Flag to use secant as a preconditioner (default: false).
bool useSecantHessVec_
 Flag to use secant as Hessian (default: false).
Real tol1_
 Absolute tolerance for truncated CG (default: 1e-4).
Real tol2_
 Relative tolerance for truncated CG (default: 1e-2).
int maxit_
 Maximum number of CG iterations (default: 20).
Real mu0_
 Sufficient decrease parameter (default: 1e-2).
Real spexp_
 Relative tolerance exponent for subproblem solve (default: 1, range: [1,2]).
Real alphaMax_
 Maximum value of relaxation parameter (default: 0.999).
int nhess_
 Number of Hessian applications.
unsigned verbosity_
 Output level (default: 0).
bool writeHeader_
 Flag to write header at every iteration.
bool hasEcon_
 Flag signifies if equality constraints exist.
Ptr< ReducedLinearConstraint< Real > > rcon_
 Equality constraint restricted to current active variables.
Ptr< NullSpaceOperator< Real > > ns_
 Null space projection onto reduced equality constraint Jacobian.

Additional Inherited Members

Protected Member Functions inherited from ROL::TypeB::Algorithm< Real >
void initialize (const Vector< Real > &x, const Vector< Real > &g)
Real optimalityCriterion (const Vector< Real > &x, const Vector< Real > &g, Vector< Real > &primal, std::ostream &outStream=std::cout) const
Protected Attributes inherited from ROL::TypeB::Algorithm< Real >
const Ptr< CombinedStatusTest< Real > > status_
const Ptr< AlgorithmState< Real > > state_
Ptr< PolyhedralProjection< Real > > proj_

Detailed Description

template<typename Real>
class ROL::TypeB::ColemanLiAlgorithm< Real >

Provides an interface to run the affine-scaling trust-region algorithm of Coleman and Li.

Definition at line 27 of file ROL_TypeB_ColemanLiAlgorithm.hpp.

Constructor & Destructor Documentation

◆ ColemanLiAlgorithm()

Member Function Documentation

◆ run()

◆ writeHeader()

template<typename Real>
void ROL::TypeB::ColemanLiAlgorithm< Real >::writeHeader ( std::ostream & os) const
overridevirtual

◆ writeName()

template<typename Real>
void ROL::TypeB::ColemanLiAlgorithm< Real >::writeName ( std::ostream & os) const
overridevirtual

Print step name.

Reimplemented from ROL::TypeB::Algorithm< Real >.

Definition at line 435 of file ROL_TypeB_ColemanLiAlgorithm_Def.hpp.

Referenced by writeOutput().

◆ writeOutput()

template<typename Real>
void ROL::TypeB::ColemanLiAlgorithm< Real >::writeOutput ( std::ostream & os,
const bool write_header = false ) const
overridevirtual

Print iterate status.

Reimplemented from ROL::TypeB::Algorithm< Real >.

Definition at line 442 of file ROL_TypeB_ColemanLiAlgorithm_Def.hpp.

References nhess_, SPflag_, SPiter_, ROL::TypeB::Algorithm< Real >::state_, TRflag_, writeHeader(), and writeName().

Referenced by run().

◆ initialize()

◆ dgpstep()

template<typename Real>
Real ROL::TypeB::ColemanLiAlgorithm< Real >::dgpstep ( Vector< Real > & s,
const Vector< Real > & w,
const Vector< Real > & x,
const Real alpha,
std::ostream & outStream = std::cout ) const
private

◆ dtrqsol()

template<typename Real>
Real ROL::TypeB::ColemanLiAlgorithm< Real >::dtrqsol ( const Real xtx,
const Real ptp,
const Real ptx,
const Real del ) const
private

Definition at line 245 of file ROL_TypeB_ColemanLiAlgorithm_Def.hpp.

References zero.

Referenced by dtrpcg().

◆ dtrpcg()

template<typename Real>
Real ROL::TypeB::ColemanLiAlgorithm< Real >::dtrpcg ( Vector< Real > & w,
int & iflag,
int & iter,
const Vector< Real > & g,
const Vector< Real > & x,
const Vector< Real > & gdual,
const Real del,
TrustRegionModel_U< Real > & model,
BoundConstraint< Real > & bnd,
const Real tol,
const Real stol,
Vector< Real > & p,
Vector< Real > & q,
Vector< Real > & r,
Vector< Real > & t,
Vector< Real > & pwa1,
Vector< Real > & pwa2,
Vector< Real > & dwa,
std::ostream & outStream = std::cout ) const
private

◆ applyC()

template<typename Real>
void ROL::TypeB::ColemanLiAlgorithm< Real >::applyC ( Vector< Real > & Cv,
const Vector< Real > & v,
const Vector< Real > & x,
const Vector< Real > & g,
BoundConstraint< Real > & bnd,
Vector< Real > & pwa ) const
private

◆ applyHessian()

template<typename Real>
void ROL::TypeB::ColemanLiAlgorithm< Real >::applyHessian ( Vector< Real > & hv,
const Vector< Real > & v,
const Vector< Real > & x,
const Vector< Real > & g,
TrustRegionModel_U< Real > & model,
BoundConstraint< Real > & bnd,
Real & tol,
Vector< Real > & pwa1,
Vector< Real > & pwa2 ) const
private

◆ applyPrecond()

template<typename Real>
void ROL::TypeB::ColemanLiAlgorithm< Real >::applyPrecond ( Vector< Real > & hv,
const Vector< Real > & v,
const Vector< Real > & x,
const Vector< Real > & g,
TrustRegionModel_U< Real > & model,
BoundConstraint< Real > & bnd,
Real & tol,
Vector< Real > & dwa,
Vector< Real > & pwa ) const
private

Definition at line 375 of file ROL_TypeB_ColemanLiAlgorithm_Def.hpp.

References ROL::TrustRegionModel_U< Real >::precond().

Referenced by dtrpcg().

Member Data Documentation

◆ model_

template<typename Real>
Ptr<TrustRegionModel_U<Real> > ROL::TypeB::ColemanLiAlgorithm< Real >::model_
private

Container for trust-region model.

Definition at line 29 of file ROL_TypeB_ColemanLiAlgorithm.hpp.

Referenced by ColemanLiAlgorithm(), and run().

◆ delMax_

template<typename Real>
Real ROL::TypeB::ColemanLiAlgorithm< Real >::delMax_
private

Maximum trust-region radius (default: ROL_INF).

Definition at line 32 of file ROL_TypeB_ColemanLiAlgorithm.hpp.

Referenced by ColemanLiAlgorithm(), and run().

◆ eta0_

template<typename Real>
Real ROL::TypeB::ColemanLiAlgorithm< Real >::eta0_
private

Step acceptance threshold (default: 0.05).

Definition at line 33 of file ROL_TypeB_ColemanLiAlgorithm.hpp.

Referenced by ColemanLiAlgorithm(), and run().

◆ eta1_

template<typename Real>
Real ROL::TypeB::ColemanLiAlgorithm< Real >::eta1_
private

Radius decrease threshold (default: 0.05).

Definition at line 34 of file ROL_TypeB_ColemanLiAlgorithm.hpp.

Referenced by ColemanLiAlgorithm().

◆ eta2_

template<typename Real>
Real ROL::TypeB::ColemanLiAlgorithm< Real >::eta2_
private

Radius increase threshold (default: 0.9).

Definition at line 35 of file ROL_TypeB_ColemanLiAlgorithm.hpp.

Referenced by ColemanLiAlgorithm(), and run().

◆ gamma0_

template<typename Real>
Real ROL::TypeB::ColemanLiAlgorithm< Real >::gamma0_
private

Radius decrease rate (negative rho) (default: 0.0625).

Definition at line 36 of file ROL_TypeB_ColemanLiAlgorithm.hpp.

Referenced by ColemanLiAlgorithm(), and run().

◆ gamma1_

template<typename Real>
Real ROL::TypeB::ColemanLiAlgorithm< Real >::gamma1_
private

Radius decrease rate (positive rho) (default: 0.25).

Definition at line 37 of file ROL_TypeB_ColemanLiAlgorithm.hpp.

Referenced by ColemanLiAlgorithm(), and run().

◆ gamma2_

template<typename Real>
Real ROL::TypeB::ColemanLiAlgorithm< Real >::gamma2_
private

Radius increase rate (default: 2.5).

Definition at line 38 of file ROL_TypeB_ColemanLiAlgorithm.hpp.

Referenced by ColemanLiAlgorithm(), and run().

◆ TRsafe_

template<typename Real>
Real ROL::TypeB::ColemanLiAlgorithm< Real >::TRsafe_
private

Safeguard size for numerically evaluating ratio (default: 1e2).

Definition at line 39 of file ROL_TypeB_ColemanLiAlgorithm.hpp.

Referenced by ColemanLiAlgorithm().

◆ eps_

template<typename Real>
Real ROL::TypeB::ColemanLiAlgorithm< Real >::eps_
private

Safeguard for numerically evaluating ratio.

Definition at line 40 of file ROL_TypeB_ColemanLiAlgorithm.hpp.

Referenced by ColemanLiAlgorithm(), and run().

◆ interpRad_

template<typename Real>
bool ROL::TypeB::ColemanLiAlgorithm< Real >::interpRad_
private

Interpolate the trust-region radius if ratio is negative (default: false).

Definition at line 41 of file ROL_TypeB_ColemanLiAlgorithm.hpp.

Referenced by ColemanLiAlgorithm(), and run().

◆ useNM_

template<typename Real>
bool ROL::TypeB::ColemanLiAlgorithm< Real >::useNM_
private

Definition at line 44 of file ROL_TypeB_ColemanLiAlgorithm.hpp.

Referenced by ColemanLiAlgorithm(), and run().

◆ storageNM_

template<typename Real>
int ROL::TypeB::ColemanLiAlgorithm< Real >::storageNM_
private

Definition at line 45 of file ROL_TypeB_ColemanLiAlgorithm.hpp.

Referenced by ColemanLiAlgorithm(), and run().

◆ TRflag_

template<typename Real>
TRUtils::ETRFlag ROL::TypeB::ColemanLiAlgorithm< Real >::TRflag_
private

Trust-region exit flag.

Definition at line 48 of file ROL_TypeB_ColemanLiAlgorithm.hpp.

Referenced by run(), and writeOutput().

◆ SPflag_

template<typename Real>
int ROL::TypeB::ColemanLiAlgorithm< Real >::SPflag_
private

Subproblem solver termination flag.

Definition at line 49 of file ROL_TypeB_ColemanLiAlgorithm.hpp.

Referenced by run(), and writeOutput().

◆ SPiter_

template<typename Real>
int ROL::TypeB::ColemanLiAlgorithm< Real >::SPiter_
private

Subproblem solver iteration count.

Definition at line 50 of file ROL_TypeB_ColemanLiAlgorithm.hpp.

Referenced by run(), and writeOutput().

◆ esec_

template<typename Real>
ESecant ROL::TypeB::ColemanLiAlgorithm< Real >::esec_
private

Secant type (default: Limited-Memory BFGS).

Definition at line 53 of file ROL_TypeB_ColemanLiAlgorithm.hpp.

Referenced by ColemanLiAlgorithm().

◆ useSecantPrecond_

template<typename Real>
bool ROL::TypeB::ColemanLiAlgorithm< Real >::useSecantPrecond_
private

Flag to use secant as a preconditioner (default: false).

Definition at line 54 of file ROL_TypeB_ColemanLiAlgorithm.hpp.

Referenced by ColemanLiAlgorithm().

◆ useSecantHessVec_

template<typename Real>
bool ROL::TypeB::ColemanLiAlgorithm< Real >::useSecantHessVec_
private

Flag to use secant as Hessian (default: false).

Definition at line 55 of file ROL_TypeB_ColemanLiAlgorithm.hpp.

Referenced by ColemanLiAlgorithm().

◆ tol1_

template<typename Real>
Real ROL::TypeB::ColemanLiAlgorithm< Real >::tol1_
private

Absolute tolerance for truncated CG (default: 1e-4).

Definition at line 58 of file ROL_TypeB_ColemanLiAlgorithm.hpp.

Referenced by ColemanLiAlgorithm(), and run().

◆ tol2_

template<typename Real>
Real ROL::TypeB::ColemanLiAlgorithm< Real >::tol2_
private

Relative tolerance for truncated CG (default: 1e-2).

Definition at line 59 of file ROL_TypeB_ColemanLiAlgorithm.hpp.

Referenced by ColemanLiAlgorithm(), and run().

◆ maxit_

template<typename Real>
int ROL::TypeB::ColemanLiAlgorithm< Real >::maxit_
private

Maximum number of CG iterations (default: 20).

Definition at line 60 of file ROL_TypeB_ColemanLiAlgorithm.hpp.

Referenced by ColemanLiAlgorithm(), and dtrpcg().

◆ mu0_

template<typename Real>
Real ROL::TypeB::ColemanLiAlgorithm< Real >::mu0_
private

Sufficient decrease parameter (default: 1e-2).

Definition at line 63 of file ROL_TypeB_ColemanLiAlgorithm.hpp.

Referenced by ColemanLiAlgorithm().

◆ spexp_

template<typename Real>
Real ROL::TypeB::ColemanLiAlgorithm< Real >::spexp_
private

Relative tolerance exponent for subproblem solve (default: 1, range: [1,2]).

Definition at line 64 of file ROL_TypeB_ColemanLiAlgorithm.hpp.

Referenced by ColemanLiAlgorithm(), and run().

◆ alphaMax_

template<typename Real>
Real ROL::TypeB::ColemanLiAlgorithm< Real >::alphaMax_
private

Maximum value of relaxation parameter (default: 0.999).

Definition at line 65 of file ROL_TypeB_ColemanLiAlgorithm.hpp.

Referenced by ColemanLiAlgorithm(), and run().

◆ nhess_

template<typename Real>
int ROL::TypeB::ColemanLiAlgorithm< Real >::nhess_
mutableprivate

Number of Hessian applications.

Definition at line 67 of file ROL_TypeB_ColemanLiAlgorithm.hpp.

Referenced by applyHessian(), initialize(), run(), and writeOutput().

◆ verbosity_

template<typename Real>
unsigned ROL::TypeB::ColemanLiAlgorithm< Real >::verbosity_
private

Output level (default: 0).

Definition at line 68 of file ROL_TypeB_ColemanLiAlgorithm.hpp.

Referenced by ColemanLiAlgorithm(), run(), and writeHeader().

◆ writeHeader_

template<typename Real>
bool ROL::TypeB::ColemanLiAlgorithm< Real >::writeHeader_
private

Flag to write header at every iteration.

Definition at line 69 of file ROL_TypeB_ColemanLiAlgorithm.hpp.

Referenced by ColemanLiAlgorithm(), and run().

◆ hasEcon_

template<typename Real>
bool ROL::TypeB::ColemanLiAlgorithm< Real >::hasEcon_
private

Flag signifies if equality constraints exist.

Definition at line 71 of file ROL_TypeB_ColemanLiAlgorithm.hpp.

Referenced by dtrpcg(), and initialize().

◆ rcon_

template<typename Real>
Ptr<ReducedLinearConstraint<Real> > ROL::TypeB::ColemanLiAlgorithm< Real >::rcon_
private

Equality constraint restricted to current active variables.

Definition at line 72 of file ROL_TypeB_ColemanLiAlgorithm.hpp.

Referenced by initialize().

◆ ns_

template<typename Real>
Ptr<NullSpaceOperator<Real> > ROL::TypeB::ColemanLiAlgorithm< Real >::ns_
private

Null space projection onto reduced equality constraint Jacobian.

Definition at line 73 of file ROL_TypeB_ColemanLiAlgorithm.hpp.

Referenced by initialize().


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