From ebe950fc4c71b72213038a57aa7d6b253229257d Mon Sep 17 00:00:00 2001 From: Harry Moffat Date: Tue, 2 Sep 2008 17:24:20 +0000 Subject: [PATCH] Changed the test problems due to isothermal compressibility changes. --- .../cathermo/HMW_graph_VvT/output_blessed.txt | 38 +++++++++---------- .../cathermo/testIAPWSPres/output_blessed.txt | 5 +++ .../cathermo/testIAPWSPres/testPress.cpp | 18 +++++++++ 3 files changed, 42 insertions(+), 19 deletions(-) diff --git a/test_problems/cathermo/HMW_graph_VvT/output_blessed.txt b/test_problems/cathermo/HMW_graph_VvT/output_blessed.txt index f93d20186..0098a2e23 100644 --- a/test_problems/cathermo/HMW_graph_VvT/output_blessed.txt +++ b/test_problems/cathermo/HMW_graph_VvT/output_blessed.txt @@ -15,25 +15,25 @@ phiV: phiV, calculated from the program, is checked T, Pres, Aphi, A_V, Delta_V0, Delta_Vs, Vex, phiV, MolarV, MolarV0 Kelvin, bar, sqrt(kg/gmol),sqrt(kg/gmol)cm3/gmol,cm**3/gmolSalt,cm**3/gmolSalt,cm**3/gmolSoln,cm**3/gmolSalt,cm**3/gmol, cm**3/gmol - 273.15, 1.01325, 0.376717, 1.5062, -10.3142, -8.58207, 0.15702, 1.73214, 16.4205, 16.2635 - 298.15, 1.01325, 0.391447, 1.87435, -10.3142, -8.1587, 0.19539, 2.15551, 16.5003, 16.3049 - 323.15, 1.01325, 0.410293, 2.37352, -10.3142, -7.58465, 0.24743, 2.72956, 16.6872, 16.4398 - 348.15, 1.01325, 0.433273, 3.06983, -10.3142, -6.78389, 0.32002, 3.53032, 16.9618, 16.6418 - 373.15, 1.01418, 0.460559, 4.05167, -10.3142, -5.65477, 0.42237, 4.65945, 17.3246, 16.9022 - 398.15, 2.32238, 0.492454, 5.4513, -10.3142, -4.04518, 0.56828, 6.26903, 17.7872, 17.2189 - 423.15, 4.76165, 0.529514, 7.48096, -10.3142, -1.71106, 0.77986, 8.60316, 18.3759, 17.596 - 448.15, 8.92602, 0.572549, 10.4889, -10.3142, 1.74806, 1.0934, 12.0623, 19.1351, 18.0417 - 473.15, 15.5493, 0.622769, 15.0764, -10.3142, 7.02378, 1.5717, 17.338, 20.1415, 18.5698 - 498.15, 25.4972, 0.682036, 22.3389, -10.3142, 15.3757, 2.3287, 25.6899, 21.531, 19.2022 - 523.15, 39.7617, 0.753389, 34.4316, -10.3142, 29.2824, 3.5894, 39.5966, 23.5634, 19.974 - 548.15, 59.4639, 0.842213, 56.0339, -10.3142, 54.1252, 5.8413, 64.4394, 26.7856, 20.9443 - 573.15, 85.879, 0.959258, 98.8138, -10.3142, 103.322, 10.301, 113.637, 32.5242, 22.2232 - 598.15, 120.51, 1.13023, 198.467, -10.3142, 217.925, 20.689, 228.239, 44.7424, 24.053 - 623.15, 165.294, 1.43872, 494.888, -10.3142, 558.811, 51.59, 569.125, 78.7661, 27.1758 - 323.15, 1.01325, 0.410293, 2.37352, -10.3142, -7.58465, 0.24743, 2.72956, 16.6872, 16.4398 + 273.15, 1.01325, 0.376717, 1.50615, -10.3142, -8.58213, 0.15701, 1.73208, 16.4205, 16.2635 + 298.15, 1.01325, 0.391447, 1.87431, -10.3142, -8.15874, 0.19539, 2.15547, 16.5002, 16.3049 + 323.15, 1.01325, 0.410293, 2.37345, -10.3142, -7.58473, 0.24742, 2.72949, 16.6872, 16.4398 + 348.15, 1.01325, 0.433273, 3.06975, -10.3142, -6.78398, 0.32001, 3.53023, 16.9618, 16.6418 + 373.15, 1.01418, 0.460559, 4.05157, -10.3142, -5.65488, 0.42236, 4.65934, 17.3246, 16.9022 + 398.15, 2.32238, 0.492454, 5.45118, -10.3142, -4.04532, 0.56826, 6.26889, 17.7872, 17.2189 + 423.15, 4.76165, 0.529514, 7.4808, -10.3142, -1.71124, 0.77985, 8.60297, 18.3759, 17.596 + 448.15, 8.92602, 0.572549, 10.4889, -10.3142, 1.74814, 1.0934, 12.0624, 19.1352, 18.0417 + 473.15, 15.5493, 0.622769, 15.0761, -10.3142, 7.02345, 1.5716, 17.3377, 20.1414, 18.5698 + 498.15, 25.4972, 0.682036, 22.3385, -10.3142, 15.3752, 2.3287, 25.6894, 21.5309, 19.2022 + 523.15, 39.7617, 0.753389, 34.431, -10.3142, 29.2817, 3.5893, 39.5959, 23.5633, 19.974 + 548.15, 59.4639, 0.842213, 56.0329, -10.3142, 54.124, 5.8412, 64.4382, 26.7855, 20.9443 + 573.15, 85.879, 0.959258, 98.8122, -10.3142, 103.321, 10.301, 113.635, 32.524, 22.2232 + 598.15, 120.51, 1.13023, 198.465, -10.3142, 217.922, 20.689, 228.237, 44.7422, 24.053 + 623.15, 165.294, 1.43872, 494.917, -10.3142, 558.844, 51.593, 569.158, 78.7691, 27.1758 + 323.15, 1.01325, 0.410293, 2.37345, -10.3142, -7.58473, 0.24742, 2.72949, 16.6872, 16.4398 Breakdown of Volume Calculation at 323.15 K, 1atm: Species MoleFrac Molal V0 partV (partV - V0) - H2O(L) 0.818703 0 18.2334 18.1515 -0.0819526 - Na+ 0.0906484 6.146 8.34 10.0749 1.73486 - Cl- 0.0906484 6.146 8.34 10.0749 1.73486 + H2O(L) 0.818703 0 18.2334 18.1515 -0.0819503 + Na+ 0.0906484 6.146 8.34 10.0748 1.73482 + Cl- 0.0906484 6.146 8.34 10.0748 1.73482 NaCl(s) 1 26.9942 26.9942 0 diff --git a/test_problems/cathermo/testIAPWSPres/output_blessed.txt b/test_problems/cathermo/testIAPWSPres/output_blessed.txt index d60ad14e3..f8c128f3f 100644 --- a/test_problems/cathermo/testIAPWSPres/output_blessed.txt +++ b/test_problems/cathermo/testIAPWSPres/output_blessed.txt @@ -8,7 +8,12 @@ h (liquid) = 0.611782 J/kg dens (gas) = 0.00485458 kg m-3 psat(373.124) = 101324 dens (liquid) = 958.368 kg m-3 +kappa (liquid) = 4.901779037782e-10 kg m-3 +kappa (liquid) = 4.901777340771e-10 kg m-3 dens (gas) = 0.597651 kg m-3 +kappa (gas) = 1.003322591472e-05 kg m-3 +dens (gas) = 0.597043 kg m-3 +kappa (gas) = 1.004308000545e-05 kg m-3 psat_est(273.15) = 611.212 psat_est(314) = 7722.3 psat_est(314) = 7675.46 diff --git a/test_problems/cathermo/testIAPWSPres/testPress.cpp b/test_problems/cathermo/testIAPWSPres/testPress.cpp index 7bcc1eef9..29d6a9fcf 100644 --- a/test_problems/cathermo/testIAPWSPres/testPress.cpp +++ b/test_problems/cathermo/testIAPWSPres/testPress.cpp @@ -60,9 +60,27 @@ int main () { dens = water->density(T, pres, WATER_LIQUID); printf("dens (liquid) = %g kg m-3\n", dens); + double kappa = water->isothermalCompressibility(); + printf("kappa (liquid) = %20.13g kg m-3 \n", kappa); + + double pres2 = pres * 1.001; + dens = water->density(T, pres2, WATER_LIQUID); + kappa = water->isothermalCompressibility(); + printf("kappa (liquid) = %20.13g kg m-3 \n", kappa); + dens = water->density(T, pres, WATER_GAS); printf("dens (gas) = %g kg m-3\n", dens); + kappa = water->isothermalCompressibility(); + printf("kappa (gas) = %20.13g kg m-3 \n", kappa); + + pres2 = pres * (0.999); + dens = water->density(T, pres2, WATER_GAS); + printf("dens (gas) = %g kg m-3\n", dens); + + kappa = water->isothermalCompressibility(); + printf("kappa (gas) = %20.13g kg m-3 \n", kappa); + /* * Calculate a few test points for the estimated * saturation pressure function