3#include "math/libfunc.h"
12 real damp = pdi * pdk;
13 real ratio = r * REAL_RECIP(damp);
14 damp = (damp == 0 ? ((
real)-1.0e16) : -pgamma * ratio * ratio * ratio);
15 real expdamp = REAL_EXP(damp);
17 scale5 = 1 - expdamp * (1 - damp);
24 real pgamma = REAL_MIN(pti, ptk);
33 real damp = pdi * pdk;
34 real ratio = r * REAL_RECIP(damp);
35 damp = (damp == 0 ? ((
real)-1.0e16) : -pgamma * ratio * ratio * ratio);
36 real expdamp = REAL_EXP(damp);
38 scale5 = 1 - expdamp * (1 - damp);
39 scale7 = 1 - expdamp * (1 - damp + (
real)0.6 * damp * damp);
46 real pgamma = REAL_MIN(pti, ptk);
47 dmpthole3_a(r, pgamma, pdi, pdk, scale3, scale5, scale7);
58 real damp = pdi * pdk;
59 real ratio = r * REAL_RECIP(damp);
60 damp = (damp == 0 ? ((
real)1.0e16) : pgamma * ratio * ratio * ratio);
61 scale31 = REAL_EXP(-damp);
62 scale51 = scale31 * (1 + damp);
63 scale71 = scale31 * (1 + damp + (
real)0.6 * damp * damp);
64 real temp3 = 3 * damp * scale31 * rr2;
86 real pgamma = REAL_MIN(pti, ptk);
87 dmpthole3g_a(r, rr2, xr, yr, zr, pgamma, pdi, pdk, scale31, scale51, scale71,
88 rc31, rc32, rc33, rc51, rc52, rc53, rc71, rc72, rc73);
96 real damp = pdi * pdk;
97 real ratio = r * REAL_RECIP(damp);
98 damp = (damp == 0 ? ((
real)1.0e16) : pgamma * ratio * ratio * ratio);
99 ex3 = REAL_EXP(-damp);
100 ex5 = ex3 * (1 + damp);
101 ex7 = ex3 * (1 + damp + (
real)0.6 * damp * damp);
104 ex9 = ex3 * (1 + damp * (1 + damp * (coef1 + coef2 * damp)));
112 real pgamma = REAL_MIN(pti, ptk);
113 dmpthole4_a(r, pgamma, pdi, pdk, ex3, ex5, ex7, ex9);
116#pragma acc routine seq
122 real ralpha = aewald * r;
123 bn[0] = REAL_ERFC(ralpha) * rinv;
124 real alsq2 = 2 * aewald * aewald;
126 real exp2a = REAL_EXP(-ralpha * ralpha);
128 for (
int j = 1; j < order; ++j) {
130 bn[j] = ((j + j - 1) * bn[j - 1] + alsq2n * exp2a) * rr2;
#define SEQ_ROUTINE
Definition: acc/seqdef.h:7
#define SEQ_CUDA
Definition: acc/seqdef.h:12
#define restrict
Definition: macro.h:51
constexpr real sqrtpi
Definition: const.h:11
float real
Definition: precision.h:80
__device__ void damp_ewald(real *__restrict__ bn, real r, real rinv, real rr2, real aewald)
Definition: damp.h:119
__device__ void damp_thole3(real r, real pdi, real pti, real pdk, real ptk, real &__restrict__ scale3, real &__restrict__ scale5, real &__restrict__ scale7)
Definition: damp.h:43
__device__ void dmpthole3_a(real r, real pgamma, real pdi, real pdk, real &__restrict__ scale3, real &__restrict__ scale5, real &__restrict__ scale7)
Definition: damp.h:30
__device__ void dmpthole2_a(real r, real pgamma, real pdi, real pdk, real &__restrict__ scale3, real &__restrict__ scale5)
Definition: damp.h:9
__device__ void dmpthole3g_a(real r, real rr2, real xr, real yr, real zr, real pgamma, real pdi, real pdk, real &__restrict__ scale31, real &__restrict__ scale51, real &__restrict__ scale71, real &__restrict__ rc31, real &__restrict__ rc32, real &__restrict__ rc33, real &__restrict__ rc51, real &__restrict__ rc52, real &__restrict__ rc53, real &__restrict__ rc71, real &__restrict__ rc72, real &__restrict__ rc73)
Definition: damp.h:51
__device__ void damp_thole3g(real r, real rr2, real xr, real yr, real zr, real pdi, real pti, real pdk, real ptk, real &__restrict__ scale31, real &__restrict__ scale51, real &__restrict__ scale71, real &__restrict__ rc31, real &__restrict__ rc32, real &__restrict__ rc33, real &__restrict__ rc51, real &__restrict__ rc52, real &__restrict__ rc53, real &__restrict__ rc71, real &__restrict__ rc72, real &__restrict__ rc73)
Definition: damp.h:79
__device__ void dmpthole4_a(real r, real pgamma, real pdi, real pdk, real &__restrict__ ex3, real &__restrict__ ex5, real &__restrict__ ex7, real &__restrict__ ex9)
Definition: damp.h:92
__device__ void damp_thole4(real r, real pdi, real pti, real pdk, real ptk, real &__restrict__ ex3, real &__restrict__ ex5, real &__restrict__ ex7, real &__restrict__ ex9)
Definition: damp.h:108
__device__ void damp_thole2(real r, real pdi, real pti, real pdk, real ptk, real &__restrict__ scale3, real &__restrict__ scale5)
Definition: damp.h:21