Skip to content

Commit

Permalink
Update fill_ints_sr for cint 6.0
Browse files Browse the repository at this point in the history
  • Loading branch information
sunqm committed Sep 28, 2023
1 parent 3ec049e commit 9068d7d
Showing 1 changed file with 0 additions and 60 deletions.
60 changes: 0 additions & 60 deletions pyscf/lib/pbc/fill_ints_sr.c
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,6 @@ static void _nr2c_k_fill(int (*intor)(), double complex *out,
int iptrxyz, dijc, ISH, JSH, IJSH, i;
JSH = refuniqshl_map[jsh-jsh0];
double *ri, *rj, Rij2, Rij2_cut;
const double omega = fabs(env_loc[PTR_RANGE_OMEGA]);

shls[1] = jsh;
for (m = 0; m < nishloc; m++) {
Expand Down Expand Up @@ -183,16 +182,8 @@ static void _nr2c_k_fill(int (*intor)(), double complex *out,
IJSH = (ISH>=JSH)?(ISH*(ISH+1)/2+JSH):(JSH*(JSH+1)/2+ISH);
Rij2_cut = uniq_Rcut2s[IJSH];
if (Rij2 < Rij2_cut) {
env_loc[PTR_RANGE_OMEGA] = 0.;
(*intor)(pbuf, NULL, shls, atm, natm, bas, nbas,
env_loc, cintopt, cache);
env_loc[PTR_RANGE_OMEGA] = omega;
if ((*intor)(pbuf2, NULL, shls, atm, natm, bas, nbas,
env_loc, cintopt, cache)) {
for (i = 0; i < dijc; ++i) {
pbuf[i] -= pbuf2[i];
}
}
}
else {
for (i = 0; i < dijc; ++i) {
Expand Down Expand Up @@ -412,8 +403,6 @@ static void _nr3c_g(int (*intor)(), void (*fsort)(), double *out,
double *cache = bufL + dijmc;
double *pbuf;

const double omega = fabs(env_loc[PTR_RANGE_OMEGA]);

shls[0] = ish;
shls[1] = jsh;
// >>>>>>>>
Expand Down Expand Up @@ -468,20 +457,12 @@ static void _nr3c_g(int (*intor)(), void (*fsort)(), double *out,
rk = env_loc + kptrxyz;
Rijk2 = get_dsqure(rc, rk);
if(Rijk2 < Rcut2) {
env_loc[PTR_RANGE_OMEGA] = 0.;
if ((*intor)(buf, NULL, shls, atm, natm, bas, nbas,
env_loc, cintopt, cache)) {
for (i = 0; i < dijkc; i++) {
pbuf[i] += buf[i];
}
}
env_loc[PTR_RANGE_OMEGA] = omega;
if ((*intor)(buf, NULL, shls, atm, natm, bas, nbas,
env_loc, cintopt, cache)) {
for (i = 0; i < dijkc; i++) {
pbuf[i] -= buf[i];
}
}
} // if Rcut
pbuf += dijkc;
}
Expand Down Expand Up @@ -786,7 +767,6 @@ static void _nr3c_bvk_k(int (*intor)(), void (*fsort)(),
shls[0] = ish;
shls[1] = jsh;
// >>>>>>>>>>
const double omega = fabs(env_loc[PTR_RANGE_OMEGA]);
int Ish, Jsh, IJsh, Ksh, idij, kiLj, kiLi;
Ish = refuniqshl_map[ish];
Jsh = refuniqshl_map[jsh-nbas];
Expand Down Expand Up @@ -854,17 +834,8 @@ static void _nr3c_bvk_k(int (*intor)(), void (*fsort)(),
rk = env_loc + kptrxyz;
Rijk2 = get_dsqure(rc, rk);
if (Rijk2 < Rcut2) {
env_loc[PTR_RANGE_OMEGA] = 0.;
(*intor)(pbuf1, NULL, shls, atm, natm, bas, nbas,
env_loc, cintopt, cache);
env_loc[PTR_RANGE_OMEGA] = omega;
if ((*intor)(pbuf2, NULL, shls, atm, natm,
bas, nbas, env_loc, cintopt,
cache)) {
for (i = 0; i < dijkc; i++) {
pbuf1[i] -= pbuf2[i];
}
}
} else {
for (i = 0; i < dijkc; i++) {
pbuf1[i] = 0;
Expand Down Expand Up @@ -1074,7 +1045,6 @@ static void _nr3c_k(int (*intor)(), void (*fsort)(),
shls[0] = ish;
shls[1] = jsh;
// >>>>>>>>>>
const double omega = fabs(env_loc[PTR_RANGE_OMEGA]);
int Ish, Jsh, IJsh, Ksh, idij, kiLj, kiLjc, kiLi;
Ish = refuniqshl_map[ish];
Jsh = refuniqshl_map[jsh-nbas];
Expand Down Expand Up @@ -1131,17 +1101,8 @@ static void _nr3c_k(int (*intor)(), void (*fsort)(),
rk = env_loc + kptrxyz;
Rijk2 = get_dsqure(rc, rk);
if (Rijk2 < Rcut2) {
env_loc[PTR_RANGE_OMEGA] = 0.;
(*intor)(pbuf, NULL, shls, atm, natm, bas, nbas,
env_loc, cintopt, cache);
env_loc[PTR_RANGE_OMEGA] = omega;
if ((*intor)(pbuf2, NULL, shls, atm, natm,
bas, nbas, env_loc, cintopt,
cache)) {
for (i = 0; i < dijkc; i++) {
pbuf[i] -= pbuf2[i];
}
}
} else {
for (i = 0; i < dijkc; i++) {
pbuf[i] = 0;
Expand Down Expand Up @@ -1470,8 +1431,6 @@ static void _nr3c_bvk_kk(int (*intor)(), void (*fsort)(),
double *bufkk_r, *bufkk_i, *bufkL_r, *bufkL_i, *bufL, *pbuf, *cache;
double *buf_rs, *buf_rs0, *pbuf_rs;

const double omega = fabs(env_loc[PTR_RANGE_OMEGA]);

shls[0] = ish;
shls[1] = jsh;
// >>>>>>>>
Expand Down Expand Up @@ -1547,17 +1506,8 @@ static void _nr3c_bvk_kk(int (*intor)(), void (*fsort)(),
rk = env_loc + kptrxyz;
Rijk2 = get_dsqure(rc, rk);
if (Rijk2 < Rcut2) {
env_loc[PTR_RANGE_OMEGA] = 0.;
(*intor)(buf_rs, NULL, shls, atm, natm, bas, nbas,
env_loc, cintopt, cache);
env_loc[PTR_RANGE_OMEGA] = omega;
if ((*intor)(pbuf_rs, NULL, shls, atm, natm,
bas, nbas, env_loc, cintopt,
cache)) {
for (i = 0; i < dijkc; i++) {
buf_rs[i] -= pbuf_rs[i];
}
}
} else {
for (i = 0; i < dijkc; i++) {
buf_rs[i] = 0;
Expand Down Expand Up @@ -1750,7 +1700,6 @@ static void _nr3c_kk(int (*intor)(), void (*fsort)(),
shls[0] = ish;
shls[1] = jsh;

const double omega = fabs(env_loc[PTR_RANGE_OMEGA]);
int Ish, Jsh, IJsh, Ksh, idij;
Ish = refuniqshl_map[ish];
Jsh = refuniqshl_map[jsh-nbas];
Expand Down Expand Up @@ -1816,17 +1765,8 @@ static void _nr3c_kk(int (*intor)(), void (*fsort)(),
rk = env_loc + kptrxyz;
Rijk2 = get_dsqure(rc, rk);
if (Rijk2 < Rcut2) {
env_loc[PTR_RANGE_OMEGA] = 0.;
(*intor)(pbuf, NULL, shls, atm, natm, bas, nbas,
env_loc, cintopt, cache);
env_loc[PTR_RANGE_OMEGA] = omega;
if ((*intor)(pbuf2, NULL, shls, atm, natm,
bas, nbas, env_loc, cintopt,
cache)) {
for (i = 0; i < dijkc; i++) {
pbuf[i] -= pbuf2[i];
}
}
} else {
for (i = 0; i < dijkc; i++) {
pbuf[i] = 0;
Expand Down

0 comments on commit 9068d7d

Please sign in to comment.