Syntax:
compute ID group-ID nparticles/tracer/region
periodic value = dim image dim = x or y or z image = image that a particle has to be in to be counted (any integer number or all) reset_marker value = yes or no yes = un-mark particles after counting them no = do not un-mark particles after counting them
Examples:
compute nparticles all nparticles/tracer/region region_count count tracer tr periodic z -1
Description:
Define a computation that calculates the number and mass of marked and un-marked particles that are in the region speficied via the region_count keyword. Particles have to be in the group "group-ID" to be counted.
Note that only particles marked by a fix property/atom/tracer or fix property/atom/tracer/stream command are counted - therefore, a valid ID of such a fix has to be provided via the tracer keyword.
The reset_marker keyword controls if particles are un-marked (default) after they have been counted once by this command.
IMPORTANT NOTE: If multiple compute nparticles/tracer/region commands are operating on the same fix property/atom/tracer commands, and the first compute resets the marker value, the second compute will not count them.
With the periodic keyword, you can restrict counting/unmarking to particles which are in a specified image in a periodic simulation. For example, using
periodic z +2
means that particles are only counted if they are in z-image #2. By default, all particles are counted/unmarked regardless in which periodic image they are.
IMPORTANT NOTE: Currently, this command only supports one periodic boundary restriction via the periodic keyword. If keyword periodic is used multiple times, the last setting will be applied.
Output info:
This this compute calculates a global vector containing the following information (the number in brackets corresponds to the vector id):
See this section for an overview of LIGGGHTS(R)-PUBLIC output options.
Restrictions:
Currently, only one periodic restriction via the periodic keyword can be used.
Related commands:
Default: reset_marker = yes, periodic is off per default