19 "Extracts information from the Reactor and records it in the AuxVariable");
21 MooseEnum quantity_choice(
"molal mg_per_kg free_mg free_cm3 neglog10a activity bulk_moles " 22 "surface_charge surface_potential temperature kinetic_moles " 23 "kinetic_additions moles_dumped transported_moles_in_original_basis",
28 "Type of quantity to output. These are available for non-kinetic species: activity (which " 30 "fugacity for gases); bulk moles (this will be zero if the species is not in the basis); " 31 "neglog10a = -log10(activity); transported_moles_in_original_basis (will throw an error if " 32 "species is not in original basis). These are available only for non-kinetic non-minerals: " 34 "mol(species)/kg(solvent_water); mg_per_kg = mg(species)/kg(solvent_water). These are " 35 "available only for minerals: " 36 "free_mg = free mg; free_cm3 = free cubic-centimeters; moles_dumped = moles dumped when " 37 "special dump and flow-through modes are active. These are available for minerals " 38 "that host sorbing sites: surface_charge (C/m^2); surface_potential (V). These are " 39 "available for kinetic species: kinetic_moles; kinetic_additions (-dt * rate = mole " 40 "increment in kinetic species for this timestep). If " 41 "quantity=temperature, then the 'species' is ignored and the AuxVariable will record the " 42 "aqueous solution temperature in degC");
44 "The name of the Geochemistry*Reactor user object.");
51 _species(getParam<
std::string>(
"species")),
54 _surface_sorption_mineral_index(0)
63 " does not appear in the model's geochemical system either as a basis or equilibrium " 64 "or kinetic species, but you requested an Aux involving it");
66 bool is_mineral =
false;
82 "the free_mg, free_cm3, moles_dumped and surface-related quantities are only available for " 87 "the molal and mg_per_kg quantities are only available for " 88 "non-kinetic, non-mineral species");
97 "cannot record surface charge or surface potential for a species that is not " 98 "involved in surface sorption");
103 "the kinetic_moles and kinetic_additions quantities are only available for kinetic " 108 paramError(
"species",
"cannot record activity, neglog10a or bulk_moles for a kinetic species");
std::vector< Real > eqm_species_molecular_weight
all quantities have a molecular weight (g)
Real getTemperature() const
std::vector< bool > kin_species_mineral
kin_species_mineral[j] = true iff the j^th kinetic species is a mineral
AuxKernel to extract information from a Geochemistry*Reactor to record into an AuxVariable.
unsigned getIndexOfOriginalBasisSpecies(const std::string &name) const
std::vector< std::string > surface_sorption_name
surface_sorption_name[k] = name of the mineral involved in surface sorption.
GeochemistryQuantityAux(const InputParameters ¶meters)
const std::vector< Real > & getBulkMolesOld() const
registerMooseObject("GeochemistryApp", GeochemistryQuantityAux)
const std::string & _species
The species of interest.
std::unordered_map< std::string, unsigned > basis_species_index
basis_species_index[name] = index of the basis species, within all ModelGeochemicalDatabase internal ...
const Node *const & _current_node
const ModelGeochemicalDatabase mgd
std::vector< Real > kin_species_molecular_weight
all quantities have a molecular weight (g/mol)
std::vector< Real > kin_species_molecular_volume
all quantities have a molecular volume (cm^3/mol) (only nonzero for minerals, however) ...
const GeochemistryReactorBase & _reactor
std::unordered_map< std::string, unsigned > eqm_species_index
eqm_species_index[name] = index of the equilibrium species (secondary aqueous species, redox couples in equilibrium with the aqueous solution, minerals in equilibrium with the aqueous solution, gases in equilibrium with the aqueous solution) within all ModelGeochemicalDatabase internal datastrcutres, with given name
unsigned getNumInBasis() const
returns the number of species in the basis
std::unordered_map< std::string, unsigned > kin_species_index
kin_species_index[name] = index of the kinetic species, within all ModelGeochemicalDatabase internal ...
Real getBasisActivity(unsigned i) const
Real getEquilibriumActivity(unsigned eqm_ind) const
Returns the value of activity for the equilibrium species with index eqm_index.
const ModelGeochemicalDatabase & modelGeochemicalDatabase() const
Return a reference to the ModelGeochemicalDatabase structure.
virtual const GeochemicalSystem & getGeochemicalSystem(dof_id_type node_id) const =0
Real getKineticMoles(unsigned kin) const
virtual Real getMolesDumped(dof_id_type node_id, const std::string &species) const =0
Constructs and stores a minimal amount of information that is pertinent to the user-defined geochemic...
const ModelGeochemicalDatabase & getModelGeochemicalDatabase() const
virtual const DenseVector< Real > & getMoleAdditions(dof_id_type node_id) const =0
void paramError(const std::string ¶m, Args... args) const
unsigned _surface_sorption_mineral_index
index into mgd.surface_sorption_name corresponding to the species: this is used if quantity is surfac...
std::vector< Real > basis_species_molecular_weight
all quantities have a molecular weight (g)
enum GeochemistryQuantityAux::QuantityChoiceEnum _quantity_choice
DIE A HORRIBLE DEATH HERE typedef LIBMESH_DEFAULT_SCALAR_TYPE Real
Real getSurfacePotential(unsigned sp) const
std::vector< Real > eqm_species_molecular_volume
all quantities have a molecular volume (cm^3) (only nonzero for minerals, however) ...
Real getEquilibriumMolality(unsigned j) const
This class holds information about bulk composition, molalities, activities, activity coefficients...
virtual Real computeValue() override
std::vector< bool > basis_species_mineral
basis_species_mineral[j] = true iff the j^th basis species is a mineral
Data structure to hold all relevant information from the database file.
static InputParameters validParams()
std::vector< bool > eqm_species_mineral
eqm_species_mineral[i] = true iff the i^th equilibrium species is a mineral
std::vector< Real > basis_species_molecular_volume
all quantities have a molecular volume (cm^3) (only nonzero for minerals, however) ...
const std::vector< Real > & getSolventMassAndFreeMolalityAndMineralMoles() const
DenseVector< Real > getTransportedBulkInOriginalBasis() const
Base class that controls the spatio-temporal solution of geochemistry reactions.
static InputParameters validParams()
Real getSurfaceCharge(unsigned sp) const
const PertinentGeochemicalSystem & getPertinentGeochemicalSystem() const
returns a reference to the PertinentGeochemicalSystem used to creat the ModelGeochemicalDatabase ...