# PhreeqcUsers Discussion Forum

## Beginners => PHREEQC basics => Topic started by: Zhaoyang on November 12, 2020, 03:41:39 PM

Title: Question about Fix_pH
Post by: Zhaoyang on November 12, 2020, 03:41:39 PM
Dear all,

I have a question about Fix_pH in the attached example. Why can't I use NaOH to increase pH in here? Is this because Ferric will react with OH-? Any help will be appreciated.

Best regards,
Zhaoyang

Code: [Select]
`DATABASE D:\Program Files\USGS\Phreeqc Interactive 3.6.2-15100\database\phreeqc.datSELECTED_OUTPUT-high_precision trueSOLUTION_MASTER_SPECIESFerric  Ferric+3 0  Ferric   55.847Ferrous  Ferrous+2  0  Ferrous    55.847SOLUTION_SPECIESFerrous+2   = Ferrous+2      log_k     0Ferric+3 = Ferric+3    log_k     0PHASES   Fix_H+   H+ = H+   log_k 0SOLUTION 1units mg/lFerrous  10pH  5Cl  1  chargeEQUILIBRIUM_PHASES 1Fix_H+   -7 HCl    10 # change pHO2(g)      -0.679  10 # = log(20.946/100)    KINETICSIron_remove-steps 1800 in 100 steps   # 900s = 15 min  # 1800 = 30 min-formula Ferrous -1 O2 -0.25 H2O -2.5 Ferric 1 OH 3 H 2-m0 100RATESIron_remove-start10 k_plus1 = 10^-3.2/(60*60*24)  # Converted to seconds20 k_plus2 = 1.2e-11/(60*60*24)  # Converted to seconds30 Lang1 = k_plus1 * tot("Ferrous")               *  10^SI("O2(g)") #40 Lang2 = k_plus2 * tot("Ferrous") / mol("H+")^2 *  10^SI("O2(g)") #50 IF -la("H+") < 4 THEN Lang = Lang1 ELSE Lang = Lang290 moles = Lang * TIME100 save moles-endUSER_GRAPH 1    -headings               time Ferric_(Fe3+) Ferrous_Fe(2+) Amount_of_acid_consumed    -axis_titles            "Time (min)" "Ferric/Ferrous concentration (mg/L)" "Acid/base consumed (micromol)"    -initial_solutions      false    -connect_simulations    true    -plot_concentration_vs  x  -start10 graph_x total_time/6020 graph_y TOT("Ferric")*55.847*1000, TOT("Ferrous")*55.847*100030 graph_sy (10-equi("Fix_H+"))*10^6  -endEND`
Title: Re: Question about Fix_pH
Post by: dlparkhurst on November 12, 2020, 05:54:40 PM
Short answer is that you need to add acid, not base.

With your simplified Ferric/Ferrous definitions, as Ferrous iron is converted to Ferric iron, the reaction is

Ferrous+2 + 1/4O2 + 1/2H2O = Ferric+3 + OH-

Initially, a little base (removal of HCl) is needed to increase the pH from 5 to 7, but ultimately, HCl is added to neutralize the base generated from the oxidation reaction. (Note that the -formula Ferrous -1 Ferric +1 is more appropriate. The H and O of your -formula cancel.)

Formation of Ferric(OH)n aqueous species or Ferric(OH)3 solid, changes the results drastically, in which case, base would be needed to maintain a pH of 7.

Code: [Select]
`SELECTED_OUTPUT-high_precision trueSOLUTION_MASTER_SPECIESFerric  Ferric+3 0  Ferric   55.847Ferrous  Ferrous+2  0  Ferrous    55.847SOLUTION_SPECIESFerrous+2   = Ferrous+2     log_k     0Ferric+3 = Ferric+3    log_k     0PHASES   Fix_H+   H+ = H+   log_k 0SOLUTION 1units mg/lFerrous  10pH  5Cl  1  chargeEQUILIBRIUM_PHASES 1Fix_H+   -7 HCl    10 # change pHO2(g)      -0.679  10 # = log(20.946/100) KINETICSIron_remove-steps 180.0 in 100 steps   # 900s = 15 min  # 1800 = 30 min#-formula Ferrous -1 O2 -0.25 H2O -2.5 Ferric 1 OH 3 H 2-formula Ferrous -1 Ferric 1-m0 100RATESIron_remove-start10 k_plus1 = 10^-3.2/(60*60*24)  # Converted to seconds20 k_plus2 = 1.2e-11/(60*60*24)  # Converted to seconds30 Lang1 = k_plus1 * tot("Ferrous")               *  10^SI("O2(g)") #40 Lang2 = k_plus2 * tot("Ferrous") / mol("H+")^2 *  10^SI("O2(g)") #50 IF -la("H+") < 4 THEN Lang = Lang1 ELSE Lang = Lang290 moles = Lang * TIME100 save moles-endUSER_GRAPH 1    -headings               time Ferric_Fe(3+) Ferrous_Fe(2+) Cl- HCl_added    -axis_titles            "Time (min)" "mol/kg water" "HCl added, moles"    -initial_solutions      true    -connect_simulations    true    -plot_concentration_vs  x  -start10 graph_x total_time/6020 graph_y TOT("Ferric"), TOT("Ferrous"), TOT("Cl")30 graph_sy -EQUI_DELTA("Fix_H+")  -endEND`
Title: Re: Question about Fix_pH
Post by: Zhaoyang on November 12, 2020, 07:27:21 PM
Thanks for your reply. I have another two questions.

One is for the EQUILIBRIUM_PHASES.
Code: [Select]
`EQUILIBRIUM_PHASES 1Fix_H+   -7 HCl    10 # change pHO2(g)      -0.679  10 # = log(20.946/100)`Why can't I seperate them like below?
Code: [Select]
`EQUILIBRIUM_PHASES 1Fix_H+   -7 HCl    10 # change pH`
Code: [Select]
`EQUILIBRIUM_PHASES 2O2(g)      -0.679  10 # = log(20.946/100)`
Another one is about the EQUI_DELTA. I have checked PHREEQC Help. Why can't I get the same plot if replacing graph_sy 10-EQUI("Fix_H+") with graph_sy -EQUI_DELTA("Fix_H+")?