Spreadsheet Tools for Solving One-Equation Chemical Equilibrium

Using Lotus spreadsheets to deal with the computational aspects of homogeneous and heterogeneous equilibrium problems...
1 downloads 0 Views 3MB Size
Simulated Chromatogram, N

D(A) to I@): 0.25,0.'/5, 1.0, 1.5, 2.5, 3.2

1500

Absorption Spectra of Thymol Blue 0.8

0.7

500

0.6

450

4

0.5

8 6 0.4

400

?

350

E:

\300

0.2

!250

0.1

0

8a 200

K

0.3

0

-0.1

200

250

300

350

150 100

400 450 500 550 Wovelength (nm)

600

650

700

Figure 6. Spectra of acid and base forms of thymol blue

50 04 I I I ' I I I 2.5 3.5 4.5 5.5 6.5 7.5 8.5 9.5 10.511.5 12.5

In this application, the width can be made unif01111for each of the spe&al bands or varied if desired. As an illustration, we started with the spectrum of thymol blue, a colorimetric acid-base indicator.It is usedin a solution at pH 6.11(3 units below its p&, representing the 99.9% basic form). After entering this data in a QPro spreadsheet, we tried to match a series of four Gaussian curves whose position (La), height (absorbam A), and o (width) were adjustable. After about 15-20 min of adjusting these parameters by visual observation of the curve representingthe sum of individual Gaussian curves. Firmre 5 was obtained. Althoueh there is no auestion that cdm-ercial curve-fittingprogram'$ could do a m k h better iob. there is distinct Dedameic value in the directness and ~ i & ~ l i &ofy this type oiexe&ie.

Naturally, the reliability of all determinations (single-com~ o n e n and t ~articularlvmulticom~onent)would simifi&tly improve if measurements on the sample were carried out using a large number of different wavelengths. Each suchmeas;rernent results in an additional independent equation ol'the variables. The array of these equations can be treated by the spreadsheet regression f b c tion. The improvement will be seen in the smaller standard deviations in the values determined. Naturally, standard spectra representing known concentrations of each of the components of the mixture must be obtained before the determinations. Figure 6 presents a special example of binary-mixture analysis as the spectrophotometric determination of equilibrium wnstants possible when the conjugate variables each have characteristically different spectra. By this technique, it is possible to determine the pK, spectrophotometrically with far greater reliability than that obtained using most potentiometric methods; it also provides a means of calibrating glass electrodes accurately (2).

Multicornponent Spectrophotornetric Analysis

Literature Cited

IIMEmin. Figure 4. Effect of column efliciency on the appearance of a chromatogram: N = 1500.

.-."..,

1. R e i w H.Comptsond Coleuloliona in Anolytiml Ckmistry; CRC bear: BocaRa-

Another, simpler, useful application is the demonstration of the use of the spreadsheet in solving multicomponent spectrophotometric analysis when experimental spectra are not available. Course instructors will find it convenient in designing homework or test problems. As many as six or seven components can be determined.

Thymol Blue Spectrum & Simulation

0.3

$ 0.2

