Geochemistry¶
Geochemistry adds aqueous speciation, acid-base reactions and configured mineral dissolution/precipitation to the compositional and microbial models. It is a cell-local chemical calculation, coupled to MRST’s reservoir transport. It is not a replacement for the Compositional model or an additional copy of its reaction sources.
H2sim uses PHREEQC with the bundled h2_biogeochemistry.dat database.
The selected inventory, redox bookkeeping and activity model define the
chemical problem. The storage examples and backend comparisons are on
PHREEQC coupling. The published compositional/biochemical starting point is
[AAC+25]; the PHREEQC framework and a related UHS
coupling approach are described in [PA99, SGW+25].
Aqueous mass action and activities¶
For an equilibrium reaction \(r\) written with signed species coefficients \(\nu_{sr}\), mass action requires
\(m_s\) is aqueous molality in mol/kg water, \(m^\circ=1\ \mathrm{mol/kgw}\) is the standard molality, and \(\gamma_s\) is the activity coefficient from the selected database/activity formulation. Activity is dimensionless. Water activity is treated according to that formulation, rather than being identified with a solute molality.
Representative equilibria are
These reactions redistribute an analytical total among species. For example, dissolved inorganic carbon is not just free CO2:
The hydrogen-ion activity defines \(\mathrm{pH}=-\log_{10}a_{\mathrm{H^+}}\). Changing pH changes substrate availability and sulfide speciation, even when the corresponding analytical total is unchanged.
Element and charge bookkeeping¶
Let \(W\) be the cell’s liquid-water mass in kg, \(A_{es}\) the amount of element \(e\) in species \(s\), and \(n_m,n_g\) mineral and gas amounts in mol. A closed local equilibrium calculation redistributes a fixed elemental inventory:
Gas terms apply only when that local chemistry workflow exchanges gas; prescribed open reservoirs or kinetic transfers need their corresponding inventory terms. Ionic charge is
where \(z_s^{\mathrm{ion}}\) is ionic charge, not overall
composition. Electroneutral input has \(q_{\mathrm{aq}}=0\);
the PHREEQC input determines whether a component or pH is adjusted to
enforce that condition. The current coupling builders write a prescribed
initial pH with #charge commented out. They must not be interpreted
as automatically charge-balancing the initial solution by adjusting pH.
The transported analytical totals and PHREEQC’s selected outputs provide
the basis for element/charge diagnostics.
Mineral equilibrium¶
For mineral \(m\), the saturation index is
\(\mathrm{IAP}_m\) is the ion-activity product of the dissolution reaction and \(K_m\) its equilibrium constant. A present equilibrium mineral at a zero target saturation index has \(SI_m=0\). A finite mineral inventory can be exhausted; equilibrium does not provide an unlimited source of carbon, sulfate or cations. Whether precipitation is permitted is controlled by the phase definition and coupling input.
Examples of dissolution reactions are
Calcite and dolomite can buffer inorganic carbon and pH. Anhydrite can replenish sulfate used by SRB. The mineral assemblage and initial amounts are case inputs, not a universal sandstone composition. Equilibrium phases are distinct from the optional kinetic anhydrite source in the reduced microbial model.
Cell-local PHREEQC kinetics¶
The compositional PHREEQC backend expresses microbial rates on a water-mass basis. With kinetic biomass amount \(B_j\), a double-Monod form is
\(B_j\) is mol of kinetic biomass per kg water, \(Y_j\) is mol biomass per mol consumed H2 and \(r_{\mathrm{H_2},j}^{w}\) is \(\mathrm{mol\ H_2/(kgw\,s)}\). The implemented kinetic blocks use dissolved H2 molality and total carbonate(4) for MET/ACE; the SRB co-substrate factor uses the free sulfate-species molality. Temperature, pH and total dissolved solids modify growth through population-specific response functions. Biomass caps and substrate inventories also constrain the update.
These concentration and biomass bases differ from the Biochemistry. Substituting a mole-fraction half-saturation constant into a molality law, or transferring a yield without its population conversion, changes the model.
What each coupling workflow exchanges¶
Workflow |
Microbial reactions |
Local gas-liquid treatment |
|---|---|---|
Compositional PHREEQC |
PHREEQC |
Fixed-volume PHREEQC gas phase repartitions passed volatile totals; the reservoir state is subsequently reconstructed with the EOS |
Multirate PHREEQC |
H2sim bounded local kinetics between coarse flow steps |
Aqueous/mineral equilibrium only, without |
In the compositional kinetic call, volatile inventories include the passed gas and dissolved shares, normalized per kg water. It is incorrect to describe that local calculation as aqueous-only. In the multirate equilibrium call, only the dissolved CO2 and H2S shares contribute to the aqueous carbon and sulfide handoff. H2, CH4 and N2 are not exchanged with PHREEQC in that equilibrium call. Keeping the multirate call aqueous-only avoids repeatedly repartitioning gas with two competing phase models and spuriously driving mineral dissolution.
The update is a local map of transported/ reacted fluid state, aqueous totals and mineral amounts:
The map adds no second microbial source when it is an equilibrium-only call. Discretization and coupling specifies the ordering of flow, kinetics, equilibrium and multirate substeps.
Implementation and limits¶
runSequentialCompositionalPhreeqcCoupling: kinetic blocks, unit-water basis, volatile gas handoff and selected outputs.
runSequentialH2BiochemPhreeqcEquilibrium: aqueous-only equilibrium, mineral inventory and feedback.
h2_biogeochemistry.dat: species, equilibrium constants and activity parameters.
Local element audits and reservoir inventory checks are necessary: nonlinear convergence of flow is not evidence that the chemical handoff conserves every element. The recorded PHREEQC coupling comparisons retain their measured audit failures and splitting limitations. Neither mineral speciation nor a porosity modifier alone constitutes a coupled geomechanical model.