Sie sind auf Seite 1von 10

WATEQ4F, Version 4.

00
Release date: 1/4/2012
Significant changes in Upgrade 4.00
Modified the code to calculate the electrical conductivity of the water sample at 25C. The
output (*.out and *.EQP) reports the calculated conductivity and the conductivity imbalance
(SCI).
100
The electrical conductivity is calculated using the method of McCleskey and other (2011). The
method is based on new measurements reported by McCleskey (2011).

Easy installation of WATEQ4F on your hard disk:


Create a new folder on your hard drive (Wateq4f suggested).
Double-click on the Wq4f_Installer.exe icon to start the self-extracting process.
Click on Open, then click on Browse, select the new folder, and click on OK.
Finally, click on Unzip. Installation will complete without further intervention.
You can alternatively save the Wq4f_Installer.exe file to your local computer and run it from
there, using the steps above.
Executing WATEQ4F
The preferred method for executing WATEQ4F is to open a DOS command prompt window, log
in to the drive and directory containing the wateq4f software, type WATEQ4F, and press Enter.
Alternatively, you may simply double-click on the WATEQ4F.EXE icon, but be advised that the
window will close immediately at the conclusion of WATEQ4F execution, so if there is an error
message you will not be able to read it. WATEQ4F will prompt you for the names of your input
and output files. To test program operation, specify input file name TstCases.csv. NOTE: You
must have available an input file of water analysis data before beginning execution of
WATEQ4F.
Creating WATEQ4F Input Files
NOTES:
1. Refer to the comments in the headers (row 1) of the TSTCASES.XLS file for information
and instructions for many of the parameters.
2. Since the input file is a comma-separated values (CSV) file and the spreadsheetcompatible output file is a tab-separated file, NO commas or tabs are allowed anywhere
in the input data.
3. The number of rows of water analysis data is subject only to spreadsheet and computer
storage limitations.
To create an input file of water analysis data, use the following procedure:

1. Open the Excel spreadsheet file TSTCASES.XLS.


2. Starting with row 2, substitute your analytical values and modeling parameters in the
columns indicated by the headers (row 1), one spreadsheet row per water analysis. A
value MUST be entered in every cell, even if it is zero. With the exception of
columns A, B, and C, all values must be numeric.
3. Leave a cell containing four asterisks in column 1 of the next row following your
data.
4. Using a new file name, save the spreadsheet as a Microsoft Excel workbook.
5. Create a file readable by WATEQ4F as follows:
a. Select File, Save As.
b. Select CSV (MS-DOS) (*.csv) format.
c. Excel will offer a file name. You may either accept it or enter a different
filename (8-character file name format, no spaces! Do NOT enter the .csv Excel automatically appends the file name extension).
d. Click Save.
e. Prior to saving the csv file, Excel warns you that you will lose other
worksheets and formatting features; answer Yes to all of the questions.
f. When you close the file, Excel will ask you if you want to save your changes.
If you followed this step and Step 4, you will have already saved an Excel
workbook version and a csv version of this data, so you can answer No to
this query.
Working With WATEQ4F Output Using a Spreadsheet Program
If the PUNCH parameter is set to 0, WATEQ4F will create a tab-separated output file suitable
for importing to a spreadsheet such as Microsoft Excel. To import this file into Excel:
1. Select Open and select the output file (with extension .eqp) that was created.
2. In the first window, select Delimited if necessary and click Next.
3. In the next window, ensure that Tab is selected, and click Finish.
4. The opened file will be displayed.
You can modify the identity and order of the minerals, dissolved species activities, and dissolved
component concentrations written to the semicolon-separated output file by editing the
MINERALS, ACTIVITY, and CONCENTR input files, respectively. All 322 minerals and 377
dissolved species are present in the respective files, one species per line. WATEQ4F will stop
reading values when it encounters the record 9999 EOF. To add a species to the section of the
file that WATEQ4F will read, move the line containing the species above the 9999 EOF
record. To remove a species, move its line below the 9999 EOF record. When done, save the
file in plain text format. Please be advised that, by computer code limitation, maximums of
250 mineral species, 250 dissolved species, and 100 dissolved components can be selected for
writing to the *.EQP file. In addition, Microsoft Excel limits the sum of hard-coded parameters
(19), minerals, dissolved species activities, and dissolved components that can be read into a
spreadsheet to 256, so if you want to add species whose sum exceeds 237 you will have to
choose some to delete.
Questions/Problems? Contact:
Blaine McCleskey, USGS/WRD, 3215 Marine Street, Boulder, CO 80303-1066 USA
303-541-3079; rbmccles@usgs.gov

