Conceptual Models > Design of conceptual models

Model of Reaction progress with Sulphur concentration

(1/5) > >>

jt2020:
Hello,

I am looking to design a reaction path model with reaction progress (mole of reaction progress) on the x axis and sulphur concentration (mol) on the y axis.

I have previously attempted to model the reaction pathway from mackinawite, to greigite, to the end-member, pyrite. I managed to produce a phase diagram following Example 6 in the manual but when trying to design a pathway it seems that pyrite forms instantly as oppose to following the pathway through the phases

I thought it might show the path better by using reaction progress and sulphur content. I know the latter can be done in Phreeqc but can reaction progress?

Thank you,

Jack

dlparkhurst:
Maybe this will help. Here is a rewrite of example 6 that has the moles of K-feldspar reacted as the X axis. It uses INCREMENTAL_REACTIONS, so the reaction increment at each point (Basic function RXN) needs to be accumulated through the GET/PUT functions to get the total amount of feldspar reacted at each step. If you do not use INCREMENTAL_REACTIONS, then RXN is the total amount added at each step.


--- Code: ---TITLE React K-feldspar
SOLUTION 1  PURE WATER
            pH    7.0 charge
          temp   25.0
PHASES
        Gibbsite
                Al(OH)3 + 3 H+ = Al+3 + 3 H2O
                log_k          8.049
                delta_h        -22.792 kcal
        Kaolinite
                Al2Si2O5(OH)4 + 6 H+ = H2O + 2 H4SiO4 + 2 Al+3
                log_k          5.708
                delta_h        -35.306 kcal
        K-mica
                KAl3Si3O10(OH)2 + 10 H+ = 3 Al+3 + 3 H4SiO4 + K+
                log_k          12.970
                delta_h        -59.377 kcal
        K-feldspar
                KAlSi3O8 + 4 H2O + 4 H+ = Al+3 + 3 H4SiO4 + K+
                log_k          0.875
                delta_h        -12.467 kcal
END
INCREMENTAL_REACTIONS
REACTION
K-feldspar 1
20*1e-8 20*1e-7  20*1e-6  20*1e-5  20*1e-4  20*1e-3  20*1e-2 
USE solution 1
EQUILIBRIUM_PHASES 1
        Gibbsite        0.0     0.0
        Kaolinite       0.0     0.0
        K-mica          0.0     0.0
        K-feldspar      0.0     0.0
USER_GRAPH 1 Simulation 6
    -headings               Log(K/H) Gibbsite Kaolinite K-mica K-feldspar
    -axis_titles            "Feldspar reacted, moles" "Log([K+] / [H+])" "Mineral, moles"
    -chart_title            "K-Feldspar Reaction Path"
    -axis_scale sy_axis     auto auto auto auto log
    -initial_solutions      false
    -connect_simulations    false
    -plot_concentration_vs  x
  -start
 5 PUT(GET(1) + RXN, 1)
  10 PLOT_XY log10(GET(1)),(LA("K+")-LA("H+")), color = Red, line_w = 0, \
  symbol = Circle, symbol_size = 10
  20 PLOT_XY log10(GET(1)), EQUI("Gibbsite") color = Green, line_w = 0, \
  symbol = Plus, symbol_size = 5, y_axis = 2
  30 PLOT_XY log10(GET(1)), EQUI("Kaolinite") color = Blue, line_w = 0, \
  symbol = Plus, symbol_size = 5, y_axis = 2
  40 PLOT_XY log10(GET(1)), EQUI("K-mica") color = Cyan, line_w = 0, \
  symbol = Plus, symbol_size = 5, y_axis = 2
  50 PLOT_XY log10(GET(1)), EQUI("K-feldspar") color = Magenta, line_w = 0, \
  symbol = Plus, symbol_size = 5, y_axis = 2
  -end
    -active                 true
END

--- End code ---

jt2020:
Ah great thank you,

I will give it a go.

Thanks again,

Jack

dlparkhurst:
Here is a fancy version that has evenly spaced log-scale reaction increments.


--- Code: ---PHASES
Gibbsite
    Al(OH)3 + 3H+ = Al+3 + 3H2O
    log_k     8.049
    delta_h   -22.792 kcal
