APL computer programs for thermodynamic ... - Springer Link

3 downloads 0 Views 915KB Size Report
1 Department of Geosciences, The Pennsylvania State University, University Park, Pa. ... University 1, permit thermodynamic calculations on solid-solid and ...
Contributions to Mineralogy and Petrology

Contrib. Mineral. Petrol. 54, 157-171 (1976)

9 by Springer-Verlag 1976

APL Computer Programs for Thermodynamic Calculations of Equilibria in P - T - X c o z Space J. Slaughter 1 *, V.J. Wall 2, and D.M. Kerrick 3 1 Department of Geosciences, The Pennsylvania State University, University Park, Pa. 16802 2 Department of Earth Sciences, Monash University, Melbourne, Australia 3 Department of Geosciences, The Pennsylvania State University, University Park, Pa. 16802

Abstract. APL computer programs for the thermodynamic calculation of devolatilization and solid-solid equilibria operate using stored values for the molar volume and entropy of solids, the free energies of H20 and COz, and the free energies of formation for 110 geologically-important phases. P-T-Xco2 calculations of devolatilization equilibria can be made at pressures from 0.2 through 10 kb, and temperatures from 200 through 1,000~ P-T-J( calculations of solid-solid equilibria may be accomplished at pressures to 30 kb and temperatures to 1,000 ~ C. Calculations can be extrapolations from experimental points, or direct calculations from thermochemical data alone. Options are available in these programs to consider effects of: real vs. ideal gas mixing, thermal expansion and compressibility, solid solution, fluid pressure differing from solid pressure, and uncertainties in high-temperature entropies. A collection of thermodynamic data programs accompanies the programs for calculating P-T-Xco2 equilibria. Over a wide range of physical conditions, the data functions report free energies, entropies, fugacities of H20 and C Q , high temperature entropies of solids, and activities of components in HaO - CO 2 mixtures. List of Symbols all20, ac02 A Gf A Gr A Go GH;o, A Hr~ K

Activity of H 2 0 and CO 2

Free energy of formation of a phase from elements Free energy change of reaction Standard state free energy change of a reaction Gco ~ Free energies of pure H20 and CO 2 Standard state enthalpy change for a reaction Equilibrium constant

Gas constant Standard state entropy change of reaction A SO Standard state entropy change of solids in a reaction d Vr~ Standard state volume change of a reaction A Vs~ Standard state volume change of solids in a reaction Xmo, Xc02 Mole fraction of H20 and CO2 7H2o, 7co2 Activity coefficient of H20 and CO z R A So

Present address: E.I.C. Inc., 55 Chapel St., Newton, Mass 02160, U.S,A.

158

J. Slaughteret al.

Introduction A collection of APL computer programs, obtainable from the Pennsylvania State University 1, permit thermodynamic calculations on solid-solid and devolatilization equilibria. Extrapolations of equilibria in P-T-Xco2 space may be performed from experimentally-determined equilibrium brackets. Alternatively, the free energy change of a reaction may be obtained at any P-T-Xco~ point by coupling other reactions, or by calculation from free energies of formation from Robie and Waldbaum (1968). A discussion of the thermodynamic expressions employed in these calculations, and of the coupling approach, is given in Slaughter, Kerrick, and Wall (1975). Kerrick (1974) provides a review of mixed-volatile equilibria. Equilibria calculated directly from thermochemical data ordinarily possess larger uncertainties than are obtained from experimental equilibrium brackets. Hence, the programs described here are designed primarily for extrapolating equilibria from reasonably narrow (_+ 10~ experimental equilibrium brackets. Table 1 lists programs that are available in this collection. Only a minimum knowledge of APL language is necessary to use the programs. Users should consult an APL text (e.g. Gilman and Rose, 1970) for familiarization with the APL system, and for APL terminology.

Capabilities and Options of the Programs The programs which calculate devolatilization equilibria (i.e. PTX, MULTIPTX, THCHCALC, and GREENWOOD) are limited to pressures between 0.2 and 10 kb, and temperatures between 200~ and 1,000~ The upper limit of 10 kb arises from the lack of reliable free energy data above 10 kb; the lower limit of 0.2 kb arises partly from the difficulty of fitting the equations of free energy of H20 and CO2 (as functions of P and T) over the entire pressure range of 1 bar to 10 kb z. A separate equation to cover the pressure range of 1 to 200 bars would be required. Furthermore, the bulk of metamorphic rocks have been subjected to pressures greater than 0.2 kb, and the majority of hydrothermal experimentation has been conducted above this pressure. The range of physical conditions (P and T) over which devolatilization calculations are permitted in these programs spans nearly the complete range of P - T conditions of metamorphism in the earth's crust. Detailed instructions on the operation of programs are available in the DESCRIBE workspace 3, which accompanies the collection of programs (Table 1). A brief summary of the options and capabilities offered by the programs is given here. The main programs will now be discussed individually. Examples of the use of each program are given at the end of this paper. Copies of theseprogramscan be obtainedthroughthe ProgramLibrarian,ComputationCenter, 215 ComputationBuilding,The PennsylvaniaState University,UniversityPark, Pa. 16802, U.S.A. 2 Specificdetailsconcerningthe derivationof equationsfittingthermodynamicdata, and precision of these equations, is discussedin the section on "ThermodynamicData and Functions". 3 A "workspace"is a block of storage in the central computer.

Thermodynamic Calculations of Equilibria in P - T - X c o 2 Space

159

SOLIDSONLY Workspace The SOLIDSONLY workspace contains the program PTXSOLIDS (Table 1), which performs calculations on solid-solid equilibria. The temperature limitation for this program (generally > 1,000~C) corresponds to the highest temperature at which entropy data is available for phases of interest (data source: Robie and Waldbaum, 1968). A listing of phases for which thermodynamic data is available is given in the MISC workspace by the THERMOC variable (Table 1). THERMOC also gives the temperature range over which entropy data of the phases is available. Consideration of thermal expansion and compressibility of solids is significant in thermodynamic calculations of some solid-solid equilibria; therefore, the option to consider these effects is provided in the PTXSOLIDS program. The pressure limitation of compressibility data (data source: Birch, 1966) sets the upper pressure limit for this program. Compressibility data, where available, is generally to 10 kb or higher. In the PTXSOLIDS program, the operator first enters the P, T, activities of phases, and the A Gr value (zero or nonzero), of a "starting point" known from experiment, coupling, or from thermochemical calculation. This program offers the option to consider thermal expansion and compressibility, and to change the activities of solid phases, between the starting point and the new P, T values. Thus, the operator selects other P - T points, with desired solid activity data specified for each, and the A Gr calculated for each specified point is given in the form of a table (see Example 1). Typically, the operator would search for the location of the equilibrium (where A G~=0) by varying one intensive variable (for example, T) while keeping the other variables constant. The equations used in this program are outlined as follows. For a known starting point we have: P1I =(A G~ o )T1 P1 + R T~ ln(K)T P1, . (A G~)r

(1)

Assuming that (A Gr)~ and the activities of solid phases are known at this point, we can evaluate (K)~, which yields ~tA~c~ For most of our applications, we select the starting point as an experimental equilibrium bracket [where (A Gr)~l = 0]. The reaction free energy at any other point (e.g. P2-T2) can then be evaluated by: zJ ~ )P2 __ ( A F2_O~Pt fT2 'Jr'T2--t~ Vr IT1--JT1

P2 ASr0 dT+Se, A Vr~dP + RT2 in (K)~x.

(2)

For equilibria involving all phases in their standard state (i.e. unit activities at P and T) the terms involving K in Eqs. (1) and (2) become zero. Where compressibility and thermal expansion data is available for all solid phases in the reaction, the integrals involving A So and A V~~ are modified accordingly.

GNRLCALC Workspace The GNRLCALC workspace contains the function MULTIPTX which calculates devolatilization equilibria at pressures between 0.2 kb and 10 kb, and temperatures between 200~ and 1,000~ Options are provided for calculations involving

J. Slaughter et al.

160 Table 1

Programs for calculating P - T - X c o 2 equilibria Workspace names

Names of main functions

Purpose

Main options

SOLIDSONLY

PTXSOLIDS

Calculation of equilibria among solid phases only.

Thermal expansion, compressibility, change of activity of solids. Contains TECM, a matrix consisting of constants for thermal expansion and compressibilities of phases.

GNRLCALC

MULTIPTX

Calculation of devolatilization equilibria.

Thermal expansion, compressibility, change in activity of solid phases. Consideration of nonideal mixing of H20 - CO2, calculations with

MIXEDVOLS

PTX

Calculation of devolatilization equilibria. Mostly isobaric although option for polybaric extrapolation is available.

T - X extrapolations involving ideal (a=x) or real (a4:x) mixing of H 2 0 - CO a ; log K vs. 1/T display; polybaric extrapolations.

T H C H C A L C allows calculation of equilibria from thermochemical data alone.

T H C H C A L C offers the option to obtain an equilibrium temperature automatically, or by successive approximations.

THERMOCALC THCHCALC

GREENWOOD

G R E E N W O O D enables T - X calculations according to Greenwood's (1967) "constant enthalpy" equation. Data functions and matrices

Workspace names

Names of main functions

THERMO .......................... SVOLS . . . . . . . . . . . . . SSOLVE . . . . . . . . . . . . DSSR . . . . . . . . . . . . . . ACTW . . . . . . . . . . . . . ACCO2 . . . . . . . . . . . . GH20 ............. GCO2 . . . . . . . . . . . . . . GC, GW . . . . . . . . . . . .

Purpose

To serve as a convenient source of thermodynamic data. Entropies of Ha O and CO 2 . High temperature entropies of solids. Entropy change of a solid reaction assemblage. Activities of H20. Activities of CO 2 . Free energy of H20 (0.2 through 10 kb; 200 through 1,000~ C). Free energy of CO 2 (0.2 through 10 kb; 200 through 1,000 ~C). Free energies of H 2 0 and CO2 at specific pressures and 200 through 1,000 ~ C.

MISC

FUGACITY ........

FugacitiesofH2OandCOzatspecificpressuresand2OOthroughl,000~

PHASID LSQFITS THCATA

PHASID reports phase identification numbers to be used in calculations of equilibria. This workspace contains the variables T H E R M O C and T H E R M O D . T H E R M O C gives information concerning the source and range of data on phases. The data is contained in the variable THERMOD. THCATA enables user to add a line of data to T H E R M O D and a corresponding description line to THERMOC. LSQFITS enables the user to obtain entropy power series coefficients for Sr-$298 as entered for phases in the matrix T H E R M O D .

Thermodynamic Calculations of Equilibria in P-T-Xco 2 Space

161

Table 1 (continued) Description programs Workspace names

Contains the variables

DESCRIBE

INTRODUCTION SOLIDSONLYHOW MIXEDVOLSHOW GNRLCALCHOW

Purpose

THERMOCALCHOW DATA MISCHOW THERMOHOW

The variables explain operation of the individual workspaces. DATA gives information on the source and range of thermodynamic data.

thermal expansion and compressibility, Pf (fluid pressure) differing from P~ (solid pressure), use of mole fraction or activity for H20 and CO 2 and for solids. This workspace was designed to provide for generality and versatility of calculation (i.e. many capabilities). Consideration of thermal expansion and compressibility of solids is usually negligible for devolatilization reactions. MULTIPTX is the only program offering the option to consider these effects for devolitilization equilibria. The operation procedure is identical to that of the PTXSOLIDS program, except that the activities of volatile components (H20 and CO2) are specified at the starting point and at the points at which new values of A Gr are to be calculated. As in PTXSOLIDS, the operator could search for the location of the equilibrium (where A Gr=0 ) by varying one intensive variable (e.g. T) while keeping the others constant. Example 2 is a sample calculation using MULTIPTX. The equations used for calculations in MULTIPTX are similar to those in SOLIDSONLY, except that additional terms appear for the gas species; hence, the expression analogous to Eq. (2) is: (A G r ) ~ . ~=(AGr)T1 o e l _ f r JT1 2 A e O'~'s dr+~f~

P2

A gso dP+(GH2o)T2-(GH2o)rl e~ P~

P1

+ (Gco2)r~ - (Gco2)rx + RT 2 In K 2 . The equilibrium constant is written in terms of activities of solids and gas species. For ideal gas mixing the activities of H20 and CO2 would be replaced by mole fractions. The terms for Gco2 would not appear for a dehydration reaction, whereas those for Gi~2owould not appear for a decarbonation reaction. As in the PTXSOLIDS program, the integrals involving A S ~ and A Vf would be modified if compressibility and thermal expansion data were available for all solid phases involved in the reaction. MULTIPTX offers three options for entry of the free energies of H20 and CO 2 (see Example 2). Option (1) yields automatic solution of these free energies from the GW and GC functions (Table 1), compatable with the standard state of Robie and Waldbaum (1968). Option (2) allows manual entry of these free energies in the triple point standard state; thus, the free energies of H20 could be entered directly from the tables of Burnham, Holloway, and Davis (1969). Option (3) was designed for entry of H20 and CO 2 free energies from the respective functions G H 2 0 and GCO2 (Table 1). Note that option (3) was chosen in example 2.

J. Slaughter et al.

162

MIXEDVOLS Workspace The workspace MIXEDVOLS contains the program PTX which isobarically extrapolates T-Xco2 equilibria from a selected starting point (usually an experimental equilibrium bracket). PTX is more convenient but less general than MULTIPTX. Calculations in PTX are limited to 12 specific pressures (0.5, 1, 1.5, 2, 3, 4, 5, 6, 7, 8, 9, and 10 kb); the capability to calculate T-Xco ~ equilibria at any pressure (rather than those fixed in PTX) would require storage of G H 2 0 and GCO2 in the MIXEDVOLS workspace, placing additional demands on workspace availability. These programs operate using the CO2 and H20 free energy functions GCO2 and G H 2 0 , respectively. These functions fit the original data source better than the corresponding functions GC and GW, which are used in MULTIPTX. Thus, PTX offers more precise isobaric extrapolations than are obtainable with MULTIPTX. At one of the 12 specific pressures, the PTX program requires the initial entry of the P, T, XH~o, Xco2, and activities of solids, at a starting point where A Gr = 0. The program locates the Xco2 coordinate(s) of the equilibrium (where A Gr=0) at temperatures requested by the operator. The equation used for isobaric extrapolations of a two-volatile ( H 2 0 - CO2) equilibrium from a starting point (T1X1) to another point (T2 X2) is: AA Gr = 0 = - ~ A So d T + (Gu:o)r: - (Ga~o)r~ + (Gco:)r: - (Gco:)r~ + RT2 In (K)r~ - RT1 in (K)r~. For dehydration and decarbonation reactions, this equation would be simplified by the absence of the respective terms Gco2 and GH2o. This calculation assumes ideal mixing in the fluid (i.e. Yco2---TH~o= 1). The program then reports the new temperatures and corresponding Xco 2 values. The operator is then offered six options (see Example 3). If the operator selects option (1), an "activity corrected" display will be reported. This calculation utilizes activity data for H 2 0 and CO 2 from Greenwood (1973) and Ryzhenko and Malinin (1971), and is limited to pressures of 0.5, 1, 1.5, and 2 kb. In this calculation the program reports Xco2 values for which the activities (of H20 and CO2) are appropriate to satisfy the extrapolated equilibrium constant at the new temperatures that were entered (see Slaughter, Kerrick and Wall, 1975, p. 153). The program corrects the initial XH~o and Xco2 values to activities in making this calculation. The operator may select option (2) to begin calculations on a different reaction, option (3) extrapolate from a different starting point on the same reaction, option (4) to calculate the equilibrium at temperatures other than those selected previously, option (5) for polybaric extrapolations, or option (6) to obtain a lnK vs. 1/T display (natural log of K vs. l/T, where Tis in ~ In the lnK vs. 1/T display, the equilibrium constant is expressed in terms of mole fractions of gas components (the standard state is unit activity at P and T). For the polybaric extrapolation, which allows the operator to locate the reaction temperature at any of the 12 specific pressures at a specified Xco~ value, the operator enters the P, T, XH~o, and Xco ~ values of a starting point at one of the 12 specific pressures (see Example 3).

Thermodynamic Calculations of Equilibria in P-T-Xco2 Space

163

THERMOCALC Workspace The workspace THERMOCALC contains two principal programs: THCHCALC and GREENWOOD. The THCHCALC program calculates equilibria using the expression:

0-----(AGf, r)lb~r.15-- ~T~ A S Od T + Ie"~A Vf dP. This program reports equilibrium temperatures at one of the 12 specific pressures, and at Xco2 values specified by the operator (see Example 4 for a sample calculation using the THCHCALC program). The value of(A Gf, r)298.15 i bar may be calculated automatically by the program from values in the T H E R M O D matrix; alternatively, any value of this quantity may be entered by the operator. As an alternative to the automatic determination of the equilibrium temperature, the operator may enter a temperature at which A Gr is to be determined. For this option, the program reports the following output data: AGr at P, T, and X of gas species, the value of -yrr~ ASrdT from 298.15 ~ K to T at i bar, A V~AP (in cal.), and the value of RT lnK (with K in terms of fugacities relative to a 1 bar standard state). This option enables the operator to calculate AGe for phases which have unsatisfactory or unavailable data at present, providing that uncertainties in the free energies of formation are relatively small for the other phases involved. The G R E E N W O O D program performs isobaric T-Xco 2 extrapolations of equilibria at any of the 12 specific pressures, according to the formulation of Greenwood (1967). Since this type of calculation assumes constant AH~ it is less rigorous than the T-Xco 2 extrapolations performed by the other programs in which an entropy power series for A ~ is integrated between temperature limits. However, extrapolations obtained from the PTX program are usually quite comparable to the extrapolations obtained from the G R E E N W O O D program (Kerrick and Slaughter, in press).

Thermodynamic Data and Functions The workspace THERMO contains functions which report thermodynamic data. Example 5 indicates some capabilities of the programs in this workspace. The workspace MISC contains data and information (THERMOC, T H E R M O D and TECM), a fitting routine for obtaining entropy power series expressions (LSQFITS), and the function THCATA for adding data to the THERMOC and T H E R M O D matrices. Most entropies reported by the functions in THERMO, and those used to calculate equilibria, are compatible with the third law (i.e. S = 0 at 0 ~ K). Exceptions to this are phases with residual (configurational) entropy terms (e.g. high albite and high sanidine). These entropies are compatible with the standard state free energy where H =0 at 298.15 ~ K, and S = 0 at 0~ K. The entropies reported in the workspace THERMO (by the functions SSOLVE and DSSR) are for solids at 1 bar and T. In programs for calculating devolatilization equilibria, these entropies are used without adjustment to higher pressures (except in MULTIPTX which offers the option to consider thermal expansion and corn-

164

J. Slaughter er al.

pressibility). Since the change of entropies of solid phases with pressure is small in contrast to the corresponding change in the entropies of gas components, it is a viable assumption that the pressure effect on the entropies of solids may be neglected in the calculations. This assumption cannot be made for solidsolid equilibria. Consequently, the option to consider thermal expansion and compressibility is offered in the SOLIDSONLY workspace (the program PTXSOLIDS). The variable THERMOC gives the source and range of data for high temperature entropies of solids. The values of Sr-S298.15 have been fitted to equations of the form: A(lnT)+B(103 x T)+C(1OS/T2)+D, an integrated form of the Maier-Kelley heat capacity equation (Kelly, 1960). The coefficients A, B, C and D, contained in the variable THERMOD, can be obtained from the least squares fitting function LSQFITS. For most solid phases, the polynomials obtained by this function reproduce the original entropy data in Robie and Waldbaum (1968) to within 0.1 ~o. As a check on the precision of the entropy of a phase, the operator can obtain the entropy at any temperature by using the SSOLVE function, one of several data programs (Table 1). For each phase the T H E R M O D matrix contains: a phase identification number (which enables programs to address proper lines in THERMOD for given phases), molar volume and entropy at 298.15 ~ K and 1 bar, entropy power series coefficients A, B, C, and D, andthe free energy of formation at 298.15 ~K and 1 bar. T H E R M O D contains data in this form for 110 phases. In T H E R M O D as in TECM (thermal expansion and compressibility matrix), a zero will appear if no data is available for a given parameter. The availability of data in matrices must be checked before attempting calculations. In TECM are stored thermal expansion and compressibility constants for each phase. The thermal expansion data are coefficients of an equation of the form: V=AT3+BTZ+CT+D (where V is accumulated per cent volume expansion at T relative to the molar volume 298.15 ~ K and 1 bar, based on the data of Skinner, 1966). Also in TECM are the values a and b given in the tables of Birch (1966) for the coefficients of the equation for compressibility of phases. It is important to note that because of a lack of data, some phases have been assigned available data of a similar mineral. Activities of H20 and CO2 in gas mixtures were fitted to equations of a=f(T, X) at constant pressure. The resulting equations are contained in the functions ACTW and ACCO2 for HaO and CO2, respectively. Equations for the activities of H 2 0 and CO2 at pressures above. 500 bars were derived by first recasting Ryzhenko and Malinin's (1971) tables of fugacity coefficients to activities, and then graphically fitting their data for each isotherm on 50~ C intervals from 400-750 ~ C. The graphical data was then fit to equations [a=f(T,X)] using regression programs. The resulting equations reproduce activities at the original 50 degree isotherms to within 2 percent for most values and to within 5 percent for all values. At temperatures between the isotherms, the equations were forced to comply with the graphically-constructured surfaces inferred from the 50 degree isotherms. This fitting procedure involves little uncertainty for CO 2 activities which vary smoothly with T and X; however, the H20 activity surface is complex at higher pressures, but only at higher values of Xmo. Since the complications are only at higher Xu2o values, they will have

Thermodynamic Calculations of Equilibria in P-T-Xco2 Space

165

only minor effects on extrapolations of equilibria where activities of H 2 0 are considered, since RT in aH2o terms become large only at low Xn2o values. Activity data at 500bars and T = 4 5 0 - 7 0 0 ~ was obtained from Greenwood (1973). Activities at 500 bars were extrapolated down to 350 ~ C to allow low-temperature activity calculations at this pressure. Thus, the accuracy of the activity data provided by A C T W and ACCO2 at P = 0 . 5 kb and at temperatures between 350 and 450 ~ C, is questionable; however, this permits a qualitative assessment of the differences in extrapolations for ideal gas mixtures (ai=X~) compared to real gas mixtures (ai :(: Xi). The functions A C T W and ACCO2 cover the following ranges: 0.5 kb., 350 800 ~ C; 1, 1.5 and 2 kb., 400 to 750 ~ C (note that the functions may be solved only at these four pressures). Use of the activity functions much beyond the indicated temperature ranges is not recommended. The activity functions are available in the workspace T H E R M O as information programs, and they are used routinely in the workspace M I X E D V O L S to yield the activitycorrected display. The functions GW and G H 2 0 are available in the workspace T H E R M O to report free energies of H 2 0 in the standard state H = 0 at 298.15 ~ K and 1 bar; S = 0 at 0 ~ K. The function GW may be employed at 0.5, 1, 1.5, 2, 3, 4, 5, 6, 7, 8, 9 and 10 kb only, and throughout the temperature range 200 to 1,000 ~ C. The function G H 2 0 may be employed at any pressure between 0.2 and 10 kb, and throughout the temperature range of 200 to 1,000 ~ C. When converted to the triple point standard state, the values reported by GW reproduce the free energies of Burnham, Holloway and Davis (1969) to within 3 cal. The function G H 2 0 reproduces the original data source to within 20 calories for most values, and to within 60 calories for all values. The equivalent functions for CO2 free energies in the same standard state are GC and GCO2. The CO2 free energies were obtained from the unpublished fugacity coefficients of Burnham and Wall, and the free energy of CO2 at 1 bar. The GC function reproduces these free energies to within 3 calories, whereas the GCO2 function reproduces these free energies to within 75 calories. The GC function may be employed at the 12 specific pressures and throughout the temperature range from 200 to 1,000 ~ C. The GCO2 function may be employed at any pressure from 0.2 through 10 kb., and temperatures from 200 through 1,000 ~ C. Users of this computer package could improve its utility by revising and expanding the data matrices and functions as new data becomes available. Our programs are subject to limitations imposed by the current APL system. A single A P L program that would be completely general and convenient could have been written if it were not for the workspace limitation of 31 kilobytes.

Examples of the Operation of Programs In the followingexamples of the calculation of equilibria, phase identificationnumbers and reaction coefficients are requested as input by the programs. The phase identification numbers enable the programs to address the lines in THERMOD and TECM. which contain data for the phases of interest. In all programs, phase identification numbers (which can be convenientlyobtained from a function entitled PHASEID in the MISC workspace) are entered only for solid phases. Reaction coefficients are the stoichiometriccoefficientsof the balanced reaction. Reactants are entered with

166

J. Slaughter et al.

negative sign, whereas products are entered with no sign (implying a positive sign). Except in the PTXSOLIDS program, the first two reaction coefficients entered are for H 2 0 and CO2. Reaction coefficients for the solids are entered in the same order as the phase-identification vector. In the examples of program operation, a D: symbol is printed by the computer to indicate that input is requested by the program. Lines immediately following such symbols are input by the operator. The remaining lines are either instructions by the program, or output. It is important to note that following certain statements in the examples, explanatory notes have been added in italicized printing enclosed in brackets.

Example 1 This is a sample calculation using the PTXSOLIDS program. An experimental equilibrium point is known at 2 kb, 600 ~ C for the reaction: Grossular + Quartz ~ Anthorite + 2 Wollastonite, involving pure phases (i.e. unit activity of solid phases). The equilibrium point at 2 kb provides the initial conditions for the calculation. It is desired to find the equilibrium temperature at 6 kb, so that free energy changes at several temperatures (all at 6 kb) are to be calculated. For each new temperature value entered, a corresponding pressure value is entered after the program request: "ENTER N E W PRESSURES (KB)." In this example, a "1" has been entered so that the thermal expansion and compressibility correction will be applied. A zero has been entered for the option to consider a change of activity values of phases, such that the activities are constant (unity in this example) throughout the calculation. The output Of the program gives new temperature values, and the corresponding zl S~ and A G~. Interpolation of the A G~ values indicates equilibrium at approximately 734 ~ C at 6 kb. The operator could rerun the program selecting a series of temperatures clustered about the equilibrium value and thus determine a more exact equilibrium temperature.

Example 1

SAVED

)LOAD S O L I D S O N L Y 1 0 . 2 0 , 0 9 09/24/7.~

PTXSOLIDS S O L I D S O L I D R E A C T I O N S O N L Y ; W I T H O P T I O N FOR THERMAl- E X P A N S I O N . C O M P R E S S I B I L I T Y E N ] E R RXN ID OROSSULAR ITE§ [Z-~ANORTHI TE+SWOL L A S T O N I ] E E N T E R RXN COEFFrS :.+ P R O D U C T S " R E A C T A N T S 0: -I -I I 2 E N T E R V E C T O R P H A S E ID. NO. 0: 103 I 18 21 V E O T O R M O L A R V O L U M E S SOLIDS~(CC)I25*3 22.688 100.79 39.93 V E C T O R S SOLIDS(S=O OoK) FOR T = 2 9 8 55 9,88 48.4-~ |9.6 ENTER O;

I FOR

THERMAL

EXPANSION

AND

COMPRESSIBILITY

CORRECTION*

OTHERWISE

EFFECTS

EN'i'ER 0

I

ENTER []:

PKB+.TC, 2 600

ENTER

NEW

~ (

ACTIVITIES I

I

OF S O L I D S

(SAME

ORDER

AS P H A S E

ID.)~MSRN.

o

PRESSURES

(KO,)

Of

. 6 6 6 6 6 6 6 6 6 6 E N T E R N E W T V A L U E S (IN DEG* C) I0 V A L U E S O: 670 688 r 7 0 0 7 i 0 720 730 740 750 ENTER G:

( IF C H A N G E

8F A C ] I V I T I E S

OF S O L I D S

760 ]IS D E S I R E D ,

OTHERWISE

ENTER

0

0 SOLIDS P R E S S U R E ; T E M P E R A T U R E ; ~S OF RXN.; aO OF RXN+; 6 6 6 6 6 6 6 670 680 690 700 710 720 730 22,037 21.9219 2~ .819 2~ +788 21.596 21.483 21.368 1424 9 ~ 1204 9 5 985,78 760 + 14 551 +62 L~6.23 I 21 .98 ENTER I FOR NEW "r;2 NEW PS;3 NEW PT;4 NEW THERMO,;5 NEW RXN.;6 NEW XSSLIDS;7 OUT [] : 7

6 740 21,252 -9(.126

6 750 21.135 -303.06

6 760 2t .017 -5t 3.83

Thermodynamic Calculations of Equilibria in P - T - X c o ~ Space

167

Example 2

This is a sample calculation using the MULTIPTX program. This will be one of the more involved calculations which could be performed with the program. We assume a known starting point at 1 kb, 495~ Xco ~ = 0.5, XH~O=0.5 , and unit activity of solids. The equilibrium temperature will be calculated at 2 kb; Xco~ and Xmo will be kept constant, although the corresponding activities will be used in the calculation (i.e. correction is made for non-ideal gas mixing). This calculation assumes a change in the activity of tremolite from 1 at the initial point to 0.85 at 2 kb. Pf is equal to P~ throughout Example 2 )LSAD

GNRLCALC 10,!56,30 0 9 / 2 4 / 7 5 )COPY SOI...IDSONLY T E E N 10o20,09 09/24/75

SAVED gAVED

MUI.. 1"I F'T'X

T E E M C O P I E D (?)* ENTER RXN If)* TREMOI.. I TE.~ 3C.ALC ]:rE'~'2QUARTZ~ 5B :I:OF'g I D E + 3 C O 2 + H 2 0 E N T E R R X N C O E F F S ~ H 2 0 F I R g T , T H E N C82~ R E A C T A N T S - ,

