onsager.out

This file contains block averages of components of the Onsager coefficient tensors from the homogeneous nonequilibrium molecular dynamics Evans-Cummings algorithm (HNEMDEC) method. It is generated when invoking the compute_hnemdec keyword. Each row averages the preceding output_interval MD steps, rather than all steps since the start of the run. Rows are appended to the file, with \(3(M+1)\) columns for \(M\) elements and no time column.

File format

If the driving force is in the \(\mu\) (\(\mu\) can be \(x\), \(y\), or \(z\)) direction and the dissipative flux is set as heat flux, for a system with \(M\) elements, this file reads:

  • column 1: \(L_{x \mu}^{\text{qq}}(t)\) (in units of \(W/mK\))

  • column 2: \(L_{y \mu}^{\text{qq}}(t)\) (in units of \(W/mK\))

  • column 3: \(L_{z \mu}^{\text{qq}}(t)\) (in units of \(W/mK\))

  • column 4: \(L_{x \mu}^{\text{1q}}(t)\) (in units of \(10^{-6} kg/smK\))

  • column 5: \(L_{y \mu}^{\text{1q}}(t)\) (in units of \(10^{-6} kg/s/m/K\))

  • column 6: \(L_{z \mu}^{\text{1q}}(t)\) (in units of \(10^{-6} kg/s/m/K\))

  • …

  • column 3M+1: \(L_{x \mu}^{\text{Mq}}(t)\) (in units of \(10^{-6} kg/smK\))

  • column 3M+2: \(L_{y \mu}^{\text{Mq}}(t)\) (in units of \(10^{-6} kg/smK\))

  • column 3M+3: \(L_{z \mu}^{\text{Mq}}(t)\) (in units of \(10^{-6} kg/smK\))

If the dissipative flux is changed to momentum flux of component \(\alpha\), this file reads:

  • column 1: \(L_{x \mu}^{q\alpha}(t)\) (in units of \(10^{-6} kg/smK\))

  • column 2: \(L_{y \mu}^{q\alpha}(t)\) (in units of \(10^{-6} kg/smK\))

  • column 3: \(L_{z \mu}^{q\alpha}(t)\) (in units of \(10^{-6} kg/smK\))

  • column 4: \(L_{x \mu}^{1\alpha}(t)\) (in units of \(10^{-12} kgs/m^{3}K\))

  • column 5: \(L_{y \mu}^{1\alpha}(t)\) (in units of \(10^{-12} kgs/m^{3}K\))

  • column 6: \(L_{z \mu}^{1\alpha}(t)\) (in units of \(10^{-12} kgs/m^{3}K\))

  • …

  • column \(3M+1\): \(L_{x \mu}^{M\alpha}(t)\) (in units of \(10^{-12} kgs/m^{3}K\))

  • column \(3M+2\): \(L_{y \mu}^{M\alpha}(t)\) (in units of \(10^{-12} kgs/m^{3}K\))

  • column \(3M+3\): \(L_{z \mu}^{M\alpha}(t)\) (in units of \(10^{-12} kgs/m^{3}K\))

Both the potential part and the kinetic part of the heat current have been considered. One can obtain the onsager coefficient \(\Lambda_{i j}^{ml}\) by:

\[\Lambda_{i j}^{ml}=T^{2}L_{i j}^{ml}\]

Obtaining the thermal conductivity

For each driving direction, use separate calculations with thermal driving (driving_force = 0) and diffusive driving for \(M-1\) selected components. Use the same temperature, composition, and density, with a sufficiently small positive field along one Cartesian axis per calculation. Average the output blocks after equilibration, and save the output from each calculation separately.

At zero total momentum, the component momentum currents obey \(\sum_{\alpha=1}^{M}\boldsymbol{J}_{\alpha}=0\). Keep the heat current and the same \(M-1\) independent momentum currents when assembling rows and driving-force columns of the Onsager matrix. Including all \(M\) component momentum currents gives a linearly dependent matrix.

Convert the printed values to SI units before assembling the matrix: multiply heat–momentum and momentum–heat coefficients by \(10^{-6}\), and momentum–momentum coefficients by \(10^{-12}\). Heat–heat coefficients already have units of W/(m K). The response-current index specifies the row and the driven-current index specifies the column.

Writing the matrix of coefficients \(L=\Lambda/T^2\) in heat (\(q\)) and independent momentum (\(d\)) blocks, the thermal conductivity at zero component mass currents is

\[\boldsymbol{\kappa}=L^{qq}-L^{qd}(L^{dd})^{-1}L^{dq}.\]

For general anisotropic transport, these blocks include the Cartesian components obtained from calculations driven along all three axes. For an isotropic system or a Cartesian direction decoupled from the other directions, the calculation reduces to an \(M\times M\) matrix for that direction.

For example, consider a binary system driven along \(x\), retaining the momentum current of the first component. Use driving_force = 0 and 1 in separate calculations, and save their outputs as onsager_heat.out and onsager_diffusion.out. The longitudinal conductivity can then be calculated as follows (the example discards the first 100 output blocks; choose this number from the equilibration behavior):

import numpy as np

n_skip = 100
thermal = np.loadtxt("onsager_heat.out", ndmin=2)[n_skip:].mean(axis=0)
diffusive = np.loadtxt("onsager_diffusion.out", ndmin=2)[n_skip:].mean(axis=0)
Lqq = thermal[0]
L1q = thermal[3] * 1e-6
Lq1 = diffusive[0] * 1e-6
L11 = diffusive[3] * 1e-12
kappa_xx = Lqq - Lq1 * L1q / L11

The result is in W/(m K), and no additional factor of \(T^2\) is needed. In this binary expression, the unit-conversion factors cancel because \(10^{-6}\times10^{-6}/10^{-12}=1\), so the same result can also be obtained directly from the printed values. The Ar-Kr HNEMDEC tutorial provides input files, output data, and a post-processing script that uses this cancellation and also plots running averages of the output blocks.