www.mooseframework.org
TestTwoPhaseFluidProperties.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 
12 
13 registerMooseObject("FluidPropertiesTestApp", TestTwoPhaseFluidProperties);
14 
15 template <>
16 InputParameters
18 {
19  InputParameters params = validParams<TwoPhaseFluidProperties>();
20 
21  params.addClassDescription("Test 2-phase fluid properties");
22 
23  params.makeParamRequired<UserObjectName>("fp_liquid");
24  params.makeParamRequired<UserObjectName>("fp_vapor");
25 
26  return params;
27 }
28 
30  : TwoPhaseFluidProperties(parameters)
31 {
32  _fp_liquid = &getUserObject<SinglePhaseFluidProperties>("fp_liquid");
33  _fp_vapor = &getUserObject<SinglePhaseFluidProperties>("fp_vapor");
34 }
35 
36 Real
38 {
39  return 25;
40 }
41 
42 Real
44 {
45  return 2 * p;
46 }
47 
48 Real
50 {
51  return 3 * T;
52 }
53 
54 Real TestTwoPhaseFluidProperties::dT_sat_dp(Real /*p*/) const { return 2; }
55 
56 Real
58 {
59  return 5 * T;
60 }
61 
62 Real
64 {
65  return 5;
66 }
67 
68 bool
70 {
71  return true;
72 }
TestTwoPhaseFluidProperties::T_sat
virtual Real T_sat(Real p) const override
Computes the saturation temperature at a pressure.
Definition: TestTwoPhaseFluidProperties.C:43
TestTwoPhaseFluidProperties::dT_sat_dp
virtual Real dT_sat_dp(Real p) const override
Computes dT/dp along the saturation line.
Definition: TestTwoPhaseFluidProperties.C:54
TestTwoPhaseFluidProperties::p_sat
virtual Real p_sat(Real T) const override
Computes the saturation pressure at a temperature.
Definition: TestTwoPhaseFluidProperties.C:49
TwoPhaseFluidProperties::_fp_liquid
const SinglePhaseFluidProperties * _fp_liquid
The user object that provides liquid phase fluid properties.
Definition: TwoPhaseFluidProperties.h:99
TwoPhaseFluidProperties::_fp_vapor
const SinglePhaseFluidProperties * _fp_vapor
The user object that provides vapor phase fluid properties.
Definition: TwoPhaseFluidProperties.h:101
SinglePhaseFluidProperties.h
TestTwoPhaseFluidProperties::TestTwoPhaseFluidProperties
TestTwoPhaseFluidProperties(const InputParameters &parameters)
Definition: TestTwoPhaseFluidProperties.C:29
validParams< TwoPhaseFluidProperties >
InputParameters validParams< TwoPhaseFluidProperties >()
Definition: TwoPhaseFluidProperties.C:15
TestTwoPhaseFluidProperties
Test 2-phase fluid properties.
Definition: TestTwoPhaseFluidProperties.h:24
TestTwoPhaseFluidProperties::p_critical
virtual Real p_critical() const override
Returns the critical pressure.
Definition: TestTwoPhaseFluidProperties.C:37
TestTwoPhaseFluidProperties::supportsPhaseChange
virtual bool supportsPhaseChange() const override
Returns true if phase change is supported, otherwise false.
Definition: TestTwoPhaseFluidProperties.C:69
registerMooseObject
registerMooseObject("FluidPropertiesTestApp", TestTwoPhaseFluidProperties)
TestTwoPhaseFluidProperties.h
TwoPhaseFluidProperties
Base class for fluid properties used with two-phase flow.
Definition: TwoPhaseFluidProperties.h:23
validParams< TestTwoPhaseFluidProperties >
InputParameters validParams< TestTwoPhaseFluidProperties >()
Definition: TestTwoPhaseFluidProperties.C:17
TestTwoPhaseFluidProperties::dsigma_dT_from_T
virtual Real dsigma_dT_from_T(Real T) const override
Computes dsigma/dT along the saturation line.
Definition: TestTwoPhaseFluidProperties.C:63
TestTwoPhaseFluidProperties::sigma_from_T
virtual Real sigma_from_T(Real T) const override
Computes surface tension sigma of saturated liquid in contact with saturated vapor.
Definition: TestTwoPhaseFluidProperties.C:57