git-svn-id: svn://svn.icms.temple.edu/lammps-ro/trunk@1653 f3b2605a-c512-4ea7-a41b-209d697bcdaa

This commit is contained in:
sjplimp
2008-03-20 15:32:33 +00:00
parent 08e197abc7
commit 4b237db3de
26 changed files with 122 additions and 100 deletions

View File

@ -176,17 +176,19 @@ void ComputeTempPartial::remove_bias(int i, double *v)
{
if (tbias) tbias->remove_bias(i,v);
if (!xflag) {
vbias[0] = v[0];
v[0] = 0.0;
}
if (!yflag) {
vbias[1] = v[1];
v[1] = 0.0;
}
if (!zflag) {
vbias[2] = v[2];
v[2] = 0.0;
if (atom->mask[i] & groupbit) {
if (!xflag) {
vbias[0] = v[0];
v[0] = 0.0;
}
if (!yflag) {
vbias[1] = v[1];
v[1] = 0.0;
}
if (!zflag) {
vbias[2] = v[2];
v[2] = 0.0;
}
}
}
@ -231,12 +233,14 @@ void ComputeTempPartial::remove_bias_all()
assume remove_bias() was previously called
------------------------------------------------------------------------- */
void ComputeTempPartial::restore_bias(double *v)
void ComputeTempPartial::restore_bias(int i, double *v)
{
v[0] += vbias[0];
v[1] += vbias[1];
v[2] += vbias[2];
if (tbias) tbias->restore_bias(v);
if (atom->mask[i] & groupbit) {
v[0] += vbias[0];
v[1] += vbias[1];
v[2] += vbias[2];
}
if (tbias) tbias->restore_bias(i,v);
}
/* ----------------------------------------------------------------------