ROL
Toggle main menu visibility
Loading...
Searching...
No Matches
src
function
objective
ROL_ScaledObjective.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_SCALED_OBJECTIVE_HPP
11
#define ROL_SCALED_OBJECTIVE_HPP
12
13
#include "
ROL_Objective.hpp
"
14
15
namespace
ROL
{
16
17
template
<
typename
Real>
18
class
ScaledObjective
:
public
Objective
<Real> {
19
private
:
20
const
Ptr<Objective<Real>>
obj_
;
21
const
Real
scale_
;
22
23
public
:
24
ScaledObjective
(
const
Ptr<
Objective<Real>
> &obj, Real scale)
25
:
obj_
(obj),
scale_
(scale) {}
26
27
void
update
(
const
Vector<Real>
&x,
UpdateType
type,
int
iter = -1)
override
;
28
void
setParameter
(
const
std::vector<Real> ¶m)
override
;
29
Real
value
(
const
Vector<Real>
&x, Real &tol )
override
;
30
void
gradient
(
Vector<Real>
&g,
const
Vector<Real>
&x, Real &tol )
override
;
31
void
hessVec
(
Vector<Real>
&hv,
const
Vector<Real>
&v,
const
Vector<Real>
&x, Real &tol )
override
;
32
void
invHessVec
(
Vector<Real>
&hv,
const
Vector<Real>
&v,
const
Vector<Real>
&x, Real &tol )
override
;
33
void
precond
(
Vector<Real>
&Pv,
const
Vector<Real>
&v,
const
Vector<Real>
&x, Real &tol )
override
;
34
35
};
// class ScaledObjective
36
37
}
// End ROL Namespace
38
39
#include "
ROL_ScaledObjective_Def.hpp
"
40
41
#endif
ROL_Objective.hpp
ROL_ScaledObjective_Def.hpp
ROL::ROL::Objective::Objective
Objective()
Definition
ROL_Constraint_SerialSimOpt.hpp:53
ROL::ScaledObjective::value
Real value(const Vector< Real > &x, Real &tol) override
Definition
ROL_ScaledObjective_Def.hpp:27
ROL::ScaledObjective::invHessVec
void invHessVec(Vector< Real > &hv, const Vector< Real > &v, const Vector< Real > &x, Real &tol) override
Definition
ROL_ScaledObjective_Def.hpp:44
ROL::ScaledObjective::update
void update(const Vector< Real > &x, UpdateType type, int iter=-1) override
Definition
ROL_ScaledObjective_Def.hpp:16
ROL::ScaledObjective::setParameter
void setParameter(const std::vector< Real > ¶m) override
Definition
ROL_ScaledObjective_Def.hpp:21
ROL::ScaledObjective::hessVec
void hessVec(Vector< Real > &hv, const Vector< Real > &v, const Vector< Real > &x, Real &tol) override
Definition
ROL_ScaledObjective_Def.hpp:38
ROL::ScaledObjective::gradient
void gradient(Vector< Real > &g, const Vector< Real > &x, Real &tol) override
Definition
ROL_ScaledObjective_Def.hpp:32
ROL::ScaledObjective::ScaledObjective
ScaledObjective(const Ptr< Objective< Real > > &obj, Real scale)
Definition
ROL_ScaledObjective.hpp:24
ROL::ScaledObjective::scale_
const Real scale_
Definition
ROL_ScaledObjective.hpp:21
ROL::ScaledObjective::obj_
const Ptr< Objective< Real > > obj_
Definition
ROL_ScaledObjective.hpp:20
ROL::ScaledObjective::precond
void precond(Vector< Real > &Pv, const Vector< Real > &v, const Vector< Real > &x, Real &tol) override
Definition
ROL_ScaledObjective_Def.hpp:50
ROL::Vector
Defines the linear algebra or vector space interface.
Definition
ROL_Vector.hpp:51
ROL
Definition
ROL_ElementwiseVector.hpp:27
ROL::UpdateType
UpdateType
Definition
ROL_UpdateType.hpp:18
Generated by
1.17.0