[lammps-users] Question about delay and every

My question is: the parameters delay and every of the command neigh_modify has such a relation (we denote timestep as M): delay is enforced to be a multiple of every, then when M delay = 0 is satified, M every = 0 is
automatically satisfied. Then this means only delay value is important to neighbor list update. Only when delay is set to zero, neighbor list updates according to the value of every--but this can be realized also by setiing delay to the expected value and every keeping its default value 1. So what I want to ask is: are there any cases where every has its unique usages which can not be substitutedd by delay--i.e., every is doing some work that delay cannot do?


Xiang Gu


See the neigh_modify docs here:


Especially this paragraph:

"The every, delay, and check options affect how often the list is
built as a simulation runs. The delay setting means never build a new
list until at least N steps after the previous build. The every
setting means build the list every M steps (after the delay has
passed). If the check setting is no, the list is built on the 1st step
that satisfies the delay and every settings. If the check setting is
yes, then the list is only built on a particular step if some atom has
moved more than half the skin distance (specified in the neighbor
command) since the last build."

So the answer to your question is yes, the "every" parameter is
important. If "check" is set to "yes", "delay" to 10, and "every" to
5, the list will be built on timestep 10 if the atoms have moved far
enough, if not, checked again on timestep 15, 20, 25 etc.