33 MInt noDistributions = 9;
34 noDistributions = Context::getSolverProperty<MInt>(
"noDistributions", solverId, AT_, &noDistributions);
37 const MString solverMethod = Context::getSolverProperty<MString>(
"solverMethod", solverId, AT_);
38 std::set<MInt> compressibleMethods = {
43 isCompressible = Context::getSolverProperty<MBool>(
"isCompressible", solverId, AT_, &isCompressible);
48 if constexpr(nDim == 2) {
49 switch(noDistributions) {
51 return std::make_unique<LbSolverDxQy<2, 9, LbSysEqnCompressible<2, 9>>>(solverId, 9, gridProxy, geometry,
57 ss <<
"Error: D" << nDim <<
"Q" << noDistributions <<
" is unsupported !" << std::endl;
61 }
else if constexpr(nDim == 3) {
62 switch(noDistributions) {
64 return std::make_unique<LbSolverDxQy<3, 19, LbSysEqnCompressible<3, 19>>>(solverId, 19, gridProxy, geometry,
69 return std::make_unique<LbSolverDxQy<3, 27, LbSysEqnCompressible<3, 27>>>(solverId, 27, gridProxy, geometry,
75 ss <<
"Error: D" << nDim <<
"Q" << noDistributions <<
" is unsupported !" << std::endl;
81 if constexpr(nDim == 2) {
82 switch(noDistributions) {
84 return std::make_unique<LbSolverDxQy<2, 9, LbSysEqnIncompressible<2, 9>>>(solverId, 9, gridProxy, geometry,
89 ss <<
"Error: D" << nDim <<
"Q" << noDistributions <<
" is unsupported !" << std::endl;
94 }
else if constexpr(nDim == 3) {
95 switch(noDistributions) {
97 return std::make_unique<LbSolverDxQy<nDim, 19, LbSysEqnIncompressible<3, 19>>>(solverId, 19, gridProxy,
102 return std::make_unique<LbSolverDxQy<nDim, 27, LbSysEqnIncompressible<3, 27>>>(solverId, 27, gridProxy,
103 geometry, gridProxy.mpiComm());
107 std::stringstream ss;
108 ss <<
"Error: D" << nDim <<
"Q" << noDistributions <<
" is unsupported !" << std::endl;
118template class LbSolverFactory<2>;
119template class LbSolverFactory<3>;
static std::unique_ptr< Solver > create(const MInt solverId, maia::grid::Proxy< nDim > &gridProxy, Geometry< nDim > &geometry, const MPI_Comm comm)
MInt string2enum(MString theString)
This global function translates strings in their corresponding enum values (integer values)....
@ MAIA_LATTICE_BGK_TOTALENERGY
@ MAIA_LATTICE_BGK_INNERENERGY
@ MAIA_LATTICE_BGK_THERMAL_TRANSPORT
@ MAIA_LATTICE_BGK_THERMAL
void mTerm(const MInt errorCode, const MString &location, const MString &message)
std::basic_string< char > MString