forked from lijiext/lammps
git-svn-id: svn://svn.icms.temple.edu/lammps-ro/trunk@12615 f3b2605a-c512-4ea7-a41b-209d697bcdaa
This commit is contained in:
parent
1b1c6a4228
commit
1cf0407a49
|
@ -330,14 +330,14 @@ ComputePropertyAtom::ComputePropertyAtom(LAMMPS *lmp, int narg, char **arg) :
|
|||
int flag;
|
||||
index[i] = atom->find_custom(&arg[iarg][2],flag);
|
||||
if (index[i] < 0 || flag != 0)
|
||||
error->all(FLERR,"Compute property/atom floating point "
|
||||
error->all(FLERR,"Compute property/atom integer "
|
||||
"vector does not exist");
|
||||
pack_choice[i] = &ComputePropertyAtom::pack_iname;
|
||||
} else if (strstr(arg[iarg],"d_") == arg[iarg]) {
|
||||
int flag;
|
||||
index[i] = atom->find_custom(&arg[iarg][2],flag);
|
||||
if (index[i] < 0 || flag != 1)
|
||||
error->all(FLERR,"Compute property/atom integer "
|
||||
error->all(FLERR,"Compute property/atom floating point "
|
||||
"vector does not exist");
|
||||
pack_choice[i] = &ComputePropertyAtom::pack_dname;
|
||||
|
||||
|
|
|
@ -1129,8 +1129,8 @@ void Molecule::allocate()
|
|||
if (radiusflag) memory->create(radius,natoms,"molecule:radius");
|
||||
if (rmassflag) memory->create(rmass,natoms,"molecule:rmass");
|
||||
|
||||
// always allocate num_bond,num_angle,etc and nspecial even if not in file
|
||||
// initialize to 0 even if not in molecule file
|
||||
// always allocate num_bond,num_angle,etc and special+nspecial
|
||||
// even if not in molecule file, initialize to 0
|
||||
// this is so methods that use these arrays don't have to check they exist
|
||||
|
||||
memory->create(num_bond,natoms,"molecule:num_bond");
|
||||
|
@ -1141,8 +1141,10 @@ void Molecule::allocate()
|
|||
for (int i = 0; i < natoms; i++) num_dihedral[i] = 0;
|
||||
memory->create(num_improper,natoms,"molecule:num_improper");
|
||||
for (int i = 0; i < natoms; i++) num_improper[i] = 0;
|
||||
|
||||
memory->create(special,natoms,maxspecial,"molecule:special");
|
||||
memory->create(nspecial,natoms,3,"molecule:nspecial");
|
||||
for (int i = 0; i < natoms; i++)
|
||||
for (int i = 0; i < natoms; i++)
|
||||
nspecial[i][0] = nspecial[i][1] = nspecial[i][2] = 0;
|
||||
|
||||
if (bondflag) {
|
||||
|
@ -1189,9 +1191,6 @@ void Molecule::allocate()
|
|||
"molecule:improper_atom4");
|
||||
}
|
||||
|
||||
if (specialflag)
|
||||
memory->create(special,natoms,maxspecial,"molecule:special");
|
||||
|
||||
if (shakeflag) {
|
||||
memory->create(shake_flag,natoms,"molecule:shake_flag");
|
||||
memory->create(shake_atom,natoms,4,"molecule:shake_flag");
|
||||
|
|
Loading…
Reference in New Issue