fix setPropertyAtom#

Syntax#

fix ID group-ID setPropertyAtom keywords values ...
  • ID is documented in fix command, the group-ID is ignored for this command

  • setPropertyAtom = style name of this fix command

  • the following keywords/values pairs are necessary

  • keywords = name, isScalar or isVector, scalarValue or vectorValue, replace or add and/or rate, regionName

    • name value = name of the atom property to be set

    • isScalar value = yes or no

      • scalarValue value = scalar value of the property to be set if isScalar = yes

    • isVector value = yes or no

      • vectorValue values = vector components of the property to be set if isVector = yes

    • replace value = yes or no

    • add value = yes or no

      • rate value = yes or no if add = yes

    • regionName value = region-ID in which the atom property is set

Examples#

fix 5 all setPropertyAtom name surfaceLiquidContent isScalar yes scalarValue 0.005 add yes rate yes regionName wet
fix 5 all setPropertyAtom name angmom isVector yes vectorValue 100 0 0 replace yes regionName change

Description#

Set or add to the value of a property of all atoms in a region in a one-off or continuous manner. The name of the atom property to be set is specified by the name keyword, which can be a scalar or vector property. This can also be a property defined by a fix property/atom command. For scalar properties, isScalar is specified as yes and the scalar value is given by scalarValue. Likewise for vector properties, isVector = yes and the vector components are given by vectorValue.

The replace and add keywords determine how the values are changed. For replace, the specified value directly replaces the current value (one-off operation). For add, the specified value is added to the current value. If add = yes, the keyword rate can be also used to enable continuous addition of the specified value to the atoms over time. In this case, the specified value in scalarValue or vectorValue will be in units of per sec.

The region to select the atoms is specified by the regionName keyword. The specified region must have been previously defined with a region command. If regionName is not specified, then the fix is applied to all atoms in the simulation domain.

Restart, fix_modify, output, run start/stop, minimise info#

No information about this fix is written to binary restart files. None of the fix_modify options are relevant to this fix. No global or per-atom quantities are stored by this fix for access by various output commands. No parameter of this fix can be used with the start/stop keywords of the run command. This fix is not invoked during energy minimisation.

Restrictions#

You cannot set an atom property (e.g. mol or q or volume) if the atom_style does not have that attribute.

isScalar and isVector cannot be both yes, replace and add cannot be both yes.

Default#

none