PRODUCT.S'+

lit I

"f

5 VEEr81:,~ I:'HA.S'E ID, N I ] ,

ENTER

3

"3

-2

01

64 29 I 20 I F8R THERMAL

ENTER

EXF'ANgION

AND

COMFIREgSIBILITY

EFFECT

CORRECTION~

I ENIFIER FINB,~C,X OR a OF H2(],X OR a OF C02~ A C T I V I T I E S OF SOLIDSI~ [l: I 4 9 5 .568 ~1546 1 i I i 0 ENI'ER ~ F O R AU'T'8MATIC SOLU'T'ION F R O M 8 H 2 0 A N D GC02~ 2 F O R M A N U A L S T A T E ~ 3 F O R ENI'RY F R O M GW A N D GC

OTHERWISE

IN ORI)ER

ENTRY

ENTER

OF P H A G E

8F D A T A

0

IDo~AGRN~

TRIPLE

FROM

F'T,,F'TD,

3 ENTER N E W

T VALUES

[]t 500 5i0 520 530 540 ENTER NEW SOLID PREg%URE

550 5 6 0 (i V A L U E )

2. NEW [I

I::'F (I

VALUE)

2 ENTER GH28 I]

i GW

AT F ' I T t

495

ENTER GC02 AT F'i'1"t

