print warning about missing fix nve/spin only on MPI rank 0

This commit is contained in:
Axel Kohlmeyer 2019-03-25 20:58:13 -04:00
parent 7b3f952990
commit 82d646cede
No known key found for this signature in database
GPG Key ID: D9B44E93BF0C375A
4 changed files with 5 additions and 5 deletions

View File

@ -173,7 +173,7 @@ void PairSpinDmi::init_style()
if (strcmp(modify->fix[ifix]->style,"nve/spin") == 0) break;
ifix++;
}
if (ifix == modify->nfix)
if ((ifix == modify->nfix) && (comm->me == 0))
error->warning(FLERR,"Using pair/spin style without nve/spin");
// get the lattice_flag from nve/spin

View File

@ -160,7 +160,7 @@ void PairSpinExchange::init_style()
if (strcmp(modify->fix[ifix]->style,"nve/spin") == 0) break;
ifix++;
}
if (ifix == modify->nfix)
if ((ifix == modify->nfix) && (comm->me == 0))
error->warning(FLERR,"Using pair/spin style without nve/spin");
// get the lattice_flag from nve/spin

View File

@ -166,7 +166,7 @@ void PairSpinMagelec::init_style()
if (strcmp(modify->fix[ifix]->style,"nve/spin") == 0) break;
ifix++;
}
if (ifix == modify->nfix)
if ((ifix == modify->nfix) && (comm->me == 0))
error->warning(FLERR,"Using pair/spin style without nve/spin");
// get the lattice_flag from nve/spin

View File

@ -173,7 +173,7 @@ void PairSpinNeel::init_style()
if (strcmp(modify->fix[ifix]->style,"nve/spin") == 0) break;
ifix++;
}
if (ifix == modify->nfix)
if ((ifix == modify->nfix) && (comm->me == 0))
error->warning(FLERR,"Using pair/spin style without nve/spin");
// get the lattice_flag from nve/spin
@ -343,7 +343,7 @@ void PairSpinNeel::compute_single_pair(int ii, double fmi[3])
double xi[3], rij[3], eij[3];
double spi[3], spj[3];
int i,j,jnum,itype,jtype,ntypes;
int j,jnum,itype,jtype,ntypes;
int k,locflag;
int *jlist,*numneigh,**firstneigh;