https://mooseframework.inl.gov
Functions
HeliumFluidPropertiesTest.C File Reference

Go to the source code of this file.

Functions

 TEST_F (HeliumFluidPropertiesTest, fluidName)
 Test that the fluid name is correctly returned. More...
 
 TEST_F (HeliumFluidPropertiesTest, molarMass)
 Test that the molar mass is correctly returned. More...
 
 TEST_F (HeliumFluidPropertiesTest, thermalConductivity)
 Test that the thermal conductivity and its derivatives are correctly computed. More...
 
 TEST_F (HeliumFluidPropertiesTest, viscosity)
 Test that the viscosity and its derivatives are correctly computed. More...
 
 TEST_F (HeliumFluidPropertiesTest, isobaricSpecificHeat)
 Test that the isobaric specific heat and its derivatives are correctly computed. More...
 
 TEST_F (HeliumFluidPropertiesTest, isochoricSpecificHeat)
 Test that the isochoric specific heat is correctly computed. More...
 
 TEST_F (HeliumFluidPropertiesTest, density)
 Test that the density and its derivatives are correctly computed. More...
 
 TEST_F (HeliumFluidPropertiesTest, specificInternalEnergy)
 Test that the specific internal energy and its derivatives are correctly computed. More...
 
 TEST_F (HeliumFluidPropertiesTest, pressure)
 Test that the pressure and its derivatives are correctly computed. More...
 
 TEST_F (HeliumFluidPropertiesTest, temperature)
 Test that the temperature and its derivatives are correctly computed. More...
 
 TEST_F (HeliumFluidPropertiesTest, specificEnthalpy)
 Test that the specific enthalpy and its derivatives are correctly computed. More...
 

Function Documentation

◆ TEST_F() [1/11]

TEST_F ( HeliumFluidPropertiesTest  ,
fluidName   
)

Test that the fluid name is correctly returned.

Definition at line 16 of file HeliumFluidPropertiesTest.C.

16 { EXPECT_EQ(_fp->fluidName(), "helium"); }

◆ TEST_F() [2/11]

TEST_F ( HeliumFluidPropertiesTest  ,
molarMass   
)

Test that the molar mass is correctly returned.

Definition at line 21 of file HeliumFluidPropertiesTest.C.

22 {
23  ABS_TEST(_fp->molarMass(), 4.002602e-3, REL_TOL_SAVED_VALUE);
24 }

◆ TEST_F() [3/11]

TEST_F ( HeliumFluidPropertiesTest  ,
thermalConductivity   
)

Test that the thermal conductivity and its derivatives are correctly computed.

Definition at line 30 of file HeliumFluidPropertiesTest.C.

31 {
32  const Real T = 120.0 + 273.15;
33  const Real p = 101325.0;
34  const Real e = _fp->e_from_p_T(p, T);
35  const Real v = 1. / _fp->rho_from_p_T(p, T);
36 
37  REL_TEST(_fp->k_from_v_e(v, e), 1.8651584722911332e-01, REL_TOL_SAVED_VALUE);
38  REL_TEST(_fp->k_from_p_T(p, T), 1.8651584722911332e-01, REL_TOL_SAVED_VALUE);
39  DERIV_TEST(_fp->k_from_p_T, p, T, REL_TOL_DERIVATIVE);
40 }
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
static const std::string v
Definition: NS.h:84

◆ TEST_F() [4/11]

TEST_F ( HeliumFluidPropertiesTest  ,
viscosity   
)

Test that the viscosity and its derivatives are correctly computed.

Definition at line 45 of file HeliumFluidPropertiesTest.C.

46 {
47  const Real T = 120.0 + 273.15;
48  const Real p = 101325.0;
49  const Real e = _fp->e_from_p_T(p, T);
50  const Real v = 1. / _fp->rho_from_p_T(p, T);
51 
52  REL_TEST(_fp->mu_from_v_e(v, e), 2.4061901685126415e-05, REL_TOL_SAVED_VALUE);
53  REL_TEST(_fp->mu_from_p_T(p, T), 2.4061901685126415e-05, REL_TOL_SAVED_VALUE);
54  DERIV_TEST(_fp->mu_from_p_T, p, T, REL_TOL_DERIVATIVE);
55 }
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
static const std::string v
Definition: NS.h:84

◆ TEST_F() [5/11]

TEST_F ( HeliumFluidPropertiesTest  ,
isobaricSpecificHeat   
)

Test that the isobaric specific heat and its derivatives are correctly computed.

Definition at line 60 of file HeliumFluidPropertiesTest.C.

61 {
62  const Real T = 120.0 + 273.15;
63  const Real p = 101325.0;
64  const Real e = _fp->e_from_p_T(p, T);
65  const Real v = 1. / _fp->rho_from_p_T(p, T);
66 
67  REL_TEST(_fp->cp_from_p_T(p, T), 5195.0, REL_TOL_SAVED_VALUE);
68  REL_TEST(_fp->cp_from_v_e(v, e), 5195.0, REL_TOL_SAVED_VALUE);
69  DERIV_TEST(_fp->cp_from_p_T, p, T, REL_TOL_DERIVATIVE);
70  DERIV_TEST(_fp->cp_from_v_e, v, e, REL_TOL_DERIVATIVE);
71 }
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
static const std::string v
Definition: NS.h:84