[I t i GC 4 9 5 NEW ACT C02 T VALUES DI '500 5 i 0 5 2 0 !330 5 4 0 5 5 0 ENTER P I(B~ r]l 2 NEW AH2O 7 VAL.UE.~ I] 5 0 0 ! 3 t 0 ~ 2 0 5 3 0 540 5 5 0 ENTER P KB* O: 2 E N T E R 8 H 2 8 AT P 2 T 2 ? V A L U E S

560

ACE02

,5

560

AC'I'W .5

[]I 2 GW 5 0 0 5i0 AT P2'r2

520 530 540 ? VAI-UEJ~

2 GC 5 0 0 5 1 0 I F'OR C H A N G E

5 2 0 5 3 0 5 4 0 550 5 6 0 IN A C T I V I T I E S 8F g O L I D S

ENTER 8 C 0 2

550

560

Ol ENTER []**

I EN'TER A C T I V I T Z E ~ Ot

OF gOl-IDg AT

r2

IN O R D E R

FROM

OF

TI

PHASE

TO

T2~

OTHERWIgE

33t4~3

0 *5 5 6 8 3 2 2 510 -" 9 5 o 9 3 8 2511,3

0 *5 5 3 2 2 2 2 520 - 96. 682 i698.4

E N T E R O P T I O N NO* D E S I R E D ; I TH * I-XP * - C O M P R * ; 10 O U T I]: iO

