25 #ifndef GRINS_PHYSICS_FACTORY_INCOMPRESSIBLE_TURB_FLOW_H
26 #define GRINS_PHYSICS_FACTORY_INCOMPRESSIBLE_TURB_FLOW_H
35 template<
template<
typename>
class DerivedPhysics>
40 const std::string& core_physics_name )
48 virtual libMesh::UniquePtr<Physics>
build_physics(
const GetPot& input,
49 const std::string& physics_name );
51 void visc_error_msg(
const std::string& physics,
const std::string& viscosity )
const;
55 template<
template<
typename>
class DerivedPhysics>
58 const std::string& physics_name )
60 std::string core_physics = this->find_core_physics_name(physics_name);
62 std::string viscosity;
65 libMesh::UniquePtr<Physics> new_physics;
67 if( viscosity ==
"constant" )
68 new_physics.reset(
new DerivedPhysics<ConstantViscosity>(physics_name,input) );
71 this->visc_error_msg(physics_name, viscosity);
73 libmesh_assert(new_physics);
78 template<
template<
typename>
class DerivedPhysics>
81 const std::string& viscosity )
const
83 std::string error =
"================================================================\n";
84 error +=
"Invalid turblence viscosity model for "+physics+
"\n";
85 error +=
"Viscosity model = "+viscosity+
"\n";
86 error +=
"================================================================\n";
88 libmesh_error_msg(error);
93 #endif // GRINS_PHYSICS_FACTORY_INCOMPRESSIBLE_TURB_FLOW_H
PhysicsFactoryIncompressibleTurbFlow(const std::string &physics_name, const std::string &core_physics_name)
virtual libMesh::UniquePtr< Physics > build_physics(const GetPot &input, const std::string &physics_name)
void visc_error_msg(const std::string &physics, const std::string &viscosity) const
PhysicsFactory base class for Physics that may have a related "core" Physics.
~PhysicsFactoryIncompressibleTurbFlow()
static void parse_turb_viscosity_model(const GetPot &input, const std::string &physics, std::string &model)
Determine viscosity model used by turblence classes.