OPEN-FILE REPORT
OF THE UNITED STATES GEOLOGICAL SURVEY
User's manual for WATEQ4F, with revised thermodynamic data base
and test cases for calculating speciation of major,
trace, and redox elements in natural waters
By James W. Ball and D. Kirk Nordstrom
Open-File Report 91-183
U.S. Geological Survey
July, 1991
****************************************
DEPARTMENT OF THE INTERIOR
MANUEL LUJAN JR., Secretary
U. S. Geological Survey
Dallas L. Peck, Director
****************************************

===============
VERSION HISTORY
===============
See the extensive comment section at the beginning of the WATEQ4F source code for
complete details of software modifications.
******************************************************************************
March, 1991: Version 2.00 Upgrade of WATEQ4F includes selenium and uranium species,
coupled redox reactions, and data base compatible with that of Nordstrom and others (1990).
Open-File Report 91-183 published July, 1991, describing Version 2.00.
******************************************************************************
October, 1991: Version 2.10 Upgrade of WATEQ4F corrects several errors in the Version 2.00
code.
******************************************************************************

September, 1992: Version 2.20 Upgrade of WATEQ4F includes interactive specifying of input
and output file names, and free-format input of individual lines of water analysis input data.
Compiler changed to Lahey F77L.
******************************************************************************
September, 1993: Version 2.21 Upgrade of WATEQ4F corrects a few minor errors in the source
code and modifies the code slightly to make it a bit more robust.
******************************************************************************
August, 1994: Version 2.22 Upgrade of WATEQ4F corrects errors in the activity product
calculations for 7 minor minerals.
******************************************************************************
September, 1995: Version 2.30 Upgrade of WATEQ4F adds
1. Capability for WATEQ4F to execute from a network (non-writable) drive. This modification
consists of querying the user for a default path to which writing to disk is permitted. Code was
added at all places where writing to disk is possible, to specify the path of a writable disk and
directory.
2. A check for existence of the user's input water analysis data file in the writable path.
******************************************************************************
May, 1998: Version 2.31 Upgrade of WATEQ4F adds calculation and printing of input versus
calculated conductance imbalance.
******************************************************************************
November, 1999: Version 2.40 Upgrade of WATEQ4F adds modification of subroutine INPUT
to read data saved from an Excel spreadsheet in comma-separated format. A specific spreadsheet
format is required, and data items must be in a specific order (See Creating WATEQ4F Input
Files above).
December, 1999: Changed Log K and delta H for jarosite, reaction 205, per Baron and Palmer
(1996, GCA 60[185]) as follows:
Log K from -9.21 1.1 to -11.0 0.3; delta H from -31.28 to -45.0
(Modifications needed for TABLE2 only)
January, 2000: Added analytical expression for Log K for BaSO4(aq), reaction 543, per Monnin
(1999, Chem Geol 153[187]) as follows:
Log K = 2.8243-166.629/T; at 298.15K: log K = 2.265, delta H = 0.762 kcal mol-1
******************************************************************************

