Question about sllod implementation

Dear All,

We are currently performing NEMD simulations using fix nvt/sllod in LAMMPS. Upon a recent discussion with a colleague, there is now some confusion among us regarding which sllod algorithm lammps is implementing. Does fix nvt/sllod implement the p-sllod algorithm, or the sllod algorithm (as described in Daivis and Todd’s work, referenced in the LAMMPS documentation), or another version of sllod?


Tim O’Sullivan.

Hello Tim,

It is my belief that the implementation of nvt/sllod is consistent with the p-SLLOD (or GSLLOD) algorithm. See this code:

116 for (int i = 0; i < nlocal; i++) {
117 if (mask[i] & groupbit) {
118 vdelu[0] = h_two[0]*v[i][0] + h_two[5]*v[i][1] + h_two[4]*v[i][2];
119 vdelu[1] = h_two[1]*v[i][1] + h_two[3]*v[i][2];
120 vdelu[2] = h_two[2]*v[i][2];
121 temperature->remove_bias(i,v[i]);
122 v[i][0] = v[i][0]factor_eta - dthalfvdelu[0];
123 v[i][1] = v[i][1]factor_eta - dthalfvdelu[1];
124 v[i][2] = v[i][2]factor_eta - dthalfvdelu[2];
125 temperature->restore_bias(i,v[i]);
126 }
127 }

Before temperature->remove_bias(…) is called, the velocity includes the streaming and thermal velocity
v = v_stream + v_thermal
v = dot(x,h_two) + v_thermal
(h_two is the rate-of-deformation tensor)

The computed correction factor is then:
vdelu = dot(v,h_two) = dot(x,h_two,h_two) + dot(v_thermal,h_two)

This is the GSLLOD correction. If temperature->remove_bias(…) is moved up three lines, you should get the regular SLLOD equations.

I’m not sure that this point is of great importance important though, since the majority of simulations using this routine are going to be for planar shear. In planar shear, GSLLOD and SLLOD are equivalent, since dot(h_two,h_two) = 0. In the USER-UEF package for NEMD under extensional flow, where GSLLOD != SLLOD, the regular SLLOD equations are implemented.


I took a look at the edit history for nvt/sllod, and I found that earlier versions of the code had the “temperature->remove_bias(…)” line before the calculation of vdelu. It was switched to its current place in this patch (almost 9 years ago):

The patch notes discuss changes made to the default value for tchain, but are not clear on why the calculation of vdelu was changed too.

24 Aug 2010
Changed the default Nose/Hoover chain setting for the fix nvt/sllod command to 1, instead of 3. This effectively turns off NH chains which seems to work better for most systems being driven in shear mode by the SLLOD model.
This patch file can be applied to the 23 Aug 2010 version. This is the list of changed files.