T;2 PF;3

0 *5~ 2 2 530.

0 *5 4 8 i 4 2 2 540

- 97 * 4 2 i 881,34

F'g;4 A C T

- 9 8 * i 56 63,51

1420;5

0

ID.28VALUEg

, 8 5 1 1 1 , 8 5 I 1 1 ~85 1 t 1 , 8 5 i i ~ * 8 5 1 1 I , 8 5 I A C T I V I T Y C 0 2 ; A C T I V I T Y H 2 0 ; F ' S O L I D S ; P F ' L U I D ; T E M P o ; AgSOLIDE~ 0 * 5"7585 0,5"7108 0 * 56591 0 * 5604 O §5 5 4 6 i

0 *5 5 8 8 4 2 2 500 - 95 * 19

ENTER

ACT

CO2;&

1 1 ,85 I ~G RXN, 0,5486

0 *5 4 9 2 6 2 2 550 -98 * 886 -749,69 9

INITIAL

I

1 0 * 54244

0 ~5641,3 2 2 560 - 99 * 6 ~ 2 -t525,7

VAL.UES~7 N E W

I::'HASE ID N8.~o;8 N E W

RI-ACTIONt9

J. Slaughter et al.

168

the calculation. Before entering the program, TECM (thermal expansion and compressibility matrix) is copied into the workspace; this step is only necessary for calculations involving thermal expansion and compressibility. The program begins with a statement reminding the operator of the need to first copy TECM. The values ofaH~o and aco ~ at the initial P, Tand X values of volatiles must be obtained from the ACTW and ACCO2 functions (see Example 5) prior to entering the MULTIPTX program. The values for the free energies for HzO and COz at the initial conditions and at the new P, T values are entered by means of the appropriate thermodynamic data functions. Since a change in the activity of tremolite is to be considered, a listing of X (or activity) values of solids at the new P, T points is entered; there is one set of such values at each new P, T point. The sequence of activity values must be entered in the order corresponding with the sequence of P, T points entered previously. The order of mole fraction (or activity) values in each set is the same as that of the solid phase identification vector. Output of the program includes the new temperature, P~, Pr, an~o, aco~, A S~ and A G~. Interpolation of the A G~ values indicates equilibrium at approximately 541~ at 2 kb, Xco ~ =0.5, and a~. . . . nt~ =0.85. Operation of this program is considerably less complicated in calculations for which: option (1) is used for free energy input, X values rather than activities of volatiles are involved, and activities of solids are not changed in the extrapolation.