◆ TEST_F() [6/11]

TEST_F ( HeliumFluidPropertiesTest  ,
isochoricSpecificHeat   
)

Test that the isochoric specific heat is correctly computed.

Definition at line 76 of file HeliumFluidPropertiesTest.C.

77 {
78  const Real T = 120.0 + 273.15;
79  const Real p = 101325.0;
80  const Real e = _fp->e_from_p_T(p, T);
81  const Real v = 1. / _fp->rho_from_p_T(p, T);
82 
83  REL_TEST(_fp->cv_from_v_e(v, e), 3117.0, REL_TOL_SAVED_VALUE);
84  REL_TEST(_fp->cv_from_p_T(p, T), 3117.0, REL_TOL_SAVED_VALUE);
85  DERIV_TEST(_fp->cv_from_p_T, p, T, REL_TOL_DERIVATIVE);
86  DERIV_TEST(_fp->cv_from_v_e, v, e, REL_TOL_DERIVATIVE);
87 }
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
static const std::string v
Definition: NS.h:84

◆ TEST_F() [7/11]

TEST_F ( HeliumFluidPropertiesTest  ,
density   
)

Test that the density and its derivatives are correctly computed.

Definition at line 92 of file HeliumFluidPropertiesTest.C.

93 {
94  const Real T = 120.0 + 273.15;
95  const Real p = 101325.0;
96 
97  ABS_TEST(_fp->rho_from_p_T(p, T), 1.2402629878970449e-01, REL_TOL_SAVED_VALUE);
98  DERIV_TEST(_fp->rho_from_p_T, p, T, REL_TOL_DERIVATIVE);
99 }
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real

◆ TEST_F() [8/11]

TEST_F ( HeliumFluidPropertiesTest  ,
specificInternalEnergy   
)

Test that the specific internal energy and its derivatives are correctly computed.

Definition at line 104 of file HeliumFluidPropertiesTest.C.

105 {
106  const Real T = 120.0 + 273.15;
107  const Real p = 101325.0;
108  const Real rho = _fp->rho_from_p_T(p, T);
109 
110  ABS_TEST(_fp->e_from_p_T(p, T), 1.2254485499999998e6, REL_TOL_SAVED_VALUE);
111  DERIV_TEST(_fp->e_from_p_T, p, T, REL_TOL_DERIVATIVE);
112  ABS_TEST(_fp->e_from_p_rho(p, rho), 1.2254485499999998e6, REL_TOL_SAVED_VALUE);
113 }
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real

◆ TEST_F() [9/11]

TEST_F ( HeliumFluidPropertiesTest  ,
pressure   
)

Test that the pressure and its derivatives are correctly computed.

Definition at line 118 of file HeliumFluidPropertiesTest.C.

119 {
120  const Real T = 120.0 + 273.15;
121  const Real p = 101325.0;
122  const Real e = _fp->e_from_p_T(p, T);
123  const Real v = 1. / _fp->rho_from_p_T(p, T);
124 
125  REL_TEST(_fp->p_from_v_e(v, e), p, REL_TOL_SAVED_VALUE);
126  DERIV_TEST(_fp->p_from_v_e, v, e, REL_TOL_DERIVATIVE);
127 }
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
static const std::string v
Definition: NS.h:84

◆ TEST_F() [10/11]

TEST_F ( HeliumFluidPropertiesTest  ,
temperature   
)

Test that the temperature and its derivatives are correctly computed.

Definition at line 132 of file HeliumFluidPropertiesTest.C.

133 {
134  const Real T = 120.0 + 273.15;
135  const Real p = 101325.0;
136  const Real e = _fp->e_from_p_T(p, T);
137  const Real v = 1. / _fp->rho_from_p_T(p, T);
138 
139  REL_TEST(_fp->T_from_v_e(v, e), T, REL_TOL_SAVED_VALUE);
140  DERIV_TEST(_fp->T_from_v_e, v, e, REL_TOL_DERIVATIVE);
141 
142  const Real h = _fp->h_from_p_T(p, T);
143  REL_TEST(_fp->T_from_p_h(p, h), T, REL_TOL_SAVED_VALUE);
144 }
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
static const std::string v
Definition: NS.h:84

◆ TEST_F() [11/11]

TEST_F ( HeliumFluidPropertiesTest  ,
specificEnthalpy   
)

Test that the specific enthalpy and its derivatives are correctly computed.

Definition at line 149 of file HeliumFluidPropertiesTest.C.

150 {
151  const Real T = 120.0 + 273.15;
152  const Real p = 101325.0;
153 
154  ABS_TEST(_fp->h_from_p_T(p, T), 2.0424142499999998e+06, REL_TOL_SAVED_VALUE);
155  DERIV_TEST(_fp->h_from_p_T, p, T, REL_TOL_DERIVATIVE);
156 }
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real