Skip to content

feat: Plug in HPCReact Activity Model - #4140

Open
frankfeifan wants to merge 19 commits into
developfrom
feat/frankfei/activityModelAPI
Open

feat: Plug in HPCReact Activity Model#4140
frankfeifan wants to merge 19 commits into
developfrom
feat/frankfei/activityModelAPI

Conversation

@frankfeifan

Copy link
Copy Markdown
Contributor

This PR makes GEOS able to run reactive transport with geochemical activity models available in HPCReact.

Specific changes include:

  • Plugged the HPCReact activity-model layer into GEOS: added ReactiveFluidSystemSelector.hpp, which dispatches nine chemical-system plus activity-model combinations, and exposed activityModelType (identity / bdot) as an optional XML attribute on the reactive fluid model.

  • Extended the HPCReact systems for non-identity activity: added B-dot and speciated ionic-strength parameters drawn from the EQ3/6 database, replaced the ultramafic stoichiometry with a no-solid 21x20 matrix, and made enforceEquilibrium_Aggregate return both its convergence state and the converged secondary concentrations so callers no longer repeat the speciation solve.

  • Fixed the reactive residual norm: the original max(minNormalizer, aggregateMole_n) discarded the sign of negative aggregate moles, normalizing those cells by minNormalizer (1e-12) and inflating the species residual, which eventually makes the Newton hard to converge. Now using abs(aggregateMole_n) instead.

  • Added solution scaling to the reactive solver: a scalingForSystemSolution override with a new SolutionScalingKernel and a maxAbsoluteLogConcentrationChange input that bounds the per-iteration change in log primary species concentration.

  • Improved reporting and test coverage: the initial equilibrium enforcement now prints as its own titled log block with a per-region, all-ranks converged status, and B-dot 1D and 2D smoke decks were added as new baselines.

  • Rebaseline

This PR depends on the molality conversion PR (#3996) and activity model PR in HPCReact (GEOS-DEV/HPCReact#17).

@frankfeifan frankfeifan self-assigned this Sep 5, 2026
@frankfeifan frankfeifan added the type: feature New feature or request label Sep 5, 2026
@frankfeifan frankfeifan added the flag: requires rebaseline Requires rebaseline branch in integratedTests label Sep 5, 2026
@frankfeifan frankfeifan added flag: requires updated submodule(s) changes XML input ci: run integrated tests Allows to run the integrated tests in GEOS CI ci: run code coverage enables running of the code coverage CI jobs ci: run device builds Allows to run the device (CUDA/HIP) builds labels Sep 5, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

changes XML input ci: run code coverage enables running of the code coverage CI jobs ci: run device builds Allows to run the device (CUDA/HIP) builds ci: run integrated tests Allows to run the integrated tests in GEOS CI flag: ready for review flag: requires rebaseline Requires rebaseline branch in integratedTests flag: requires updated submodule(s) type: feature New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant