apply fix from balance command to fix balance
This commit is contained in:
@ -64,14 +64,15 @@ FixBalance::FixBalance(LAMMPS *lmp, int narg, char **arg) :
|
||||
int iarg = 5;
|
||||
if (lbstyle == SHIFT) {
|
||||
if (iarg+4 > narg) error->all(FLERR,"Illegal fix balance command");
|
||||
if (strlen(arg[iarg+1]) > 3)
|
||||
if (strlen(arg[iarg+1]) > Balance::BSTR_SIZE)
|
||||
error->all(FLERR,"Illegal fix balance command");
|
||||
strcpy(bstr,arg[iarg+1]);
|
||||
strncpy(bstr,arg[iarg+1], Balance::BSTR_SIZE+1);
|
||||
nitermax = utils::inumeric(FLERR,arg[iarg+2],false,lmp);
|
||||
if (nitermax <= 0) error->all(FLERR,"Illegal fix balance command");
|
||||
stopthresh = utils::numeric(FLERR,arg[iarg+3],false,lmp);
|
||||
if (stopthresh < 1.0) error->all(FLERR,"Illegal fix balance command");
|
||||
iarg += 4;
|
||||
|
||||
} else if (lbstyle == BISECTION) {
|
||||
iarg++;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user