USER_PUNCH/USER_GRAPH > BASIC functions

Uranium speciation plots

(1/2) > >>

Kaushalye:
Hi friends,

I am using ‘PHREEQC Interactive’ for the first time. I intend to generate uranium speciation plots with varying pH (from pH=3 to pH=9) under the concentrations of Uranium(6)= 89 mM, Ca2+ =3.3 mM, CO32-= 25 mM at 25 oC. I am planning on using thermodynamic date from OECD-NEA database corrected for zero ionic strength with SIT. How to develop this PHREEQC code to generate percentage species distribution vs pH plot? I tried editing a code for Copper speciation in this forum but I keep getting error reports. Your help is much appreciated.

Thanks.

dlparkhurst:
Attached is a script to get you started. Clearly, it is not that easy to do what you want directly with PHREEQC, mainly because of the difficulty in identifying the aqueous species of interest.

The script runs an initial solution to get a list of the uranium species. It then writes a script to scan over pH to a file named pH_scan.pqi. The trick of using an equilibrium phase to add acid or base as necessary is demonstrated in Example 8 of the manual.

Next it uses the list of uranium species to write SELECTED_OUTPUT 2/USER_PUNCH 2 data blocks that will write the results to a file.

Similarly, it writes a USER_GRAPH 2 data block to file that will be used to graph the results.

Once SELECTED_OUTPUT/USER_PUNCH 20, 21, and 22 have been used to as part of the initial solution calculation to write these blocks, they are inactivated.

The generated blocks of code are inserted (INCLUDE$) from the files and the calculations are performed to scan over pH, generate the selected output file, and graph the results.

Hopefully this will help, but it is probably a lot more complicated than you had in mind. Part of the complication is the generality. I tested with llnl.dat, but it should run on your database, although you may have even more aqueous species to deal with.

You should also check out PhreePlot  (https://phreeplot.org/). It is based on PHREEQC, but provides capabilities to create species predominance and other kinds of graphs that are difficult in PHREEQC alone.

Kaushalye:
@dlparkhurst
Thank you for your help on where to start. Really appreciate it.

Chen:
Hi Friends:
 
I am doing speciation diagrams for Uranium. There is one question confusing me for a long long time. It is that, in some range of pH, the tot(U) is never equal to the sum of molar concentrations for all the species. And there is no redox which happened. I have tried different databases with SIT. I didn't make mistakes of units, there is no precipitation and I have no warning no errors message. Could someone please help me to understand ? I put the input as following:

#database  NEA_TDB_phreeqc_December2020
# U C jamais eu de précipité en réel
PHASES
        Fix_H+
        H+ = H+
        log_k  0.0


USER_GRAPH
 -headings pH    UO2+2 UO2OH+ UO2(CO3)3-4 UO2(CO3)2-2 UO2(OH)3- UO2(OH)2  UO2CO3 UO2Cl+ (UO2)2(OH)+3 (UO2)2(OH)2+2 (UO2)2CO3(OH)3- (UO2)3(OH)5+ mu
 -chart_title U_solubility_and_speciation
 -axis_titles pH   Speciation(%)
 -axis_scale x_axis 3 11 1
 -axis_scale y_axis  0 100 10
 -axis_scale sy_axis  0 0.005 0.001

 -connect_simulations true
 -initial_solutions false
 -start
 05 graph_x -la("H+")
# 10 graph_y log10(tot("U"))
 20 graph_y 100*mol("UO2+2")/tot("U")
 30 graph_y 100*mol("UO2OH+")/tot("U")
 40 graph_y 100*mol("UO2(CO3)3-4")/tot("U")
 50 graph_y 100*mol("UO2(CO3)2-2")/tot("U")
 60 graph_y 100*mol("UO2(OH)3-")/tot("U")
 70 graph_y 100*mol("UO2(OH)2")/tot("U")
 80 graph_y 100*mol("UO2CO3")/tot("U")
 90 graph_y 100*mol("UO2Cl+")/tot("U")
 100 graph_y 100*mol("(UO2)2(OH)+3")/tot("U")
 110 graph_y 100*mol("(UO2)2(OH)2+2")/tot("U")
 120 graph_y 100*mol("(UO2)2CO3(OH)3-")/tot("U")
 130 graph_y 100*mol("(UO2)3(OH)5+")/tot("U")
 140 graph_sy mu      #force ionique

-end

SOLUTION 1
-unit mol/kgw
 temp 25
 pH 3
 Na 0.002
 Cl 0.001  charge
 U 1.9e-4
 C 1.0e-3
EQUILIBRIUM_PHASES 1  #par défaut, unité en mol/L
Fix_H+   -3  HCl

end

For the output for example. U(6)=1.9e-4, but check, all the species together is just half of the totality.

U(6)             1.900e-04
   (UO2)2CO3(OH)3-        7.763e-05   7.389e-05    -4.110    -4.131    -0.021
   UO2CO3                 2.271e-05   2.271e-05    -4.644    -4.644     0.000
   (UO2)3(OH)5+           2.521e-06   2.406e-06    -5.598    -5.619    -0.020
   UO2(CO3)2-2            1.651e-06   1.355e-06    -5.782    -5.868    -0.086
   UO2OH+                 1.208e-06   1.149e-06    -5.918    -5.940    -0.021
   UO2+2                  2.489e-07   2.044e-07    -6.604    -6.689    -0.085
   (UO2)4(OH)7+           2.308e-07   2.197e-07    -6.637    -6.658    -0.021
   UO2(OH)2               1.447e-07   1.447e-07    -6.840    -6.840     0.000
   (UO2)2(OH)2+2          1.218e-07   1.002e-07    -6.914    -6.999    -0.085
   (UO2)3(OH)4+2          1.307e-08   1.075e-08    -7.884    -7.969    -0.085
   UO2(CO3)3-4            6.465e-09   2.934e-09    -8.189    -8.533    -0.343
   UO2(OH)3-              1.209e-09   1.149e-09    -8.918    -8.940    -0.022
   (UO2)3O(OH)2(HCO3)+    5.135e-10   4.888e-10    -9.289    -9.311    -0.021
   UO2Cl+                 4.956e-10   4.718e-10    -9.305    -9.326    -0.021
   (UO2)2OH+3             1.300e-10   8.337e-11    -9.886   -10.079    -0.193
   (UO2)3(OH)7-           5.659e-11   5.387e-11   -10.247   -10.269    -0.021
   (UO2)11(CO3)6(OH)12-2   3.532e-13   2.899e-13   -12.452   -12.538    -0.086
   (UO2)3(CO3)6-6         2.171e-13   3.677e-14   -12.663   -13.435    -0.771
   UO2Cl2                 3.953e-14   3.953e-14   -13.403   -13.403     0.000
   UO2(OH)4-2             9.911e-16   8.135e-16   -15.004   -15.090    -0.086
   UO2ClO3+               0.000e+00   0.000e+00   -95.234   -95.234     0.000
     
Thanks.

Leo:

--- Quote from: Chen on June 08, 2021, 12:11:36 PM ---but check, all the species together is just half of the totality.
--- End quote ---

Regarding this: If you consider the stoichiometry (e. g.: 3 mol U in 1 mol (UO2)3(CO3)6-6, whereas 1 mol U in 1 mol UO2CO3), this should add up just fine.

Navigation

[0] Message Index

[#] Next page

Go to full version