ROL
Toggle main menu visibility
Loading...
Searching...
No Matches
src
step
ROL_StepFactory.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_STEPFACTORY_H
11
#define ROL_STEPFACTORY_H
12
13
#include "
ROL_Types.hpp
"
14
15
#include "ROL_ParameterList.hpp"
16
#include "ROL_Ptr.hpp"
17
18
#include "
ROL_Step.hpp
"
19
#include "
ROL_LineSearchStep.hpp
"
20
#include "
ROL_TrustRegionStep.hpp
"
21
#include "
ROL_PrimalDualActiveSetStep.hpp
"
22
#include "
ROL_CompositeStep.hpp
"
23
#include "
ROL_AugmentedLagrangianStep.hpp
"
24
#include "
ROL_MoreauYosidaPenaltyStep.hpp
"
25
#include "
ROL_BundleStep.hpp
"
26
#include "
ROL_InteriorPointStep.hpp
"
27
#include "
ROL_FletcherStep.hpp
"
28
29
namespace
ROL
{
30
31
template
<
class
Real>
32
class
StepFactory
{
33
public
:
34
~StepFactory
(
void
){}
35
36
ROL::Ptr<Step<Real>>
getStep
(
const
std::string &type,
37
ROL::ParameterList &parlist)
const
{
38
EStep
els =
StringToEStep
(type);
39
switch
(els) {
40
case
STEP_AUGMENTEDLAGRANGIAN
:
return
ROL::makePtr<AugmentedLagrangianStep<Real>>(parlist);
41
case
STEP_BUNDLE
:
return
ROL::makePtr<BundleStep<Real>>(parlist);
42
case
STEP_COMPOSITESTEP
:
return
ROL::makePtr<CompositeStep<Real>>(parlist);
43
case
STEP_LINESEARCH
:
return
ROL::makePtr<LineSearchStep<Real>>(parlist);
44
case
STEP_MOREAUYOSIDAPENALTY
:
return
ROL::makePtr<MoreauYosidaPenaltyStep<Real>>(parlist);
45
case
STEP_PRIMALDUALACTIVESET
:
return
ROL::makePtr<PrimalDualActiveSetStep<Real>>(parlist);
46
case
STEP_TRUSTREGION
:
return
ROL::makePtr<TrustRegionStep<Real>>(parlist);
47
case
STEP_INTERIORPOINT
:
return
ROL::makePtr<InteriorPointStep<Real>>(parlist);
48
case
STEP_FLETCHER
:
return
ROL::makePtr<FletcherStep<Real>>(parlist);
49
default
:
return
ROL::nullPtr;
50
}
51
}
52
};
53
54
}
55
56
#endif
ROL_AugmentedLagrangianStep.hpp
ROL_BundleStep.hpp
ROL_CompositeStep.hpp
ROL_FletcherStep.hpp
ROL_InteriorPointStep.hpp
ROL_LineSearchStep.hpp
ROL_MoreauYosidaPenaltyStep.hpp
ROL_PrimalDualActiveSetStep.hpp
ROL_Step.hpp
ROL_TrustRegionStep.hpp
ROL_Types.hpp
Contains definitions of custom data types in ROL.
ROL::StepFactory
Definition
ROL_StepFactory.hpp:32
ROL::StepFactory::~StepFactory
~StepFactory(void)
Definition
ROL_StepFactory.hpp:34
ROL::StepFactory::getStep
ROL::Ptr< Step< Real > > getStep(const std::string &type, ROL::ParameterList &parlist) const
Definition
ROL_StepFactory.hpp:36
ROL
Definition
ROL_ElementwiseVector.hpp:27
ROL::EStep
EStep
Definition
ROL_Types.hpp:243
ROL::STEP_PRIMALDUALACTIVESET
@ STEP_PRIMALDUALACTIVESET
Definition
ROL_Types.hpp:249
ROL::STEP_BUNDLE
@ STEP_BUNDLE
Definition
ROL_Types.hpp:245
ROL::STEP_AUGMENTEDLAGRANGIAN
@ STEP_AUGMENTEDLAGRANGIAN
Definition
ROL_Types.hpp:244
ROL::STEP_LINESEARCH
@ STEP_LINESEARCH
Definition
ROL_Types.hpp:247
ROL::STEP_COMPOSITESTEP
@ STEP_COMPOSITESTEP
Definition
ROL_Types.hpp:246
ROL::STEP_INTERIORPOINT
@ STEP_INTERIORPOINT
Definition
ROL_Types.hpp:251
ROL::STEP_FLETCHER
@ STEP_FLETCHER
Definition
ROL_Types.hpp:252
ROL::STEP_MOREAUYOSIDAPENALTY
@ STEP_MOREAUYOSIDAPENALTY
Definition
ROL_Types.hpp:248
ROL::STEP_TRUSTREGION
@ STEP_TRUSTREGION
Definition
ROL_Types.hpp:250
ROL::StringToEStep
EStep StringToEStep(std::string s)
Definition
ROL_Types.hpp:361
Generated by
1.17.0