[lammps-users] fix spring with lammps 2001

Hello, everyone

Recently, I checked the source code about the “fix spring” in the version of lammps 2001 to help me understand the action induced by this command. However, I am confused by the following codes:

fixcoeff(4,iwhich) = fixcoeff(4,iwhich)dtfactordtfactor (1)

(f_x = kdelx, f_y = kdely, f_z = kdelz )
( fixcoeff(4,iwhich) = k, kcal/(mol
Å*Å) )
(dtfactor = 48.88821)

I can understand the parameter “dtfactor” which is used to converted the input time unit (fs) to click (that is 1click = 48.88821fs). However, in equation(1), I am not able to understand why the “dtfactor” needs to multiply force constant k twice. I also checked the similar code about the bond style/harmonic, where similar behaviors can not be found.

I really need any help about this question.

Thanks a lot.

Can't recall - the Fortran version was too long ago. I suggest you
try it in the current LAMMPS (fix spring) and see if you get the
same answer. Units in the older Fortran LAMMPS were more confusing
(e.g. the clicks) than in the current version, but I'm guessing it is correct.

Steve