Example 3 This is a sample calculation using the PTX program. In this calculation an equilibrium point at 2 kb, 485 ~ C, and Xco ~=0.85, its to be extrapolated to other temperatures at 2 kb. The initial conditions are Example 3

SAVED

)LOAD MIXEDVOLS ~0o05.35 0 9 / 2 4 / 7 5

PTX PROG* C O M P U T E S P'TX E Q U n I B R I A . . . . . J . S L A U B H T E R 1974 E N T E R RXN. If). 5 D O L O N ll E.t8QUARTZ+N20-~TREMOLII E + 3 C A L C I T E + 7 C 0 2 ENTER VECTOR OF RXN. COEFFS.(H2(],C02 FIRST),+F'RODUCTS, -REACI'ANI'.~ O.' "i 7 -5 "8 i 3 ENTER INIT IA L p,T,XH20,XC02~ ACTIVITIES OF" SOLIDS IN ORDER OF REACTION COEFFS. 8~ 2 485 . i 5 .85 i i i i ENTER VECTOR OF UNCERI'AINTIIIS IN E298 FOR %OL:[DS IN SAME ORDER AS PHASE I D . 8: - , 0 7 -.02 , i 5 +2 ENTER VECTOR PHAs ID . NO, O~ 30 ~ 64 29 ENTER NEW T VALUES O: 400 410 420 430 440 450 460 470 485 490 500 510 R KB,, NEW T V A L U E S , X C O 2 U A L U E S [two Zoo 2 values giwn for reactions with T maxima] 2 2 2 2 2 2 2 2 2 2 2 2 510 48~ 490 500 400 4i 0 420 430 440 4.~0 460 470 0.96 0,8B 0,879 0,927 0 ,3 0 6 0 ,3 5 6 0.4i2 0,473 0.'539 0,608 0, 6 7 9 0,751 O 0 0 0 0 0 0 0 0 0 0 0 E N T E R 0 FOR OUT;I AFI'IVI'rY C O R R E C T F D D I S P L A Y S 2 NEW REA[',TION~3 NEW I N P U T D A T A ; 4 N E W T V A L U E S ; 5 N E W P R E S S U R E ; 6 LOGK VS. I/ I O; i ACTIVITY CORRECTED VALUEE R K B . , NEW T VALUES, XC02 VAI.UES 2 2 2 2 ? 2 2 2 2 2 2 2 400 410 420 430 440 450 460 470 485 490 500 510 0.204 0.248 0 .3 0 3 0~37 0. 45 0.54i ().639 0.733 0.88 0.878 0.932 0.965 0 0 0 0 0 0 0 0 0 0 0 0 E N T E R 0 FOR 8Ul'~i ACI'IVITY CSRRI.---CTED DISPI_AY;2 N E W REAC'I'ION~3 N E W INPUT D A T A ~ 4 N E W T V A L U E S ; 5 N E W F'RESSURE~& L O 8 K V,~. I/ l 0: ENTER D; ENTER D .*

DATA

FOR

STARTING

PSINT

(p KB.,TC,XI..120~XC02~

2 485 .15 .85 i i i i NEW PRE,~.~LIRIES (~5~I ~I .'.5,2~3,4,5,6,7~8,9~10

ACTIVITIES

KB,

OF SOLIDSE

ONE_T).

95 ~ i , 5 2 3 4 5 & "7 8 9 ~0 P , KB, AND TEMF'S, OI:~ EXTRAPOLATED POIN'F,'C AT XH2(I=O, 1 5 X C 0 2 = 0 , 8 ~ (),~: i I .5 2 3 4 5 6 394 431 461 48i~ 528 565 600 632 ENTER 0 FOR OUl'~'t A C T I V I 1 Y C.8RRECTED D I S P L A Y ; 2 NEW R E A C T I O N ; 3 NEW I N P U T D A T A ; 4 1' [] : 0

2 8 9 iO 663 69'3 Ti 9 740 NEW T V A L I J V ~ ; 5 NEW PRE,~SURE;6 LOGN VS~ 1 /

Thermodynamic Calculations of Equilibria in P-T-Xc% Space

169

provided by the equilibrium point; the activity values of all solids are unity. Changes of a~oHdvalues with temperature or pressure cannot be considered in this program and should be dealt with in the MULTIPTX program. Uncertainty values for entropies are entered for solids in the same order as reaction coefficients and phase-identification numbers. Entropy uncertainty values are given by Robie and Waldbaum (1968). The consideration of these uncertainties does not typically have much effect on the extrapolations. Assigning negative uncertainties to the reactants and positive uncertainties to the products will give an extrapolation corresponding to one of two limits of uncertainty for the reaction location. To find the other uncertainty limit of the extrapolation, the operator would redo the calculation using the opposite uncertainties (i.e. change all the signs of the entropy uncertainties). The "ideal display" gives Xco~ values where )(co ~ and Xn~o are appropriate to satisfy the extrapolated equilibrium constants. The "activity corrected" display reports the Xco~ values at which activities of H20 and CO2 satisfy the extrapolated equilibrium constants. A polybaric extrapolation using PTX is also given for this reaction, starting from the I kb equilibrium point.

Example 4 This is a sample calculation using the THCHCALC program. This calculation was made to compare the direct calculation of this equilibrium from thermochemical data with the experimentally-determined bracket of 494 + 10~ C, P = 1 kb, Xco~=0.5, by Slaughter, Kerrick, and Wall (1975). First, the temperature of the equilibrium at I kb, )(co~= 0.5, and X H:o = 0.5, is found automatically by the program employing the A Gf values of phases from Robie and Waldbaum (1968). The free energy change of reaction is then calculated for the conditions of an equilibrium point (495~C) known from experimental work on this reaction. Note that at 495~C the calculated value for A G~ is -858 cal. whereas the experimental bracket yields A G~=0. Summing Robie and Waldbaum's (1968) tabulated uncertainties in A G,. for products and reactants shows that this discrepancy is well within the total uncertainty range for the calculated AG~.

Example 4

SAVED

PROG§ ENTER TREMOL ENTER O~ ENTER Ot ENTER

)LOAD T H E R M O C A L C 22.50§ 09/19/75

THCHCALC C O M P U T E S T OF R E A C T I O N AT S P E C I F I E D P R E S S U R E R E A C T I O N ID I T E + 3 C A L C I ]'E+2QUARTZ45D I OPS I D E + 3 C O 2 + H 2 0 0 FOR AUI'OMATIC A G 2 9 8 , 0 T H E R W I S E E N T E R aO291B V A L U E 0 VECTOR

