https://mooseframework.inl.gov
Public Member Functions | List of all members
GeochemistryActivityCoefficients Class Referenceabstract

Base class to compute activity coefficients for non-minerals and non-gases (since these species do not have activity coefficients). More...

#include <GeochemistryActivityCoefficients.h>

Inheritance diagram for GeochemistryActivityCoefficients:
[legend]

Public Member Functions

 GeochemistryActivityCoefficients ()
 
bool operator== (const GeochemistryActivityCoefficients &) const
 
virtual void setInternalParameters (Real temperature, const ModelGeochemicalDatabase &mgd, const std::vector< Real > &basis_species_molality, const std::vector< Real > &eqm_species_molality, const std::vector< Real > &kin_species_molality)=0
 Sets internal parameters, such as the ionic strength and Debye-Huckel parameters, prior to computing activity coefficients and activity of water. More...
 
virtual Real waterActivity () const =0
 Computes and returns the activity of water. More...
 
virtual void buildActivityCoefficients (const ModelGeochemicalDatabase &mgd, std::vector< Real > &basis_activity_coef, std::vector< Real > &eqm_activity_coef) const =0
 Compute the activity coefficients and store them in basis_activity_coef and eqm_activity_coef Note: More...
 

Detailed Description

Base class to compute activity coefficients for non-minerals and non-gases (since these species do not have activity coefficients).

Also computes the activity of water.

Definition at line 18 of file GeochemistryActivityCoefficients.h.

Constructor & Destructor Documentation

◆ GeochemistryActivityCoefficients()

GeochemistryActivityCoefficients::GeochemistryActivityCoefficients ( )
inline

Definition at line 21 of file GeochemistryActivityCoefficients.h.

21 {};

Member Function Documentation

◆ buildActivityCoefficients()

virtual void GeochemistryActivityCoefficients::buildActivityCoefficients ( const ModelGeochemicalDatabase mgd,
std::vector< Real > &  basis_activity_coef,
std::vector< Real > &  eqm_activity_coef 
) const
pure virtual

Compute the activity coefficients and store them in basis_activity_coef and eqm_activity_coef Note:

  • you will probably want to call setInternalParameters prior to calling this method
  • the activity coefficient for water (basis species = 0) is not computed since it is meaningless: use getWaterActivity() instead
  • the activity coefficient for any mineral is not computed since minerals do not have activity coefficients
  • the activity coefficient for any gas is not computed since gases do not have activity coefficients Hence, the elements in basis_activity_coef and eqm_activity_coef corresponding to these species will be undefined after this method returns

Implemented in GeochemistryActivityCoefficientsDebyeHuckel.

Referenced by GeochemicalSystem::computeConsistentConfiguration(), and GeochemicalSystem::setSolventMassAndFreeMolalityAndMineralMolesAndSurfacePotsAndKineticMoles().

◆ operator==()

bool GeochemistryActivityCoefficients::operator== ( const GeochemistryActivityCoefficients ) const
inline

Definition at line 23 of file GeochemistryActivityCoefficients.h.

23 { return true; };

◆ setInternalParameters()

virtual void GeochemistryActivityCoefficients::setInternalParameters ( Real  temperature,
const ModelGeochemicalDatabase mgd,
const std::vector< Real > &  basis_species_molality,
const std::vector< Real > &  eqm_species_molality,
const std::vector< Real > &  kin_species_molality 
)
pure virtual

Sets internal parameters, such as the ionic strength and Debye-Huckel parameters, prior to computing activity coefficients and activity of water.

If using a Debye-Huckel activity model, you must ensure the ionic strength calculator (eg, maxIonicStrength) is set appropriately before calling this function.

Parameters
temperaturethe temperature in degC
mgdthe Model Geochemical database
basis_species_molalityMolalities of the basis species in mgd
eqm_species_molalityMolalities of the equilibrium species in mgd
kin_species_molalityMolalities of the kinetic species

Implemented in GeochemistryActivityCoefficientsDebyeHuckel.

Referenced by GeochemicalSystem::computeConsistentConfiguration(), GeochemicalSystem::setSolventMassAndFreeMolalityAndMineralMolesAndSurfacePotsAndKineticMoles(), and GeochemicalSystem::setTemperature().

◆ waterActivity()

virtual Real GeochemistryActivityCoefficients::waterActivity ( ) const
pure virtual

Computes and returns the activity of water.

Note that you will probably want to call setInternalParameters prior to calling this method

Returns
the activity of water

Implemented in GeochemistryActivityCoefficientsDebyeHuckel.

Referenced by GeochemicalSystem::computeRemainingBasisActivities().


The documentation for this class was generated from the following file: