ROL
Toggle main menu visibility
Loading...
Searching...
No Matches
src
function
polyproj
ROL_DykstraProjection.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_DYKSTRAPROJECTION_H
11
#define ROL_DYKSTRAPROJECTION_H
12
13
#include "
ROL_PolyhedralProjection.hpp
"
14
#include "ROL_ParameterList.hpp"
15
16
namespace
ROL
{
17
18
template
<
typename
Real>
19
class
DykstraProjection
:
public
PolyhedralProjection
<Real> {
20
private
:
21
int
dim_
;
22
Ptr<Vector<Real>>
tmp_
,
p_
,
q_
,
y_
,
z_
;
23
Real
b_
,
cdot_
;
24
25
Real
DEFAULT_atol_
,
DEFAULT_rtol_
;
26
int
DEFAULT_maxit_
,
DEFAULT_verbosity_
;
27
28
Real
atol_
,
rtol_
;
29
int
maxit_
,
verbosity_
;
30
31
using
PolyhedralProjection
<Real>
::bnd_
;
32
using
PolyhedralProjection
<Real>
::con_
;
33
using
PolyhedralProjection
<Real>
::xprim_
;
34
using
PolyhedralProjection
<Real>
::xdual_
;
35
using
PolyhedralProjection
<Real>
::mul_
;
36
using
PolyhedralProjection
<Real>
::res_
;
37
38
public
:
39
40
DykstraProjection
(
const
Vector<Real>
&xprim,
41
const
Vector<Real>
&xdual,
42
const
Ptr<
BoundConstraint<Real>
> &bnd,
43
const
Ptr<
Constraint<Real>
> &con,
44
const
Vector<Real>
&mul,
45
const
Vector<Real>
&res);
46
47
DykstraProjection
(
const
Vector<Real>
&xprim,
48
const
Vector<Real>
&xdual,
49
const
Ptr<
BoundConstraint<Real>
> &bnd,
50
const
Ptr<
Constraint<Real>
> &con,
51
const
Vector<Real>
&mul,
52
const
Vector<Real>
&res,
53
ParameterList &list);
54
55
void
project
(
Vector<Real>
&x, std::ostream &stream = std::cout)
override
;
56
57
private
:
58
59
Real
residual_1d
(
const
Vector<Real>
&x)
const
;
60
61
void
residual_nd
(
Vector<Real>
&r,
const
Vector<Real>
&y)
const
;
62
63
void
project_bnd
(
Vector<Real>
&x,
const
Vector<Real>
&y)
const
;
64
65
void
project_con
(
Vector<Real>
&x,
const
Vector<Real>
&y)
const
;
66
67
void
project_Dykstra
(
Vector<Real>
&x, std::ostream &stream = std::cout)
const
;
68
69
};
// class DykstraProjection
70
71
}
// namespace ROL
72
73
#include "
ROL_DykstraProjection_Def.hpp
"
74
75
#endif
ROL_DykstraProjection_Def.hpp
ROL_PolyhedralProjection.hpp
ROL::BoundConstraint
Provides the interface to apply upper and lower bound constraints.
Definition
ROL_BoundConstraint.hpp:39
ROL::Constraint
Defines the general constraint operator interface.
Definition
ROL_Constraint.hpp:52
ROL::DykstraProjection::y_
Ptr< Vector< Real > > y_
Definition
ROL_DykstraProjection.hpp:22
ROL::DykstraProjection::DEFAULT_rtol_
Real DEFAULT_rtol_
Definition
ROL_DykstraProjection.hpp:25
ROL::DykstraProjection::maxit_
int maxit_
Definition
ROL_DykstraProjection.hpp:29
ROL::DykstraProjection::z_
Ptr< Vector< Real > > z_
Definition
ROL_DykstraProjection.hpp:22
ROL::DykstraProjection::residual_1d
Real residual_1d(const Vector< Real > &x) const
Definition
ROL_DykstraProjection_Def.hpp:77
ROL::DykstraProjection::residual_nd
void residual_nd(Vector< Real > &r, const Vector< Real > &y) const
Definition
ROL_DykstraProjection_Def.hpp:82
ROL::DykstraProjection::cdot_
Real cdot_
Definition
ROL_DykstraProjection.hpp:23
ROL::DykstraProjection::rtol_
Real rtol_
Definition
ROL_DykstraProjection.hpp:28
ROL::DykstraProjection::b_
Real b_
Definition
ROL_DykstraProjection.hpp:23
ROL::DykstraProjection::dim_
int dim_
Definition
ROL_DykstraProjection.hpp:21
ROL::DykstraProjection::p_
Ptr< Vector< Real > > p_
Definition
ROL_DykstraProjection.hpp:22
ROL::DykstraProjection::DEFAULT_maxit_
int DEFAULT_maxit_
Definition
ROL_DykstraProjection.hpp:26
ROL::DykstraProjection::project
void project(Vector< Real > &x, std::ostream &stream=std::cout) override
Definition
ROL_DykstraProjection_Def.hpp:67
ROL::DykstraProjection::atol_
Real atol_
Definition
ROL_DykstraProjection.hpp:28
ROL::DykstraProjection::verbosity_
int verbosity_
Definition
ROL_DykstraProjection.hpp:29
ROL::DykstraProjection::project_Dykstra
void project_Dykstra(Vector< Real > &x, std::ostream &stream=std::cout) const
Definition
ROL_DykstraProjection_Def.hpp:112
ROL::DykstraProjection::tmp_
Ptr< Vector< Real > > tmp_
Definition
ROL_DykstraProjection.hpp:22
ROL::DykstraProjection::project_con
void project_con(Vector< Real > &x, const Vector< Real > &y) const
Definition
ROL_DykstraProjection_Def.hpp:95
ROL::DykstraProjection::DykstraProjection
DykstraProjection(const Vector< Real > &xprim, const Vector< Real > &xdual, const Ptr< BoundConstraint< Real > > &bnd, const Ptr< Constraint< Real > > &con, const Vector< Real > &mul, const Vector< Real > &res)
Definition
ROL_DykstraProjection_Def.hpp:16
ROL::DykstraProjection::DEFAULT_atol_
Real DEFAULT_atol_
Definition
ROL_DykstraProjection.hpp:25
ROL::DykstraProjection::project_bnd
void project_bnd(Vector< Real > &x, const Vector< Real > &y) const
Definition
ROL_DykstraProjection_Def.hpp:89
ROL::DykstraProjection::DEFAULT_verbosity_
int DEFAULT_verbosity_
Definition
ROL_DykstraProjection.hpp:26
ROL::DykstraProjection::q_
Ptr< Vector< Real > > q_
Definition
ROL_DykstraProjection.hpp:22
ROL::PolyhedralProjection::con_
const Ptr< Constraint< Real > > con_
Definition
ROL_PolyhedralProjection.hpp:23
ROL::PolyhedralProjection::xprim_
Ptr< Vector< Real > > xprim_
Definition
ROL_PolyhedralProjection.hpp:24
ROL::PolyhedralProjection::bnd_
const Ptr< BoundConstraint< Real > > bnd_
Definition
ROL_PolyhedralProjection.hpp:22
ROL::PolyhedralProjection::mul_
Ptr< Vector< Real > > mul_
Definition
ROL_PolyhedralProjection.hpp:24
ROL::PolyhedralProjection::xdual_
Ptr< Vector< Real > > xdual_
Definition
ROL_PolyhedralProjection.hpp:24
ROL::PolyhedralProjection::res_
Ptr< Vector< Real > > res_
Definition
ROL_PolyhedralProjection.hpp:24
ROL::PolyhedralProjection::PolyhedralProjection
PolyhedralProjection(const Ptr< BoundConstraint< Real > > &bnd)
Definition
ROL_PolyhedralProjection_Def.hpp:16
ROL::Vector
Defines the linear algebra or vector space interface.
Definition
ROL_Vector.hpp:51
ROL
Definition
ROL_ElementwiseVector.hpp:27
Generated by
1.17.0