March, 2000: Version 2.41 Upgrade of WATEQ4F adds modification of subroutine OUTPCH to
generate a file of semicolon-separated plotting parameters suitable for opening by Microsoft
Excel. Removed output of log AP values for minerals, to decrease the size of the file so that it
could be accommodated by Excel's maximum of 230 columns.
******************************************************************************
July, 2000: Version 2.42 Upgrade of WATEQ4F adds total and speciated ionic strength to the
Excel output file.
******************************************************************************
January, 2001: Version 2.43 Upgrade of WATEQ4F adds capability to read and discard an initial
data record from the input file. This allows leaving the header record in the .CSV file for easier
subsequent data modifications.
Added equivalents per million cations and equivalents per million anions to the Excel output file.
******************************************************************************
August, 2002: Version 2.44 Upgrade of WATEQ4F adds revision of thermodynamic data for
arsenic hydrolysis species and oxide and sulfide minerals, and addition of two new aqueous
thioarsenite species and the mineral phase amorphous orpiment, per Nordstrom and Archer
(2002). Source code was modified to add calculations for the three new species and modify the
stoichiometry for the arsenolite and claudetite activity product calculations.
Removed capability for WATEQ4F to execute from a network (non-writable) drive. WATEQ4F
now reads from and writes to only the drive and directory from which it is executed.
Changed the name of the default input file to WATEQ4F.CSV from WATEQ4F.DAT.
Changed output to the spreadsheet-compatible file to output trace elements in milligrams per
liter, rather than micrograms per liter, to be consistent with other output data.
******************************************************************************
October, 2002: Version 2.45 and 2.46 Upgrades of WATEQ4F add the capability to specify,
external to the computer code, the list of minerals, dissolved species activities, and dissolved
component concentrations written to the spreadsheet-compatible output file. Modify input files
TABLE5, TABLE6, and TABLE7, respectively, to specify the lists.
******************************************************************************
April, 2003: Version 2.47 and 2.48 Upgrades of WATEQ4F update thermodynamic data for
kAs/As3, As2O5 (Nordstrom and Archer, 2002), AlSO4+, and Al(SO4)2 - (Nordstrom et al,

1990) species. Adds microcrystalline gibbsite mineral species (index #651). Removes duplicate
input of DOC from the input data. NOTE that earlier datasets are NOT compatible.
******************************************************************************
July, 2003: Version 2.49 Upgrade to WATEQ4F restores the '****' end-of-file flag to correctly
terminate execution when reading the .CSV file. WATEQ4F otherwise continued reading blank
records. Adds code to trap and fix lowercase concentration units input. Program now accepts
'mg/l', 'mg/L', 'ppm', 'mmol', and 'mol' units on input. Fixes a minor error in OUTPCH, wherein
values tested for writing to the spreadsheet compatible output file had to be greater than -100.
Values now must be greater than -1000. This error caused charge and conductance imbalances
less than -100 to be discarded.
******************************************************************************
August, 2003: Version 2.60 Upgrade to WATEQ4F uses a new compiler, Lahey/Fujitsu Fortran
95 Express, Version 5.7. The delimiter for the spreadsheet output file has been changed to a TAB
from a semicolon; this facilitates reading the file into Excel. The maximum number of aqueous
complexes or mineral species that can be chosen for the spreadsheet output file has been
increased to 250 (the Excel limitation of 237 still applies, however). A Y2K-compatible date and
time function has been implemented. Several minor errors were corrected. V was being input and
output as Hg it is now V. The character string containing the sample description has been
lengthened to allow the sample collection date to be appended to it.
******************************************************************************
October, 2003: Version 2.61 Upgrade to WATEQ4F removes the H4AsO4+ species from the
aqueous speciation calculations. The species is now thought not to exist.
******************************************************************************
December, 2003: Version 2.62 Upgrade to WATEQ4F significantly revises the spreadsheet
output features.
******************************************************************************
May, 2004: Version 2.63 Upgrade to WATEQ4F adds the version number and execution date
and time to the top of the printed output file.
******************************************************************************
WATEQ4F, VERSION 3.00
1. Added subroutine CHROME to include Cr speciation in the model.
2. Added Cr mineral species to the model
******************************************************************************

WATEQ4F, VERSION 3.01


1. Removed uranium silicate aqueous species from the model.
2. Added microcrystalline gibbsite mineral species to the model (index #708).
******************************************************************************
WATEQ4F, VERSION 3.
1. Updated thermodynamic data for AlSO4+, Al(SO4)2 -, and BaSO4 aq species per Nordstrom
et al (1990).
2. Removed duplicate input of DOC from the input data.
******************************************************************************
WATEQ4F, VERSION 3.03
1. Revised thermodynamic data (Table2 only) for the following As species, based on Nordstrom
and Archer (2002):
# Species
log K del-H
=================================
557 kAs3/As
12.532 -27.517
488 As2O5
8.228 -7.557
2. Corrected errors in MAIN program and SUMS. Test of PRNT parameter before calling
RATIO was incorrect
Two U+4-CO3 species were missing from distribution of carbonate species calculations in
SUMS
******************************************************************************
WATEQ4F, VERSION 3.04
1. Corrected minor error in PREP: increased size of DO loop initializing EH and PE from 14 to
15.
******************************************************************************
WATEQ4F, VERSION 3.
1. Restored the '****' end-of-file flag to correctly terminate execution when reading the .CSV
file WATEQ4F otherwise continued reading blank records.
2. Added code to trap and fix lowercase concentration units input. Program now accepts 'mg/l',
'ppm, mmol', and 'mol' units on input
******************************************************************************
WATEQ4F, VERSION 3.10
1. Changed compiler to Lahey/Fujitsu Fortran 95
2. In subroutine SOLUTS, substituted Y2K-compatible function DATE_AND_TIME to acquire

the computer's current date and time


3. In subroutine OUTPCH, increased array bounds for specifying aqueous species and minerals
to 250.
4. Deleted Hg from miscellaneous trace metals output and substituted V, since V is in the input
file.
4. Changed delimiter for spreadsheet output to tab from semicolon
******************************************************************************
WATEQ4F, VERSION 3.11
1. Corrected error in TABLE5--wrong reference number for microcrystalline gibbsite was
entered
2. Added output of pe calculated from Cr+3 and Cr+ activities to the spreadsheet output file.
3. Added output of 3 Cr-containing minerals, Cr(OH)3 (cr), Cr(OH)3 (am), and BaCrO4, to
minerals in TABLE5
******************************************************************************
WATEQ4F, VERSION 3.12
1. Removed H4AsO3 from As speciation calculations.
******************************************************************************
WATEQ4F, VERSION 3.13
1. Significant reorganization of spreadsheet features.
A) Revised to read lists only once per execution.
B) Collected all "miscellaneous" parameters to be written to front of parameter set.
C) Renamed TABLEs 5, 6, and 7 to the more explanatory MINERALS, ACTIVITY, and
CONCENTR, respectively.
D) Added query to user to choose disposition of pre-existing spreadsheet file. User can choose to
(O)verwrite, (R)ename, or (A)ppend to, the file.
E) Added an additional line to the spreadsheet file to label the three major groups of output
parameters: Log activities of aqueous species, Log AP/Ks of minerals, and log concentrations
of dissolved components.
******************************************************************************
WATEQ4F, VERSION 3.14
1. Significant revision of aqueous speciation printing and master species percentage calculations
A) Revised aqueous speciation printing to print complete lists of species grouped by anionic
master species for CO3, F, PO4, S=, and SO4.
B) Revised percent of master species calculations to correctly account for all polynuclear metal
and ligand species
******************************************************************************

