Skip to content

Commit

Permalink
Fix integral ggkin
Browse files Browse the repository at this point in the history
  • Loading branch information
sunqm committed May 14, 2020
1 parent 220c17b commit b42531d
Show file tree
Hide file tree
Showing 5 changed files with 16 additions and 14 deletions.
2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
cmake_minimum_required (VERSION 2.6)
project (cint C)
set(cint_SOVERSION "3")
set(cint_VERSION "3.0.19")
set(cint_VERSION "3.0.20")

#set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -g -O2 -DNDEBUG")
if ("${CMAKE_BUILD_TYPE}" STREQUAL "")
Expand Down
2 changes: 2 additions & 0 deletions ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
Version 3.0.20 (2020-05-13):
* Fix integral ggkin
Version 3.0.19 (2019-11-30):
* support fractional nuclear charges
Version 3.0.18 (2019-07-02):
Expand Down
4 changes: 2 additions & 2 deletions README
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
libcint
=======

version 3.0.19
2019-11-30
version 3.0.20
2020-05-13


What is libcint
Expand Down
2 changes: 1 addition & 1 deletion scripts/auto_intor.cl
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@
'("int1e_irrp" ( \| rc rc nabla \| ))
'("int1e_irpr" ( \| rc nabla rc \| ))
'("int1e_ggovlp" ( \| g g \|))
'("int1e_ggkin" (.5 \| g g nabla dot nabla \|))
'("int1e_ggkin" (.5 \| g g p dot p \|))
'("int1e_ggnuc" ( \| g g nuc \|))
'("int1e_grjxp" ( \| g r cross p \|))
'("int1e_rinv" (\| rinv \|))
Expand Down
20 changes: 10 additions & 10 deletions src/autocode/intor1.c
Original file line number Diff line number Diff line change
Expand Up @@ -2779,7 +2779,7 @@ return CINT1e_spinor_drv(out, dims, &envs, cache, &c2s_sf_1e, 0);
} // int1e_ggovlp_spinor
ALL_CINT1E(int1e_ggovlp)
ALL_CINT1E_FORTRAN_(int1e_ggovlp)
/* <i|G G NABLA DOT NABLA |j> */
/* <i|G G P DOT P |j> */
void CINTgout1e_int1e_ggkin(double *gout, double *g, FINT *idx, CINTEnvVars *envs, FINT gout_empty) {
FINT nf = envs->nf;
FINT ix, iy, iz, n;
Expand Down Expand Up @@ -2913,15 +2913,15 @@ s[77] = + g0[ix+0]*g2[iy+0]*g13[iz+0];
s[78] = + g1[ix+0]*g0[iy+0]*g14[iz+0];
s[79] = + g0[ix+0]*g1[iy+0]*g14[iz+0];
s[80] = + g0[ix+0]*g0[iy+0]*g15[iz+0];
gout[n*9+0] += - c[4]*s[72] + 2*c[5]*s[63] - c[8]*s[36] - c[4]*s[76] + 2*c[5]*s[67] - c[8]*s[40] - c[4]*s[80] + 2*c[5]*s[71] - c[8]*s[44];
gout[n*9+1] += - c[5]*s[54] + c[8]*s[27] + c[3]*s[72] - c[6]*s[45] - c[5]*s[58] + c[8]*s[31] + c[3]*s[76] - c[6]*s[49] - c[5]*s[62] + c[8]*s[35] + c[3]*s[80] - c[6]*s[53];
gout[n*9+2] += - c[3]*s[63] + c[6]*s[36] + c[4]*s[54] - c[7]*s[27] - c[3]*s[67] + c[6]*s[40] + c[4]*s[58] - c[7]*s[31] - c[3]*s[71] + c[6]*s[44] + c[4]*s[62] - c[7]*s[35];
gout[n*9+3] += - c[7]*s[18] + c[1]*s[72] + c[8]*s[9] - c[2]*s[63] - c[7]*s[22] + c[1]*s[76] + c[8]*s[13] - c[2]*s[67] - c[7]*s[26] + c[1]*s[80] + c[8]*s[17] - c[2]*s[71];
gout[n*9+4] += - c[8]*s[0] + 2*c[6]*s[18] - c[0]*s[72] - c[8]*s[4] + 2*c[6]*s[22] - c[0]*s[76] - c[8]*s[8] + 2*c[6]*s[26] - c[0]*s[80];
gout[n*9+5] += - c[6]*s[9] + c[0]*s[63] + c[7]*s[0] - c[1]*s[54] - c[6]*s[13] + c[0]*s[67] + c[7]*s[4] - c[1]*s[58] - c[6]*s[17] + c[0]*s[71] + c[7]*s[8] - c[1]*s[62];
gout[n*9+6] += - c[1]*s[45] + c[4]*s[18] + c[2]*s[36] - c[5]*s[9] - c[1]*s[49] + c[4]*s[22] + c[2]*s[40] - c[5]*s[13] - c[1]*s[53] + c[4]*s[26] + c[2]*s[44] - c[5]*s[17];
gout[n*9+7] += - c[2]*s[27] + c[5]*s[0] + c[0]*s[45] - c[3]*s[18] - c[2]*s[31] + c[5]*s[4] + c[0]*s[49] - c[3]*s[22] - c[2]*s[35] + c[5]*s[8] + c[0]*s[53] - c[3]*s[26];
gout[n*9+8] += - c[0]*s[36] + 2*c[1]*s[27] - c[4]*s[0] - c[0]*s[40] + 2*c[1]*s[31] - c[4]*s[4] - c[0]*s[44] + 2*c[1]*s[35] - c[4]*s[8];
gout[n*9+0] += + c[4]*s[72] -2*c[5]*s[63] + c[8]*s[36] + c[4]*s[76] -2*c[5]*s[67] + c[8]*s[40] + c[4]*s[80] -2*c[5]*s[71] + c[8]*s[44];
gout[n*9+1] += + c[5]*s[54] - c[8]*s[27] - c[3]*s[72] + c[6]*s[45] + c[5]*s[58] - c[8]*s[31] - c[3]*s[76] + c[6]*s[49] + c[5]*s[62] - c[8]*s[35] - c[3]*s[80] + c[6]*s[53];
gout[n*9+2] += + c[3]*s[63] - c[6]*s[36] - c[4]*s[54] + c[7]*s[27] + c[3]*s[67] - c[6]*s[40] - c[4]*s[58] + c[7]*s[31] + c[3]*s[71] - c[6]*s[44] - c[4]*s[62] + c[7]*s[35];
gout[n*9+3] += + c[7]*s[18] - c[1]*s[72] - c[8]*s[9] + c[2]*s[63] + c[7]*s[22] - c[1]*s[76] - c[8]*s[13] + c[2]*s[67] + c[7]*s[26] - c[1]*s[80] - c[8]*s[17] + c[2]*s[71];
gout[n*9+4] += + c[8]*s[0] -2*c[6]*s[18] + c[0]*s[72] + c[8]*s[4] -2*c[6]*s[22] + c[0]*s[76] + c[8]*s[8] -2*c[6]*s[26] + c[0]*s[80];
gout[n*9+5] += + c[6]*s[9] - c[0]*s[63] - c[7]*s[0] + c[1]*s[54] + c[6]*s[13] - c[0]*s[67] - c[7]*s[4] + c[1]*s[58] + c[6]*s[17] - c[0]*s[71] - c[7]*s[8] + c[1]*s[62];
gout[n*9+6] += + c[1]*s[45] - c[4]*s[18] - c[2]*s[36] + c[5]*s[9] + c[1]*s[49] - c[4]*s[22] - c[2]*s[40] + c[5]*s[13] + c[1]*s[53] - c[4]*s[26] - c[2]*s[44] + c[5]*s[17];
gout[n*9+7] += + c[2]*s[27] - c[5]*s[0] - c[0]*s[45] + c[3]*s[18] + c[2]*s[31] - c[5]*s[4] - c[0]*s[49] + c[3]*s[22] + c[2]*s[35] - c[5]*s[8] - c[0]*s[53] + c[3]*s[26];
gout[n*9+8] += + c[0]*s[36] -2*c[1]*s[27] + c[4]*s[0] + c[0]*s[40] -2*c[1]*s[31] + c[4]*s[4] + c[0]*s[44] -2*c[1]*s[35] + c[4]*s[8];
}}
void int1e_ggkin_optimizer(CINTOpt **opt, FINT *atm, FINT natm, FINT *bas, FINT nbas, double *env) {
FINT ng[] = {0, 4, 0, 0, 4, 1, 1, 9};
Expand Down

0 comments on commit b42531d

Please sign in to comment.