PHASE

ID~

NO.

64 29 I 20 V E C T O R OF R E A C T I O N

COEFFS.,H20

AND

6"02 FIRST,

+PRODUCTS~

-REACTANTS

3 -I -3 -2 5 ENTER X H 2 0 , X C 0 2 OF- INTEREST O: ,5 ~ ENTER $298 UNCERTAINTIES OF PHASES (WITH SIGN) IN SANE ORDER AS PHASE. I D . D,' 00 0 0 E N T E R P KB, 0: I ENTER 0 FOR AUTOMATIC SOLUTION,OTHERWISE S P E C I F Y T TO BE S O L V E D 0 P R E S S U R E = I KB 9 T=485 E N T E R O F O R OUT~I NEW R E A C T I O N ; 2 NEW P ; 3 NEW T;4 NEW X ; 5 NEW U N C E R T A I N T I E S ; 6 NEW O: 3 E N T E R 0 FOR A U T O M A T I C S O L U T I O N * O T H E R W I S E S P E C I F Y T TO BE S O L V E D 0: 495 PRESSURE=INB~ T=495DEG~ ~G=-861o271 aG298=31827 AS~T='68335*I RTLOGF=38002.2 E N T E R 0 FOR OUT;I NEW R E A C T I O N ~ 2 NEW F';~ N E W T;4 NEW X;5 N E W U N C E R T A I N T I E S ; 6 NEW O: 0

