Skip to content

Commit e40ab56

Browse files
authored
Merge pull request #701 from bobmyhill/add_relaxation_docs
added relaxation documentation
2 parents 34ffb7a + f2c3c61 commit e40ab56

File tree

2 files changed

+88
-0
lines changed

2 files changed

+88
-0
lines changed

docs/background.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ Here is a bit of background on the methods used to calculate thermoelastic and t
66

77
.. include:: background_thermoelastics.txt
88
.. include:: background_thermodynamics.txt
9+
.. include:: background_relaxation.txt
910
.. include:: background_solutions.txt
1011
.. include:: background_composites.txt
1112
.. include:: background_equilibration.txt

docs/background_relaxation.txt

Lines changed: 87 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,87 @@
1+
Calculating Relaxed Thermodynamic Properties
2+
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
3+
4+
Burnman can calculate relaxed thermodynamic properties for materials that have
5+
isochemical degrees of freedom. This is done by minimizing the Gibbs free energy
6+
of the system with respect to the isochemical variables at each pressure and
7+
temperature point. If these isochemical variables can vary on timescales
8+
shorter than the timescales of changes in pressure and temperature,
9+
then the second derivatives of the Gibbs free energy with respect to these variables
10+
are affected by the relaxation.
11+
12+
To calculate these properties, we use
13+
variational calculus. Let the extent of the isochemical reactions be given by the
14+
vector :math:`\xi`. Let us also define the partial derivative function
15+
:math:`F(P,T,X,\xi) = \partial G / \partial \xi`, where :math:`G` is the Gibbs free energy
16+
of the system. The relaxed state is given by the condition :math:`F(P,T,X,\xi) = 0`.
17+
For simplicity, let us group the pressure, temperature, and composition variables
18+
into a single vector :math:`Z = (P,T,X)` (we aren't actually interested in the composition,
19+
but keep it here for completeness). Finally, we define a function
20+
:math:`\phi(Z) = \xi`, which gives the extent of the isochemical reactions
21+
at equilibrium for given pressure, temperature, and composition.
22+
Assuming that the reaction variables are always at equilibrium, we have:
23+
.. math::
24+
F = F(Z, \phi(Z)) = \frac{\partial G}{\partial \xi} (Z, \phi(Z))
25+
26+
Taking the total derivative of this expression with respect to :math:`Z`, we have:
27+
.. math::
28+
\frac{d F}{d Z} = \frac{\partial F}{\partial Z} + \frac{\partial F}{\partial \xi}
29+
\frac{\partial \phi}{\partial Z}
30+
31+
Now, since :math:`F(Z, \phi(Z)) = 0` for all :math:`Z`, we also have :math:`d F / d Z = 0`,
32+
and therefore:
33+
.. math::
34+
\frac{\partial F}{\partial \xi}
35+
\frac{\partial \phi}{\partial Z} = - \frac{\partial F}{\partial Z}
36+
37+
Note that the matrix :math:`\partial F / \partial \xi` is the Hessian matrix of second derivatives
38+
of the Gibbs free energy with respect to the isochemical variables:
39+
.. math::
40+
41+
\frac{\partial F}{\partial \xi} = \frac{\partial^2 G}{\partial \xi^2}
42+
43+
It is therefore symmetric. Let us define the pseudo-inverse of this matrix as
44+
:math:`R`, so that :math:`R \partial F / \partial \xi = I`, where :math:`I` is the identity matrix.
45+
Then we have:
46+
.. math::
47+
\frac{\partial \phi}{\partial Z} = - R \frac{\partial F}{\partial Z}
48+
49+
50+
Finally, define a function :math:`g(Z) = G(Z, \phi(Z))`, which gives the Gibbs free energy
51+
of the system at equilibrium. Using the chain rule, we can write the total derivative of this function with respect to :math:`Z` as:
52+
.. math::
53+
\frac{d g}{d Z} = \frac{\partial G}{\partial Z} + \frac{\partial G}{\partial \xi}
54+
\frac{\partial \phi}{\partial Z}
55+
56+
However, since :math:`F = \partial G / \partial \xi = 0`, the second term on the right-hand side
57+
vanishes, and we have:
58+
.. math::
59+
\frac{d g}{d Z} = \frac{\partial G(Z, \phi(Z))}{\partial Z}
60+
61+
Taking the second derivative of :math:`g` with respect to :math:`Z`, we have:
62+
.. math::
63+
\frac{d^2 g}{d Z^2} = \frac{\partial^2 G}{\partial Z^2} +
64+
\frac{\partial^2 G}{\partial Z \partial \xi} \frac{\partial \phi}{\partial Z}
65+
66+
67+
Now, substituting in our expression for :math:`\partial \phi / \partial Z`, we have:
68+
.. math::
69+
\frac{d^2 g}{d Z^2} = \frac{\partial^2 G}{\partial Z^2} -
70+
\frac{\partial^2 G}{\partial Z \partial \xi} R
71+
\frac{\partial F}{\partial Z}
72+
73+
or, equivalently:
74+
.. math::
75+
\frac{d^2 g}{d Z^2} = \frac{\partial^2 G}{\partial Z^2} -
76+
\frac{\partial^2 G}{\partial Z \partial \xi}
77+
R
78+
\frac{\partial^2 G}{\partial \xi \partial Z}
79+
80+
This expression gives the relaxed second derivatives of the Gibbs free energy
81+
with respect to pressure, temperature, and composition. These second derivatives
82+
can then be used to calculate the relaxed thermodynamic properties of the system,
83+
such as the bulk modulus, thermal expansivity, and heat capacity:
84+
.. math::
85+
K_{P,relaxed} = -V \left(\frac{\partial^2 g}{\partial P^2}\right)^{-1}, \quad
86+
\alpha_{relaxed} = \frac{1}{V} \frac{\partial^2 g}{\partial P \partial T}, \quad
87+
C_{P,relaxed} = - T \frac{\partial^2 g}{\partial T^2}

0 commit comments

Comments
 (0)