41#ifndef NEKTAR_LIB_UTILITIES_TIME_INTEGRATION_BDF_TIME_INTEGRATION_SCHEME
42#define NEKTAR_LIB_UTILITIES_TIME_INTEGRATION_BDF_TIME_INTEGRATION_SCHEME
44#define LUE LIB_UTILITIES_EXPORT
46#include <boost/core/ignore_unused.hpp>
61 std::vector<NekDouble> freeParams)
66 "BDFImplicit Time integration scheme bad order (1-4): " +
67 std::to_string(order));
71 for (
size_t n = 0; n < order; ++n)
116 "BDFImplicit Time integration scheme bad order: " +
117 std::to_string(order));
126 std::string variant,
size_t order, std::vector<NekDouble> freeParams)
130 variant, order, freeParams);
140 constexpr NekDouble ABcoefficients[5] = {0.,
147 constexpr NekDouble UVcoefficients[5][4] =
148 { { 0., 0., 0., 0. },
152 { 4./ 3., -1./ 3., 0., 0. },
154 { 18./11., -9./11., 2./11., 0. },
156 { 48./25., -36./25., 16./25., -3./25. } };
160 phase->m_order = order;
162 std::string(
"BDFImplicitOrder" + std::to_string(phase->m_order));
164 phase->m_numsteps = phase->m_order;
165 phase->m_numstages = 1;
182 phase->m_A[0][0][0] = ABcoefficients[phase->m_order];
183 phase->m_B[0][0][0] = ABcoefficients[phase->m_order];
186 for (
size_t n = 0; n < phase->m_order; ++n)
188 phase->m_U[0][n] = UVcoefficients[phase->m_order][n];
189 phase->m_V[0][n] = UVcoefficients[phase->m_order][n];
193 for (
size_t n = 1; n < phase->m_order; ++n)
195 phase->m_V[n][n - 1] = 1.0;
198 phase->m_numMultiStepValues = phase->m_order;
199 phase->m_numMultiStepImplicitDerivs = 0;
200 phase->m_numMultiStepExplicitDerivs = 0;
202 for (
size_t n = 0; n < phase->m_order; ++n)
204 phase->m_timeLevelOffset[n] = n;
207 phase->CheckAndVerify();
213 return std::string(
"BDFImplicit");
230 std::vector<NekDouble> freeParams)
233 boost::ignore_unused(variant, order);
237 [[maybe_unused]] std::string variant, [[maybe_unused]]
size_t order,
238 std::vector<NekDouble> freeParams)
258 std::vector<NekDouble> freeParams)
261 boost::ignore_unused(variant, order);
265 [[maybe_unused]] std::string variant, [[maybe_unused]]
size_t order,
266 std::vector<NekDouble> freeParams)
286 std::vector<NekDouble> freeParams)
289 boost::ignore_unused(variant, order);
293 [[maybe_unused]] std::string variant, [[maybe_unused]]
size_t order,
294 std::vector<NekDouble> freeParams)
314 std::vector<NekDouble> freeParams)
317 boost::ignore_unused(variant, order);
321 [[maybe_unused]] std::string variant, [[maybe_unused]]
size_t order,
322 std::vector<NekDouble> freeParams)
#define ASSERTL1(condition, msg)
Assert Level 1 – Debugging which is used whether in FULLDEBUG or DEBUG compilation mode....
static std::string TimeIntegrationMethodLookupId
BDFImplicitOrder1TimeIntegrationScheme(std::string variant, size_t order, std::vector< NekDouble > freeParams)
static TimeIntegrationSchemeSharedPtr create(std::string variant, size_t order, std::vector< NekDouble > freeParams)
static std::string className
static std::string className
static TimeIntegrationSchemeSharedPtr create(std::string variant, size_t order, std::vector< NekDouble > freeParams)
BDFImplicitOrder2TimeIntegrationScheme(std::string variant, size_t order, std::vector< NekDouble > freeParams)
static std::string TimeIntegrationMethodLookupId
static TimeIntegrationSchemeSharedPtr create(std::string variant, size_t order, std::vector< NekDouble > freeParams)
static std::string className
static std::string TimeIntegrationMethodLookupId
BDFImplicitOrder3TimeIntegrationScheme(std::string variant, size_t order, std::vector< NekDouble > freeParams)
BDFImplicitOrder4TimeIntegrationScheme(std::string variant, size_t order, std::vector< NekDouble > freeParams)
static TimeIntegrationSchemeSharedPtr create(std::string variant, size_t order, std::vector< NekDouble > freeParams)
static std::string className
static std::string TimeIntegrationMethodLookupId
static std::string className
LUE NekDouble v_GetTimeStability() const override
BDFImplicitTimeIntegrationScheme(std::string variant, size_t order, std::vector< NekDouble > freeParams)
LUE std::string v_GetName() const override
~BDFImplicitTimeIntegrationScheme() override
static TimeIntegrationSchemeSharedPtr create(std::string variant, size_t order, std::vector< NekDouble > freeParams)
static LUE void SetupSchemeData(TimeIntegrationAlgorithmGLMSharedPtr &phase, size_t order)
static LUE void SetupSchemeData(TimeIntegrationAlgorithmGLMSharedPtr &phase, size_t order)
Base class for GLM time integration schemes.
TimeIntegrationAlgorithmGLMVector m_integration_phases
static std::shared_ptr< DataType > AllocateSharedPtr(const Args &...args)
Allocate a shared pointer from the memory pool.
std::shared_ptr< TimeIntegrationAlgorithmGLM > TimeIntegrationAlgorithmGLMSharedPtr
@ eDiagonallyImplicit
Diagonally implicit scheme (e.g. the DIRK schemes)
std::vector< TimeIntegrationAlgorithmGLMSharedPtr > TimeIntegrationAlgorithmGLMVector
std::shared_ptr< TimeIntegrationScheme > TimeIntegrationSchemeSharedPtr