port thread-safe temperature biasing from LAMMPS-ICMS

This commit is contained in:
Axel Kohlmeyer
2017-05-16 18:15:13 -04:00
parent 06c151421c
commit d2810f9f83
23 changed files with 256 additions and 12 deletions

View File

@ -331,6 +331,15 @@ void ComputeTempSphere::remove_bias(int i, double *v)
tbias->remove_bias(i,v);
}
/* ----------------------------------------------------------------------
remove velocity bias from atom I to leave thermal velocity
------------------------------------------------------------------------- */
void ComputeTempSphere::remove_bias_thr(int i, double *v, double *b)
{
tbias->remove_bias_thr(i,v,b);
}
/* ----------------------------------------------------------------------
add back in velocity bias to atom I removed by remove_bias()
assume remove_bias() was previously called
@ -340,3 +349,13 @@ void ComputeTempSphere::restore_bias(int i, double *v)
{
tbias->restore_bias(i,v);
}
/* ----------------------------------------------------------------------
add back in velocity bias to atom I removed by remove_bias_thr()
assume remove_bias_thr() was previously called with the same buffer b
------------------------------------------------------------------------- */
void ComputeTempSphere::restore_bias_thr(int i, double *v, double *b)
{
tbias->restore_bias_thr(i,v,b);
}