diff --git a/examples/USER/misc/srp/in.srp b/examples/USER/misc/srp/in.srp index 6913434362..234026e9cb 100644 --- a/examples/USER/misc/srp/in.srp +++ b/examples/USER/misc/srp/in.srp @@ -15,6 +15,7 @@ bond_style harmonic bond_coeff * 225.0 0.85 comm_modify vel yes +comm_modify cutoff 3.6 # must use pair hybrid, since srp bond particles # do not interact with other atoms types diff --git a/src/USER-MISC/fix_srp.cpp b/src/USER-MISC/fix_srp.cpp index 08499b2abc..fbd8473cb0 100644 --- a/src/USER-MISC/fix_srp.cpp +++ b/src/USER-MISC/fix_srp.cpp @@ -264,14 +264,11 @@ void FixSRP::setup_pre_force(int zz) if (cutghostmin > comm->cutghost[2]) cutghostmin = comm->cutghost[2]; - // reset cutghost if needed + // stop if cutghost is insufficient if (cutneighmax_srp > cutghostmin){ - if(comm->me == 0){ - sprintf(str, "Extending ghost comm cutoff. New %f, old %f.", cutneighmax_srp, cutghostmin); - error->message(FLERR,str); - } - // cutghost updated by comm->setup - comm->cutghostuser = cutneighmax_srp; + sprintf(str, "Communication cutoff too small for fix srp. " + "Need %f, current %f.", cutneighmax_srp, cutghostmin); + error->all(FLERR,str); } // assign tags for new atoms, update map