~G.

aVS~R=-2355.39 aG~

170

J. Slaughter et al.

Example 5 Here, several examples are given illustrating the use of the thermodynamic data programs.

Example 5 THE THERMODYNAMIC FUNCTIONS GH20,GCO2~GW,GC,ACrW,ACC02 AND PUOACITY ARE DYADIC ( I . E . A PAIR OF ARGUMENTS IS REQUIRED TO OPERATE THEM). FOR ALL THE ABOVE FUNCF'IONS EXCEPT ACTW AND ACC02 THESE ARGUMENTS ARE P AND T. FOR ACTW AND ACC02, THE ARGUMENTS ARE r AND X. SOME E X A M P L E S OF rilE OF'ERATION OF T H E S E P R O G R A M S ARE G I V E N BELOW, FIRST~ FOR S U B S E Q U E N T C O N V E N I E N C E A LIST OF T E M P E R A T U R E T~400 450 500 550 600 650 700 750 800 850 900

VALUES

IS A S S I G N E D

TO A V A R I A B L E ;

A . ) THE OPERATOR TYPESt 2 OW T THE -13253 ]'HIS STANDARD

COMPUTER RESPONI)S~ -1480T -i6426 "-18i04 -i9838 -'2t62~ -2346i -25343 -27268 -29233 -31236 IS A LIST OF FREE E N E R G I E S OF H20 F'OR THE V E C r O R OF' T E M P E R A T U R E S AND 2 KB, IN THE S T A T E G I V E N IN THE T H E R M O D Y N A M I C DATA S E C T I O N (SEE TEXT).

