|
| static constexpr int | nVarsFixed = getnVarsFixed(model) |
| | Number of fixed conservative variables (Eigen::Dynamic for NS_EX).
|
| |
| static constexpr int | dim = getDim_Fixed(model) |
| | Physics spatial dimension (2 for NS_2D, 3 for all others).
|
| |
| static constexpr int | gDim = getGeomDim_Fixed(model) |
| | Geometry (mesh) spatial dimension.
|
| |
| static constexpr bool | hasSA = (model == NS_SA || model == NS_SA_3D) |
| | True for Spalart-Allmaras models (NS_SA, NS_SA_3D).
|
| |
| static constexpr bool | has2EQ = (model == NS_2EQ || model == NS_2EQ_3D) |
| | True for 2-equation RANS models (NS_2EQ, NS_2EQ_3D).
|
| |
| static constexpr bool | hasRANS = hasSA || has2EQ |
| | True for any RANS turbulence model (SA or 2-equation).
|
| |
| static constexpr int | nRANSVars = hasSA ? 1 : (has2EQ ? 2 : 0) |
| | Number of extra RANS transport variables (0, 1, or 2).
|
| |
| static constexpr bool | isExtended = (model == NS_EX || model == NS_EX_3D) |
| | True for extended/dynamic models (NS_EX, NS_EX_3D).
|
| |
| static constexpr bool | isPlainNS = !hasRANS && !isExtended |
| | True for plain NS without turbulence or extensions.
|
| |
| static constexpr bool | isGeom2D = (gDim == 2) |
| | True for 2D geometry models.
|
| |
| static constexpr bool | isGeom3D = (gDim == 3) |
| | True for 3D geometry models.
|
| |
template<
EulerModel model>
struct DNDS::Euler::EulerModelTraits< model >
Compile-time traits for EulerModel variants.
Bundles all model-dependent compile-time constants (variable count, dimensions, feature flags) into a single struct, replacing scattered if constexpr chains with clean named traits. All members are static constexpr.
Usage example:
static_assert(Traits::nVarsFixed == 6);
static_assert(Traits::dim == 3);
static_assert(Traits::gDim == 3);
static_assert(Traits::hasSA);
static_assert(Traits::hasRANS);
static_assert(Traits::nRANSVars == 1);
Compile-time traits for EulerModel variants.
Future models (reactive, multi-species) should add traits here rather than adding new if-constexpr chains.
- Template Parameters
-
| model | The EulerModel enumerant to query traits for. |
Definition at line 1085 of file Euler.hpp.