Commit e196a2b9 authored by Axel Kohlmeyer's avatar Axel Kohlmeyer
Browse files

import changes to various fixes by aidan to include virial contributions

parent b3547a9e
Loading
Loading
Loading
Loading
+5 −0
Original line number Original line Diff line number Diff line
@@ -97,6 +97,11 @@ The "fix_modify"_fix_modify.html {energy} option is supported by this
fix to add the potential "energy" of the CMAP interactions system's
fix to add the potential "energy" of the CMAP interactions system's
potential energy as part of "thermodynamic output"_thermo_style.html.
potential energy as part of "thermodynamic output"_thermo_style.html.


The "fix_modify"_fix_modify.html {virial} option is supported by this
fix to add the contribution due to the interaction between
atoms and each wall to the system's virial as part of "thermodynamic
output"_thermo_style.html. The default is {virial yes}

This fix computes a global scalar which can be accessed by various
This fix computes a global scalar which can be accessed by various
"output commands"_Section_howto.html#howto_15.  The scalar is the
"output commands"_Section_howto.html#howto_15.  The scalar is the
potential energy discussed above.  The scalar value calculated by this
potential energy discussed above.  The scalar value calculated by this
+5 −0
Original line number Original line Diff line number Diff line
@@ -124,6 +124,11 @@ can include the forces added by this fix in a consistent manner.
I.e. there is a decrease in potential energy when atoms move in the
I.e. there is a decrease in potential energy when atoms move in the
direction of the added force due to the electric field.
direction of the added force due to the electric field.


The "fix_modify"_fix_modify.html {virial} option is supported by this
fix to add the contribution due to the interaction between
atoms and each wall to the system's virial as part of "thermodynamic
output"_thermo_style.html. The default is {virial no}

The "fix_modify"_fix_modify.html {respa} option is supported by this
The "fix_modify"_fix_modify.html {respa} option is supported by this
fix. This allows to set at which level of the "r-RESPA"_run_style.html
fix. This allows to set at which level of the "r-RESPA"_run_style.html
integrator the fix adding its forces. Default is the outermost level.
integrator the fix adding its forces. Default is the outermost level.
+5 −0
Original line number Original line Diff line number Diff line
@@ -131,6 +131,11 @@ forces added by this fix in a consistent manner. I.e. there is a
decrease in potential energy when atoms move in the direction of the
decrease in potential energy when atoms move in the direction of the
added force.
added force.


The "fix_modify"_fix_modify.html {virial} option is supported by this
fix to add the contribution due to the interaction between
atoms and each wall to the system's virial as part of "thermodynamic
output"_thermo_style.html. The default is {virial yes}

This fix computes a global scalar which can be accessed by various
This fix computes a global scalar which can be accessed by various
"output commands"_Section_howto.html#howto_15.  The scalar is the
"output commands"_Section_howto.html#howto_15.  The scalar is the
potential energy discussed above.  The scalar stored by this fix
potential energy discussed above.  The scalar stored by this fix
+26 −7
Original line number Original line Diff line number Diff line
@@ -14,10 +14,11 @@ fix_modify fix-ID keyword value ... :pre


fix-ID = ID of the fix to modify :ulb,l
fix-ID = ID of the fix to modify :ulb,l
one or more keyword/value pairs may be appended :l
one or more keyword/value pairs may be appended :l
keyword = {temp} or {press} or {energy} or {respa} or {dynamic/dof} :l
keyword = {temp} or {press} or {energy} or {virial} or {respa} or {dynamic/dof} :l
  {temp} value = compute ID that calculates a temperature
  {temp} value = compute ID that calculates a temperature
  {press} value = compute ID that calculates a pressure
  {press} value = compute ID that calculates a pressure
  {energy} value = {yes} or {no}
  {energy} value = {yes} or {no}
  {virial} value = {yes} or {no}
  {respa} value = {1} to {max respa level} or {0} (for outermost level)
  {respa} value = {1} to {max respa level} or {0} (for outermost level)
  {dynamic/dof} value = {yes} or {no}
  {dynamic/dof} value = {yes} or {no}
    yes/no = do or do not recompute the number of degrees of freedom (DOF) contributing to the temperature :pre
    yes/no = do or do not recompute the number of degrees of freedom (DOF) contributing to the temperature :pre
