https://mooseframework.inl.gov
Loading...
Searching...
No Matches
SpecificEnthalpyFromPressureTemperatureIC.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
12
14
17{
19 params.addRequiredParam<UserObjectName>("fp", "The name of fluid properties user object.");
20 params.addRequiredCoupledVar("p", "The pressure [Pa]");
21 params.addRequiredCoupledVar("T", "The temperature [K]");
22 params.addClassDescription("Computes the specific enthalpy from pressure and temperature.");
23 return params;
24}
25
27 const InputParameters & parameters)
28 : InitialCondition(parameters),
29 _spfp(getUserObject<SinglePhaseFluidProperties>("fp")),
30 _p(coupledValue("p")),
31 _T(coupledValue("T"))
32{
33}
34
35Real
37{
38 return _spfp.h_from_p_T(_p[_qp], _T[_qp]);
39}
registerMooseObject("FluidPropertiesApp", SpecificEnthalpyFromPressureTemperatureIC)
static InputParameters validParams()
void addRequiredCoupledVar(const std::string &name, const std::string &doc_string)
void addRequiredParam(const std::string &name, const std::string &doc_string)
void addClassDescription(const std::string &doc_string)
Common class for single phase fluid properties.
Computes specific enthalpy from pressure and temperature variables.
SpecificEnthalpyFromPressureTemperatureIC(const InputParameters &parameters)
const SinglePhaseFluidProperties & _spfp
Single phase fluid property user object.