Nektar++
SchemeInitializer.cpp
Go to the documentation of this file.
1///////////////////////////////////////////////////////////////////////////////
2//
3// File: SchemeInitializer.cpp
4//
5// For more information, please see: http://www.nektar.info
6//
7// The MIT License
8//
9// Copyright (c) 2006 Division of Applied Mathematics, Brown University (USA),
10// Department of Aeronautics, Imperial College London (UK), and Scientific
11// Computing and Imaging Institute, University of Utah (USA).
12//
13// License for the specific language governing rights and limitations under
14// Permission is hereby granted, free of charge, to any person obtaining a
15// copy of this software and associated documentation files (the "Software"),
16// to deal in the Software without restriction, including without limitation
17// the rights to use, copy, modify, merge, publish, distribute, sublicense,
18// and/or sell copies of the Software, and to permit persons to whom the
19// Software is furnished to do so, subject to the following conditions:
20//
21// The above copyright notice and this permission notice shall be included
22// in all copies or substantial portions of the Software.
23//
24// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
25// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
26// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
27// THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
28// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
29// FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
30// DEALINGS IN THE SOFTWARE.
31//
32// Description: This file isused to add each of the Time Integration Schemes
33// to the NekFactory.
34//
35///////////////////////////////////////////////////////////////////////////////
36
50
52
56
58
60
62{
63
64// Register all the schemes with the Time Integration Scheme Factory...
65//
66#define FACTORYREGISTER(scheme) \
67 std::string scheme##TimeIntegrationScheme::className = \
68 GetTimeIntegrationSchemeFactory().RegisterCreatorFunction( \
69 #scheme, scheme##TimeIntegrationScheme::create)
70#define SESSIONREGISTER(scheme) \
71 std::string scheme##TimeIntegrationScheme::TimeIntegrationMethodLookupId = \
72 SessionReader::RegisterEnumValue("TimeIntegrationMethod", #scheme, 0)
73
74// AdamsBashforthTimeIntegrationSchemes.h
75FACTORYREGISTER(AdamsBashforth);
76FACTORYREGISTER(AdamsBashforthOrder1);
77SESSIONREGISTER(AdamsBashforthOrder1);
78FACTORYREGISTER(AdamsBashforthOrder2);
79SESSIONREGISTER(AdamsBashforthOrder2);
80FACTORYREGISTER(AdamsBashforthOrder3);
81SESSIONREGISTER(AdamsBashforthOrder3);
82FACTORYREGISTER(AdamsBashforthOrder4);
83SESSIONREGISTER(AdamsBashforthOrder4);
84
85// AdamsMoultonTimeIntegrationSchemes.h
86FACTORYREGISTER(AdamsMoulton);
87FACTORYREGISTER(AdamsMoultonOrder1);
88SESSIONREGISTER(AdamsMoultonOrder1);
89FACTORYREGISTER(AdamsMoultonOrder2);
90SESSIONREGISTER(AdamsMoultonOrder2);
91FACTORYREGISTER(AdamsMoultonOrder3);
92SESSIONREGISTER(AdamsMoultonOrder3);
93FACTORYREGISTER(AdamsMoultonOrder4);
94SESSIONREGISTER(AdamsMoultonOrder4);
95
96// BDFImplicitTimeIntegrationSchemes.h
97FACTORYREGISTER(BDFImplicit);
98FACTORYREGISTER(BDFImplicitOrder1);
99SESSIONREGISTER(BDFImplicitOrder1);
100FACTORYREGISTER(BDFImplicitOrder2);
101SESSIONREGISTER(BDFImplicitOrder2);
102FACTORYREGISTER(BDFImplicitOrder3);
103SESSIONREGISTER(BDFImplicitOrder3);
104FACTORYREGISTER(BDFImplicitOrder4);
105SESSIONREGISTER(BDFImplicitOrder4);
106
107// EulerTimeIntegrationSchemes.h
109FACTORYREGISTER(BackwardEuler);
110SESSIONREGISTER(BackwardEuler);
111FACTORYREGISTER(ForwardEuler);
112SESSIONREGISTER(ForwardEuler);
113
114// EulerExponentialTimeIntegrationSchemes.h
115FACTORYREGISTER(EulerExponential);
116
117// TimeIntegrationSchemesFIT.h
121
122// CNABTimeIntegrationScheme.h
125
126// DIRKTimeIntegrationSchemes.h
128FACTORYREGISTER(DIRKOrder1);
129SESSIONREGISTER(DIRKOrder1);
130FACTORYREGISTER(DIRKOrder2);
131SESSIONREGISTER(DIRKOrder2);
132FACTORYREGISTER(DIRKOrder3);
133SESSIONREGISTER(DIRKOrder3);
134FACTORYREGISTER(DIRKOrder3_ES5);
135SESSIONREGISTER(DIRKOrder3_ES5);
136FACTORYREGISTER(DIRKOrder4_ES6);
137SESSIONREGISTER(DIRKOrder4_ES6);
138
139// IMEXdirkTimeIntegrationSchemes.h
141FACTORYREGISTER(IMEXdirk_1_1_1);
142SESSIONREGISTER(IMEXdirk_1_1_1);
143FACTORYREGISTER(IMEXdirk_1_2_1);
144SESSIONREGISTER(IMEXdirk_1_2_1);
145FACTORYREGISTER(IMEXdirk_1_2_2);
146SESSIONREGISTER(IMEXdirk_1_2_2);
147FACTORYREGISTER(IMEXdirk_2_2_2);
148SESSIONREGISTER(IMEXdirk_2_2_2);
149FACTORYREGISTER(IMEXdirk_2_3_2);
150SESSIONREGISTER(IMEXdirk_2_3_2);
151FACTORYREGISTER(IMEXdirk_2_3_3);
152SESSIONREGISTER(IMEXdirk_2_3_3);
153FACTORYREGISTER(IMEXdirk_3_4_3);
154SESSIONREGISTER(IMEXdirk_3_4_3);
155FACTORYREGISTER(IMEXdirk_4_4_3);
156SESSIONREGISTER(IMEXdirk_4_4_3);
157
158// IMEXGearTimeIntegrationScheme.h
161
162// IMEXTimeIntegrationSchemes.h
164FACTORYREGISTER(IMEXOrder1);
165SESSIONREGISTER(IMEXOrder1);
166FACTORYREGISTER(IMEXOrder2);
167SESSIONREGISTER(IMEXOrder2);
168FACTORYREGISTER(IMEXOrder3);
169SESSIONREGISTER(IMEXOrder3);
170FACTORYREGISTER(IMEXOrder4);
171SESSIONREGISTER(IMEXOrder4);
172
173// MCNABTimeIntegrationScheme.h
176
177// RungeKuttaTimeIntegrationSchemes.h
178FACTORYREGISTER(RungeKutta);
179FACTORYREGISTER(RungeKutta1);
180SESSIONREGISTER(RungeKutta1);
181FACTORYREGISTER(RungeKutta2);
182SESSIONREGISTER(RungeKutta2);
183FACTORYREGISTER(RungeKutta2_ImprovedEuler);
184SESSIONREGISTER(RungeKutta2_ImprovedEuler);
185FACTORYREGISTER(RungeKutta2_SSP);
186SESSIONREGISTER(RungeKutta2_SSP);
187FACTORYREGISTER(RungeKutta3);
188SESSIONREGISTER(RungeKutta3);
189FACTORYREGISTER(RungeKutta3_SSP);
190SESSIONREGISTER(RungeKutta3_SSP);
191FACTORYREGISTER(ClassicalRungeKutta4);
192SESSIONREGISTER(ClassicalRungeKutta4);
193FACTORYREGISTER(RungeKutta4);
194SESSIONREGISTER(RungeKutta4);
195FACTORYREGISTER(RungeKutta5);
196SESSIONREGISTER(RungeKutta5);
197
198// Do nothing
201
202// TimeIntegrationSchemesSDC.h
212
213// TimeIntegrationSchemesGEM.h
216 "ExtrapolationMethod", TimeIntegrationSchemeGEM::create);
217
218} // namespace Nektar::LibUtilities
static TimeIntegrationSchemeSharedPtr create(std::string variant, size_t order, std::vector< NekDouble > freeParams)
static TimeIntegrationSchemeSharedPtr create(std::string variant, size_t order, std::vector< NekDouble > freeParams)
Creator.
static TimeIntegrationSchemeSharedPtr create(std::string variant, size_t order, std::vector< NekDouble > freeParams)
static TimeIntegrationSchemeSharedPtr create(std::string variant, size_t order, std::vector< NekDouble > freeParams)
tKey RegisterCreatorFunction(tKey idKey, CreatorFunction classCreator, std::string pDesc="")
Register a class with the factory.
static TimeIntegrationSchemeSharedPtr create(std::string variant, size_t order, std::vector< NekDouble > freeParams)
TimeIntegrationSchemeFactory & GetTimeIntegrationSchemeFactory()
FACTORYREGISTER(AdamsBashforth)
SESSIONREGISTER(AdamsBashforthOrder1)