forked from lijiext/lammps
git-svn-id: svn://svn.icms.temple.edu/lammps-ro/trunk@10273 f3b2605a-c512-4ea7-a41b-209d697bcdaa
This commit is contained in:
parent
e3bc276ce6
commit
580bffefea
|
@ -2265,7 +2265,7 @@ void MSM::restriction(int n)
|
|||
{
|
||||
//fprintf(screen,"Restricting from level %i to %i\n\n",n,n+1);
|
||||
|
||||
int p = order-1;
|
||||
const int p = order-1;
|
||||
|
||||
double ***qgrid1 = qgrid[n];
|
||||
double ***qgrid2 = qgrid[n+1];
|
||||
|
@ -2287,7 +2287,8 @@ void MSM::restriction(int n)
|
|||
|
||||
// zero out charge on coarser grid
|
||||
|
||||
memset(&(qgrid2[nzlo_out[n+1]][nylo_out[n+1]][nxlo_out[n+1]]),0,ngrid[n+1]*sizeof(double));
|
||||
memset(&(qgrid2[nzlo_out[n+1]][nylo_out[n+1]][nxlo_out[n+1]]),0,
|
||||
ngrid[n+1]*sizeof(double));
|
||||
|
||||
for (kp = nzlo_in[n+1]; kp <= nzhi_in[n+1]; kp++)
|
||||
for (jp = nylo_in[n+1]; jp <= nyhi_in[n+1]; jp++)
|
||||
|
@ -2338,7 +2339,7 @@ void MSM::prolongation(int n)
|
|||
{
|
||||
//fprintf(screen,"Prolongating from level %i to %i\n\n",n+1,n);
|
||||
|
||||
int p = order-1;
|
||||
const int p = order-1;
|
||||
|
||||
double ***egrid1 = egrid[n];
|
||||
double ***egrid2 = egrid[n+1];
|
||||
|
|
|
@ -215,7 +215,7 @@ void DisplaceAtoms::command(int narg, char **arg)
|
|||
axis[1] = force->numeric(FLERR,arg[6]);
|
||||
axis[2] = force->numeric(FLERR,arg[7]);
|
||||
double theta = force->numeric(FLERR,arg[8]);
|
||||
if (dim == 2 and (axis[0] != 0.0 || axis[1] != 0.0))
|
||||
if (dim == 2 && (axis[0] != 0.0 || axis[1] != 0.0))
|
||||
error->all(FLERR,"Invalid displace_atoms rotate axis for 2d");
|
||||
|
||||
double len = sqrt(axis[0]*axis[0] + axis[1]*axis[1] + axis[2]*axis[2]);
|
||||
|
|
|
@ -200,7 +200,7 @@ void Input::file()
|
|||
// execute the command
|
||||
|
||||
if (execute_command()) {
|
||||
char str[maxline+32];
|
||||
char *str = new char[maxline+32];
|
||||
sprintf(str,"Unknown command: %s",line);
|
||||
error->all(FLERR,str);
|
||||
}
|
||||
|
@ -266,7 +266,7 @@ char *Input::one(const char *single)
|
|||
// execute the command and return its name
|
||||
|
||||
if (execute_command()) {
|
||||
char str[maxline+32];
|
||||
char *str = new char[maxline+32];
|
||||
sprintf(str,"Unknown command: %s",line);
|
||||
error->all(FLERR,str);
|
||||
}
|
||||
|
|
|
@ -3618,7 +3618,7 @@ unsigned int Variable::data_mask(char *str)
|
|||
// compute
|
||||
// ----------------
|
||||
|
||||
if ((strncmp(word,"c_",2) == 0) && (i>0) && (not isalnum(str[i-1]))){
|
||||
if ((strncmp(word,"c_",2) == 0) && (i>0) && (!isalnum(str[i-1]))) {
|
||||
if (domain->box_exist == 0)
|
||||
error->all(FLERR,
|
||||
"Variable evaluation before simulation box is defined");
|
||||
|
@ -3636,7 +3636,7 @@ unsigned int Variable::data_mask(char *str)
|
|||
delete [] id;
|
||||
}
|
||||
|
||||
if ((strncmp(word,"f_",2) == 0) && (i>0) && (not isalnum(str[i-1]))) {
|
||||
if ((strncmp(word,"f_",2) == 0) && (i>0) && (!isalnum(str[i-1]))) {
|
||||
if (domain->box_exist == 0)
|
||||
error->all(FLERR,
|
||||
"Variable evaluation before simulation box is defined");
|
||||
|
@ -3652,7 +3652,7 @@ unsigned int Variable::data_mask(char *str)
|
|||
delete [] id;
|
||||
}
|
||||
|
||||
if ((strncmp(word,"v_",2) == 0) && (i>0) && (not isalnum(str[i-1]))) {
|
||||
if ((strncmp(word,"v_",2) == 0) && (i>0) && (!isalnum(str[i-1]))) {
|
||||
int ivar = find(word);
|
||||
datamask &= data_mask(ivar);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue