25 namespace ThermalTwoPhaseFlowWithPP
30 std::unique_ptr<ProcessLib::AbstractJacobianAssembler>&& jacobian_assembler,
31 std::vector<ProcessVariable>
const& variables,
32 std::vector<std::unique_ptr<ParameterLib::ParameterBase>>
const& parameters,
33 unsigned const integration_order,
36 std::unique_ptr<MathLib::PiecewiseLinearInterpolation>>
const&
42 DBUG(
"Create nonisothermal two-phase flow model.");
54 std::vector<std::vector<std::reference_wrapper<ProcessVariable>>>
56 process_variables.push_back(std::move(per_process_variables));
62 std::vector<double>
const b =
65 assert(!b.empty() && b.size() < 4);
66 Eigen::VectorXd specific_body_force(b.size());
70 std::copy_n(b.data(), b.size(), specific_body_force.data());
76 auto const& diff_coeff_b = ParameterLib::findParameter<double>(
79 "diffusion_coeff_component_b", parameters, 1, &mesh);
80 auto const& diff_coeff_a = ParameterLib::findParameter<double>(
83 "diffusion_coeff_component_a", parameters, 1, &mesh);
87 auto const& density_solid = ParameterLib::findParameter<double>(
90 "density_solid", parameters, 1, &mesh);
91 DBUG(
"Use '{:s}' as density_solid parameter.", density_solid.name);
94 auto const& latent_heat_evaporation = ParameterLib::findParameter<double>(
97 "latent_heat_evaporation", parameters, 1, &mesh);
98 DBUG(
"Use '{:s}' as latent_heat_evaporation parameter.",
99 latent_heat_evaporation.name);
104 std::unique_ptr<ThermalTwoPhaseFlowWithPPMaterialProperties> material =
114 latent_heat_evaporation,
115 std::move(material)};
117 return std::make_unique<ThermalTwoPhaseFlowWithPPProcess>(
118 std::move(
name), mesh, std::move(jacobian_assembler), parameters,
119 integration_order, std::move(process_variables),
120 std::move(process_data), std::move(secondary_variables), mat_config,
void DBUG(char const *fmt, Args const &... args)
void checkConfigParameter(std::string const ¶m, T const &value) const
T getConfigParameter(std::string const ¶m) const
ConfigTree getConfigSubtree(std::string const &root) const
Handles configuration of several secondary variables from the project file.
Eigen::Map< const Vector > toVector(std::vector< double > const &data, Eigen::VectorXd::Index size)
Creates an Eigen mapped vector from the given data vector.
PropertyVector< int > const * materialIDs(Mesh const &mesh)
std::unique_ptr< ThermalTwoPhaseFlowWithPPMaterialProperties > createThermalTwoPhaseFlowWithPPMaterialProperties(BaseLib::ConfigTree const &config, MeshLib::PropertyVector< int > const *material_ids, std::vector< std::unique_ptr< ParameterLib::ParameterBase >> const ¶meters)
std::unique_ptr< Process > createThermalTwoPhaseFlowWithPPProcess(std::string name, MeshLib::Mesh &mesh, std::unique_ptr< ProcessLib::AbstractJacobianAssembler > &&jacobian_assembler, std::vector< ProcessVariable > const &variables, std::vector< std::unique_ptr< ParameterLib::ParameterBase >> const ¶meters, unsigned const integration_order, BaseLib::ConfigTree const &config, std::map< std::string, std::unique_ptr< MathLib::PiecewiseLinearInterpolation >> const &curves)
std::vector< std::reference_wrapper< ProcessVariable > > findProcessVariables(std::vector< ProcessVariable > const &variables, BaseLib::ConfigTree const &pv_config, std::initializer_list< std::string > tags)
void createSecondaryVariables(BaseLib::ConfigTree const &config, SecondaryVariableCollection &secondary_variables)