Merge pull request #1857 from ohenrich/user-cgdna

USER-CGDNA: Increased tolerance for fatal error in FENE bond
This commit is contained in:
Axel Kohlmeyer
2020-01-31 12:20:57 -05:00
committed by GitHub

View File

@ -221,7 +221,7 @@ void BondOxdnaFene::compute(int eflag, int vflag)
TAGINT_FORMAT " " TAGINT_FORMAT " %g",
update->ntimestep,atom->tag[a],atom->tag[b],r);
error->warning(FLERR,str,0);
if (rlogarg <= -3.0) error->one(FLERR,"Bad FENE bond");
if (rlogarg <= -8.0) error->one(FLERR,"Bad FENE bond");
}
fbond = -k[type]*rr0/rlogarg/Deltasq/r;
@ -421,7 +421,7 @@ double BondOxdnaFene::single(int type, double rsq, int /*i*/, int /*j*/,
sprintf(str,"FENE bond too long: " BIGINT_FORMAT " %g",
update->ntimestep,sqrt(rsq));
error->warning(FLERR,str,0);
if (rlogarg <= -3.0) error->one(FLERR,"Bad FENE bond");
if (rlogarg <= -8.0) error->one(FLERR,"Bad FENE bond");
}
double eng = -0.5 * k[type]*log(rlogarg);