NAMD
|
#include "msm_defn.h"
Go to the source code of this file.
Functions | |
static int | setup_bin_data (NL_Msm *pm) |
static int | spatial_hashing (NL_Msm *pm) |
static int | bin_evaluation_1away (NL_Msm *pm) |
static int | bin_evaluation_k_away (NL_Msm *pm) |
int | NL_msm_compute_short_range_sprec (NL_Msm *pm) |
|
static |
Definition at line 117 of file msm_shortrng_sprec.c.
References NL_Msm_t::a_f, NL_Msm_t::atom_f, NL_Msm_t::bin, NL_Msm_t::cellvec1_f, NL_Msm_t::cellvec2_f, NL_Msm_t::cellvec3_f, NL_Msm_t::felec_f, NL_Msm_t::msmflags, NL_Msm_t::nbx, NL_Msm_t::nby, NL_Msm_t::nbz, next(), NL_Msm_t::next, NL_MSM_PERIODIC_VEC1, NL_MSM_PERIODIC_VEC2, NL_MSM_PERIODIC_VEC3, NL_MSM_SUCCESS, Q, split(), NL_Msm_t::split, SPOLY_SPREC, NL_Msm_t::uelec, X, Y, and Z.
Referenced by NL_msm_compute_short_range_sprec().
|
static |
Definition at line 273 of file msm_shortrng_sprec.c.
References NL_Msm_t::a_f, NL_Msm_t::atom_f, NL_Msm_t::bin, NL_Msm_t::cellvec1_f, NL_Msm_t::cellvec2_f, NL_Msm_t::cellvec3_f, NL_Msm_t::felec_f, NL_Msm_t::msmflags, NL_Msm_t::nbrhd, NL_Msm_t::nbrhdlen, NL_Msm_t::nbx, NL_Msm_t::nby, NL_Msm_t::nbz, next(), NL_Msm_t::next, NL_MSM_PERIODIC_VEC1, NL_MSM_PERIODIC_VEC2, NL_MSM_PERIODIC_VEC3, NL_MSM_SUCCESS, Q, split(), NL_Msm_t::split, SPOLY_SPREC, NL_Msm_t::uelec, X, Y, and Z.
Referenced by NL_msm_compute_short_range_sprec().
int NL_msm_compute_short_range_sprec | ( | NL_Msm * | pm | ) |
Definition at line 37 of file msm_shortrng_sprec.c.
References bin_evaluation_1away(), bin_evaluation_k_away(), NL_Msm_t::maxatoms, NL_Msm_t::msmflags, NL_MSM_COMPUTE_1AWAY, NL_MSM_SUCCESS, NL_Msm_t::numatoms, setup_bin_data(), and spatial_hashing().
Referenced by NL_msm_compute_force_sprec().
|
static |
Compute the short-range part of MSM forces, using single precision.
Perform spatial hashing of atoms into bins. The implementation uses the simplest approach where the bin lengths are at least as large as the cutoff distance, so only nearest neighbor bins need be checked. The bins are represented by a simple linked list of atom indices using fixed array storage: an array of int for the bins giving the index of a "head" atom in the bin and an array of int for the "next" atom in the bin, where -1 denotes the end of the list.
The formulation of bins is determined for an arbitrary set of basis vectors and the spatial hashing is performed in reciprocal space, so this part of the MSM code is ready to support non-orthogonal basis vectors.
XXX The virial is not calculated.
XXX The idea of excluded interaction pairs is totally disregarded. This should be fine for calculating normal systems of atoms, where the full 1/r interaction is later subtracted out for excluded pairs without causing excessive numerical error. However, doing so will be a problem for systems containing Drude particles, possibly also for lone pairs, and is unsuitable for calculating Lennard-Jones.
Definition at line 57 of file msm_shortrng_sprec.c.
References ASSERT, NL_Msm_t::maxatoms, NL_Msm_t::next, NL_MSM_ERROR_MALLOC, NL_MSM_SUCCESS, and NL_Msm_t::numatoms.
Referenced by NL_msm_compute_short_range_sprec().
|
static |
Definition at line 69 of file msm_shortrng_sprec.c.
References NL_Msm_t::atom_f, NL_Msm_t::bin, NL_Msm_t::cellcenter_f, NL_Msm_t::nbx, NL_Msm_t::nby, NL_Msm_t::nbz, next(), NL_Msm_t::next, NL_MSM_SUCCESS, numatoms, NL_Msm_t::numatoms, NL_Msm_t::numbins, NL_Msm_t::recipvec1_f, NL_Msm_t::recipvec2_f, NL_Msm_t::recipvec3_f, X, Y, and Z.
Referenced by NL_msm_compute_short_range_sprec().