44 #ifndef ROL_SECANTFACTORY_H
45 #define ROL_SECANTFACTORY_H
49 #include "ROL_ParameterList.hpp"
50 #include "ROL_Ptr.hpp"
63 case SECANT_LDFP:
return ROL::makePtr<lDFP<Real>>(L);
64 case SECANT_LSR1:
return ROL::makePtr<lSR1<Real>>(L);
66 default:
return ROL::nullPtr;
73 parlist.sublist(
"General").sublist(
"Secant").get(
"Type",
"Limited-Memory BFGS") );
74 int L = parlist.sublist(
"General").sublist(
"Secant").get(
"Maximum Storage",10);
75 int BB = parlist.sublist(
"General").sublist(
"Secant").get(
"Barzilai-Borwein",1);
76 bool uds = parlist.sublist(
"General").sublist(
"Secant").get(
"Use Default Scaling",
true);
77 Real s = parlist.sublist(
"General").sublist(
"Secant").get(
"Initial Hessian Scale",1.0);
79 case SECANT_LBFGS:
return ROL::makePtr<lBFGS<Real>>(L,uds,s);
80 case SECANT_LDFP:
return ROL::makePtr<lDFP<Real>>(L,uds,s);
81 case SECANT_LSR1:
return ROL::makePtr<lSR1<Real>>(L,uds,s,mode);
83 default:
return ROL::nullPtr;
ROL::Ptr< Secant< Real > > SecantFactory(ROL::ParameterList &parlist, ESecantMode mode=SECANTMODE_BOTH)
Contains definitions of custom data types in ROL.
ESecant StringToESecant(std::string s)
ESecant
Enumeration of secant update algorithms.
ROL::Ptr< Secant< Real > > getSecant(ESecant esec=SECANT_LBFGS, int L=10, int BBtype=1)