3-9 A""".

2. Yamaeaki. H.; Sperline, R. P;Reiaer. H.'Spe~tmphotomebie Determination of pH and its Applicaion to Determination of Thermdpamic Eqdibrium constants-; Andytiml Chemishy 1992.64.2720-2125.

Spreadsheet Tools For Solving One-Equation Chemical Equilibrium Problems Bhairav D. Joshi State University College Geneseo, NY 14454-1494

A central question in dealing with chemical equilibrium problems is this:

0.25

J

a

Given the equilibrium constant for a reaction as writfen and the initial concentrations orpartial pressures of all the species inuolued, what will be the concentrations orpartialpressures of uarious species once the reaction reaches its equilibrium position?

2

yIo.15

5gi

O.'

The eauilibrium concentrations of various s~eciesare

10.05

governed by the extent of the rr;ictionl In a recent series

0 250

300

275

350

325

400

375

450

500

425 475 525 HAVElENGTR nm

550

600

575

650

625

Figure 5. Simulation of thymol blue base form with Gaussian model.

'The extent of a react on measdies ts degree of progress startlng fromthe initial amounts of materials in the reaction mixture. It is measured in moles (or other related units) and is defined as the common factor by which the amounts ofvarious species change during a reaction. See also footnote2. Volume 71 Number 7 July 1994

551

121

EQUILIBRIUM EXTENT OF A REACTION: Ideal gases; Constant P & T

All single equation chemical equilibrium pmblems involving N species can be represented by a balanced equation expressed i n the following generalized, and notationally most convenient, form (7): N

O=Cag¶; i=l

ai -1 -4 2 7

II 38

nio

ni

xi

3.000E+00 2.WOE+W O.WOE+W 5.WOE+W

2.992E-01 1.968E+00 1.602E-02 5.056E+00

2.982E-01 1.962E-01 1.597E-03 5.040E-01

RESULTS

Pi 1.491E+00 9.808-01 7.983E-03 2.520E+00

(1)

where Ai represents the ith species participating in the reaction, a n d ai i s i t s stoichiometric coefficient. In t h i s way of representing chemical equations, the values of ai are positive for products a n d negative for reactants. Depending upon the pressure ( p ) ,volume (V), and temperature ( T ) conditions under which the reactions are being studied, all equilibrium problems described by eq 1can be treated under three broad categories:

Ideal gas equilibria at canstant T and V are best expressed in terms of the partial Newy 18.008~-03 pressures of various species and the corresponding equilibrium constant, Kp. An automated temolate., FORM-KP. has been developed to calculate the equilibrium partial pressures of homogeneous as well as heterogeneous reactions. For each species i participating in the reaction the template uses a computational device, called an activity switch,Si.These switches are assigned a value of 1 if the activity is constant or a value of zem otherwise. 2. Equilibria involvingideal aqueous solutions at constant T and V are best expressed in terms of molarities of various species and the equilibrium constant Kc. The template FORM-KC has been developed to calculate the equilibrium malarities for homogeneous as well as heterogeneous reactions using the activity switches mentioned above. From a computational point of view, FORM-KP and FORM-KC work exactly the same way 3. Equilibria involving ideal gases at constant P and Tare best expressed in term* of mole fractions of varinur species and thc equilibrium cunstsnt K, The template FORM-KX has been develo~edto calculate the eauilibrium properties of homogenious as well as heterog&eous reactions at eonstantp and T. 1.

F

6.617E-24

1

Ox

14.767~05

Figure 1. An example of the use of the FORM-KX template.

1

.

of papers Weltin has demonstrated that the extent of a reaction and the eauilibrium concentrations are uniauelv determined by initial concentrations ( 1 3 , . He has s;&sted the bisection mrthod forcalculat~ngthemuilihrium cxrcnt of a reaction (2). A BASIC fbr the bisection method has recently been published by Campanario and Ballesteros (4). We have found that the most widelv used iterative method for solving equations, Newton's method, can be utilized to find the euuilibnum extent u f a reaction (5).This method is quadratically convergent and is easily implemented on a computer using a spreadsheet. We have used Lotus (6) . . sureadsheet uroeram imulemented on a Zenith 2-386125 personal computer to develop three automated spreadshiets that make i t extremeG easy for beginning students, as well as for seasoned pmfessionals, to deal with the computational aspects of homogeneous and heterogeneous muilibrium uroblems. More attention can thus directed'toward anunderstanding and interpretation of the principles of chemical equilibrium and their conseauences without being distracted by the oRen complex numerical computations~involved.such visual tools also allow students to easilv cam out a varietv of WHATIIF type numerical experiments and thus pro6de enormous potential for enriching their knowledge of the urinciules involved. The tem~latesdescribed here are ideally suited for students in a&lytical and physical chemistry courses. They can be profitably used by general chemistry students aRer gaining some experience with them via tutorials and reviewsessi&. The tkmplates are very useful and novel teaching tools for instructors with classroom computing and projec%on facilities. They are also valuable time savers for teachers and teaching assistants in grading examinations and homework assignments.

. -

552

Journal of Chemical Education

Calculations All three templates solve equations of the following type, written for case 3 above. for the extent of reactions a t eaui-

where the reaction quotient, Q,, is a function ofy (8).The equilibrium constants for the forward and reverse reac'For the general reaction represented by eq 1. r = ( n ?L - n . J l ~ i

where np and n; are moles of A; at the beginning and at some later time t.

C23:

The chemical equation forthe reaction.

C25:

Pressure in atmospheres.

E25:

Temperature in Kelvins.

C26:

Equilibrium constant. Kp.

A29

A36: Switch settings (1 for pure solids or pure liquids, 0 otherwise.

C29 D29

tions are inversely related. F o r reasons o f convergence of t h e Newton's method. reactions are always written in such a way that the equilibrium constants are always ~ 1and , ~ the initial conditions are reorganized, if necessary, in such a wav that a t least one of the oraducts i s i n i t i d l v absent from th; reaction m i ~ t u r e . ~

..

Newton's i t e r a t i v e f o r m u l a f o r t h e solution o f e q 2 i s

..

C36: Stoichiometric coefficients (negative for reactants and positive for products - reactants first).

- F(rl)IE"(rl)

YZ = '1

(3)

where v, i s t h e i n i t i a l a p ~ r o x i m a t i o n .v9 i s t h e improved ) value o l j , and F'(yl) i s t h k ' f i s t d e r i v a t i i i o f ~ ( yevaiuated a t v = v , . Analvtical exoressions for F"(v) for a l l three cases a n k methods For estim'atingyl f o r s o l & g equations o f t h e type 2 are discussed elsewhere (8).

.. D36: Initial moles. Note: Other templates need similar input data.

lure 2. User provided input information shown in Figure 1.

An Example: Using the FORM-KX template In F i g u r e 1i s presented a p a r t of FORM-KX template Cells G26 and G39 contain the equilibrium extent of reaction (last two iterations).

w h i c h finds t h e e q u i l i b r i u m properties o f t h e following r e action (9)from t h e d a t a shown in t h e shaded areas a n d b r i e f l y described below in F i g u r e 2.

Cells E29 .. E36 wntain equilibrium mole numbers.

..

Cell F29 F36 contain equilibrium molefractions. Cells G29 .. G36 contain equilibrium partial pressures.

T h e calculated results o f interest a r e shown in t h e clear blocks and a r e b r i e f l v described in F i e u r e 3. T h e calculations a& carried o u t bfinvoking t h e macro, G. a n d i t s associated submacro.. R.. shown inFieure4.5T h i s macro

Cells C37 .. G37 contain sum of the values of quantities in tne blocks above them, exduding the va ues corresponding to the spectes with constant act vity.

-

Cell C39 contains the calue of F(y) at equilibrium

(a) estimates the initialvalue o f y (Oldy), (b) uses Newton's formula,. es. 3, d of . to find an i m ~ r w e value y (Newy), and (c) replaces the Oldy by Newy and then repeats the steps (b) and (c) ten times.

Cell E(39) contains the equilibrium value of the reaction quotient, Qx.

Figure 3. Calculated results shown on Figure 1.

T h e convergence o f t h e results i s tested visuallv by t h e crit e r i a sho&in Figure 5. I f t h e results have n o i c o w e r g e d , t h e iterations can be repeated in u n i t s o f t e n b y i n v o k i n-g t h e s u b m a m , R. In F i g u r e 6 are presented t h e d a t a and e q u i l i b r i u m results f o r t h i s heterogeneous reaction (10):

N o t e t h a t for s ~ e c i e whose s activities r e m a i n constant duri n g a heterog&eous reaction t h e i n i t i a l moles ( o r p a r t i a l oressures o r concentrations) are eiven as 1.0. a n d t h e corresponding activity switches are t u r n e d ON^ A l l t h r e e templates have been extensively tested and they all have t h e same convenient general form f o r displaying input data and the calculated results inone screen o f 20 m w s a n d a maximumof 7 columns. Those parts o f the FORM-KX

Figure 4. Macro to use with the FORM-KX template.

1'1 the Kfor the reaction as gtven is >I. we rewrite it as the reverse reanion whose Kvahe will then be ess than 1. Wlth thls In rnlnd, the templates can handle equilibria with any value of K. 4When all oroducts are initiallv ~resent for reactions with K s 1. simole stoichioietric arouments &I be oseudo'initial "~ - ~used - - to - find ~ - new . .. -- - . conod ons In whch at least one product is absent from the reactlon mixt~re.This is Done Dy assuming tnat lira the reaction goes 100% towaro reactants. controlled only by the Imit'ng reagent. Tne reactlon is then allowed to proceed to its equilibrium state from these pseudo initial conditions. 5The macro is invoked by holding the Alt key down and typing G. 61n heterooenwus svstems an eouilibrium exists onlv if all soecies In tne chem & equat dn are preser;t in the phases shown. he equlIlbr dm constant for s ~ c hreact ons IS Independent of the actual amount of pdre sold (or I ~ dlJ phase present Note, however, that 11 there is a solid (or liquid) limiting reagent that gets used up before equilibrium is reached we do nothavean equilibrium problem on our hands. ?

Compare the values of Oldy and Newy; they should be idntical to the desired number of significantfigures, or

I

Compare the values of KXand Ox; they should also be identical to the desired number of significantfigures, or Examine the value of F(y); it should be pretty dose to zero.

Figure 5. Convergence criteria.

I

~

~

~

-

~~

~

~~~

~

Volume 71 Number 7 July 1994

553

template where the intermediate calculations are carried 20 out are not shown in Figures 1and 6. 2' Conclusions The templates presented in this note should serve as very useful tools for students interested in mastering the subject matter of chemical equilibrium. These tools cover all types of one-equation equilibrium problems encountered in general, analytical, and physical chemist r y courses. Numerous WHATIIF types of numerical experiments can be designed around these templates to stimulate student interest. Copies of the templates can be obtained fmm the author for $15. Literature Cited

A

B

C

E

D

F

G

EQUILIBRIUM EXTENT OF A REACTION: Ideal gases; Constant P & T

-

22

lSbEk(~)+ 3 H2(g) = 2 Sb(s) + 3 H&)

27 28 29

-

30 31

32 -

Si 1

0 1 0

i

ai -1

ni 1.000E+00 1.000E+00

3

-3 2

4

3

2.000E+00 1.1 40E+00 5.701 E-01 2.850E-01 1.000E+00 1.000E+00 1.000E+00 1.000E+00 0.000E+00 8.599E-01 4.299E-01 2.150E-01

1 2

nio

xi 1.000E+00

Pi 1.000E+00

5

33 34 35 -

7

36

8

6

1. weltin, E. J. cham. E ~ U C . ~ m 67, , 37 2 0.00 2.000E+00 2.000E+00 1.000E+00 5.000E-01 548. 2. Weltin. E.J. Cham. Ed=. 1991.68, 38 RESULTS 486487. 3. Welfin, E. J . Chem. Edue 1992, 69, 393396. 39 F Qx Newy 4. campsnsrio, J. M.; Ballerteros, R. J. Comp. Moth. e n d Sc. Teaching 40 1990rJ1. 10.87-94. 5 . Gerald, C. FApplMNumerical Anoly. sis, Addison-Wesley: Reading, MA, 1980; pp 1S22. e, Devel op,, i,,L~tus Figure 6. Using FORM-KX template fora heterogeneous equilibrium. 1-2-3 f o r DOS. Release 2.3: Cambridge: MA.ssi. 9. hi,^. D. unpublished results ~ W Kfrom , thermodynamic data. 7. Denhigh, K. The Principles ofChamieol Equilibrium; Cambridge Universlt~Press: 10. M8m. S. H.; Landa. J. B. Iirndomrntols ofPhyaieol Che"isby: Maemillan: New Cambridge. UK. 1971: pp 14iL147. 8. Joshi, B. D J Camp Molh.ondSc. Ihoching, 1994,1311), 101-123. York, 1974; p 385, proh. 25.

pizEY

554

Journal of Chemical Education

pzizzr

pzEiiE5