https://mooseframework.inl.gov
Loading...
Searching...
No Matches
FlowChannelGasMix.C
Go to the documentation of this file.
1//* This file is part of the MOOSE framework
2//* https://mooseframework.inl.gov
3//*
4//* All rights reserved, see COPYRIGHT for full restrictions
5//* https://github.com/idaholab/moose/blob/master/COPYRIGHT
6//*
7//* Licensed under LGPL 2.1, please see LICENSE for details
8//* https://www.gnu.org/licenses/lgpl-2.1.html
9
10#include "FlowChannelGasMix.h"
12
13registerMooseObject("ThermalHydraulicsApp", FlowChannelGasMix);
14
17{
19
20 params.addParam<FunctionName>("initial_mass_fraction",
21 "Initial mass fraction of the secondary gas");
22 params.addParamNamesToGroup("initial_mass_fraction", "Variable initialization");
23
24 params.addParam<Real>(
25 "scaling_factor_xirhoA", 1.0, "Scaling factor for the secondary component mass equation");
26 params.addParam<Real>("scaling_factor_rhoA", 1.0, "Scaling factor for the mixture mass equation");
27 params.addParam<Real>("scaling_factor_rhouA", 1.0, "Scaling factor for the momentum equation");
28 params.addParam<Real>("scaling_factor_rhoEA", 1.0, "Scaling factor for the energy equation");
30 "scaling_factor_xirhoA scaling_factor_rhoA scaling_factor_rhouA scaling_factor_rhoEA",
31 "Numerical scheme");
32
33 params.addClassDescription("Single-phase flow channel with a binary gas mixture");
34
35 return params;
36}
37
41
42void
44{
46 if (dynamic_cast<const VaporMixtureFluidProperties *>(&fp) == nullptr)
47 logError("The supplied fluid properties object must be of type "
48 "'VaporMixtureFluidProperties'.");
49}
50
51std::string
53{
54 return "FlowModelGasMix";
55}
56
57std::vector<std::string>
59{
60 return {"initial_p", "initial_T", "initial_vel", "initial_mass_fraction"};
61}
registerMooseObject("ThermalHydraulicsApp", FlowChannelGasMix)
void logError(Args &&... args) const
Logs an error.
Definition Component.h:226
THMProblem & getTHMProblem() const
Gets the THM problem.
Definition Component.C:135
T & getUserObject(const std::string &name, unsigned int tid=0) const
Base class for single-phase flow channels.
static InputParameters validParams()
const UserObjectName & _fp_name
Name of fluid properties user object.
Flow channel containing a mixture of two gases.
virtual std::vector< std::string > ICParameters() const override
Returns the names of the IC parameters.
FlowChannelGasMix(const InputParameters &params)
static InputParameters validParams()
virtual void checkFluidProperties() const override
Logs an error if the fluid properties is not valid.
virtual std::string flowModelClassName() const override
Returns the flow model class name.
void addParamNamesToGroup(const std::string &space_delim_names, const std::string group_name)
void addParam(const std::string &name, const std::initializer_list< typename T::value_type > &value, const std::string &doc_string)
void addClassDescription(const std::string &doc_string)
Base class for fluid properties of vapor mixtures.