Temperature compute degrees of freedom < 0 Error in 2D simulation

Dear Users,

I am performing a 2D simulation of colloidal particles in LAMMPS (12 Dec 2018). I have two particles which forms a spherical bigger colloidal particle. So when I am performing the simulation its shows following error as;

ERROR: Temperature compute degrees of freedom < 0 (…/compute_temp.cpp:101)

My atom style is hybrid bond sphere. Please help me to resolve the issue…

Thanks in Advance

The input script is given below:-

#######################Initial Section######################

dimension 2

units lj

boundary p p p

atom_style hybrid bond sphere

neighbor 1.0 bin

neigh_modify every 1 delay 10

read_data system.data

group sp1 type 1 2

set group sp1 diameter 1.0

pair_style lj/cut 2.5

pair_modify shift yes

pair_coeff 1 1 1.0 1.0 1.122

pair_coeff 1 2 2.0 1.0 2.5

pair_coeff 2 2 1.0 1.0 1.122

minimize 1e-5 1e-7 100000 100000

####################### Minimization_stage1 ###############################

fix 1 all nve

fix 4 sp1 rigid group 1 sp1 langevin 1 1 1 428175

fix 2dmini all enforce2d # 2D Simulation

dump minimize1j sp1 custom 100 sp1_pass_mini_1.lammpstrj id mol type x y z ix iy iz

timestep 0.001

thermo 10

run 1000000

unfix 1

unfix 2dmini

############################# main MD run - compute #########################

velocity all create 1.0 234985 rot yes dist gaussian

fix 64 all nve

fix 10 all langevin 1.0 1.0 10.0 985247

reset_timestep 0

timestep 0.001

fix 2d all enforce2d # 2D Simulation

thermo_style custom step temp pe etotal press vol epair ebond eangle ecoul

thermo 10

dump 48 sp1 custom 10 traj_sp1.lammpstrj id type x y z ix iy iz

dump 2 sp1 xyz 10 sp1_pos.xyz

dump 4 sp1 custom 10 sp1_velo.dat id type vx vy vz

run 2000000

Dear Users,

I am performing a 2D simulation of colloidal particles in LAMMPS (12 Dec 2018). I have two particles which forms a spherical bigger colloidal particle. So when I am performing the simulation its shows following error as;

ERROR: Temperature compute degrees of freedom < 0 (…/compute_temp.cpp:101)

My atom style is hybrid bond sphere. Please help me to resolve the issue…

the use of fix rigid will remove degrees of freedom from your system, but that number is not correctly set up since your temperature in the thermo output is based on compute temp. you have to replace it with compute temp/sphere using thermo_modify which considers the additional degrees of freedom of extended particles.

however, the use of atom style sphere in your input makes no sense. it is not used for anything but defining the mass of the particles, however, since that one is all the same, it could be set just as well using the ‘mass’ keyword. thus the cleaner approach would be to simply use atom style bond. then all the complications from using extended particles would be automatically gone. they are spurious in the first place, since the additional degrees of freedom are not used or time integrated.

axel.