Tabulated pair¶
Description¶
The tabpair_compute_force operator interpolates a pair potential given as a table. The table gives, on a set of distances \(r_k\), the energy \(E(r_k)\) and its derivative \(\mathrm{d}E/\mathrm{d}r\,(r_k)\). Both are interpolated with cubic splines:
The energy and the derivative are interpolated independently, so the table must provide a consistent derivative.
The table is read from a YAML file (searched in the data paths) or given inline. It contains three lists of the same length:
| Key | Units | Description |
|---|---|---|
r |
distance | Distances \(r_k\), in increasing order |
e |
energy | Energy \(E(r_k)\) |
de |
energy/distance | Derivative \(\mathrm{d}E/\mathrm{d}r\) at \(r_k\) |
format |
— | Optional. exastampv1: values are plain numbers in SI units (m, J, N) |
Without format, each value is read as a quantity, so units can be given value by value (2.5 ang, 0.01 eV, ...). Values without units are taken in internal units.
YAML syntax¶
- VALUE = Physical value of the intended parameter.
- UNITS = Units of the provided value that will be passed to the conversion helper for internal units conversion.
- FILENAME = YAML file with the
r,eanddelists.parameters: FILENAMEis also accepted.
Inline data can be given instead of a file:
tabpair_compute_force:
rcut: 5.0 ang
parameters:
r: [ 2.0 ang , 2.5 ang , ... ]
e: [ 1.2 eV , 0.3 eV , ... ]
de: [ -5.1 eV/ang , -1.0 eV/ang , ... ]
Usage examples¶
Systems with a single atomic specy
Systems with multiple atomic species
Note
lj_tab.yml (a tabulated Lennard-Jones potential, exastampv1 format) is shipped in exaStamp/data/potentials/. The tabulated pair potential runs on CPU only.