WATEQ4F, VERSION 3.15


1. Minor revision of aqueous speciation printing and spreadsheet output.
A) Revised aqueous speciation printing to replace 'CO2 Tot' with 'DIC Tot' (dissolved inorganic
carbon).
B) Added 'Log DIC tot' to spreadsheet output
******************************************************************************
WATEQ4F, VERSION 3.16
1. Minor bug fix revision:
Added specific test prior to calculating pe and Eh from Cr+3 and Cr+2 activities.
******************************************************************************
WATEQ4F, VERSION 3.17
1. Minor thermodynamic database revisions:
Revised data for Al hydrolysis and SO4 aqueous species as follows:
AlOH 2+ Log K = 4.771 - 2899.05/T
Al(OH)2 + No changes
Al(OH)3 aq Log K = -16.8
Removed analytical expression
Al(OH)4 - Log K = -22.99
Log K = 40.875-10908.4/T-11.041*Log(T)
AlSO4 + Log K = 3.5; delta-H = 2.29
Al(SO4)2 - Log K = 5.0; delta-H = 3.11
******************************************************************************
WATEQ4F, VERSION 3.18
1. Added input charge imbalance to spreadsheet output.
2. Updated thermodynamic database tabular output to reflect current values used in analytical
expressions (see v.3.17 changes above).
3. Updated spreadsheet output to trim leading and trailing blanks from column headers.
******************************************************************************
WATEQ4F, VERSION 4.00
1. Incorporate RoBust Method for Electrical Conductivity per the method of McCleskey and
others (2011).
******************************************************************************
USAGE NOTES FOR WATEQ4F ON PC SYSTEMS
WATEQ4F has been compiled to run on any IBM PC/XT/AT/386/486/Pentium compatible
computer; if no math coprocessor exists WATEQ4F will emulate the functions.

