ROL
ROL_PQNObjective.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_PQNOBJECTIVE_H
11#define ROL_PQNOBJECTIVE_H
12
13#include "ROL_Objective.hpp"
14#include "ROL_Secant.hpp"
15
33namespace ROL {
34
35template<typename Real>
36class PQNObjective : public Objective<Real> {
37private:
38 const Ptr<Secant<Real>> secant_;
39 const Ptr<Vector<Real>> x_, g_, pwa_, dwa_;
40
41public:
42 PQNObjective(const Ptr<Secant<Real>> &secant,
43 const Vector<Real> &x,
44 const Vector<Real> &g);
45
46 Real value( const Vector<Real> &x, Real &tol ) override;
47 void gradient( Vector<Real> &g, const Vector<Real> &x, Real &tol ) override;
48 void hessVec( Vector<Real> &hv, const Vector<Real> &v, const Vector<Real> &x, Real &tol ) override;
49
50 void setAnchor(const Vector<Real> &x, const Vector<Real> &g);
51}; // class PQNObjective
52
53} // namespace ROL
54
56
57#endif
Provides the interface to evaluate objective functions.
Provides the interface to evaluate the quadratic quasi-Newton objective.
void setAnchor(const Vector< Real > &x, const Vector< Real > &g)
const Ptr< Vector< Real > > dwa_
const Ptr< Secant< Real > > secant_
void gradient(Vector< Real > &g, const Vector< Real > &x, Real &tol) override
Compute gradient.
const Ptr< Vector< Real > > x_
const Ptr< Vector< Real > > pwa_
void hessVec(Vector< Real > &hv, const Vector< Real > &v, const Vector< Real > &x, Real &tol) override
Apply Hessian approximation to vector.
Real value(const Vector< Real > &x, Real &tol) override
Compute value.
const Ptr< Vector< Real > > g_
Provides interface for and implements limited-memory secant operators.
Defines the linear algebra or vector space interface.