Replacing binsizex with multi2 version
This commit is contained in:
@ -248,6 +248,7 @@ void Comm::init()
|
||||
// Could remove NP_NEWTON from npair_full_*multi2*, but could be cryptic
|
||||
// Also could be cases where you want newton off (hybrid) but don't use multi2 comm
|
||||
// Could add check on neighbor build, if full and comm->multi2 error...
|
||||
// or just add check on comm setup - is that run before every run? Only if box change...
|
||||
if (force->newton == 0 && multi2)
|
||||
error->all(FLERR,"Cannot use multi2 communication with Newton off");
|
||||
}
|
||||
|
||||
@ -345,11 +345,11 @@ void NStencil::create_setup()
|
||||
stencil_range = sqrt(cutneighsq[i][j]);
|
||||
|
||||
sx = static_cast<int> (stencil_range*bininvx_multi2[bin_type]);
|
||||
if (sx*binsizex < stencil_range) sx++;
|
||||
if (sx*binsizex_multi2[bin_type] < stencil_range) sx++;
|
||||
sy = static_cast<int> (stencil_range*bininvy_multi2[bin_type]);
|
||||
if (sy*binsizey < stencil_range) sy++;
|
||||
if (sy*binsizey_multi2[bin_type] < stencil_range) sy++;
|
||||
sz = static_cast<int> (stencil_range*bininvz_multi2[bin_type]);
|
||||
if (sz*binsizez < stencil_range) sz++;
|
||||
if (sz*binsizez_multi2[bin_type] < stencil_range) sz++;
|
||||
|
||||
stencil_sx_multi2[i][j] = sx;
|
||||
stencil_sy_multi2[i][j] = sy;
|
||||
|
||||
@ -88,7 +88,7 @@ void NStencilHalfMulti22d::create()
|
||||
if (j > 0 || (j == 0 && i > 0)) {
|
||||
if (bin_distance_multi2(i,j,0,bin_type) < cutsq)
|
||||
stencil_multi2[itype][jtype][ns++] = j*mbinx + i;
|
||||
}
|
||||
}
|
||||
} else {
|
||||
for (j = -sy; j <= sy; j++)
|
||||
for (i = -sx; i <= sx; i++)
|
||||
|
||||
@ -92,7 +92,7 @@ void NStencilHalfMulti23d::create()
|
||||
if (bin_distance_multi2(i,j,k,bin_type) < cutsq)
|
||||
stencil_multi2[itype][jtype][ns++] =
|
||||
k*mbiny*mbinx + j*mbinx + i;
|
||||
}
|
||||
}
|
||||
} else {
|
||||
for (k = -sz; k <= sz; k++)
|
||||
for (j = -sy; j <= sy; j++)
|
||||
|
||||
Reference in New Issue
Block a user