B*) THE OPERA'IOR TYPESI 2 . 3 GC02 T THE COMPUTER RESF'ONDSI -24645

-26783

-28973

-3121i

-334?6

-3582G

-38190

-40594

-43033

-45503

-48002

THIS IS A LIST OF FREE ENERGIES. OF (202 AT THE TEMPERATURES AND 2 . 3 KB. IN THE STANDARD STATE GIVEN IN THE THERMODYNAMIC'DATA SECTION*

C.)

THE OPERATOR TYPES~ 5 t 0 ACTW . 0 2 . t . 2

.3

,4

.5

.6

.7

.8

.9

t

THE COMPUTER RESPONDSF ENTER P KB. 0$ THE OPERATOR TYPES/ 2 0.032333 0.13728 0.25657 0.36459 0.46371 0.55583 0.64558 0*73452 0.B2194 0 . 9 f 0 6 8 I THESE ARE ACTIVITIES OF H20 IN H20+C02 MIXTURES AT 2KB.,510 DEG. C AND THE VEC'rOR OF XH20 VALUES (THE XH2O VALUES ARE THE ARGUMENT ON THE RIGHT). TO EMPLOY THE OTHER PROGRAMS IN THERHO, WHICH ARE SSOLVE, DSSR AND $VOLS, THE OPERATOR TYPES THE APPROPRIATE PROGRAM NAME. D.> SVOLS REPORTS THIRD LAW ENTROPIES OF H20 AND C02. ENTER P ( 0 . 5 ~ I , I . 5 , 2 , 3 , 4 , 5 , 6 , ' ? , 8 , 9 OR I 0 KB* ONLY)+ OF THE OPERATOR TYF'ESI 5 ENTER T VALUES (ANY FROM 200 THROUGH iO00 DEO. C) OF THE OPERATOR TYPESt 400 450 500 550 600 650 700 750 BOO T VALUES, ENTROPIES OF H20 AND CO2~ 400 450 500 550 600 29.i08 3 0 .2 9 2 31. 382 32.383 33.G02 30.424 3t.742 32.98 34,t39 35.225 ENTER 0 FOR OUT;I NEW P;2 MEW T VALUES. Of 0

650 34.15i 36.24

700 34.944 37,t89

750 35.70t 38.077

800 36,443 38,908

Acknowledgments. This paper represents part of J. Slaughter's Ph.D. thesis at The Pennsylvania State University. We are very grateful to Paul Metz for reviewing an early draft of the manuscript, and to John Hunt, who was very helpful in the development of these computer programs. This work was supported by N.S.F. Grant GA-25685 to D.M. Kerrick.

References Birch, F.: Compressibility: elastic constants. In: Handbook of physical constants. S. P. Clark, Jr., ed., Memoir 97, The Geological Society of America 1966 Burnham, C. W., Holloway, J. R., Davis, N. F. : Thermodynamic properties of water to 1000 deg. C and 10000 bars. Geol. Soc. Am. Spec. Paper 132, 96 p. (1969) Gilman, L., Rose, A. J.: APL/360 an interactive approach. 335 p. New York: Wiley 1970

Thermodynamic Calculations of Equilibria in P-T-Xco 2 Space

171

Greenwood, H.J.: Mineral equilibria in the system M g O - S i O 2 - H 2 0 - C O 2. In: Researches in geochemistry, II, Abelson, P.H., ed., p. 542-547. New York: Wiley 1967 Greenwood, H.J.: Thermodynamic properties of gaseous mixtures of H20 and CO 2 between 450 and 800 deg. C and 0-500 bars. Am. J. Sci 273, 561-571 (1973) Kelley, K.K.: Contributions to the data on theoretical metallurgy XIII. High-temperature heatcapacity, and entropy data for the elements and inorganic compounds. U.S. Bur. Mines Bull. 584, 232 p. (1960) Kerrick, D.M.: Review of mixed volatile (H/O-CO~) equilibria. Am. Mineralogist 59, 729-762 (1974) Kerrick, D.M., Slaughter, J. : Comparison of methods for calculating and extrapolating equilibria in P - T - X c o 2 space. Am. J. Sci. (in press) Ryzhenko, B.N., Malinin, S.D. : The fugacity rule for the systems CO2 - H 2 0 , C O 2 - CH4, CO2-N2, and CO 2 - H . Geochemistry Internat. 562-574 (1971) Robie, R.A., Waldbaum, D.R.: Thermodynamic properties of minerals and related substances at 298.15 deg. K (25~C) and one atmosphere (1.013 bars) pressure and at higher temperatures. U.S. Geol. Survey Bull. 1259, 256 pp. (1968) Skinner, B.J.: Thermal expansion. In: Handbook of physical constants. S.P. Clark, Jr., ed., Memoir 97, The Geological Society of America 1966 Slaughter, J., Kerrick, D.M., Wall, V.J.: Experimental and thermodynamic study of equilibria in the system C a O - M g O - SiO 2 - H 2 0 - CO 2 . Am. J. Sci. 275, 143-162 (1975) Zen, E.: Gibbs free-energy, enthalpy, and entropy of ten rockforming minerals: calculations, discrepancies and implications. Am. Mineralogist 57, 524-553 (1972)

Received April 30, 1975 / Accepted October 6, 1975

Suggest Documents