@@ -52,11 +53,10 @@ define their own compute by default, as described in their
documentation.  Thus this option allows the user to override the
documentation.  Thus this option allows the user to override the
default method for computing P.
default method for computing P.


For fixes that calculate a contribution to the potential energy of the
The {energy} keyword can be used with fixes that support it.
system, the {energy} keyword will include that contribution in
{energy yes} adds a contribution to the potential energy of the
thermodynamic output of potential energy.  This is because the {energy
system. The fix's global and per-atom
yes} setting must be specified to include the fix's global or per-atom
energy is included in the calculation performed by the "compute
energy in the calculation performed by the "compute
pe"_compute_pe.html or "compute pe/atom"_compute_pe_atom.html
pe"_compute_pe.html or "compute pe/atom"_compute_pe_atom.html
commands.  See the "thermo_style"_thermo_style.html command for info
commands.  See the "thermo_style"_thermo_style.html command for info
on how potential energy is output.  For fixes that tally a global
on how potential energy is output.  For fixes that tally a global
@@ -69,6 +69,25 @@ are using it when performing an "energy minimization"_minimize.html
and if you want the energy and forces it produces to be part of the
and if you want the energy and forces it produces to be part of the
optimization criteria.
optimization criteria.


The {virial} keyword can be used with fixes that support it.
{virial yes} adds a contribution to the virial of the
system. The fix's global and per-atom
virial is included in the calculation performed by the "compute
pressure"_compute_pressure.html or
"compute stress/atom"_compute_stress_atom.html
commands.  See the "thermo_style"_thermo_style.html command for info
on how pressure is output. 

NOTE: You must specify the {virial yes} setting for a fix if you
are doing "box relaxation"_fix_box_relax.html and
if you want virial contribution of the fix to be part of the
relaxation criteria, although this seems unlikely.

NOTE: This option is only supported by fixes that explicitly say
so. For some of these (e.g. the
"fix shake"_fix_shake.html command) the default setting is
{virial yes}, for others it is {virial no}.

For fixes that set or modify forces, it may be possible to select at
For fixes that set or modify forces, it may be possible to select at
which "r-RESPA"_run_style.html level the fix operates via the {respa}
which "r-RESPA"_run_style.html level the fix operates via the {respa}
keyword. The RESPA level at which the fix is active can be selected.
keyword. The RESPA level at which the fix is active can be selected.
@@ -111,4 +130,4 @@ pressure"_compute_pressure.html, "thermo_style"_thermo_style.html
[Default:]
[Default:]


The option defaults are temp = ID defined by fix, press = ID defined
The option defaults are temp = ID defined by fix, press = ID defined
by fix, energy = no, respa = 0.
by fix, energy = no, virial = different for each fix style, respa = 0.
+5 −0
Original line number Original line Diff line number Diff line
@@ -703,6 +703,11 @@ NVT, NPT, NPH rigid styles to add the energy change induced by the
thermostatting to the system's potential energy as part of
thermostatting to the system's potential energy as part of
"thermodynamic output"_thermo_style.html.
"thermodynamic output"_thermo_style.html.


The "fix_modify"_fix_modify.html {virial} option is supported by this
fix to add the contribution due to the interaction between
atoms and each wall to the system's virial as part of "thermodynamic
output"_thermo_style.html. The default is {virial yes}

The "fix_modify"_fix_modify.html {temp} and {press} options are
The "fix_modify"_fix_modify.html {temp} and {press} options are
supported by the 4 NPT and NPH rigid styles to change the computes
supported by the 4 NPT and NPH rigid styles to change the computes
used to calculate the instantaneous pressure tensor.  Note that the 2
used to calculate the instantaneous pressure tensor.  Note that the 2
Loading