From 2741279254b92bdbb7ad7d24c19a29a63dd51a4d Mon Sep 17 00:00:00 2001 From: jtclemm Date: Tue, 22 Jun 2021 14:40:10 -0600 Subject: [PATCH] Adding correct scalar variable --- src/GRANULAR/compute_fabric.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/GRANULAR/compute_fabric.cpp b/src/GRANULAR/compute_fabric.cpp index 548c29eb10..61d3b632a5 100644 --- a/src/GRANULAR/compute_fabric.cpp +++ b/src/GRANULAR/compute_fabric.cpp @@ -134,7 +134,7 @@ ComputeFabric::ComputeFabric(LAMMPS *lmp, int narg, char **arg) : extvector = 0; scalar_flag = 1; - extscalar = 0; + extscalar = 1; vector = new double[size_vector]; } @@ -585,11 +585,11 @@ double ComputeFabric::compute_scalar() nc += 1.0; } } - //Count total contacts across processors MPI_Allreduce(&nc, &temp_dbl, 1, MPI_DOUBLE, MPI_SUM, world); nc = temp_dbl; + scalar = nc; return nc; }