Fixed undefined tdof in setup

git-svn-id: svn://svn.icms.temple.edu/lammps-ro/trunk@14277 f3b2605a-c512-4ea7-a41b-209d697bcdaa
This commit is contained in:
athomps
2015-12-01 21:42:17 +00:00
parent e993934732
commit 3ca986fc6a

View File

@ -700,6 +700,11 @@ void FixNH::init()
void FixNH::setup(int vflag)
{
// tdof needed by compute_temp_target()
t_current = temperature->compute_scalar();
tdof = temperature->dof;
// t_target is needed by NPH and NPT in compute_scalar()
// If no thermostat or using fix nphug,
// t_target must be defined by other means.
@ -726,9 +731,6 @@ void FixNH::setup(int vflag)
if (pstat_flag) compute_press_target();
t_current = temperature->compute_scalar();
tdof = temperature->dof;
if (pstat_flag) {
if (pstyle == ISO) pressure->compute_scalar();
else pressure->compute_vector();