Kaolinite
    Al2Si2O5(OH)4 + 6H+ = 2Al+3 + H2O + 2H4SiO4
    log_k     5.708
    delta_h   -35.306 kcal
K-mica
    KAl3Si3O10(OH)2 + 10H+ = 3Al+3 + 3H4SiO4 + K+
    log_k     12.97
    delta_h   -59.377 kcal
K-feldspar
    KAlSi3O8 + 4H+ + 4H2O = Al+3 + 3H4SiO4 + K+
    log_k     0.875
    delta_h   -12.467 kcal
END
TITLE Simulation 6A.--React to phase boundaries.
SOLUTION 1 PURE WATER
    temp      25
    pH        7 charge
    pe        4
    redox     pe
    units     mmol/kgw
    density   1
    -water    1 # kg
SELECTED_OUTPUT 100
-file increments.pqi
USER_PUNCH 100
10 low = -8
20 up = -3
30 steps = 200
35 size = (up -low)/steps
40 FOR i = low TO up STEP size
50 PUNCH 10^i, EOL$
60 NEXT i
END
SELECTED_OUTPUT 100
-active false
END
REACTION 1
    K-feldspar 1
INCLUDE$ increments.pqi
USE solution 1
EQUILIBRIUM_PHASES 1
    Gibbsite  0 0
    K-feldspar 0 0
    K-mica    0 0
    Kaolinite 0 0
USER_GRAPH 1 Simulation 6
    -headings               Log(K+/H+) Gibbsite Kaolinite K-mica K-feldspar
    -axis_titles            "Feldspar reacted, moles" "Log([K+] / [H+])" "Mineral, moles"
    -chart_title            "K-Feldspar Reaction Path"
    -axis_scale x_axis      -8 -3 auto auto
    -axis_scale sy_axis     1e-9 0.001 auto auto log
    -initial_solutions      false
    -connect_simulations    false
    -plot_concentration_vs  x
  -start
#5 PUT(GET(1) + RXN, 1)
 10 PUT(RXN, 1)
 20 PLOT_XY LOG10(GET(1)), (LA("K+")-LA("H+")), color = red, line_w = 2, symbol = circle, symbol_size = 0
 30 IF EQUI("Gibbsite") > 0 THEN y = EQUI("Gibbsite") ELSE y = 1e-12
 40 PLOT_XY LOG10(GET(1)), y, color = green, line_w = 2, symbol = plus, symbol_size = 0, y_axis = 2
 50 IF EQUI("Kaolinite") > 0 THEN y = EQUI("Kaolinite") ELSE y = 1e-12
 60 PLOT_XY LOG10(GET(1)), y, color = blue, line_w = 2, symbol = plus, symbol_size = 0, y_axis = 2
 70 IF EQUI("K-mica") > 0 THEN y = EQUI("K-mica") ELSE y = 1e-12
 80 PLOT_XY LOG10(GET(1)), y, color = cyan, line_w = 2, symbol = plus, symbol_size = 0, y_axis = 2
 90 IF EQUI("K-feldspar") > 0 THEN y = EQUI("K-feldspar") ELSE y = 1e-12
100 PLOT_XY LOG10(GET(1)), y, color = magenta, line_w = 2, symbol = plus, symbol_size = 0, y_axis = 2
  -end
    -active                 true
END

--- End code ---

jt2020:
Hello again,

Thanks for the log scaled diagram. It looked great and I have got it to work for the mackinawite-pyrite pathway.

I've tried, more recently, to input reactions using elemental S but when trying to run the model there are two errors.

ERROR: Elements in species have not been tabulated, Fe3S4.
ERROR: Reaction for species has not been defined, Fe3S4.
ERROR: Elements in species have not been tabulated, FeS.
ERROR: Reaction for species has not been defined, FeS.
ERROR: Elements in species have not been tabulated, S.
ERROR: Reaction for species has not been defined, S.
ERROR: Calculations terminating due to input errors.

I think that there is something wrong with the database I've used. Im not sure if these reactions are suitable as they show a transformation from the old phase, i.e. mackinawite, to the new phase, i.e. pyrite. Plus, I'm not sure if elemental S is included correctly (I think it needs a '0' next to it).

I have attached the database and input file.

Thanks

Jack



Navigation

[0] Message Index

[#] Next page

Go to full version