namespace rgpot_edip¶
Overview¶
EDIP silicon in gather form. More…
namespace rgpot_edip {
// global variables
real(wp), parameter exp_floor = -300.0_wp;
// global functions
subroutine, public edip_energy_forces(real(wp), dimension(:, :), intent(in), contiguous positions, real(wp), dimension(3, 3), intent(in) cell, type(edip_params_t), intent(in) par, type(neighbor_table_t), intent(inout) table, real(wp), intent(out) energy, real(wp), dimension(:, :), intent(out), contiguous forces, integer, intent(out) status, character(len=:), intent(out), allocatable errmsg);
} // namespace rgpot_edip
Detailed Documentation¶
EDIP silicon in gather form.
EDIP gives atom i a pair sum whose strength depends on a coordination number Z_i, plus a three-body sum over the neighbour pairs i centres:
E_i = sum_j V2(r_ij, Z_i) + sum_{j<k} V3(r_ij, r_ik, theta_jik, Z_i)
Z_i counts neighbours through a cutoff function f(r) that falls from one to zero between c and b, so every term of E_i also pushes on the atoms that set Z_i. The published form is a scatter with three force channels writing into other atoms’ slots, which serialises the atom loop.
The gather closes because both environment dependencies collapse to one scalar per atom, Z_i and dE_i/dZ_i. With those known the whole force on i is a sum over i ‘s own neighbourhood:
two-body,
[dV2/dr(r_ij, Z_i) + dV2/dr(r_ij, Z_j)] * u_ij;coordination,
[dE_i/dZ_i + dE_j/dZ_j] * df/dr(r_ij) * u_ij;three-body,
ias the centre of(j, i, k)and as an end of every triplet centred on a neighbourm, the two roles ofrgpot_sw.
Evaluation is therefore two do concurrent passes: one over the per-atom scalars (Z, energy, dE/dZ), one over forces. Neither writes outside the atom it is indexed by.
A triplet whose two ends are the same atom reached through different periodic images is dropped, in the centre role and the end role alike, so the force stays the exact gradient of the energy reported here.
Global Variables¶
real(wp), parameter exp_floor = -300.0_wp
Exponential arguments below this underflow to zero; guarding keeps exp out of its denormal range for pairs sitting at a cutoff.
Global Functions¶
subroutine, public edip_energy_forces(real(wp), dimension(:, :), intent(in), contiguous positions, real(wp), dimension(3, 3), intent(in) cell, type(edip_params_t), intent(in) par, type(neighbor_table_t), intent(inout) table, real(wp), intent(out) energy, real(wp), dimension(:, :), intent(out), contiguous forces, integer, intent(out) status, character(len=:), intent(out), allocatable errmsg)
Energy and forces for positions (3 x natoms) in cell.