pH error in OSRT

36 views
Skip to first unread message

Won Woo Yoon

unread,
Nov 25, 2025, 8:25:49 PM11/25/25
to pflotran-users
Hi all,

Currently I'm developing an AI surrogate model for the reaction part of RTM using PFLOTRAN. In the process, I identified an issue with the OSRT mode.

The system is a simple 1D transport problem involving uranium and a single exchange site. I observed that the system's pH could not exceed 7.0 during the simulation, even when I set the initial and boundary condition pH to over 10. Under the exact same condition using GIRT, the model correctly simulated the pH above 7.0.

I suspect this is due to the total concentration masking logic within RStep() in reaction.F90. The code appears to clamp total concentration lower than 1e-40 to 1e-40. Therefore, when the pH is high enough to result in a negative Total H+, it is reset to 1e-40, causing a loss of information regarding Total H+. I was able to obtain the correct pH range after I disabled the line 'rt_auxvar%total(i,1) = 1.d-40'.

I suspect a similar issue might occur for O2(aq), though I have not verified this. 

Input and database I used are attached.

I would greatly appreciate any further discussion to solve this problem.

Best regards,

Won Woo Yoon

PFLOTRAN_O2_ThermoChimie_v12a.dat
test.in

Hammond, Glenn E

unread,
Dec 4, 2025, 11:40:33 AM12/4/25
to pflotra...@googlegroups.com
Won Woo,

Thank you for reporting this issue. I will work on resolving it over the coming weeks. It may take some time.

Glenn

From: pflotra...@googlegroups.com <pflotra...@googlegroups.com> on behalf of Won Woo Yoon <yys...@yonsei.ac.kr>
Date: Tuesday, November 25, 2025 at 5:26 PM
To: pflotran-users <pflotra...@googlegroups.com>
Subject: [pflotran-users: 8622] pH error in OSRT

Check twice before you click! This email originated from outside PNNL.
--
You received this message because you are subscribed to the Google Groups "pflotran-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to pflotran-user...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/pflotran-users/48c76990-bb54-43b1-aec3-2b7d155977ecn%40googlegroups.com.

Won Woo Yoon

unread,
Feb 20, 2026, 1:47:03 AM (7 days ago) Feb 20
to pflotra...@googlegroups.com
Dear Glenn,

I was wondering if there has been any progress or updates on this issue since.

Best regards,

Won Woo Yoon

2025년 12월 5일 (금) AM 1:40, 'Hammond, Glenn E' via pflotran-users <pflotra...@googlegroups.com>님이 작성:

Hammond, Glenn E

unread,
Feb 23, 2026, 8:28:13 PM (3 days ago) Feb 23
to pflotra...@googlegroups.com
Won Woo,

I apologize for responding earlier. You are correct that the truncation is incorrect for total component concentrations that can fall below zero. This was a significant error on my part. I have since modified the code to allow for negative totals for primary species with negative stoichiometric contributions to secondary aqueous complexes. 


Please pull the latest source code and see if that resolve the issue.

Regards,

Glenn

Reply all
Reply to author
Forward
0 new messages