git-svn-id: svn://svn.icms.temple.edu/lammps-ro/trunk@7137 f3b2605a-c512-4ea7-a41b-209d697bcdaa
This commit is contained in:
@ -195,10 +195,11 @@ void PairHybrid::settings(int narg, char **arg)
|
|||||||
allocated = 0;
|
allocated = 0;
|
||||||
|
|
||||||
// count sub-styles by skipping numeric args
|
// count sub-styles by skipping numeric args
|
||||||
// exception is 1st arg of style "table", which is non-numeric word
|
// exception is 1st arg of table style, which is non-numeric word
|
||||||
// exception is 1st two args of style "lj/coul", which are non-numeric
|
// exception is 1st two args of lj/coul style, which are non-numeric
|
||||||
// exception is 1st two args of style "buck/coul", which are non-numeric
|
// exception is 1st two args of buck/coul, which are non-numeric
|
||||||
// exception is 1st arg of reax/c style, which is non-numeric
|
// exception is 1st arg of reax/c style, which is non-numeric
|
||||||
|
// execption is 1st 6 args of gran styles, which can have NULLs
|
||||||
// need a better way to skip these exceptions
|
// need a better way to skip these exceptions
|
||||||
|
|
||||||
nstyles = 0;
|
nstyles = 0;
|
||||||
@ -208,6 +209,8 @@ void PairHybrid::settings(int narg, char **arg)
|
|||||||
if (strcmp(arg[i],"lj/coul") == 0) i += 2;
|
if (strcmp(arg[i],"lj/coul") == 0) i += 2;
|
||||||
if (strcmp(arg[i],"buck/coul") == 0) i += 2;
|
if (strcmp(arg[i],"buck/coul") == 0) i += 2;
|
||||||
if (strcmp(arg[i],"reax/c") == 0) i++;
|
if (strcmp(arg[i],"reax/c") == 0) i++;
|
||||||
|
if (strstr(arg[i],"gran/hooke")) i += 6;
|
||||||
|
if (strstr(arg[i],"gran/hertz")) i += 6;
|
||||||
i++;
|
i++;
|
||||||
while (i < narg && !isalpha(arg[i][0])) i++;
|
while (i < narg && !isalpha(arg[i][0])) i++;
|
||||||
nstyles++;
|
nstyles++;
|
||||||
@ -220,10 +223,11 @@ void PairHybrid::settings(int narg, char **arg)
|
|||||||
|
|
||||||
// allocate each sub-style and call its settings() with subset of args
|
// allocate each sub-style and call its settings() with subset of args
|
||||||
// define subset of args for a sub-style by skipping numeric args
|
// define subset of args for a sub-style by skipping numeric args
|
||||||
// exception is 1st arg of style "table", which is non-numeric
|
// exception is 1st arg of table style, which is non-numeric word
|
||||||
// exception is 1st two args of style "lj/coul", which are non-numeric
|
// exception is 1st two args of lj/coul style, which are non-numeric
|
||||||
// exception is 1st two args of style "buck/coul", which are non-numeric
|
// exception is 1st two args of buck/coul, which are non-numeric
|
||||||
// exception is 1st arg of reax/c style, which is non-numeric
|
// exception is 1st arg of reax/c style, which is non-numeric
|
||||||
|
// execption is 1st 6 args of gran styles, which can have NULLs
|
||||||
// need a better way to skip these exceptions
|
// need a better way to skip these exceptions
|
||||||
|
|
||||||
int dummy;
|
int dummy;
|
||||||
@ -246,6 +250,8 @@ void PairHybrid::settings(int narg, char **arg)
|
|||||||
if (strcmp(arg[i],"lj/coul") == 0) i += 2;
|
if (strcmp(arg[i],"lj/coul") == 0) i += 2;
|
||||||
if (strcmp(arg[i],"buck/coul") == 0) i += 2;
|
if (strcmp(arg[i],"buck/coul") == 0) i += 2;
|
||||||
if (strcmp(arg[i],"reax/c") == 0) i++;
|
if (strcmp(arg[i],"reax/c") == 0) i++;
|
||||||
|
if (strstr(arg[i],"gran/hooke")) i += 6;
|
||||||
|
if (strstr(arg[i],"gran/hertz")) i += 6;
|
||||||
i++;
|
i++;
|
||||||
while (i < narg && !isalpha(arg[i][0])) i++;
|
while (i < narg && !isalpha(arg[i][0])) i++;
|
||||||
styles[nstyles]->settings(i-istyle-1,&arg[istyle+1]);
|
styles[nstyles]->settings(i-istyle-1,&arg[istyle+1]);
|
||||||
|
|||||||
Reference in New Issue
Block a user