ROL
ROL_TypeB_SpectralGradientAlgorithm.hpp
Go to the documentation of this file.
1 // @HEADER
2 // *****************************************************************************
3 // Rapid Optimization Library (ROL) Package
4 //
5 // Copyright 2014 NTESS and the ROL contributors.
6 // SPDX-License-Identifier: BSD-3-Clause
7 // *****************************************************************************
8 // @HEADER
9 
10 #ifndef ROL_TYPEB_SPECTRALGRADIENTALGORITHM_HPP
11 #define ROL_TYPEB_SPECTRALGRADIENTALGORITHM_HPP
12 
13 #include "ROL_TypeB_Algorithm.hpp"
14 
19 namespace ROL {
20 namespace TypeB {
21 
22 template<typename Real>
24 private:
29 
33 
34  void initialize(Vector<Real> &x,
35  const Vector<Real> &g,
36  Objective<Real> &obj,
38  std::ostream &outStream = std::cout);
39 
40 public:
41 
42  SpectralGradientAlgorithm(ParameterList &list);
43 
45  void run( Vector<Real> &x,
46  const Vector<Real> &g,
47  Objective<Real> &obj,
49  std::ostream &outStream = std::cout) override;
50 
51  void writeHeader( std::ostream& os ) const override;
52 
53  void writeName( std::ostream &os ) const override;
54 
55  void writeOutput( std::ostream &os, const bool write_header = false ) const override;
56 
57 }; // class ROL::TypeB::SpectralGradientAlgorithm
58 
59 } // namespace TypeB
60 } // namespace ROL
61 
63 
64 #endif
Provides the interface to evaluate objective functions.
Defines the linear algebra or vector space interface.
Definition: ROL_Vector.hpp:46
void writeOutput(std::ostream &os, const bool write_header=false) const override
Print iterate status.
void writeName(std::ostream &os) const override
Print step name.
Provides an interface to run bound constrained optimization algorithms.
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...
Provides an interface to run the spectral projected gradient algorithm.
void initialize(Vector< Real > &x, const Vector< Real > &g, Objective< Real > &obj, BoundConstraint< Real > &bnd, std::ostream &outStream=std::cout)
void writeHeader(std::ostream &os) const override
Print iterate header.
Provides the interface to apply upper and lower bound constraints.