11.2 Thermomechanical code structure 153
associated with each marker. This approach allows us to minimise the amount of
storage associated with markers to only 3 floating point values (two coordinates
and temperature) and one integer (rock type). The amount of different rock types in
one experiment is typically limited to few tens at most. There are several equations
(rheology, density, etc.) associated with each rock type which allow us to compute
various properties for a marker of a given type, based on the local temperature
and pressure at this marker. The effective values of all these properties at the
Eulerian nodal points are computed from the markers at each time step by using a
bilinear interpolation (Eq. (8.18)). Note that viscosity for shear (η
s
) and normal (η
n
)
stresses is interpolated separately (Fig. 11.2) by using a local interpolation scheme
that takes into account markers found within half a grid spacing distance from
the nodes, in both the horizontal and vertical directions (see dashed boundary in
Fig. 8.8). The statistical weights of these markers thus vary from 0.25 to 1 (one
can also renormalise these weights to vary from 0 to 1). The local interpolation
of viscosity allows for a more accurate solution of the momentum equation in the
case of a strongly variable viscosity (Gerya and Yuen, 2007; Schmeling et al.,
2008). All other properties are interpolated to the basic nodes (cf. solid squares
in Fig. 11.2) using a standard scheme that involves markers found in the four
grid cells around each node (Fig. 8.8, Eq. (8.18)). In cases when we require a
more accurate solution of the temperature equation, for example under the con-
dition of a strongly variable thermal conductivity, localised interpolation schemes
from markers should also be used for the thermal conductivity k that will be com-
puted separately for the different heat flux nodes (see solid and open circles in
Fig. 11.2). Thermal boundary conditions should be applied to the obtained nodal
values after interpolating the temperature from markers. This precludes accumulat-
ing an interpolation error which will otherwise grow along the model boundaries
as the number of time steps increases.
We use a standard, first-order-accurate bilinear interpolation procedure that
involves four nodal points (Fig. 8.9, Eq. (8.19)) for the reverse problem of inter-
polating scalar properties (including calculated temperature changes), vectors and
tensors from the corresponding Eulerian nodal points (see different types of Eule-
rian nodes in Fig. 11.2), back to the markers and other geometric points (e.g.
other nodes). Equation (8.19) is used uniformly, for interpolating velocity, stresses,
strain rates, pressure, temperature and other properties from nodal points to mark-
ers. Since our staggered grid represents, in fact, the superposition of four simple
rectangular grids corresponding to different scalar fields, vectors and tensors (see
four different symbols for grid points in Fig. 10.2), these Eulerian grids are used
individually for interpolating the respective field variables. Defining the indices
of the four nodal points that surround a given marker is done on the basis of the
bisection procedure (Fig. 8.10).