During execution, WATEQ4F will display on the screen the title of each problem defined in the
input file as it works on that particular problem.
WATEQ4F automatically gets the time and date of the simulation run from the computer and
writes this time and date stamp in the first few lines of the output file. Of course, if your
computer does not maintain the correct time and date, these will also be incorrect in your
output file. The calls to the computer's time and date are specific to Lahey/Fujitsu Fortran
95 Express, and take place in subroutine SOLUTS. If you want to recompile WATEQ4F
with a different compiler, simply delete or comment out the section that uses the call to
subroutine DATE_AND_TIME in SOLUTS.FOR, or substitute similar code appropriate
to your microcomputer FORTRAN compiler.
REFERENCES
Ball, J. W., and Nordstrom, D. K., 1991, User's manual for WATEQ4F, with revised
thermodynamic data base and test cases for calculating speciation of major, trace, and
redox elements in natural waters: U.S. Geological Survey Open-File Report 91-183, 189
pp. (revised and reprinted August 1992).
Nordstrom, D. K., Plummer, L. N., Langmuir, Donald, Busenberg, Eurybiades, May, H. M.,
Jones, B. F., and Parkhurst, D. L., 1990, Revised chemical equilibrium data for major
water-mineral reactions and their limitations In Melchior, D.C., and Bassett, R.L., eds.,
Chemical modeling in aqueous systems II: Washington D.C., American Chemical
Society Symposium Series 416, pp. 398-413.
Nordstrom, D.K., and Archer, D.G., 2002, Arsenic thermodynamic data and environmental
geochemistry In Welch, A.H. and Stollenwerk, K.G., eds., Arsenic in groundwater:
Kluwer, in press.
McCleskey, R.B., Nordstrom, D.K., Ryan, J.N., and Ball, J.W., 2011, A New Method of
Calculating Electrical Conductivity With Applications to Natural Waters (in press):
Geochimica et Cosmochimica Acta.
[http://www.sciencedirect.com/science/article/pii/S0016703711006181]
McCleskey, R.B., 2011, Electrical conductivity of electrolytes found in natural waters from (5 to
90) C: Journal of Chemical & Engineering Data, v. 56, p. 317-327.
[http://dx.doi.org/10.1021/je101012n]
*** WARNING ***
Although WATEQ4F has been used by the U. S. Geological Survey, no warranty, expressed or
implied, is made by the USGS as to the accuracy or functioning of the programs and related
program materials nor shall the fact of distribution constitute any such warranty, and no
responsibility is assumed by the USGS in connection therewith.

Das könnte Ihnen auch gefallen