-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathternary-diagram.tex
388 lines (354 loc) · 17.6 KB
/
ternary-diagram.tex
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
\documentclass[10pt]{article}
\usepackage[margin=1in]{geometry}
\usepackage{amsmath,amssymb,graphicx,hyperref,mathrsfs,siunitx}
\usepackage[small,bf]{caption}
\title{Isothermobaric Ternary Phase Diagrams}
\author{Trevor Keller}
\date{\small \today}
\frenchspacing
\hypersetup{linktocpage, colorlinks, citecolor=black, filecolor=black, linkcolor=black, urlcolor=blue}
\begin{document}
\maketitle
It is always useful to view the thermodynamic phase diagram as a sanity check on
kinetic simulations. This is commonly done for binary alloy systems. The process
for generating a correct ternary phase diagram is less routine; this document
summarizes the derivation from the system free energy functional as a
constrained minimization problem.
An exposition of the method is given in part on
\href{https://math.stackexchange.com/questions/632/validating-a-mathematical-model-lagrange-formulation-and-geometry}
{math.stackexchange.com}. The Python source code in this repository provides a
complete implementation.
\section*{Binary Two-Phase}
Consider a binary system with two phases, the free energies of which are defined
by the functions $G_{\alpha}(x)$ and $G_{\beta}(x)$. The system will have volume
fraction $v_{\alpha}$ of phase $\alpha$ and $v_{\beta}$ of phase $\beta$. We
seek to determine the equilibrium phase compositions ($x_{\alpha}$, $x_{\beta}$)
and volume fractions that minimize the free energy of the total system, subject
to two constraints. To do so, we'll make use of Lagrange multipliers.
\begin{align}
G(x_{\alpha}, x_{\beta}) &= v_{\alpha} G_{\alpha}(x_{\alpha})
+ v_{\beta} G_{\beta}(x_{\beta})\\
v_{\alpha} x_{\alpha} + v_{\beta} x_{\beta} &= x\\
v_{\alpha} + v_{\beta} &= 1
\end{align}
where $x$ is the system composition. The system functional and integrand are
\begin{align}
\mathcal{L}[x_{\alpha}, x_{\beta}, v_{\alpha}, v_{\beta}, \lambda_1, \lambda_2]
&= \int\limits_VF\mathrm{d}V\\
F(x_{\alpha}, x_{\beta}, v_{\alpha}, v_{\beta}, \lambda_1, \lambda_2)
&= v_{\alpha} G_{\alpha}(x_{\alpha}) + v_{\beta} G_{\beta}(x_{\beta})
- \lambda_1(v_{\alpha} x_{\alpha} + v_{\beta} x_{\beta} - x)
- \lambda_2(v_{\alpha} + v_{\beta} - 1).
\end{align}
Therefore, the system of Euler-Lagrange Equations is
\begin{align}
\label{eqn:el1}
\frac{\delta\mathcal{L}}{\delta x_{\alpha}} = \frac{\partial F}{\partial x_{\alpha}} = 0
&= v_{\alpha} \frac{\partial G_{\alpha}}{\partial x_{\alpha}} - \lambda_1 v_{\alpha}\\
\label{eqn:el2}
\frac{\delta\mathcal{L}}{\delta x_{\beta}} = \frac{\partial F}{\partial x_{\beta}} = 0
&= v_{\beta} \frac{\partial G_{\beta}}{\partial x_{\beta}} - \lambda_1 v_{\beta}\\
\label{eqn:el3}
\frac{\delta\mathcal{L}}{\delta v_{\alpha}} = \frac{\partial F}{\partial v_{\alpha}} = 0
&= G_{\alpha}(x_{\alpha}) - \lambda_1x_{\alpha} - \lambda_2\\
\label{eqn:el4}
\frac{\delta\mathcal{L}}{\delta v_{\beta}} = \frac{\partial F}{\partial v_{\beta}} = 0
&= G_{\beta}(x_{\beta}) - \lambda_1x_{\beta} - \lambda_2
\end{align}
Solving Eqns.~\ref{eqn:el1}~\&~\ref{eqn:el2} for $\lambda_1$ gives
\begin{align}
\lambda_1 &= \frac{\partial G_{\alpha}}{\partial x_{\alpha}}
= \frac{\partial G_{\beta}}{\partial x_{\beta}}\\
\label{eqn:chempot}
\therefore \frac{\partial G_{\alpha}}{\partial x_{\alpha}} &=
\frac{\partial G_{\beta}}{\partial x_{\beta}}.
\end{align}
Solving Eqns.~\ref{eqn:el3}$~\&~$\ref{eqn:el4} for $\lambda_2$ and substituting
Eqn.~\ref{eqn:chempot} gives
\begin{align}
\lambda_2 &= G_{\alpha}(x_{\alpha})
- \frac{\partial G_{\alpha}}{\partial x_{\alpha}} x_{\alpha}
= G_{\beta}(x_{\beta})
- \frac{\partial G_{\alpha}}{\partial x_{\alpha}} x_{\beta}\\
\label{eqn:grandpot}
\therefore G_{\beta}(x_{\beta}) &= G_{\alpha}(x_{\alpha})
- \frac{\partial G_{\alpha}}{\partial x_{\alpha}}
\left(x_{\alpha} - x_{\beta}\right).
\end{align}
Eqn.~\ref{eqn:chempot} represents equality of chemical potential, while
Eqn.~\ref{eqn:grandpot} represents equality of grand potential energy. This pair
of equations can be solved to determine the two unknown compositions needed to
specify the common tangent line containing points $G_{\alpha}(x_{\alpha})$,
$G(x)$, and $G_{\beta}(x_{\beta})$.
\newpage
\section*{Ternary Two-Phase}
Consider a ternary system with two phases, the free energies of which are
defined by the functions $G_{\alpha}(x_1, x_2)$ and $G_{\beta}(x_1, x_2)$. The
system will have volume fraction $v_{\alpha}$ of phase $\alpha$ and $v_{\beta}$
of phase $\beta$. We seek to determine the equilibrium phase compositions
($x_1^{\alpha}, x_2^{\alpha}, x_1^{\beta}, x_2^{\beta}$) and volume fractions
that minimize the free energy of the total system, subject to three constraints.
Unlike the binary case, we must make use of the constraints directly by
including Euler-Lagrange equations with respect to the Lagrange multipliers.
This is because the common tangent \emph{line} between the two points does not
completely specify the equilibrium tangent \emph{plane}.
\begin{align}
G(x_1^{\alpha}, x_2^{\alpha}, x_1^{\beta}, x_2^{\beta})
&= v_{\alpha} G_{\alpha}(x_1^{\alpha},x_2^{\alpha})
+ v_{\beta} G_{\beta}(x_1^{\beta}, x_2^{\beta})\\
v_{\alpha} x_1^{\alpha} + v_{\beta} x_1^{\beta} &= x_1\\
v_{\alpha} x_2^{\alpha} + v_{\beta} x_2^{\beta} &= x_2\\
v_{\alpha} + v_{\beta} &= 1
\end{align}
where A and B label phases, 1 and 2 label components, $x_1$ and $x_2$ are the
system compositions, and compositions with labels $x_i^j$ represent the
composition of component $i$ in phase $j$. The integrand is
\begin{align}
\nonumber
F(x_1^{\alpha}, x_2^{\alpha}, x_1^{\beta}, x_2^{\beta})
&= v_{\alpha} G_{\alpha}(x_1^{\alpha}, x_2^{\alpha})
+ v_{\beta} G_{\beta}(x_1^{\beta}, x_2^{\beta})\\
\nonumber
&- \lambda_1(v_{\alpha} x_1^{\alpha} + v_{\beta} x_1^{\beta} - x_1)\\
\nonumber
&- \lambda_2(v_{\alpha} x_2^{\alpha} + v_{\beta} x_2^{\beta} - x_2)\\
&- \lambda_3(v_{\alpha} + v_{\beta} - 1)
\end{align}
The system of Euler-Lagrange Equations becomes
\begin{align}
\label{eqn:2el1}
\frac{\partial F}{\partial x_1^{\alpha}} = 0
&= v_{\alpha} \frac{\partial G_{\alpha}}{\partial x_1^{\alpha}}
- \lambda_1 v_{\alpha}\\
\label{eqn:2el2}
\frac{\partial F}{\partial x_1^{\beta}} = 0
&= v_{\beta} \frac{\partial G_{\beta}}{\partial x_1^{\beta}}
- \lambda_1 v_{\beta}\\
\label{eqn:2el3}
\frac{\partial F}{\partial x_2^{\alpha}} = 0
&= v_{\alpha} \frac{\partial G_{\alpha}}{\partial x_2^{\alpha}}
- \lambda_2 v_{\alpha}\\
\label{eqn:2el4}
\frac{\partial F}{\partial x_2^{\beta}} = 0
&= v_{\beta} \frac{\partial G_{\beta}}{\partial x_2^{\beta}}
- \lambda_2 v_{\beta}\\
\label{eqn:2el5}
\frac{\partial F}{\partial v_{\alpha}} = 0
&= G_{\alpha} - \lambda_1 x_1^{\alpha} - \lambda_2 x_2^{\alpha}
- \lambda_3\\
\label{eqn:2el6}
\frac{\partial F}{\partial v_{\beta}} = 0
&= G_{\beta} - \lambda_1 x_1^{\beta} - \lambda_2 x_2^{\beta}
- \lambda_3\\
\label{eqn:2el7}
\frac{\partial F}{\partial \lambda_1} = 0
&= v_{\alpha} x_1^{\alpha} + v_{\beta} x_1^{\beta} - x_1\\
\label{eqn:2el8}
\frac{\partial F}{\partial \lambda_2} = 0
&= v_{\alpha} x_2^{\alpha} + v_{\beta} x_2^{\beta} - x_2\\
\label{eqn:2el9}
\frac{\partial F}{\partial \lambda_3} = 0
&= v_{\alpha} + v_{\beta} - 1
\end{align}
Solving Eqns.~\ref{eqn:2el1}~\&~\ref{eqn:2el2} for $\lambda_1$ gives
\begin{align}
\lambda_1 &= \frac{\partial G_{\alpha}}{\partial x_1^{\alpha}}
= \frac{\partial G_{\beta}}{\partial x_1^{\beta}}\\
\label{eqn:chempot1}
\therefore \frac{\partial G_{\alpha}}{\partial x_1^{\alpha}}
&= \frac{\partial G_{\beta}}{\partial x_1^{\beta}}
\end{align}
This represents equality of chemical potential of component 1.
Likewise, solving Eqns.~\ref{eqn:2el3}~\&~\ref{eqn:2el4} for $\lambda_2$ gives
\begin{align}
\lambda_2 &= \frac{\partial G_{\alpha}}{\partial x_2^{\alpha}}
= \frac{\partial G_{\beta}}{\partial x_2^{\beta}}\\
\label{eqn:chempot2}
\therefore \frac{\partial G_{\alpha}}{\partial x_2^{\alpha}}
&= \frac{\partial G_{\beta}}{\partial x_2^{\beta}}
\end{align}
This represents equality of chemical potential of component 2. Solving
Eqns.~\ref{eqn:2el5}$~\&~$\ref{eqn:2el6} for $\lambda_3$, after substituting
Eqns.~\ref{eqn:chempot1}~\&~\ref{eqn:chempot2}, gives
\begin{align}
\nonumber
\lambda_3 &= G_{\alpha}
- \frac{\partial G_{\alpha}}{\partial x_1^{\alpha}} x_1^{\alpha}
- \frac{\partial G_{\alpha}}{\partial x_2^{\alpha}} x_2^{\alpha}\\
&= G_{\beta}
- \frac{\partial G_{\alpha}}{\partial x_1^{\alpha}} x_1^{\beta}
- \frac{\partial G_{\alpha}}{\partial x_2^{\alpha}} x_2^{\beta}\\
\label{eqn:grandpot1}
\therefore
G_{\beta} &= G_{\alpha}
- \frac{\partial G_{\alpha}}{\partial x_1^{\alpha}}(x_1^{\alpha} - x_1^{\beta})
- \frac{\partial G_{\alpha}}{\partial x_2^{\alpha}}(x_2^{\alpha} - x_2^{\beta}).
\end{align}
This represents equality of the grand potential of phases A and B.
Substituting Eqn.~\ref{eqn:2el9} into Eqns.~\ref{eqn:2el7}~\&~\ref{eqn:2el8}
gives
\begin{align}
x_1 &= v_{\alpha} x_1^{\alpha} + (1 - v_{\alpha}) x_1^{\beta}\\
x_2 &= v_{\alpha} x_2^{\alpha} + (1 - v_{\alpha}) x_2^{\beta}
\end{align}
Solving for $v_{\alpha}$ gives us the ternary Lever Rule:
\begin{align}
\nonumber
v_{\alpha} &= \frac{x_1 - x_1^{\beta}}{x_1^{\alpha} - x_1^{\beta}}\\
&= \frac{x_2 - x_2^{\beta}}{x_2^{\alpha} - x_2^{\beta}}\\
\label{eqn:lever}
\therefore \frac{x_1 - x_1^{\beta}}{x_1^{\alpha} - x_1^{\beta}}
&= \frac{x_2 - x_2^{\beta}}{x_2^{\alpha} - x_2^{\beta}}.
\end{align}
The system of Eqns.~\ref{eqn:chempot1}, \ref{eqn:chempot2}, \ref{eqn:grandpot1}
\& \ref{eqn:lever} can be solved to determine the two unknown composition pairs
needed to specify the equilibrium tie line containing the points
$G_{\alpha}(x_1^{\alpha},x_2^{\alpha})$, $G(x_1,x_2)$, and
$G_{\beta}(x_1^{\beta},x_2^{\beta})$.
\newpage
\section*{Ternary Three-Phase}
Consider a ternary system with three phases, the free energies of which are
defined by the functions $G_{\alpha}(x_1, x_2)$, $G_{\beta}(x_1, x_2)$, and
$G_{\gamma}(x_1, x_2)$. The system will have volume fraction $v_{\alpha}$ of
phase $\alpha$, $v_{\beta}$ of phase $\beta$, and $v_{\gamma}$ of phase
$\gamma$. We seek to determine the equilibrium phase compositions
($x_1^{\alpha}, x_2^{\alpha}, x_1^{\beta}, x_2^{\beta}, x_1^{\gamma},
x_2^{\gamma}$) and volume fractions that minimize the free energy of the total
system, subject to three constraints. Like the binary case, we do not make use
of the constraints directly because three points completely specify the common
tangent \emph{plane}.
\begin{align}
G(x_1^{\alpha}, x_1^{\beta}, x_1^{\gamma}, x_2^{\alpha}, x_2^{\beta}, x_2^{\gamma})
&= v_{\alpha} G_{\alpha}(x_1^{\alpha},x_2^{\alpha})
+ v_{\beta} G_{\beta}(x_1^{\beta}, x_2^{\beta})
+ v_{\gamma} G_{\gamma}(x_1^{\gamma}, x_2^{\gamma})\\
v_{\alpha} x_1^{\alpha} + v_{\beta} x_1^{\beta} + v_{\gamma} x_1^{\gamma} &= x_1\\
v_{\alpha} x_2^{\alpha} + v_{\beta} x_2^{\beta} + v_{\gamma} x_2^{\gamma} &= x_2\\
v_{\alpha} + v_{\beta} + v_{\gamma} &= 1
\end{align}
where $x_1$ and $x_2$ are the system compositions. The integrand is
\begin{align}
\nonumber
F(x_1^{\alpha}, x_1^{\beta}, x_1^{\gamma}, x_2^{\alpha}, x_2^{\beta}, x_2^{\gamma})
&= v_{\alpha} G_{\alpha}(x_1^{\alpha}, x_2^{\alpha})
+ v_{\beta} G_{\beta}(x_1^{\beta}, x_2^{\beta})
+ v_{\beta} G_{\gamma}(x_1^{\gamma}, x_2^{\gamma})\\
\nonumber
&- \lambda_1(v_{\alpha} x_1^{\alpha} + v_{\beta} x_1^{\beta} + v_{\gamma} x_1^{\gamma} - x_1)\\
\nonumber
&- \lambda_2(v_{\alpha} x_2^{\alpha} + v_{\beta} x_2^{\beta} + v_{\gamma} x_2^{\gamma} - x_2)\\
&- \lambda_3(v_{\alpha} + v_{\beta} + v_{\gamma} - 1)
\end{align}
The system of Euler-Lagrange Equations becomes
\begin{align}
\label{eqn:3el1}
\frac{\partial F}{\partial x_1^{\alpha}} = 0
&= v_{\alpha} \frac{\partial G_{\alpha}}{\partial x_1^{\alpha}} - \lambda_1 v_{\alpha}\\
\label{eqn:3el2}
\frac{\partial F}{\partial x_1^{\beta}} = 0
&= v_{\beta} \frac{\partial G_{\beta}}{\partial x_1^{\beta}} - \lambda_1 v_{\beta}\\
\label{eqn:3el3}
\frac{\partial F}{\partial x_1^{\gamma}} = 0
&= v_{\gamma} \frac{\partial G_{\gamma}}{\partial x_1^{\gamma}} - \lambda_1 v_{\gamma}\\
\label{eqn:3el4}
\frac{\partial F}{\partial x_2^{\alpha}} = 0
&= v_{\alpha} \frac{\partial G_{\alpha}}{\partial x_2^{\alpha}} - \lambda_2 v_{\alpha}\\
\label{eqn:3el5}
\frac{\partial F}{\partial x_2^{\beta}} = 0
&= v_{\beta} \frac{\partial G_{\beta}}{\partial x_2^{\beta}} - \lambda_2 v_{\beta}\\
\label{eqn:3el6}
\frac{\partial F}{\partial x_2^{\gamma}} = 0
&= v_{\gamma} \frac{\partial G_{\gamma}}{\partial x_2^{\gamma}} - \lambda_2 v_{\gamma}\\
\label{eqn:3el7}
\frac{\partial F}{\partial v_{\alpha}} = 0
&= G_{\alpha} - \lambda_1 x_1^{\alpha} - \lambda_2 x_2^{\alpha} - \lambda_3\\
\label{eqn:3el8}
\frac{\partial F}{\partial v_{\beta}} = 0
&= G_{\beta} - \lambda_1 x_1^{\beta} - \lambda_2 x_2^{\beta} - \lambda_3\\
\label{eqn:3el9}
\frac{\partial F}{\partial v_{\gamma}} = 0
&= G_{\gamma} - \lambda_1 x_1^{\gamma} - \lambda_2 x_2^{\gamma} - \lambda_3
\end{align}
Solving Eqns.~\ref{eqn:3el1},~\ref{eqn:3el2}~\&~\ref{eqn:3el3}
for $\lambda_1$ gives
\begin{align}
\lambda_1 &= \frac{\partial G_{\alpha}}{\partial x_1^{\alpha}}
= \frac{\partial G_{\beta}}{\partial x_1^{\beta}}
= \frac{\partial G_{\gamma}}{\partial x_1^{\gamma}}\\
\label{eqn:3chempot1a}
\therefore \frac{\partial G_{\alpha}}{\partial x_1^{\alpha}}
&= \frac{\partial G_{\beta}}{\partial x_1^{\beta}}\\
\label{eqn:3chempot1b}
\frac{\partial G_{\alpha}}{\partial x_1^{\alpha}}
&= \frac{\partial G_{\gamma}}{\partial x_1^{\gamma}}
\end{align}
Eqns.~\ref{eqn:3chempot1a}~\&~\ref{eqn:3chempot1b} represent equality of
chemical potential of component 1 in pairs of phases $\alpha-\beta$ and
$\alpha-\gamma$. Similarly, solving
Eqns.~\ref{eqn:3el4},~\ref{eqn:3el5},~\&~\ref{eqn:3el6} for $\lambda_2$ gives
\begin{align}
\lambda_2 &= \frac{\partial G_{\alpha}}{\partial x_2^{\alpha}}
= \frac{\partial G_{\beta}}{\partial x_2^{\beta}}
= \frac{\partial G_{\gamma}}{\partial x_2^{\gamma}}\\
\label{eqn:3chempot2a}
\therefore \frac{\partial G_{\alpha}}{\partial x_2^{\alpha}}
&= \frac{\partial G_{\beta}}{\partial x_2^{\beta}}\\
\label{eqn:3chempot2b}
\frac{\partial G_{\alpha}}{\partial x_2^{\alpha}}
&= \frac{\partial G_{\gamma}}{\partial x_2^{\gamma}}
\end{align}
Eqns.~\ref{eqn:3chempot2a}~\&~\ref{eqn:3chempot2b} represent equality of
chemical potential of component 2 in pairs of phases $\alpha-\beta$ and
$\alpha-\gamma$. Solving Eqns.~\ref{eqn:3el7},~\ref{eqn:3el8}~\&~\ref{eqn:3el9}
for $\lambda_3$ gives
\begin{align}
\lambda_3 &= G_{\alpha}
- \frac{\partial G_{\alpha}}{\partial x_1^{\alpha}} x_1^{\alpha}
- \frac{\partial G_{\alpha}}{\partial x_2^{\alpha}} x_2^{\alpha}
= G_{\beta}
- \frac{\partial G_{\alpha}}{\partial x_1^{\alpha}} x_1^{\beta}
- \frac{\partial G_{\alpha}}{\partial x_2^{\alpha}} x_2^{\beta}
= G_{\gamma}
- \frac{\partial G_{\alpha}}{\partial x_1^{\alpha}} x_1^{\gamma}
- \frac{\partial G_{\alpha}}{\partial x_2^{\alpha}} x_2^{\gamma}\\
\label{eqn:3grandpot1}
\therefore G_{\beta} &= G_{\alpha}
- \frac{\partial G_{\alpha}}{\partial x_1^{\alpha}}(x_1^{\alpha} - x_1^{\beta})
- \frac{\partial G_{\alpha}}{\partial x_2^{\alpha}}(x_2^{\alpha} - x_2^{\beta})\\
\label{eqn:3grandpot2}
G_{\gamma} &= G_{\alpha}
- \frac{\partial G_{\alpha}}{\partial x_1^{\alpha}}(x_1^{\alpha} - x_1^{\gamma})
- \frac{\partial G_{\alpha}}{\partial x_2^{\alpha}}(x_2^{\alpha} - x_2^{\gamma})
\end{align}
These represent equality of the grand potentials between pairs of phases $\alpha-\beta$ and
$\alpha-\gamma$.
The system of Eqns.~\ref{eqn:3chempot1a}, \ref{eqn:3chempot1b},
\ref{eqn:3chempot2a}, \ref{eqn:3chempot2b}, \ref{eqn:3grandpot1} \&
\ref{eqn:3grandpot2} represents 6 equations for 6 unknowns, which can be solved
for the equilibrium plane containing the points
$G_{\alpha}(x_1^{\alpha},x_2^{\alpha}), G_{\beta}(x_1^{\beta},x_2^{\beta})$ and
$G_{\gamma}(x_1^{\gamma},x_2^{\gamma})$.
\section*{Put it All Together}
The code accompanying this document generates the equilibrium isothermobaric
(constant $T$ and $P$) phase diagram for a ternary alloy with three phases. The
program iterates through system compositions $(x_1, x_2)$ in the Gibbs simplex.
At each test point, test energies are computed for
\begin{enumerate}
\item $G_{\alpha}(x_1, x_2)$
\item $G_{\beta}(x_1, x_2)$
\item $G_{\gamma}(x_1, x_2)$
\item $G_{\alpha\beta} = v_{\alpha}G_{\alpha}(x_1^{\alpha}, x_2^{\alpha})
+ v_{\beta}G_{\beta}(x_1^{\beta}, x_2^{\beta})$
\item $G_{\alpha\gamma} = v_{\alpha}G_{\alpha}(x_1^{\alpha}, x_2^{\alpha})
+ v_{\gamma}G_{\gamma}$
\item $G_{\beta\gamma} = v_{\beta}G_{\beta}(x_1^{\beta}, x_2^{\beta})
+ v_{\gamma}G_{\gamma}(x_1^{\gamma}, x_2^{\gamma})$
\item $G_{\alpha\beta\gamma} = v_{\alpha}G_{\alpha}(x_1^{\alpha}, x_2^{\alpha})
+ v_{\beta}G_{\beta}(x_1^{\beta}, x_2^{\beta})
+ v_{\gamma}G_{\gamma}(x_1^{\gamma}, x_2^{\gamma})$
\end{enumerate}
The equilibrium phases and compositions corresponding to the system composition
$(x_1, x_2)$ are those corresponding to the minimum energy represented in that
set of 7 possibilities, subject to the constraint that all endpoints must lie
within the Gibbs simplex.
\end{document}