From bbef0a814a8c56e1310ee33b17dc6095a42bbf10 Mon Sep 17 00:00:00 2001 From: sjplimp Date: Fri, 24 Jul 2015 23:15:45 +0000 Subject: [PATCH] git-svn-id: svn://svn.icms.temple.edu/lammps-ro/trunk@13722 f3b2605a-c512-4ea7-a41b-209d697bcdaa --- src/USER-MISC/fix_pimd.cpp | 12 ++++++------ src/USER-MISC/fix_pimd.h | 4 ++-- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/src/USER-MISC/fix_pimd.cpp b/src/USER-MISC/fix_pimd.cpp index a7d272b059..46c753dd45 100644 --- a/src/USER-MISC/fix_pimd.cpp +++ b/src/USER-MISC/fix_pimd.cpp @@ -270,7 +270,7 @@ void FixPIMD::nhc_init() nhc_eta_dot[i][ichain] = 0.0; nhc_eta_dotdot[i][ichain] = 0.0; nhc_eta_mass[i][ichain] = mass0; - nhc_eta_mass[i][ichain] *= fmass; + if((method==CMD || method==NMPIMD) && universe->iworld==0) ; else nhc_eta_mass[i][ichain] *= fmass; } nhc_eta_dot[i][nhc_nchain] = 0.0; @@ -656,8 +656,8 @@ void FixPIMD::comm_exec(double **ptr) { char error_line[256]; - sprintf(error_line, "Atom %d is missing at world [%d] rank [%d] required by rank [%d].\n", - tag_send[i], universe->iworld, comm->me, plan_recv[iplan]); + sprintf(error_line, "Atom %d is missing at world [%d] rank [%d] required by rank [%d] (%d, %d, %d).\n", + tag_send[i], universe->iworld, comm->me, plan_recv[iplan], atom->tag[0], atom->tag[1], atom->tag[2]); error->universe_one(FLERR,error_line); } @@ -679,7 +679,7 @@ void FixPIMD::comm_exec(double **ptr) /* ---------------------------------------------------------------------- */ -int FixPIMD::pack_comm(int n, int *list, double *buf, +int FixPIMD::pack_forward_comm(int n, int *list, double *buf, int pbc_flag, int *pbc) { int i,j,m; @@ -693,12 +693,12 @@ int FixPIMD::pack_comm(int n, int *list, double *buf, buf[m++] = comm_ptr[j][2]; } - return 3; + return m; } /* ---------------------------------------------------------------------- */ -void FixPIMD::unpack_comm(int n, int first, double *buf) +void FixPIMD::unpack_forward_comm(int n, int first, double *buf) { int i,m,last; diff --git a/src/USER-MISC/fix_pimd.h b/src/USER-MISC/fix_pimd.h index 4a159f8252..37ea652dfe 100644 --- a/src/USER-MISC/fix_pimd.h +++ b/src/USER-MISC/fix_pimd.h @@ -47,8 +47,8 @@ class FixPIMD : public Fix { int size_restart(int); double compute_vector(int); - int pack_comm(int, int*, double *, int, int*); - void unpack_comm(int, int, double *); + int pack_forward_comm(int, int*, double *, int, int*); + void unpack_forward_comm(int, int, double *); int method; int np;