use 58.44 as molar mass of salt

This commit is contained in:
Tor Harald Sandve 2023-05-04 09:48:03 +02:00
parent 46f5558b59
commit 4f3b67fa77
5 changed files with 9 additions and 6 deletions

View File

@ -93,7 +93,7 @@ int main(int argc, char **argv)
if (argc > 6)
rs = atof(argv[6]);
const double MmNaCl = 58e-3; // molar mass of NaCl [kg/mol]
const double MmNaCl = 58.44e-3; // molar mass of NaCl [kg/mol]
// convert to mass fraction
std::vector<double> salinity = {0.0};
if (molality > 0.0)

View File

@ -216,7 +216,7 @@ private:
static Evaluation salinityToMolFrac_(const Evaluation& salinity) {
const Scalar Mw = H2O::molarMass(); /* molecular weight of water [kg/mol] */
const Scalar Ms = 58.8e-3; /* molecular weight of NaCl [kg/mol] */
const Scalar Ms = 58.44e-3; /* molecular weight of NaCl [kg/mol] */
const Evaluation X_NaCl = salinity;
/* salinity: conversion from mass fraction to mol fraction */

View File

@ -79,9 +79,8 @@ public:
static Evaluation molarMass(const Evaluation& salinity)
{
const Scalar M1 = H2O::molarMass();
constexpr Scalar M2 = 58e-3; // molar mass of NaCl [kg/mol]
const Evaluation X2 = salinity; // mass fraction of salt in brine
return M1*M2/(M2 + X2*(M1 - M2));
return M1*mM_salt/(mM_salt + X2*(M1 - mM_salt));
}
/*!
@ -347,6 +346,10 @@ public:
return mu_brine/1000.0; // convert to [Pa s] (todo: check if correct cP->Pa s is times 10...)
}
//Molar mass salt (assumes pure NaCl) [kg/mol]
static constexpr Scalar mM_salt = 58.44e-3;
};
} // namespace Opm

View File

@ -119,7 +119,7 @@ initFromState(const EclipseState& eclState, const Schedule& schedule)
// when we are using the the CO2STORE option
if (eclState.runspec().co2Storage()) {
const Scalar molality = eclState.getTableManager().salinity(); // mol/kg
const Scalar MmNaCl = 58e-3; // molar mass of NaCl [kg/mol]
const Scalar MmNaCl = 58.44e-3; // molar mass of NaCl [kg/mol]
// convert to mass fraction
const Scalar salinity = 1 / ( 1 + 1 / (molality*MmNaCl));
for (unsigned regionIdx = 0; regionIdx < numRegions; ++regionIdx) {

View File

@ -56,7 +56,7 @@ initFromState(const EclipseState& eclState, const Schedule&)
size_t regionIdx = 0;
// Currently we only support constant salinity
const Scalar molality = eclState.getTableManager().salinity(); // mol/kg
const Scalar MmNaCl = 58e-3; // molar mass of NaCl [kg/mol]
const Scalar MmNaCl = 58.44e-3; // molar mass of NaCl [kg/mol]
// convert to mass fraction
salinity_[regionIdx] = 1 / ( 1 + 1 / (molality*MmNaCl));
// set the surface conditions using the STCOND keyword