git-svn-id: svn://svn.icms.temple.edu/lammps-ro/trunk@7363 f3b2605a-c512-4ea7-a41b-209d697bcdaa

This commit is contained in:
sjplimp 2011-12-14 15:18:48 +00:00
parent ea56c1ec97
commit a86eeda9b3
2 changed files with 3 additions and 1 deletions

View File

@ -26,6 +26,7 @@ class Atom : protected Pointers {
// atom counts
bigint natoms; // total # of atoms in system, could be 0
// natoms may not be current if atoms lost
int nlocal,nghost; // # of owned and ghost atoms on this proc
int nmax; // max # of owned+ghost in arrays on this proc
int tag_enable; // 0/1 if atom ID tags are defined

View File

@ -363,7 +363,8 @@ bigint Thermo::lost_check()
bigint ntotal;
bigint nblocal = atom->nlocal;
MPI_Allreduce(&nblocal,&ntotal,1,MPI_LMP_BIGINT,MPI_SUM,world);
if (ntotal < 0 || ntotal > MAXBIGINT) error->all(FLERR,"Too many total atoms");
if (ntotal < 0 || ntotal > MAXBIGINT)
error->all(FLERR,"Too many total atoms");
if (ntotal == atom->natoms) return ntotal;
// if not checking or already warned, just return