silence more compiler warnings

This commit is contained in:
Axel Kohlmeyer
2021-04-23 16:57:39 -04:00
parent 99fa6ed4b4
commit 917cd1b924
10 changed files with 17 additions and 18 deletions

View File

@ -101,7 +101,7 @@ void ComputeInertiaChunk::compute_array()
// zero local per-chunk values
for (int i = 0; i < nchunk; i++) {
for (i = 0; i < nchunk; i++) {
massproc[i] = 0.0;
com[i][0] = com[i][1] = com[i][2] = 0.0;
for (j = 0; j < 6; j++) inertia[i][j] = 0.0;
@ -117,7 +117,7 @@ void ComputeInertiaChunk::compute_array()
double *rmass = atom->rmass;
int nlocal = atom->nlocal;
for (int i = 0; i < nlocal; i++)
for (i = 0; i < nlocal; i++)
if (mask[i] & groupbit) {
index = ichunk[i]-1;
if (index < 0) continue;
@ -133,7 +133,7 @@ void ComputeInertiaChunk::compute_array()
MPI_Allreduce(massproc,masstotal,nchunk,MPI_DOUBLE,MPI_SUM,world);
MPI_Allreduce(&com[0][0],&comall[0][0],3*nchunk,MPI_DOUBLE,MPI_SUM,world);
for (int i = 0; i < nchunk; i++) {
for (i = 0; i < nchunk; i++) {
if (masstotal[i] > 0.0) {
comall[i][0] /= masstotal[i];
comall[i][1] /= masstotal[i];