www.mooseframework.org
SpecificEnthalpyAux.C
Go to the documentation of this file.
1 //* This file is part of the MOOSE framework
2 //* https://www.mooseframework.org
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 "SpecificEnthalpyAux.h"
12 
13 registerMooseObject("FluidPropertiesApp", SpecificEnthalpyAux);
14 
17 {
19  params.addRequiredCoupledVar("p", "Pressure");
20  params.addRequiredCoupledVar("T", "Temperature");
21  params.addRequiredParam<UserObjectName>("fp", "The name of the user object for fluid properties");
22  params.addClassDescription("Computes specific enthalpy from pressure and temperature");
23  return params;
24 }
25 
27  : AuxKernel(parameters),
28  _pressure(coupledValue("p")),
29  _temperature(coupledValue("T")),
30  _fp(getUserObject<SinglePhaseFluidProperties>("fp"))
31 {
32 }
33 
34 Real
36 {
37  return _fp.h_from_p_T(_pressure[_qp], _temperature[_qp]);
38 }
registerMooseObject("FluidPropertiesApp", SpecificEnthalpyAux)
Computes specific enthalpy from pressure and temperature.
const VariableValue & _temperature
static InputParameters validParams()
const VariableValue & _pressure
const SinglePhaseFluidProperties & _fp
void addRequiredParam(const std::string &name, const std::string &doc_string)
virtual Real computeValue() override
Common class for single phase fluid properties.
void addRequiredCoupledVar(const std::string &name, const std::string &doc_string)
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
void addClassDescription(const std::string &doc_string)
static InputParameters validParams()
SpecificEnthalpyAux(const InputParameters &parameters)