From 7b47c82452d8de1629f51b830e2df71981c390ce Mon Sep 17 00:00:00 2001 From: Axel Kohlmeyer Date: Sun, 17 Feb 2019 18:50:35 -0500 Subject: [PATCH] update global bonus data counters --- src/set.cpp | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/src/set.cpp b/src/set.cpp index 34b86ea328..00b2d8a9b0 100644 --- a/src/set.cpp +++ b/src/set.cpp @@ -964,6 +964,21 @@ void Set::set(int keyword) count++; } + // update bonus data numbers + if (keyword == SHAPE) { + bigint nlocal_bonus = avec_ellipsoid->nlocal_bonus; + MPI_Allreduce(&nlocal_bonus,&atom->nellipsoids,1, + MPI_LMP_BIGINT,MPI_SUM,world); + } + if (keyword == LENGTH) { + bigint nlocal_bonus = avec_line->nlocal_bonus; + MPI_Allreduce(&nlocal_bonus,&atom->nlines,1,MPI_LMP_BIGINT,MPI_SUM,world); + } + if (keyword == TRI) { + bigint nlocal_bonus = avec_tri->nlocal_bonus; + MPI_Allreduce(&nlocal_bonus,&atom->ntris,1,MPI_LMP_BIGINT,MPI_SUM,world); + } + // clear up per-atom memory if allocated memory->destroy(vec1);