mirror of https://github.com/lammps/lammps.git
git-svn-id: svn://svn.icms.temple.edu/lammps-ro/trunk@4495 f3b2605a-c512-4ea7-a41b-209d697bcdaa
This commit is contained in:
parent
4529d7187c
commit
0b378cd869
|
@ -323,16 +323,16 @@ in the command's documentation.
|
|||
of each style or click on the style itself for a full description:
|
||||
</P>
|
||||
<DIV ALIGN=center><TABLE BORDER=1 >
|
||||
<TR ALIGN="center"><TD ><A HREF = "fix_adapt.html">adapt</A></TD><TD ><A HREF = "fix_addforce.html">addforce</A></TD><TD ><A HREF = "fix_aveforce.html">aveforce</A></TD><TD ><A HREF = "fix_ave_atom.html">ave/atom</A></TD><TD ><A HREF = "fix_ave_histo.html">ave/histo</A></TD><TD ><A HREF = "fix_ave_spatial.html">ave/spatial</A></TD><TD ><A HREF = "fix_ave_time.html">ave/time</A></TD><TD ><A HREF = "fix_bond_break.html">bond/break</A></TD></TR>
|
||||
<TR ALIGN="center"><TD ><A HREF = "fix_bond_create.html">bond/create</A></TD><TD ><A HREF = "fix_bond_swap.html">bond/swap</A></TD><TD ><A HREF = "fix_box_relax.html">box/relax</A></TD><TD ><A HREF = "fix_deform.html">deform</A></TD><TD ><A HREF = "fix_deposit.html">deposit</A></TD><TD ><A HREF = "fix_drag.html">drag</A></TD><TD ><A HREF = "fix_dt_reset.html">dt/reset</A></TD><TD ><A HREF = "fix_efield.html">efield</A></TD></TR>
|
||||
<TR ALIGN="center"><TD ><A HREF = "fix_enforce2d.html">enforce2d</A></TD><TD ><A HREF = "fix_evaporate.html">evaporate</A></TD><TD ><A HREF = "fix_freeze.html">freeze</A></TD><TD ><A HREF = "fix_gravity.html">gravity</A></TD><TD ><A HREF = "fix_heat.html">heat</A></TD><TD ><A HREF = "fix_indent.html">indent</A></TD><TD ><A HREF = "fix_langevin.html">langevin</A></TD><TD ><A HREF = "fix_lineforce.html">lineforce</A></TD></TR>
|
||||
<TR ALIGN="center"><TD ><A HREF = "fix_momentum.html">momentum</A></TD><TD ><A HREF = "fix_move.html">move</A></TD><TD ><A HREF = "fix_msst.html">msst</A></TD><TD ><A HREF = "fix_nh.html">nph</A></TD><TD ><A HREF = "fix_nph_asphere.html">nph/asphere</A></TD><TD ><A HREF = "fix_nph_sphere.html">nph/sphere</A></TD><TD ><A HREF = "fix_nh.html">npt</A></TD><TD ><A HREF = "fix_npt_asphere.html">npt/asphere</A></TD></TR>
|
||||
<TR ALIGN="center"><TD ><A HREF = "fix_npt_sphere.html">npt/sphere</A></TD><TD ><A HREF = "fix_nve.html">nve</A></TD><TD ><A HREF = "fix_nve_asphere.html">nve/asphere</A></TD><TD ><A HREF = "fix_nve_limit.html">nve/limit</A></TD><TD ><A HREF = "fix_nve_noforce.html">nve/noforce</A></TD><TD ><A HREF = "fix_nve_sphere.html">nve/sphere</A></TD><TD ><A HREF = "fix_nh.html">nvt</A></TD><TD ><A HREF = "fix_nvt_asphere.html">nvt/asphere</A></TD></TR>
|
||||
<TR ALIGN="center"><TD ><A HREF = "fix_nvt_sllod.html">nvt/sllod</A></TD><TD ><A HREF = "fix_nvt_sphere.html">nvt/sphere</A></TD><TD ><A HREF = "fix_orient_fcc.html">orient/fcc</A></TD><TD ><A HREF = "fix_planeforce.html">planeforce</A></TD><TD ><A HREF = "fix_poems.html">poems</A></TD><TD ><A HREF = "fix_pour.html">pour</A></TD><TD ><A HREF = "fix_press_berendsen.html">press/berendsen</A></TD><TD ><A HREF = "fix_print.html">print</A></TD></TR>
|
||||
<TR ALIGN="center"><TD ><A HREF = "fix_reax_bonds.html">reax/bonds</A></TD><TD ><A HREF = "fix_recenter.html">recenter</A></TD><TD ><A HREF = "fix_rigid.html">rigid</A></TD><TD ><A HREF = "fix_rigid.html">rigid/nve</A></TD><TD ><A HREF = "fix_rigid.html">rigid/nvt</A></TD><TD ><A HREF = "fix_setforce.html">setforce</A></TD><TD ><A HREF = "fix_shake.html">shake</A></TD><TD ><A HREF = "fix_spring.html">spring</A></TD></TR>
|
||||
<TR ALIGN="center"><TD ><A HREF = "fix_spring_rg.html">spring/rg</A></TD><TD ><A HREF = "fix_spring_self.html">spring/self</A></TD><TD ><A HREF = "fix_store_force.html">store/force</A></TD><TD ><A HREF = "fix_store_state.html">store/state</A></TD><TD ><A HREF = "fix_temp_berendsen.html">temp/berendsen</A></TD><TD ><A HREF = "fix_temp_rescale.html">temp/rescale</A></TD><TD ><A HREF = "fix_thermal_conductivity.html">thermal/conductivity</A></TD><TD ><A HREF = "fix_tmd.html">tmd</A></TD></TR>
|
||||
<TR ALIGN="center"><TD ><A HREF = "fix_ttm.html">ttm</A></TD><TD ><A HREF = "fix_viscosity.html">viscosity</A></TD><TD ><A HREF = "fix_viscous.html">viscous</A></TD><TD ><A HREF = "fix_wall.html">wall/colloid</A></TD><TD ><A HREF = "fix_wall_gran.html">wall/gran</A></TD><TD ><A HREF = "fix_wall.html">wall/harmonic</A></TD><TD ><A HREF = "fix_wall.html">wall/lj126</A></TD><TD ><A HREF = "fix_wall.html">wall/lj93</A></TD></TR>
|
||||
<TR ALIGN="center"><TD ><A HREF = "fix_wall_reflect.html">wall/reflect</A></TD><TD ><A HREF = "fix_wall_region.html">wall/region</A>
|
||||
<TR ALIGN="center"><TD ><A HREF = "fix_adapt.html">adapt</A></TD><TD ><A HREF = "fix_addforce.html">addforce</A></TD><TD ><A HREF = "fix_aveforce.html">aveforce</A></TD><TD ><A HREF = "fix_ave_atom.html">ave/atom</A></TD><TD ><A HREF = "fix_ave_correlate.html">ave/correlate</A></TD><TD ><A HREF = "fix_ave_histo.html">ave/histo</A></TD><TD ><A HREF = "fix_ave_spatial.html">ave/spatial</A></TD><TD ><A HREF = "fix_ave_time.html">ave/time</A></TD></TR>
|
||||
<TR ALIGN="center"><TD ><A HREF = "fix_bond_break.html">bond/break</A></TD><TD ><A HREF = "fix_bond_create.html">bond/create</A></TD><TD ><A HREF = "fix_bond_swap.html">bond/swap</A></TD><TD ><A HREF = "fix_box_relax.html">box/relax</A></TD><TD ><A HREF = "fix_deform.html">deform</A></TD><TD ><A HREF = "fix_deposit.html">deposit</A></TD><TD ><A HREF = "fix_drag.html">drag</A></TD><TD ><A HREF = "fix_dt_reset.html">dt/reset</A></TD></TR>
|
||||
<TR ALIGN="center"><TD ><A HREF = "fix_efield.html">efield</A></TD><TD ><A HREF = "fix_enforce2d.html">enforce2d</A></TD><TD ><A HREF = "fix_evaporate.html">evaporate</A></TD><TD ><A HREF = "fix_freeze.html">freeze</A></TD><TD ><A HREF = "fix_gravity.html">gravity</A></TD><TD ><A HREF = "fix_heat.html">heat</A></TD><TD ><A HREF = "fix_indent.html">indent</A></TD><TD ><A HREF = "fix_langevin.html">langevin</A></TD></TR>
|
||||
<TR ALIGN="center"><TD ><A HREF = "fix_lineforce.html">lineforce</A></TD><TD ><A HREF = "fix_momentum.html">momentum</A></TD><TD ><A HREF = "fix_move.html">move</A></TD><TD ><A HREF = "fix_msst.html">msst</A></TD><TD ><A HREF = "fix_nh.html">nph</A></TD><TD ><A HREF = "fix_nph_asphere.html">nph/asphere</A></TD><TD ><A HREF = "fix_nph_sphere.html">nph/sphere</A></TD><TD ><A HREF = "fix_nh.html">npt</A></TD></TR>
|
||||
<TR ALIGN="center"><TD ><A HREF = "fix_npt_asphere.html">npt/asphere</A></TD><TD ><A HREF = "fix_npt_sphere.html">npt/sphere</A></TD><TD ><A HREF = "fix_nve.html">nve</A></TD><TD ><A HREF = "fix_nve_asphere.html">nve/asphere</A></TD><TD ><A HREF = "fix_nve_limit.html">nve/limit</A></TD><TD ><A HREF = "fix_nve_noforce.html">nve/noforce</A></TD><TD ><A HREF = "fix_nve_sphere.html">nve/sphere</A></TD><TD ><A HREF = "fix_nh.html">nvt</A></TD></TR>
|
||||
<TR ALIGN="center"><TD ><A HREF = "fix_nvt_asphere.html">nvt/asphere</A></TD><TD ><A HREF = "fix_nvt_sllod.html">nvt/sllod</A></TD><TD ><A HREF = "fix_nvt_sphere.html">nvt/sphere</A></TD><TD ><A HREF = "fix_orient_fcc.html">orient/fcc</A></TD><TD ><A HREF = "fix_planeforce.html">planeforce</A></TD><TD ><A HREF = "fix_poems.html">poems</A></TD><TD ><A HREF = "fix_pour.html">pour</A></TD><TD ><A HREF = "fix_press_berendsen.html">press/berendsen</A></TD></TR>
|
||||
<TR ALIGN="center"><TD ><A HREF = "fix_print.html">print</A></TD><TD ><A HREF = "fix_reax_bonds.html">reax/bonds</A></TD><TD ><A HREF = "fix_recenter.html">recenter</A></TD><TD ><A HREF = "fix_rigid.html">rigid</A></TD><TD ><A HREF = "fix_rigid.html">rigid/nve</A></TD><TD ><A HREF = "fix_rigid.html">rigid/nvt</A></TD><TD ><A HREF = "fix_setforce.html">setforce</A></TD><TD ><A HREF = "fix_shake.html">shake</A></TD></TR>
|
||||
<TR ALIGN="center"><TD ><A HREF = "fix_spring.html">spring</A></TD><TD ><A HREF = "fix_spring_rg.html">spring/rg</A></TD><TD ><A HREF = "fix_spring_self.html">spring/self</A></TD><TD ><A HREF = "fix_store_force.html">store/force</A></TD><TD ><A HREF = "fix_store_state.html">store/state</A></TD><TD ><A HREF = "fix_temp_berendsen.html">temp/berendsen</A></TD><TD ><A HREF = "fix_temp_rescale.html">temp/rescale</A></TD><TD ><A HREF = "fix_thermal_conductivity.html">thermal/conductivity</A></TD></TR>
|
||||
<TR ALIGN="center"><TD ><A HREF = "fix_tmd.html">tmd</A></TD><TD ><A HREF = "fix_ttm.html">ttm</A></TD><TD ><A HREF = "fix_viscosity.html">viscosity</A></TD><TD ><A HREF = "fix_viscous.html">viscous</A></TD><TD ><A HREF = "fix_wall.html">wall/colloid</A></TD><TD ><A HREF = "fix_wall_gran.html">wall/gran</A></TD><TD ><A HREF = "fix_wall.html">wall/harmonic</A></TD><TD ><A HREF = "fix_wall.html">wall/lj126</A></TD></TR>
|
||||
<TR ALIGN="center"><TD ><A HREF = "fix_wall.html">wall/lj93</A></TD><TD ><A HREF = "fix_wall_reflect.html">wall/reflect</A></TD><TD ><A HREF = "fix_wall_region.html">wall/region</A>
|
||||
</TD></TR></TABLE></DIV>
|
||||
|
||||
<P>These are fix styles contributed by users, which can be used if
|
||||
|
|
|
@ -386,6 +386,7 @@ of each style or click on the style itself for a full description:
|
|||
"addforce"_fix_addforce.html,
|
||||
"aveforce"_fix_aveforce.html,
|
||||
"ave/atom"_fix_ave_atom.html,
|
||||
"ave/correlate"_fix_ave_correlate.html,
|
||||
"ave/histo"_fix_ave_histo.html,
|
||||
"ave/spatial"_fix_ave_spatial.html,
|
||||
"ave/time"_fix_ave_time.html,
|
||||
|
|
|
@ -1093,9 +1093,11 @@ command.
|
|||
</P>
|
||||
<H5><A NAME = "fixoutput"></A>Fixes that write output files
|
||||
</H5>
|
||||
<P>Three fixes take various quantities as input and can write output
|
||||
<P>Sevarl fixes take various quantities as input and can write output
|
||||
files: <A HREF = "fix_ave_time.html">fix ave/time</A>, <A HREF = "fix_ave_spatial.html">fix
|
||||
ave/spatial</A>, and <A HREF = "fix_print.html">fix print</A>.
|
||||
ave/spatial</A>, <A HREF = "fix_ave_histo.html">fix ave/histo</A>,
|
||||
<A HREF = "fix_ave_correlate.html">fix ave/correlate</A>, and <A HREF = "fix_print.html">fix
|
||||
print</A>.
|
||||
</P>
|
||||
<P>The <A HREF = "fix_ave_time.html">fix ave/time</A> command enables direct output to
|
||||
a file and/or time-averaging of global scalars or vectors. The user
|
||||
|
@ -1126,6 +1128,11 @@ to a file of histogrammed quantities, which can be global or per-atom
|
|||
or local quantities. The histogram output of this fix can also be
|
||||
used as input to other output commands.
|
||||
</P>
|
||||
<P>The <A HREF = "fix_ave_histo.html">fix ave/correlate</A> command enables direct
|
||||
output to a file of time-correlated quantities, which can be global
|
||||
scalars. The correlation matrix output of this fix can also be used
|
||||
as input to other output commands.
|
||||
</P>
|
||||
<P>The <A HREF = "fix_print.html">fix print</A> command can generate a line of output
|
||||
written to the screen and log file or to a separate file, periodically
|
||||
during a running simulation. The line can contain one or more
|
||||
|
@ -1141,10 +1148,10 @@ from normal thermodynamic or dump file output.
|
|||
<H5><A NAME = "computeoutput"></A>Computes that process output quantities
|
||||
</H5>
|
||||
<P>The <A HREF = "compute_reduce.html">compute reduce</A> and <A HREF = "compute_reduce.html">compute
|
||||
reduce/region</A> commands take one or more vector
|
||||
quantities as inputs and "reduce" them (sum, min, max, ave) to scalar
|
||||
quantities. These are produced as output values which can be used as
|
||||
input to other output commands.
|
||||
reduce/region</A> commands take one or more per-atom
|
||||
or local vector quantities as inputs and "reduce" them (sum, min, max,
|
||||
ave) to scalar quantities. These are produced as output values which
|
||||
can be used as input to other output commands.
|
||||
</P>
|
||||
<P>The <A HREF = "compute_property_atom.html">compute property/atom</A> command takes a
|
||||
list of one or more pre-defined atom attributes (id, x, fx, etc) and
|
||||
|
@ -1169,9 +1176,9 @@ quantities calculated by a <A HREF = "compute.html">compute</A>, by a
|
|||
time-averaged per-atom output of this fix can be used as input to
|
||||
other output commands.
|
||||
</P>
|
||||
<P>The <A HREF = "fix_ave_atom.html">fix store</A> command can archive one or more
|
||||
per-atom attributes at a particular time, so that the old values can
|
||||
be used in a future calculation or output. The list of atom
|
||||
<P>The <A HREF = "fix_store_state.html">fix store/state</A> command can archive one or
|
||||
more per-atom attributes at a particular time, so that the old values
|
||||
can be used in a future calculation or output. The list of atom
|
||||
attributes is the same as for the <A HREF = "dump.html">dump custom</A> command,
|
||||
including per-atom quantities calculated by a <A HREF = "compute.html">compute</A>,
|
||||
by a <A HREF = "fix.html">fix</A>, or by an atom-style <A HREF = "variable.html">variable</A>.
|
||||
|
@ -1232,14 +1239,15 @@ vector input could be a column of an array.
|
|||
<TR><TD ><A HREF = "compute.html">computes</A></TD><TD > N/A</TD><TD > global/per-atom/local scalar/vector/array</TD><TD ></TD></TR>
|
||||
<TR><TD ><A HREF = "fix.html">fixes</A></TD><TD > N/A</TD><TD > global/per-atom/local scalar/vector/array</TD><TD ></TD></TR>
|
||||
<TR><TD ><A HREF = "variable.html">variables</A></TD><TD > global scalars, per-atom vectors</TD><TD > global scalar, per-atom vector</TD><TD ></TD></TR>
|
||||
<TR><TD ><A HREF = "compute_reduce.html">compute reduce</A></TD><TD > global/per-atom/local vectors</TD><TD > global scalar/vector</TD><TD ></TD></TR>
|
||||
<TR><TD ><A HREF = "compute_reduce.html">compute reduce</A></TD><TD > per-atom/local vectors</TD><TD > global scalar/vector</TD><TD ></TD></TR>
|
||||
<TR><TD ><A HREF = "compute_property_atom.html">compute property/atom</A></TD><TD > per-atom vectors</TD><TD > per-atom vector/array</TD><TD ></TD></TR>
|
||||
<TR><TD ><A HREF = "compute_property_local.html">compute property/local</A></TD><TD > local vectors</TD><TD > local vector/array</TD><TD ></TD></TR>
|
||||
<TR><TD ><A HREF = "fix_ave_atom.html">fix ave/atom</A></TD><TD > per-atom vectors</TD><TD > per-atom vector/array</TD><TD ></TD></TR>
|
||||
<TR><TD ><A HREF = "fix_ave_time.html">fix ave/time</A></TD><TD > global scalars/vectors</TD><TD > global scalar/vector/array, file</TD><TD ></TD></TR>
|
||||
<TR><TD ><A HREF = "fix_ave_spatial.html">fix ave/spatial</A></TD><TD > per-atom vectors</TD><TD > global array, file</TD><TD ></TD></TR>
|
||||
<TR><TD ><A HREF = "fix_ave_histo.html">fix ave/histo</A></TD><TD > global/per-atom/local scalars and vectors</TD><TD > global array, file</TD><TD ></TD></TR>
|
||||
<TR><TD ><A HREF = "fix_store.html">fix store</A></TD><TD > per-atom vectors</TD><TD > per-atom vector/array</TD><TD ></TD></TR>
|
||||
<TR><TD ><A HREF = "fix_ave_correlate.html">fix ave/correlate</A></TD><TD > global scalars</TD><TD > global array, file</TD><TD ></TD></TR>
|
||||
<TR><TD ><A HREF = "fix_store_state.html">fix store/state</A></TD><TD > per-atom vectors</TD><TD > per-atom vector/array</TD><TD ></TD></TR>
|
||||
<TR><TD >
|
||||
</TD></TR></TABLE></DIV>
|
||||
|
||||
|
|
|
@ -1084,9 +1084,11 @@ command.
|
|||
|
||||
Fixes that write output files :h5,link(fixoutput)
|
||||
|
||||
Three fixes take various quantities as input and can write output
|
||||
Sevarl fixes take various quantities as input and can write output
|
||||
files: "fix ave/time"_fix_ave_time.html, "fix
|
||||
ave/spatial"_fix_ave_spatial.html, and "fix print"_fix_print.html.
|
||||
ave/spatial"_fix_ave_spatial.html, "fix ave/histo"_fix_ave_histo.html,
|
||||
"fix ave/correlate"_fix_ave_correlate.html, and "fix
|
||||
print"_fix_print.html.
|
||||
|
||||
The "fix ave/time"_fix_ave_time.html command enables direct output to
|
||||
a file and/or time-averaging of global scalars or vectors. The user
|
||||
|
@ -1117,6 +1119,11 @@ to a file of histogrammed quantities, which can be global or per-atom
|
|||
or local quantities. The histogram output of this fix can also be
|
||||
used as input to other output commands.
|
||||
|
||||
The "fix ave/correlate"_fix_ave_histo.html command enables direct
|
||||
output to a file of time-correlated quantities, which can be global
|
||||
scalars. The correlation matrix output of this fix can also be used
|
||||
as input to other output commands.
|
||||
|
||||
The "fix print"_fix_print.html command can generate a line of output
|
||||
written to the screen and log file or to a separate file, periodically
|
||||
during a running simulation. The line can contain one or more
|
||||
|
@ -1132,10 +1139,10 @@ from normal thermodynamic or dump file output.
|
|||
Computes that process output quantities :h5,link(computeoutput)
|
||||
|
||||
The "compute reduce"_compute_reduce.html and "compute
|
||||
reduce/region"_compute_reduce.html commands take one or more vector
|
||||
quantities as inputs and "reduce" them (sum, min, max, ave) to scalar
|
||||
quantities. These are produced as output values which can be used as
|
||||
input to other output commands.
|
||||
reduce/region"_compute_reduce.html commands take one or more per-atom
|
||||
or local vector quantities as inputs and "reduce" them (sum, min, max,
|
||||
ave) to scalar quantities. These are produced as output values which
|
||||
can be used as input to other output commands.
|
||||
|
||||
The "compute property/atom"_compute_property_atom.html command takes a
|
||||
list of one or more pre-defined atom attributes (id, x, fx, etc) and
|
||||
|
@ -1160,9 +1167,9 @@ quantities calculated by a "compute"_compute.html, by a
|
|||
time-averaged per-atom output of this fix can be used as input to
|
||||
other output commands.
|
||||
|
||||
The "fix store"_fix_ave_atom.html command can archive one or more
|
||||
per-atom attributes at a particular time, so that the old values can
|
||||
be used in a future calculation or output. The list of atom
|
||||
The "fix store/state"_fix_store_state.html command can archive one or
|
||||
more per-atom attributes at a particular time, so that the old values
|
||||
can be used in a future calculation or output. The list of atom
|
||||
attributes is the same as for the "dump custom"_dump.html command,
|
||||
including per-atom quantities calculated by a "compute"_compute.html,
|
||||
by a "fix"_fix.html, or by an atom-style "variable"_variable.html.
|
||||
|
@ -1222,14 +1229,15 @@ Command: Input: Output:
|
|||
"computes"_compute.html: N/A: global/per-atom/local scalar/vector/array:
|
||||
"fixes"_fix.html: N/A: global/per-atom/local scalar/vector/array:
|
||||
"variables"_variable.html: global scalars, per-atom vectors: global scalar, per-atom vector:
|
||||
"compute reduce"_compute_reduce.html: global/per-atom/local vectors: global scalar/vector:
|
||||
"compute reduce"_compute_reduce.html: per-atom/local vectors: global scalar/vector:
|
||||
"compute property/atom"_compute_property_atom.html: per-atom vectors: per-atom vector/array:
|
||||
"compute property/local"_compute_property_local.html: local vectors: local vector/array:
|
||||
"fix ave/atom"_fix_ave_atom.html: per-atom vectors: per-atom vector/array:
|
||||
"fix ave/time"_fix_ave_time.html: global scalars/vectors: global scalar/vector/array, file:
|
||||
"fix ave/spatial"_fix_ave_spatial.html: per-atom vectors: global array, file:
|
||||
"fix ave/histo"_fix_ave_histo.html: global/per-atom/local scalars and vectors: global array, file:
|
||||
"fix store"_fix_store.html: per-atom vectors: per-atom vector/array:
|
||||
"fix ave/correlate"_fix_ave_correlate.html: global scalars: global array, file:
|
||||
"fix store/state"_fix_store_state.html: per-atom vectors: per-atom vector/array:
|
||||
:tb(s=:)
|
||||
|
||||
:line
|
||||
|
|
|
@ -32,10 +32,10 @@
|
|||
<LI>input = x, y, z, vx, vy, vz, fx, fy, fz, c_ID, c_ID[N], f_ID, f_ID[N], v_name
|
||||
|
||||
<PRE> x,y,z,vx,vy,vz,fx,fy,fz = atom attribute (position, velocity, force component)
|
||||
c_ID = vector calculated by a compute with ID
|
||||
c_ID[I] = Ith column of array calculated by a compute with ID
|
||||
f_ID = vector calculated by a fix with ID
|
||||
f_ID[I] = Ith column of array calculated by a fix with ID
|
||||
c_ID = per-atom or local vector calculated by a compute with ID
|
||||
c_ID[I] = Ith column of per-atom or local array calculated by a compute with ID
|
||||
f_ID = per-atom or local vector calculated by a fix with ID
|
||||
f_ID[I] = Ith column of per-atom or local array calculated by a fix with ID
|
||||
v_name = per-atom vector calculated by an atom-style variable with name
|
||||
</PRE>
|
||||
<LI>zero or more keyword/args pairs may be appended
|
||||
|
@ -58,11 +58,14 @@ compute 3 fluid reduce max c_index<B>1</B> c_index<B>2</B> c_dist replace 1 3 re
|
|||
<P><B>Description:</B>
|
||||
</P>
|
||||
<P>Define a calculation that "reduces" one or more vector inputs into
|
||||
scalar values, one per listed input. The inputs can be global,
|
||||
per-atom, or local quantities. Atom attributes are per-atom
|
||||
quantities, <A HREF = "compute.html">computes</A> and <A HREF = "fix.html">fixes</A> may generate
|
||||
any of the three kinds of quantities, and <A HREF = "variable.html">atom-style
|
||||
variables</A> generate per-atom quantities.
|
||||
scalar values, one per listed input. The inputs can be per-atom or
|
||||
local quantities; they cannot be global quantities. Atom attributes
|
||||
are per-atom quantities, <A HREF = "compute.html">computes</A> and <A HREF = "fix.html">fixes</A>
|
||||
may generate any of the three kinds of quantities, and <A HREF = "variable.html">atom-style
|
||||
variables</A> generate per-atom quantities. See the
|
||||
<A HREF = "variable">variable</A> command and its special functions which can
|
||||
perform the same operations as the compute reduce command on global
|
||||
vectors.
|
||||
</P>
|
||||
<P>The reduction operation is specified by the <I>mode</I> setting. The <I>sum</I>
|
||||
option adds the values in the vector into a global total. The <I>min</I>
|
||||
|
@ -92,8 +95,8 @@ property/atom</A> command and then specifying
|
|||
an input value from that compute.
|
||||
</P>
|
||||
<P>If a value begins with "c_", a compute ID must follow which has been
|
||||
previously defined in the input script. Computes can generate global,
|
||||
per-atom, or local quantities. See the individual
|
||||
previously defined in the input script. Computes can generate
|
||||
per-atom or local quantities. See the individual
|
||||
<A HREF = "compute.html">compute</A> doc page for details. If no bracketed integer
|
||||
is appended, the vector calculated by the compute is used. If a
|
||||
bracketed interger is appended, the Ith column of the array calculated
|
||||
|
@ -101,10 +104,10 @@ by the compute is used. Users can also write code for their own
|
|||
compute styles and <A HREF = "Section_modify.html">add them to LAMMPS</A>.
|
||||
</P>
|
||||
<P>If a value begins with "f_", a fix ID must follow which has been
|
||||
previously defined in the input script. Fixes can generate global,
|
||||
per-atom, or local quantities. See the individual <A HREF = "fix.html">fix</A> doc
|
||||
page for details. Note that some fixes only produce their values on
|
||||
certain timesteps, which must be compatible with when compute reduce
|
||||
previously defined in the input script. Fixes can generate per-atom
|
||||
or local quantities. See the individual <A HREF = "fix.html">fix</A> doc page for
|
||||
details. Note that some fixes only produce their values on certain
|
||||
timesteps, which must be compatible with when compute reduce
|
||||
references the values, else an error results. If no bracketed integer
|
||||
is appended, the vector calculated by the fix is used. If a bracketed
|
||||
integer is appended, the Ith column of the array calculated by the fix
|
||||
|
@ -151,7 +154,7 @@ IDs and the bond stretch will be printed with thermodynamic output.
|
|||
|
||||
<P>If a single input is specified this compute produces a global scalar
|
||||
value. If multiple inputs are specified, this compute produces a
|
||||
vector of global values, the length of which is equal to the number of
|
||||
global vector of values, the length of which is equal to the number of
|
||||
inputs specified.
|
||||
</P>
|
||||
<P>As discussed below, for <I>sum</I> mode, the value(s) produced by this
|
||||
|
@ -162,18 +165,20 @@ command with <A HREF = "thermo_modify.html">thermo_modify norm yes</A> set as an
|
|||
option. Or it can be accessed by a <A HREF = "variable.html">variable</A> that
|
||||
divides by the appropriate atom count.
|
||||
</P>
|
||||
<HR>
|
||||
|
||||
<P><B>Output info:</B>
|
||||
</P>
|
||||
<P>This compute calculates a global scalar or global vector of length N
|
||||
where N is the number of inputs, and which can be accessed by indices
|
||||
1-N. These values can be used by any command that uses global scalar
|
||||
or vector values from a compute as input. See <A HREF = "Section_howto.html#4_15">this
|
||||
section</A> for an overview of LAMMPS output
|
||||
options.
|
||||
<P>This compute calculates a global scalar if a single input value is
|
||||
specified or a global vector of length N where N is the number of
|
||||
inputs, and which can be accessed by indices 1 to N. These values can
|
||||
be used by any command that uses global scalar or vector values from a
|
||||
compute as input. See <A HREF = "Section_howto.html#4_15">this section</A> for an
|
||||
overview of LAMMPS output options.
|
||||
</P>
|
||||
<P>For <I>sum</I> mode, the scalar and vector values calculated by this
|
||||
compute are "extensive". For <I>min</I> or <I>max</I> or <I>ave</I> modes, the
|
||||
value(s) are "intensive".
|
||||
<P>All the scalar or vector values calculated by this compute are
|
||||
"intensive", except when the <I>sum</I> mode is used on per-atom or local
|
||||
vectors, in which case the calculated values are "extensive".
|
||||
</P>
|
||||
<P>The scalar or vector values will be in whatever <A HREF = "units.html">units</A> the
|
||||
quantities being reduced are in.
|
||||
|
|
|
@ -22,10 +22,10 @@ mode = {sum} or {min} or {max} or {ave} :l
|
|||
one or more inputs can be listed :l
|
||||
input = x, y, z, vx, vy, vz, fx, fy, fz, c_ID, c_ID\[N\], f_ID, f_ID\[N\], v_name :l
|
||||
x,y,z,vx,vy,vz,fx,fy,fz = atom attribute (position, velocity, force component)
|
||||
c_ID = vector calculated by a compute with ID
|
||||
c_ID\[I\] = Ith column of array calculated by a compute with ID
|
||||
f_ID = vector calculated by a fix with ID
|
||||
f_ID\[I\] = Ith column of array calculated by a fix with ID
|
||||
c_ID = per-atom or local vector calculated by a compute with ID
|
||||
c_ID\[I\] = Ith column of per-atom or local array calculated by a compute with ID
|
||||
f_ID = per-atom or local vector calculated by a fix with ID
|
||||
f_ID\[I\] = Ith column of per-atom or local array calculated by a fix with ID
|
||||
v_name = per-atom vector calculated by an atom-style variable with name :pre
|
||||
|
||||
zero or more keyword/args pairs may be appended :l
|
||||
|
@ -45,11 +45,14 @@ compute 3 fluid reduce max c_index[1] c_index[2] c_dist replace 1 3 replace 2 3
|
|||
[Description:]
|
||||
|
||||
Define a calculation that "reduces" one or more vector inputs into
|
||||
scalar values, one per listed input. The inputs can be global,
|
||||
per-atom, or local quantities. Atom attributes are per-atom
|
||||
quantities, "computes"_compute.html and "fixes"_fix.html may generate
|
||||
any of the three kinds of quantities, and "atom-style
|
||||
variables"_variable.html generate per-atom quantities.
|
||||
scalar values, one per listed input. The inputs can be per-atom or
|
||||
local quantities; they cannot be global quantities. Atom attributes
|
||||
are per-atom quantities, "computes"_compute.html and "fixes"_fix.html
|
||||
may generate any of the three kinds of quantities, and "atom-style
|
||||
variables"_variable.html generate per-atom quantities. See the
|
||||
"variable"_variable command and its special functions which can
|
||||
perform the same operations as the compute reduce command on global
|
||||
vectors.
|
||||
|
||||
The reduction operation is specified by the {mode} setting. The {sum}
|
||||
option adds the values in the vector into a global total. The {min}
|
||||
|
@ -79,8 +82,8 @@ property/atom"_compute_property_atom.html command and then specifying
|
|||
an input value from that compute.
|
||||
|
||||
If a value begins with "c_", a compute ID must follow which has been
|
||||
previously defined in the input script. Computes can generate global,
|
||||
per-atom, or local quantities. See the individual
|
||||
previously defined in the input script. Computes can generate
|
||||
per-atom or local quantities. See the individual
|
||||
"compute"_compute.html doc page for details. If no bracketed integer
|
||||
is appended, the vector calculated by the compute is used. If a
|
||||
bracketed interger is appended, the Ith column of the array calculated
|
||||
|
@ -88,10 +91,10 @@ by the compute is used. Users can also write code for their own
|
|||
compute styles and "add them to LAMMPS"_Section_modify.html.
|
||||
|
||||
If a value begins with "f_", a fix ID must follow which has been
|
||||
previously defined in the input script. Fixes can generate global,
|
||||
per-atom, or local quantities. See the individual "fix"_fix.html doc
|
||||
page for details. Note that some fixes only produce their values on
|
||||
certain timesteps, which must be compatible with when compute reduce
|
||||
previously defined in the input script. Fixes can generate per-atom
|
||||
or local quantities. See the individual "fix"_fix.html doc page for
|
||||
details. Note that some fixes only produce their values on certain
|
||||
timesteps, which must be compatible with when compute reduce
|
||||
references the values, else an error results. If no bracketed integer
|
||||
is appended, the vector calculated by the fix is used. If a bracketed
|
||||
integer is appended, the Ith column of the array calculated by the fix
|
||||
|
@ -138,7 +141,7 @@ IDs and the bond stretch will be printed with thermodynamic output.
|
|||
|
||||
If a single input is specified this compute produces a global scalar
|
||||
value. If multiple inputs are specified, this compute produces a
|
||||
vector of global values, the length of which is equal to the number of
|
||||
global vector of values, the length of which is equal to the number of
|
||||
inputs specified.
|
||||
|
||||
As discussed below, for {sum} mode, the value(s) produced by this
|
||||
|
@ -149,18 +152,20 @@ command with "thermo_modify norm yes"_thermo_modify.html set as an
|
|||
option. Or it can be accessed by a "variable"_variable.html that
|
||||
divides by the appropriate atom count.
|
||||
|
||||
:line
|
||||
|
||||
[Output info:]
|
||||
|
||||
This compute calculates a global scalar or global vector of length N
|
||||
where N is the number of inputs, and which can be accessed by indices
|
||||
1-N. These values can be used by any command that uses global scalar
|
||||
or vector values from a compute as input. See "this
|
||||
section"_Section_howto.html#4_15 for an overview of LAMMPS output
|
||||
options.
|
||||
This compute calculates a global scalar if a single input value is
|
||||
specified or a global vector of length N where N is the number of
|
||||
inputs, and which can be accessed by indices 1 to N. These values can
|
||||
be used by any command that uses global scalar or vector values from a
|
||||
compute as input. See "this section"_Section_howto.html#4_15 for an
|
||||
overview of LAMMPS output options.
|
||||
|
||||
For {sum} mode, the scalar and vector values calculated by this
|
||||
compute are "extensive". For {min} or {max} or {ave} modes, the
|
||||
value(s) are "intensive".
|
||||
All the scalar or vector values calculated by this compute are
|
||||
"intensive", except when the {sum} mode is used on per-atom or local
|
||||
vectors, in which case the calculated values are "extensive".
|
||||
|
||||
The scalar or vector values will be in whatever "units"_units.html the
|
||||
quantities being reduced are in.
|
||||
|
|
|
@ -0,0 +1,342 @@
|
|||
<HTML>
|
||||
<CENTER><A HREF = "http://lammps.sandia.gov">LAMMPS WWW Site</A> - <A HREF = "Manual.html">LAMMPS Documentation</A> - <A HREF = "Section_commands.html#comm">LAMMPS Commands</A>
|
||||
</CENTER>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<HR>
|
||||
|
||||
<H3>fix ave/correlate command
|
||||
</H3>
|
||||
<P><B>Syntax:</B>
|
||||
</P>
|
||||
<PRE>fix ID group-ID ave/correlate Nevery Nrepeat Nfreq value1 value2 ... keyword args ...
|
||||
</PRE>
|
||||
<UL><LI>ID, group-ID are documented in <A HREF = "fix.html">fix</A> command
|
||||
|
||||
<LI>ave/time = style name of this fix command
|
||||
|
||||
<LI>Nevery = use input values every this many timesteps
|
||||
|
||||
<LI>Nrepeat = # of correlation time windows to accumulate
|
||||
|
||||
<LI>Nfreq = calculate tine window averages every this many timesteps
|
||||
|
||||
<LI>one or more input values can be listed
|
||||
|
||||
<LI>value = c_ID, c_ID[N], f_ID, f_ID[N], v_name
|
||||
|
||||
<PRE> c_ID = global scalar calculated by a compute with ID
|
||||
c_ID[I] = Ith component of global vector calculated by a compute with ID
|
||||
f_ID = global scalar calculated by a fix with ID
|
||||
f_ID[I] = Ith component of global vector calculated by a fix with ID
|
||||
v_name = global value calculated by an equal-style variable with name
|
||||
</PRE>
|
||||
<LI>zero or more keyword/arg pairs may be appended
|
||||
|
||||
<LI>keyword = <I>type</I> or <I>ave</I> or <I>start</I> or <I>prefactor</I> or <I>file</I> or <I>title1</I> or <I>title2</I> or <I>title3</I>
|
||||
|
||||
<PRE> <I>type</I> arg = <I>auto</I> or <I>upper</I> or <I>lower</I> or <I>auto/upper</I> or <I>auto/lower</I> or <I>full</I>
|
||||
auto = correlate each value with itself
|
||||
upper = correlate each value with each succeeding value
|
||||
lower = correlate each value with each preceding value
|
||||
auto/upper = auto + upper
|
||||
auto/lower = auto + lower
|
||||
full = correlate each value with every other value, including itself = auto + upper + lower
|
||||
<I>ave</I> args = <I>one</I> or <I>running</I>
|
||||
one = zero the correlation accumulation every Nfreq steps
|
||||
running = accumulate correlations continuously
|
||||
<I>start</I> args = Nstart
|
||||
Nstart = start accumulating correlations on this timestep
|
||||
<I>prefactor</I> args = value
|
||||
value = prefactor to scale all the correlation data by
|
||||
<I>file</I> arg = filename
|
||||
filename = name of file to output correlation data to
|
||||
<I>title1</I> arg = string
|
||||
string = text to print as 1st line of output file
|
||||
<I>title2</I> arg = string
|
||||
string = text to print as 2nd line of output file
|
||||
<I>title3</I> arg = string
|
||||
string = text to print as 3rd line of output file
|
||||
</PRE>
|
||||
|
||||
</UL>
|
||||
<P><B>Examples:</B>
|
||||
</P>
|
||||
<PRE>fix 1 all ave/correlate 5 100 1000 c_myTemp file temp.correlate
|
||||
fix 1 all ave/correlate 1 50 10000 &
|
||||
c_thermo_press[1] c_thermo_press[2] c_thermo_press[3] &
|
||||
type upper ave running title1 "My correlation data"
|
||||
</PRE>
|
||||
<P><B>Description:</B>
|
||||
</P>
|
||||
<P>Use one or more global scalar values as inputs every few timesteps,
|
||||
calculate time correlations bewteen them at varying time intervals,
|
||||
and average the correlation data over longer timescales. The
|
||||
resulting correlation values can be time integrated by
|
||||
<A HREF = "variable.html">variables</A> or used by other <A HREF = "Section_howto.html#4_15">output
|
||||
commands</A> such as <A HREF = "thermo_style.html">thermo_style
|
||||
custom</A>, and can also be written to a file.
|
||||
</P>
|
||||
<P>The group specified with this command is ignored. However, note that
|
||||
specified values may represent calculations performed by computes and
|
||||
fixes which store their own "group" definitions.
|
||||
</P>
|
||||
<P>Each listed value can be the result of a <A HREF = "compute.html">compute</A> or
|
||||
<A HREF = "fix.html">fix</A> or the evaluation of an equal-style
|
||||
<A HREF = "variable.html">variable</A>. In each case, the compute, fix, or variable
|
||||
must produce a global quantity, not a per-atom or local quantity. If
|
||||
you wish to spatial- or time-average or histogram per-atom quantities
|
||||
from a compute, fix, or variable, then see the <A HREF = "fix_ave_spatial.html">fix
|
||||
ave/spatial</A>, <A HREF = "fix_ave_atom.html">fix ave/atom</A>,
|
||||
or <A HREF = "fix_ave_histo.html">fix ave/histo</A> commands. If you wish to sum a
|
||||
per-atom quantity into a single global quantity, see the <A HREF = "compute_reduce.html">compute
|
||||
reduce</A> command.
|
||||
</P>
|
||||
<P><A HREF = "compute.html">Computes</A> that produce global quantities are those which
|
||||
do not have the word <I>atom</I> in their style name. Only a few
|
||||
<A HREF = "fix.html">fixes</A> produce global quantities. See the doc pages for
|
||||
individual fixes for info on which ones produce such values.
|
||||
<A HREF = "variable.html">Variables</A> of style <I>equal</I> are the only ones that can
|
||||
be used with this fix. Variables of style <I>atom</I> cannot be used,
|
||||
since they produce per-atom values.
|
||||
</P>
|
||||
<P>The input values must either be all scalars. What kinds of
|
||||
correlations between input values are calculated is determined by the
|
||||
<I>type</I> keyword as discussed below.
|
||||
</P>
|
||||
<HR>
|
||||
|
||||
<P>The <I>Nevery</I>, <I>Nrepeat</I>, and <I>Nfreq</I> arguments specify on what
|
||||
timesteps the input values will be used to calculate correlation data.
|
||||
The input values are sampled every <I>Nevery</I> timesteps. The
|
||||
correlation data for the preceding samples is computed every <I>Nfreq</I>
|
||||
timesteps. Consider a set of samples from some initial time up to an
|
||||
output timestep. The initial time could be the beginning of the
|
||||
simulation or the last output time; see the <I>ave</I> keyword for options.
|
||||
For the set of samples, the correlation value Cij is calculated as:
|
||||
</P>
|
||||
<PRE>Cij(delta) = <Vi(t)*Vj(t+delta)>
|
||||
</PRE>
|
||||
<P>which is the correlation value between input values Vi and Vj,
|
||||
separated by time delta. Note that the second value Vj in the pair is
|
||||
always the one sampled at the later time. The <> brackets represent
|
||||
an average over every pair of samples in the set that are separated by
|
||||
time delta. The maximum delta used is of size (<I>Nrepeat</I>-1)*<I>Nevery</I>.
|
||||
Thus the correlation between a pair of input values yields <I>Nrepeat</I>
|
||||
correlation datums:
|
||||
</P>
|
||||
<PRE>Cij(0), Cij(Nevery), Cij(2*Nevery), ..., Cij((Nrepeat-1)*Nevery)
|
||||
</PRE>
|
||||
<P><I>Nfreq</I> must be a multiple of <I>Nevery</I>; <I>Nevery</I> and <I>Nrepeat</I> must be
|
||||
non-zero. Also, <I>Nfreq</I> >= (<I>Nrepeat</I>-1)*<I>Nevery</I> is required.
|
||||
</P>
|
||||
<P>For example, if Nevery=5, Nrepeat=6, and Nfreq=100, then values on
|
||||
timesteps 0,5,10,15,...,100 will be used to compute the final averages
|
||||
on timestep 100. Six averages will be computed: Cij(0), Cij(5),
|
||||
Cij(10), Cij(15), Cij(20), and Cij(25). Cij(10) on timestep 100 will
|
||||
be the average of 19 samples, namely Vi(0)*Vj(10), Vi(5)*Vj(15),
|
||||
Vi(10)*V j20), Vi(15)*Vj(25), ..., Vi(85)*Vj(95), Vi(90)*Vj(100).
|
||||
</P>
|
||||
<HR>
|
||||
|
||||
<P>If a value begins with "c_", a compute ID must follow which has been
|
||||
previously defined in the input script. If no bracketed term is
|
||||
appended, the global scalar calculated by the compute is used. If a
|
||||
bracketed term is appended, the Ith element of the global vector
|
||||
calculated by the compute is used.
|
||||
</P>
|
||||
<P>Note that there is a <A HREF = "compute_reduce.html">compute reduce</A> command
|
||||
which can sum per-atom quantities into a global scalar or vector which
|
||||
can thus be accessed by fix ave/correlate. Or it can be a compute
|
||||
defined not in your input script, but by <A HREF = "thermo_style.html">thermodynamic
|
||||
output</A> or other fixes such as <A HREF = "fix_nh.html">fix nvt</A>
|
||||
or <A HREF = "fix_temp_rescale.html">fix temp/rescale</A>. See the doc pages for
|
||||
these commands which give the IDs of these computes. Users can also
|
||||
write code for their own compute styles and <A HREF = "Section_modify.html">add them to
|
||||
LAMMPS</A>.
|
||||
</P>
|
||||
<P>If a value begins with "f_", a fix ID must follow which has been
|
||||
previously defined in the input script. If no bracketed term is
|
||||
appended, the global scalar calculated by the fix is used. If a
|
||||
bracketed term is appended, the Ith element of the global vector
|
||||
calculated by the fix is used.
|
||||
</P>
|
||||
<P>Note that some fixes only produce their values on certain timesteps,
|
||||
which must be compatible with <I>Nevery</I>, else an error will result.
|
||||
Users can also write code for their own fix styles and <A HREF = "Section_modify.html">add them to
|
||||
LAMMPS</A>.
|
||||
</P>
|
||||
<P>If a value begins with "v_", a variable name must follow which has
|
||||
been previously defined in the input script. Only equal-style
|
||||
variables can be referenced. See the <A HREF = "variable.html">variable</A> command
|
||||
for details. Note that variables of style <I>equal</I> define a formula
|
||||
which can reference individual atom properties or thermodynamic
|
||||
keywords, or they can invoke other computes, fixes, or variables when
|
||||
they are evaluated, so this is a very general means of specifying
|
||||
quantities to time correlate.
|
||||
</P>
|
||||
<HR>
|
||||
|
||||
<P>Additional optional keywords also affect the operation of this fix.
|
||||
</P>
|
||||
<P>The <I>type</I> keyword determines which pairs of input values are
|
||||
correlated with each other. For N input values Vi, for i = 1 to N,
|
||||
let the number of pairs = Npair. Note that the second value in the
|
||||
pair Vi(t)*Vj(t+delta) is always the one sampled at the later time.
|
||||
</P>
|
||||
<UL><LI>If <I>type</I> is set to <I>auto</I> then each input value is correlated with
|
||||
itself. I.e. Cii = Vi*Vi, for i = 1 to N, so Npair = N.
|
||||
|
||||
<LI>If <I>type</I> is set
|
||||
to <I>upper</I> then each input value is correlated with every succeeding
|
||||
value. I.e. Cij = Vi*Vj, for i < j, so Npair = N*(N-1)/2.
|
||||
|
||||
<LI>If <I>type</I> is set
|
||||
to <I>lower</I> then each input value is correlated with every preceeding
|
||||
value. I.e. Cij = Vi*Vj, for i > j, so Npair = N*(N-1)/2.
|
||||
|
||||
<LI>If <I>type</I> is set to <I>auto/upper</I> then each input value is correlated
|
||||
with itself and every succeeding value. I.e. Cij = Vi*Vj, for i >= j,
|
||||
so Npair = N*(N+1)/2.
|
||||
|
||||
<LI>If <I>type</I> is set to <I>auto/lower</I> then each input value is correlated
|
||||
with itself and every preceding value. I.e. Cij = Vi*Vj, for i <= j,
|
||||
so Npair = N*(N+1)/2.
|
||||
|
||||
<LI>If <I>type</I> is set to <I>full</I> then each input value is correlated with
|
||||
itself and every other value. I.e. Cij = Vi*Vj, for i,j = 1,N so
|
||||
Npair = N^2.
|
||||
</UL>
|
||||
<P>The <I>ave</I> keyword determines what happens to the accumulation of
|
||||
correlation samples every <I>Nfreq</I> timesteps. If the <I>ave</I> setting is
|
||||
<I>one</I>, then the accumulation is restarted or zeroed every <I>Nfreq</I>
|
||||
timesteps. Thus the outputs on successive <I>Nfreq</I> timesteps are
|
||||
essentially independent of each other. The exception is that the
|
||||
Cij(0) = Vi(T)*Vj(T) value at a timestep T, where T is a multiple of
|
||||
<I>Nfreq</I>, contributes to the correlation output both at time T and at
|
||||
time T+Nfreq.
|
||||
</P>
|
||||
<P>If the <I>ave</I> setting is <I>running</I>, then the accumulation is never
|
||||
zeroed. Thus the output of correlation data at any timestep is the
|
||||
average over samples accumulated every <I>Nevery</I> steps since the fix
|
||||
was defined. it can only be restarted by deleting the fix via the
|
||||
<A HREF = "unfix.html">unfix</A> command, or by re-defining the fix by re-specifying
|
||||
it.
|
||||
</P>
|
||||
<P>The <I>start</I> keyword specifies what timestep the accumulation of
|
||||
correlation samples will begin on. The default is step 0. Setting it
|
||||
to a larger value can avoid adding non-equilibrated data to the
|
||||
correlation averages.
|
||||
</P>
|
||||
<P>The <I>prefactor</I> keyword specifies a constant which will be used as a
|
||||
multiplier on the correlation data after it is averaged. It is
|
||||
effectively a scale factor on Vi*Vj, which can be used to account for
|
||||
the size of the time window or other unit conversions.
|
||||
</P>
|
||||
<P>The <I>file</I> keyword allows a filename to be specified. Every <I>Nfreq</I>
|
||||
steps, an array of correlation data is written to the file. The
|
||||
number of rows is <I>Nrepeat</I>, as described above. The number of
|
||||
columns is the Npair+2, also as described above. Thus the file ends
|
||||
up to be a series of these array sections.
|
||||
</P>
|
||||
<P>The <I>title1</I> and <I>title2</I> and <I>title3</I> keywords allow specification of
|
||||
the strings that will be printed as the first 3 lines of the output
|
||||
file, assuming the <I>file</I> keyword was used. LAMMPS uses default
|
||||
values for each of these, so they do not need to be specified.
|
||||
</P>
|
||||
<P>By default, these header lines are as follows:
|
||||
</P>
|
||||
<PRE># Time-correlated data for fix ID
|
||||
# TimeStep Number-of-time-windows
|
||||
# Index TimeDelta Ncount valueI*valueJ valueI*valueJ ...
|
||||
</PRE>
|
||||
<P>In the first line, ID is replaced with the fix-ID. The second line
|
||||
describes the two values that are printed at the first of each section
|
||||
of output. In the third line the value pairs are replaced with the
|
||||
appropriate fields from the fix ave/correlate command.
|
||||
</P>
|
||||
<HR>
|
||||
|
||||
<P>Let Sij = a set of time correlation data for input values I and J,
|
||||
namely the <I>Nrepeat</I> values:
|
||||
</P>
|
||||
<PRE>Sij = Cij(0), Cij(Nevery), Cij(2*Nevery), ..., Cij(*Nrepeat-1)*Nevery)
|
||||
</PRE>
|
||||
<P>As explained below, these datums are output as one column of a global
|
||||
array, which is effectively the correlation matrix.
|
||||
</P>
|
||||
<P>The <I>trap</I> function defined for <A HREF = "variable.html">equal-style variables</A>
|
||||
can be used to perform a time integration of this vector of datums,
|
||||
using a trapezoidal rule. This is useful for calculating various
|
||||
quantities which can be derived from time correlation data. If a
|
||||
normalization factor is needed for the time integration, it can be
|
||||
included in the variable formula or via the <I>prefactor</I> keyword.
|
||||
</P>
|
||||
<HR>
|
||||
|
||||
<P><B>Restart, fix_modify, output, run start/stop, minimize info:</B>
|
||||
</P>
|
||||
<P>No information about this fix is written to <A HREF = "restart.html">binary restart
|
||||
files</A>. None of the <A HREF = "fix_modify.html">fix_modify</A> options
|
||||
are relevant to this fix.
|
||||
</P>
|
||||
<P>This fix computes a global array of values which can be accessed by
|
||||
various <A HREF = "Section_howto.html#4_15">output commands</A>. The values can
|
||||
only be accessed on timesteps that are multiples of <I>Nfreq</I> since that
|
||||
is when averaging is performed. The global array has # of rows =
|
||||
<I>Nrepeat</I> and # of columns = Npair+2. The first column has the time
|
||||
delta (in timesteps) between the pairs of input values used to
|
||||
calculate the correlation, as described above. The 2nd column has the
|
||||
number of samples contributing to the correlation average, as
|
||||
described above. The remaining Npair columns are for I,J pairs of the
|
||||
N input values, as determined by the <I>type</I> keyword, as described
|
||||
above.
|
||||
</P>
|
||||
<UL><LI>For <I>type</I> = <I>auto</I>, the Npair = N columns are ordered: C11, C22, ...,
|
||||
CNN.
|
||||
|
||||
<LI>For <I>type</I> = <I>upper</I>, the Npair = N*(N-1)/2 columns are ordered: C12,
|
||||
C13, ..., C1N, C23, ..., C2N, C34, ..., CN-1N.
|
||||
|
||||
<LI>For <I>type</I> = <I>lower</I>, the Npair = N*(N-1)/2 columns are ordered: C21,
|
||||
C31, C32, C41, C42, C43, ..., CN1, CN2, ..., CNN-1.
|
||||
|
||||
<LI>For <I>type</I> = <I>auto/upper</I>, the Npair = N*(N+1)/2 columns are ordered:
|
||||
C11, C12, C13, ..., C1N, C22, C23, ..., C2N, C33, C34, ..., CN-1N,
|
||||
CNN.
|
||||
|
||||
<LI>For <I>type</I> = <I>auto/lower</I>, the Npair = N*(N+1)/2 columns are ordered:
|
||||
C11, C21, C22, C31, C32, C33, C41, ..., C44, CN1, CN2, ..., CNN-1,
|
||||
CNN.
|
||||
|
||||
<LI>For <I>type</I> = <I>full</I>, the Npair = N^2 columns are ordered: C11, C12,
|
||||
..., C1N, C21, C22, ..., C2N, C31, ..., C3N, ..., CN1, ..., CNN-1,
|
||||
CNN.
|
||||
</UL>
|
||||
<P>The array values calculated by this fix are treated as "intensive".
|
||||
If you need to divide them by the number of atoms, you must do this in
|
||||
a later processing step, e.g. when using them in a
|
||||
<A HREF = "variable.html">variable</A>.
|
||||
</P>
|
||||
<P>No parameter of this fix can be used with the <I>start/stop</I> keywords of
|
||||
the <A HREF = "run.html">run</A> command. This fix is not invoked during <A HREF = "minimize.html">energy
|
||||
minimization</A>.
|
||||
</P>
|
||||
<P><B>Restrictions:</B> none
|
||||
</P>
|
||||
<P><B>Related commands:</B>
|
||||
</P>
|
||||
<P><A HREF = "compute.html">compute</A>, <A HREF = "fix_ave_time.html">fix ave/time</A>, <A HREF = "fix_ave_atom.html">fix
|
||||
ave/atom</A>, <A HREF = "fix_ave_spatial.html">fix ave/spatial</A>,
|
||||
<A HREF = "fix_ave_histo.html">fix ave/histo</A>, <A HREF = "variable.html">variable</A>
|
||||
</P>
|
||||
<P><B>Default:</B> none
|
||||
</P>
|
||||
<P>The option defaults are ave = one, type = auto, start = 0, no file
|
||||
output, title 1,2,3 = strings as described above, and prefactor = 1.0.
|
||||
</P>
|
||||
</HTML>
|
|
@ -0,0 +1,327 @@
|
|||
"LAMMPS WWW Site"_lws - "LAMMPS Documentation"_ld - "LAMMPS Commands"_lc :c
|
||||
|
||||
:link(lws,http://lammps.sandia.gov)
|
||||
:link(ld,Manual.html)
|
||||
:link(lc,Section_commands.html#comm)
|
||||
|
||||
:line
|
||||
|
||||
fix ave/correlate command :h3
|
||||
|
||||
[Syntax:]
|
||||
|
||||
fix ID group-ID ave/correlate Nevery Nrepeat Nfreq value1 value2 ... keyword args ... :pre
|
||||
|
||||
ID, group-ID are documented in "fix"_fix.html command :ulb,l
|
||||
ave/time = style name of this fix command :l
|
||||
Nevery = use input values every this many timesteps :l
|
||||
Nrepeat = # of correlation time windows to accumulate :l
|
||||
Nfreq = calculate tine window averages every this many timesteps :l
|
||||
one or more input values can be listed :l
|
||||
value = c_ID, c_ID\[N\], f_ID, f_ID\[N\], v_name :l
|
||||
c_ID = global scalar calculated by a compute with ID
|
||||
c_ID\[I\] = Ith component of global vector calculated by a compute with ID
|
||||
f_ID = global scalar calculated by a fix with ID
|
||||
f_ID\[I\] = Ith component of global vector calculated by a fix with ID
|
||||
v_name = global value calculated by an equal-style variable with name :pre
|
||||
|
||||
zero or more keyword/arg pairs may be appended :l
|
||||
keyword = {type} or {ave} or {start} or {prefactor} or {file} or {title1} or {title2} or {title3} :l
|
||||
{type} arg = {auto} or {upper} or {lower} or {auto/upper} or {auto/lower} or {full}
|
||||
auto = correlate each value with itself
|
||||
upper = correlate each value with each succeeding value
|
||||
lower = correlate each value with each preceding value
|
||||
auto/upper = auto + upper
|
||||
auto/lower = auto + lower
|
||||
full = correlate each value with every other value, including itself = auto + upper + lower
|
||||
{ave} args = {one} or {running}
|
||||
one = zero the correlation accumulation every Nfreq steps
|
||||
running = accumulate correlations continuously
|
||||
{start} args = Nstart
|
||||
Nstart = start accumulating correlations on this timestep
|
||||
{prefactor} args = value
|
||||
value = prefactor to scale all the correlation data by
|
||||
{file} arg = filename
|
||||
filename = name of file to output correlation data to
|
||||
{title1} arg = string
|
||||
string = text to print as 1st line of output file
|
||||
{title2} arg = string
|
||||
string = text to print as 2nd line of output file
|
||||
{title3} arg = string
|
||||
string = text to print as 3rd line of output file :pre
|
||||
:ule
|
||||
|
||||
[Examples:]
|
||||
|
||||
fix 1 all ave/correlate 5 100 1000 c_myTemp file temp.correlate
|
||||
fix 1 all ave/correlate 1 50 10000 &
|
||||
c_thermo_press\[1\] c_thermo_press\[2\] c_thermo_press\[3\] &
|
||||
type upper ave running title1 "My correlation data" :pre
|
||||
|
||||
[Description:]
|
||||
|
||||
Use one or more global scalar values as inputs every few timesteps,
|
||||
calculate time correlations bewteen them at varying time intervals,
|
||||
and average the correlation data over longer timescales. The
|
||||
resulting correlation values can be time integrated by
|
||||
"variables"_variable.html or used by other "output
|
||||
commands"_Section_howto.html#4_15 such as "thermo_style
|
||||
custom"_thermo_style.html, and can also be written to a file.
|
||||
|
||||
The group specified with this command is ignored. However, note that
|
||||
specified values may represent calculations performed by computes and
|
||||
fixes which store their own "group" definitions.
|
||||
|
||||
Each listed value can be the result of a "compute"_compute.html or
|
||||
"fix"_fix.html or the evaluation of an equal-style
|
||||
"variable"_variable.html. In each case, the compute, fix, or variable
|
||||
must produce a global quantity, not a per-atom or local quantity. If
|
||||
you wish to spatial- or time-average or histogram per-atom quantities
|
||||
from a compute, fix, or variable, then see the "fix
|
||||
ave/spatial"_fix_ave_spatial.html, "fix ave/atom"_fix_ave_atom.html,
|
||||
or "fix ave/histo"_fix_ave_histo.html commands. If you wish to sum a
|
||||
per-atom quantity into a single global quantity, see the "compute
|
||||
reduce"_compute_reduce.html command.
|
||||
|
||||
"Computes"_compute.html that produce global quantities are those which
|
||||
do not have the word {atom} in their style name. Only a few
|
||||
"fixes"_fix.html produce global quantities. See the doc pages for
|
||||
individual fixes for info on which ones produce such values.
|
||||
"Variables"_variable.html of style {equal} are the only ones that can
|
||||
be used with this fix. Variables of style {atom} cannot be used,
|
||||
since they produce per-atom values.
|
||||
|
||||
The input values must either be all scalars. What kinds of
|
||||
correlations between input values are calculated is determined by the
|
||||
{type} keyword as discussed below.
|
||||
|
||||
:line
|
||||
|
||||
The {Nevery}, {Nrepeat}, and {Nfreq} arguments specify on what
|
||||
timesteps the input values will be used to calculate correlation data.
|
||||
The input values are sampled every {Nevery} timesteps. The
|
||||
correlation data for the preceding samples is computed every {Nfreq}
|
||||
timesteps. Consider a set of samples from some initial time up to an
|
||||
output timestep. The initial time could be the beginning of the
|
||||
simulation or the last output time; see the {ave} keyword for options.
|
||||
For the set of samples, the correlation value Cij is calculated as:
|
||||
|
||||
Cij(delta) = <Vi(t)*Vj(t+delta)> :pre
|
||||
|
||||
which is the correlation value between input values Vi and Vj,
|
||||
separated by time delta. Note that the second value Vj in the pair is
|
||||
always the one sampled at the later time. The <> brackets represent
|
||||
an average over every pair of samples in the set that are separated by
|
||||
time delta. The maximum delta used is of size ({Nrepeat}-1)*{Nevery}.
|
||||
Thus the correlation between a pair of input values yields {Nrepeat}
|
||||
correlation datums:
|
||||
|
||||
Cij(0), Cij(Nevery), Cij(2*Nevery), ..., Cij((Nrepeat-1)*Nevery) :pre
|
||||
|
||||
{Nfreq} must be a multiple of {Nevery}; {Nevery} and {Nrepeat} must be
|
||||
non-zero. Also, {Nfreq} >= ({Nrepeat}-1)*{Nevery} is required.
|
||||
|
||||
For example, if Nevery=5, Nrepeat=6, and Nfreq=100, then values on
|
||||
timesteps 0,5,10,15,...,100 will be used to compute the final averages
|
||||
on timestep 100. Six averages will be computed: Cij(0), Cij(5),
|
||||
Cij(10), Cij(15), Cij(20), and Cij(25). Cij(10) on timestep 100 will
|
||||
be the average of 19 samples, namely Vi(0)*Vj(10), Vi(5)*Vj(15),
|
||||
Vi(10)*V j20), Vi(15)*Vj(25), ..., Vi(85)*Vj(95), Vi(90)*Vj(100).
|
||||
|
||||
:line
|
||||
|
||||
If a value begins with "c_", a compute ID must follow which has been
|
||||
previously defined in the input script. If no bracketed term is
|
||||
appended, the global scalar calculated by the compute is used. If a
|
||||
bracketed term is appended, the Ith element of the global vector
|
||||
calculated by the compute is used.
|
||||
|
||||
Note that there is a "compute reduce"_compute_reduce.html command
|
||||
which can sum per-atom quantities into a global scalar or vector which
|
||||
can thus be accessed by fix ave/correlate. Or it can be a compute
|
||||
defined not in your input script, but by "thermodynamic
|
||||
output"_thermo_style.html or other fixes such as "fix nvt"_fix_nh.html
|
||||
or "fix temp/rescale"_fix_temp_rescale.html. See the doc pages for
|
||||
these commands which give the IDs of these computes. Users can also
|
||||
write code for their own compute styles and "add them to
|
||||
LAMMPS"_Section_modify.html.
|
||||
|
||||
If a value begins with "f_", a fix ID must follow which has been
|
||||
previously defined in the input script. If no bracketed term is
|
||||
appended, the global scalar calculated by the fix is used. If a
|
||||
bracketed term is appended, the Ith element of the global vector
|
||||
calculated by the fix is used.
|
||||
|
||||
Note that some fixes only produce their values on certain timesteps,
|
||||
which must be compatible with {Nevery}, else an error will result.
|
||||
Users can also write code for their own fix styles and "add them to
|
||||
LAMMPS"_Section_modify.html.
|
||||
|
||||
If a value begins with "v_", a variable name must follow which has
|
||||
been previously defined in the input script. Only equal-style
|
||||
variables can be referenced. See the "variable"_variable.html command
|
||||
for details. Note that variables of style {equal} define a formula
|
||||
which can reference individual atom properties or thermodynamic
|
||||
keywords, or they can invoke other computes, fixes, or variables when
|
||||
they are evaluated, so this is a very general means of specifying
|
||||
quantities to time correlate.
|
||||
|
||||
:line
|
||||
|
||||
Additional optional keywords also affect the operation of this fix.
|
||||
|
||||
The {type} keyword determines which pairs of input values are
|
||||
correlated with each other. For N input values Vi, for i = 1 to N,
|
||||
let the number of pairs = Npair. Note that the second value in the
|
||||
pair Vi(t)*Vj(t+delta) is always the one sampled at the later time.
|
||||
|
||||
If {type} is set to {auto} then each input value is correlated with
|
||||
itself. I.e. Cii = Vi*Vi, for i = 1 to N, so Npair = N. :ulb,l
|
||||
|
||||
If {type} is set
|
||||
to {upper} then each input value is correlated with every succeeding
|
||||
value. I.e. Cij = Vi*Vj, for i < j, so Npair = N*(N-1)/2. :l
|
||||
|
||||
If {type} is set
|
||||
to {lower} then each input value is correlated with every preceeding
|
||||
value. I.e. Cij = Vi*Vj, for i > j, so Npair = N*(N-1)/2. :l
|
||||
|
||||
If {type} is set to {auto/upper} then each input value is correlated
|
||||
with itself and every succeeding value. I.e. Cij = Vi*Vj, for i >= j,
|
||||
so Npair = N*(N+1)/2. :l
|
||||
|
||||
If {type} is set to {auto/lower} then each input value is correlated
|
||||
with itself and every preceding value. I.e. Cij = Vi*Vj, for i <= j,
|
||||
so Npair = N*(N+1)/2. :l
|
||||
|
||||
If {type} is set to {full} then each input value is correlated with
|
||||
itself and every other value. I.e. Cij = Vi*Vj, for i,j = 1,N so
|
||||
Npair = N^2. :l,ule
|
||||
|
||||
The {ave} keyword determines what happens to the accumulation of
|
||||
correlation samples every {Nfreq} timesteps. If the {ave} setting is
|
||||
{one}, then the accumulation is restarted or zeroed every {Nfreq}
|
||||
timesteps. Thus the outputs on successive {Nfreq} timesteps are
|
||||
essentially independent of each other. The exception is that the
|
||||
Cij(0) = Vi(T)*Vj(T) value at a timestep T, where T is a multiple of
|
||||
{Nfreq}, contributes to the correlation output both at time T and at
|
||||
time T+Nfreq.
|
||||
|
||||
If the {ave} setting is {running}, then the accumulation is never
|
||||
zeroed. Thus the output of correlation data at any timestep is the
|
||||
average over samples accumulated every {Nevery} steps since the fix
|
||||
was defined. it can only be restarted by deleting the fix via the
|
||||
"unfix"_unfix.html command, or by re-defining the fix by re-specifying
|
||||
it.
|
||||
|
||||
The {start} keyword specifies what timestep the accumulation of
|
||||
correlation samples will begin on. The default is step 0. Setting it
|
||||
to a larger value can avoid adding non-equilibrated data to the
|
||||
correlation averages.
|
||||
|
||||
The {prefactor} keyword specifies a constant which will be used as a
|
||||
multiplier on the correlation data after it is averaged. It is
|
||||
effectively a scale factor on Vi*Vj, which can be used to account for
|
||||
the size of the time window or other unit conversions.
|
||||
|
||||
The {file} keyword allows a filename to be specified. Every {Nfreq}
|
||||
steps, an array of correlation data is written to the file. The
|
||||
number of rows is {Nrepeat}, as described above. The number of
|
||||
columns is the Npair+2, also as described above. Thus the file ends
|
||||
up to be a series of these array sections.
|
||||
|
||||
The {title1} and {title2} and {title3} keywords allow specification of
|
||||
the strings that will be printed as the first 3 lines of the output
|
||||
file, assuming the {file} keyword was used. LAMMPS uses default
|
||||
values for each of these, so they do not need to be specified.
|
||||
|
||||
By default, these header lines are as follows:
|
||||
|
||||
# Time-correlated data for fix ID
|
||||
# TimeStep Number-of-time-windows
|
||||
# Index TimeDelta Ncount valueI*valueJ valueI*valueJ ... :pre
|
||||
|
||||
In the first line, ID is replaced with the fix-ID. The second line
|
||||
describes the two values that are printed at the first of each section
|
||||
of output. In the third line the value pairs are replaced with the
|
||||
appropriate fields from the fix ave/correlate command.
|
||||
|
||||
:line
|
||||
|
||||
Let Sij = a set of time correlation data for input values I and J,
|
||||
namely the {Nrepeat} values:
|
||||
|
||||
Sij = Cij(0), Cij(Nevery), Cij(2*Nevery), ..., Cij(*Nrepeat-1)*Nevery) :pre
|
||||
|
||||
As explained below, these datums are output as one column of a global
|
||||
array, which is effectively the correlation matrix.
|
||||
|
||||
The {trap} function defined for "equal-style variables"_variable.html
|
||||
can be used to perform a time integration of this vector of datums,
|
||||
using a trapezoidal rule. This is useful for calculating various
|
||||
quantities which can be derived from time correlation data. If a
|
||||
normalization factor is needed for the time integration, it can be
|
||||
included in the variable formula or via the {prefactor} keyword.
|
||||
|
||||
:line
|
||||
|
||||
[Restart, fix_modify, output, run start/stop, minimize info:]
|
||||
|
||||
No information about this fix is written to "binary restart
|
||||
files"_restart.html. None of the "fix_modify"_fix_modify.html options
|
||||
are relevant to this fix.
|
||||
|
||||
This fix computes a global array of values which can be accessed by
|
||||
various "output commands"_Section_howto.html#4_15. The values can
|
||||
only be accessed on timesteps that are multiples of {Nfreq} since that
|
||||
is when averaging is performed. The global array has # of rows =
|
||||
{Nrepeat} and # of columns = Npair+2. The first column has the time
|
||||
delta (in timesteps) between the pairs of input values used to
|
||||
calculate the correlation, as described above. The 2nd column has the
|
||||
number of samples contributing to the correlation average, as
|
||||
described above. The remaining Npair columns are for I,J pairs of the
|
||||
N input values, as determined by the {type} keyword, as described
|
||||
above.
|
||||
|
||||
For {type} = {auto}, the Npair = N columns are ordered: C11, C22, ...,
|
||||
CNN. :ulb,l
|
||||
|
||||
For {type} = {upper}, the Npair = N*(N-1)/2 columns are ordered: C12,
|
||||
C13, ..., C1N, C23, ..., C2N, C34, ..., CN-1N. :l
|
||||
|
||||
For {type} = {lower}, the Npair = N*(N-1)/2 columns are ordered: C21,
|
||||
C31, C32, C41, C42, C43, ..., CN1, CN2, ..., CNN-1. :l
|
||||
|
||||
For {type} = {auto/upper}, the Npair = N*(N+1)/2 columns are ordered:
|
||||
C11, C12, C13, ..., C1N, C22, C23, ..., C2N, C33, C34, ..., CN-1N,
|
||||
CNN. :l
|
||||
|
||||
For {type} = {auto/lower}, the Npair = N*(N+1)/2 columns are ordered:
|
||||
C11, C21, C22, C31, C32, C33, C41, ..., C44, CN1, CN2, ..., CNN-1,
|
||||
CNN. :l
|
||||
|
||||
For {type} = {full}, the Npair = N^2 columns are ordered: C11, C12,
|
||||
..., C1N, C21, C22, ..., C2N, C31, ..., C3N, ..., CN1, ..., CNN-1,
|
||||
CNN. :l,ule
|
||||
|
||||
The array values calculated by this fix are treated as "intensive".
|
||||
If you need to divide them by the number of atoms, you must do this in
|
||||
a later processing step, e.g. when using them in a
|
||||
"variable"_variable.html.
|
||||
|
||||
No parameter of this fix can be used with the {start/stop} keywords of
|
||||
the "run"_run.html command. This fix is not invoked during "energy
|
||||
minimization"_minimize.html.
|
||||
|
||||
[Restrictions:] none
|
||||
|
||||
[Related commands:]
|
||||
|
||||
"compute"_compute.html, "fix ave/time"_fix_ave_time.html, "fix
|
||||
ave/atom"_fix_ave_atom.html, "fix ave/spatial"_fix_ave_spatial.html,
|
||||
"fix ave/histo"_fix_ave_histo.html, "variable"_variable.html
|
||||
|
||||
[Default:] none
|
||||
|
||||
The option defaults are ave = one, type = auto, start = 0, no file
|
||||
output, title 1,2,3 = strings as described above, and prefactor = 1.0.
|
|
@ -317,7 +317,7 @@ minimization</A>.
|
|||
</P>
|
||||
<P><A HREF = "compute.html">compute</A>, <A HREF = "fix_ave_atom.html">fix ave/atom</A>, <A HREF = "fix_ave_spatial.html">fix
|
||||
ave/spatial</A>, <A HREF = "fix_ave_time.html">fix ave/time</A>,
|
||||
<A HREF = "variable.html">variable</A>,
|
||||
<A HREF = "variable.html">variable</A>, <A HREF = "fix_ave_correlate.html">fix ave/correlate</A>,
|
||||
</P>
|
||||
<P><B>Default:</B> none
|
||||
</P>
|
||||
|
|
|
@ -305,7 +305,7 @@ minimization"_minimize.html.
|
|||
|
||||
"compute"_compute.html, "fix ave/atom"_fix_ave_atom.html, "fix
|
||||
ave/spatial"_fix_ave_spatial.html, "fix ave/time"_fix_ave_time.html,
|
||||
"variable"_variable.html,
|
||||
"variable"_variable.html, "fix ave/correlate"_fix_ave_correlate.html,
|
||||
|
||||
[Default:] none
|
||||
|
||||
|
|
|
@ -49,12 +49,12 @@
|
|||
|
||||
<PRE> <I>units</I> arg = <I>box</I> or <I>lattice</I> or <I>reduced</I>
|
||||
<I>norm</I> arg = <I>all</I> or <I>sample</I>
|
||||
<I>file</I> arg = filename
|
||||
filename = file to write results to
|
||||
<I>ave</I> args = <I>one</I> or <I>running</I> or <I>window M</I>
|
||||
one = output new average value every Nfreq steps
|
||||
running = output cumulative average of all previous Nfreq steps
|
||||
window M = output average of M most recent Nfreq steps
|
||||
<I>file</I> arg = filename
|
||||
filename = file to write results to
|
||||
<I>title1</I> arg = string
|
||||
string = text to print as 1st line of output file
|
||||
<I>title2</I> arg = string
|
||||
|
@ -322,7 +322,7 @@ simulation box size doesn't change or if the <I>units</I> keyword is set to
|
|||
</P>
|
||||
<P><A HREF = "compute.html">compute</A>, <A HREF = "fix_ave_atom.html">fix ave/atom</A>, <A HREF = "fix_ave_histo.html">fix
|
||||
ave/histo</A>, <A HREF = "fix_ave_time.html">fix ave/time</A>,
|
||||
<A HREF = "variable.html">variable</A>,
|
||||
<A HREF = "variable.html">variable</A>, <A HREF = "fix_ave_correlate.html">fix ave/correlate</A>,
|
||||
</P>
|
||||
<P><B>Default:</B>
|
||||
</P>
|
||||
|
|
|
@ -34,12 +34,12 @@ zero or more keyword/arg pairs may be appended :l
|
|||
keyword = {norm} or {units} or {file} or {ave} or {title1} or {title2} or {title3} :l
|
||||
{units} arg = {box} or {lattice} or {reduced}
|
||||
{norm} arg = {all} or {sample}
|
||||
{file} arg = filename
|
||||
filename = file to write results to
|
||||
{ave} args = {one} or {running} or {window M}
|
||||
one = output new average value every Nfreq steps
|
||||
running = output cumulative average of all previous Nfreq steps
|
||||
window M = output average of M most recent Nfreq steps
|
||||
{file} arg = filename
|
||||
filename = file to write results to
|
||||
{title1} arg = string
|
||||
string = text to print as 1st line of output file
|
||||
{title2} arg = string
|
||||
|
@ -306,7 +306,7 @@ simulation box size doesn't change or if the {units} keyword is set to
|
|||
|
||||
"compute"_compute.html, "fix ave/atom"_fix_ave_atom.html, "fix
|
||||
ave/histo"_fix_ave_histo.html, "fix ave/time"_fix_ave_time.html,
|
||||
"variable"_variable.html,
|
||||
"variable"_variable.html, "fix ave/correlate"_fix_ave_correlate.html,
|
||||
|
||||
[Default:]
|
||||
|
||||
|
|
|
@ -42,8 +42,6 @@
|
|||
<PRE> <I>mode</I> arg = <I>scalar</I> or <I>vector</I>
|
||||
scalar = all input values are global scalars
|
||||
vector = all input values are global vectors or global arrays
|
||||
<I>file</I> arg = filename
|
||||
filename = name of file to output time averages to
|
||||
<I>ave</I> args = <I>one</I> or <I>running</I> or <I>window M</I>
|
||||
one = output a new average value every Nfreq steps
|
||||
running = output cummulative average of all previous Nfreq steps
|
||||
|
@ -52,6 +50,8 @@
|
|||
Nstart = start averaging on this timestep
|
||||
<I>off</I> arg = M = do not average this value
|
||||
M = value # from 1 to Nvalues
|
||||
<I>file</I> arg = filename
|
||||
filename = name of file to output time averages to
|
||||
<I>title1</I> arg = string
|
||||
string = text to print as 1st line of output file
|
||||
<I>title2</I> arg = string
|
||||
|
@ -82,7 +82,7 @@ a file.
|
|||
specified values may represent calculations performed by computes and
|
||||
fixes which store their own "group" definitions.
|
||||
</P>
|
||||
<P>Each input value can be the result of a <A HREF = "compute.html">compute</A> or
|
||||
<P>Each listed value can be the result of a <A HREF = "compute.html">compute</A> or
|
||||
<A HREF = "fix.html">fix</A> or the evaluation of an equal-style
|
||||
<A HREF = "variable.html">variable</A>. In each case, the compute, fix, or variable
|
||||
must produce a global quantity, not a per-atom or local quantity. If
|
||||
|
@ -298,13 +298,13 @@ of rows = length of the input vectors and # of columns = number of
|
|||
inputs.
|
||||
</P>
|
||||
<P>If the fix prouduces a scalar or vector, then the scalar and each
|
||||
element of the vector may be either "intensive" or "extensive". If
|
||||
the fix produces an array, then all elements in the array will be
|
||||
either "intensive" or "extensive". If a compute or fix provides the
|
||||
value being time averaged, then the compute or fix determines whether
|
||||
the value is intensive or extensive; see the doc page for that compute
|
||||
or fix for further info. Values produced by a variable are whatever
|
||||
the variable calculates.
|
||||
element of the vector can be either "intensive" or "extensive". If
|
||||
the fix produces an array, then all elements in the array must be the
|
||||
same, either "intensive" or "extensive". If a compute or fix provides
|
||||
the value being time averaged, then the compute or fix determines
|
||||
whether the value is intensive or extensive; see the doc page for that
|
||||
compute or fix for further info. Values produced by a variable are
|
||||
treated as intensive.
|
||||
</P>
|
||||
<P>No parameter of this fix can be used with the <I>start/stop</I> keywords of
|
||||
the <A HREF = "run.html">run</A> command. This fix is not invoked during <A HREF = "minimize.html">energy
|
||||
|
@ -316,7 +316,7 @@ minimization</A>.
|
|||
</P>
|
||||
<P><A HREF = "compute.html">compute</A>, <A HREF = "fix_ave_atom.html">fix ave/atom</A>, <A HREF = "fix_ave_spatial.html">fix
|
||||
ave/spatial</A>, <A HREF = "fix_ave_histo.html">fix ave/histo</A>,
|
||||
<A HREF = "variable.html">variable</A>
|
||||
<A HREF = "variable.html">variable</A>, <A HREF = "fix_ave_correlate.html">fix ave/correlate</A>,
|
||||
</P>
|
||||
<P><B>Default:</B> none
|
||||
</P>
|
||||
|
|
|
@ -30,8 +30,6 @@ keyword = {mode} or {file} or {ave} or {start} or {off} or {title1} or {title2}
|
|||
{mode} arg = {scalar} or {vector}
|
||||
scalar = all input values are global scalars
|
||||
vector = all input values are global vectors or global arrays
|
||||
{file} arg = filename
|
||||
filename = name of file to output time averages to
|
||||
{ave} args = {one} or {running} or {window M}
|
||||
one = output a new average value every Nfreq steps
|
||||
running = output cummulative average of all previous Nfreq steps
|
||||
|
@ -40,6 +38,8 @@ keyword = {mode} or {file} or {ave} or {start} or {off} or {title1} or {title2}
|
|||
Nstart = start averaging on this timestep
|
||||
{off} arg = M = do not average this value
|
||||
M = value # from 1 to Nvalues
|
||||
{file} arg = filename
|
||||
filename = name of file to output time averages to
|
||||
{title1} arg = string
|
||||
string = text to print as 1st line of output file
|
||||
{title2} arg = string
|
||||
|
@ -69,7 +69,7 @@ The group specified with this command is ignored. However, note that
|
|||
specified values may represent calculations performed by computes and
|
||||
fixes which store their own "group" definitions.
|
||||
|
||||
Each input value can be the result of a "compute"_compute.html or
|
||||
Each listed value can be the result of a "compute"_compute.html or
|
||||
"fix"_fix.html or the evaluation of an equal-style
|
||||
"variable"_variable.html. In each case, the compute, fix, or variable
|
||||
must produce a global quantity, not a per-atom or local quantity. If
|
||||
|
@ -285,13 +285,13 @@ of rows = length of the input vectors and # of columns = number of
|
|||
inputs.
|
||||
|
||||
If the fix prouduces a scalar or vector, then the scalar and each
|
||||
element of the vector may be either "intensive" or "extensive". If
|
||||
the fix produces an array, then all elements in the array will be
|
||||
either "intensive" or "extensive". If a compute or fix provides the
|
||||
value being time averaged, then the compute or fix determines whether
|
||||
the value is intensive or extensive; see the doc page for that compute
|
||||
or fix for further info. Values produced by a variable are whatever
|
||||
the variable calculates.
|
||||
element of the vector can be either "intensive" or "extensive". If
|
||||
the fix produces an array, then all elements in the array must be the
|
||||
same, either "intensive" or "extensive". If a compute or fix provides
|
||||
the value being time averaged, then the compute or fix determines
|
||||
whether the value is intensive or extensive; see the doc page for that
|
||||
compute or fix for further info. Values produced by a variable are
|
||||
treated as intensive.
|
||||
|
||||
No parameter of this fix can be used with the {start/stop} keywords of
|
||||
the "run"_run.html command. This fix is not invoked during "energy
|
||||
|
@ -303,7 +303,7 @@ minimization"_minimize.html.
|
|||
|
||||
"compute"_compute.html, "fix ave/atom"_fix_ave_atom.html, "fix
|
||||
ave/spatial"_fix_ave_spatial.html, "fix ave/histo"_fix_ave_histo.html,
|
||||
"variable"_variable.html
|
||||
"variable"_variable.html, "fix ave/correlate"_fix_ave_correlate.html,
|
||||
|
||||
[Default:] none
|
||||
|
||||
|
|
|
@ -34,8 +34,7 @@
|
|||
x==y, x!=y, x<y, x<=y, x>y, x>=y, x&&y, x||y
|
||||
math functions = sqrt(x), exp(x), ln(x), log(x),
|
||||
sin(x), cos(x), tan(x), asin(x), acos(x), atan(x),
|
||||
ceil(x), floor(x), round(x), ramp(x,y), stagger(x,y),
|
||||
logfreq(x,y,z)
|
||||
ceil(x), floor(x), round(x)
|
||||
group functions = count(group), mass(group), charge(group),
|
||||
xcm(group,dim), vcm(group,dim), fcm(group,dim),
|
||||
bound(group,xmin), gyration(group), ke(group),
|
||||
|
@ -44,6 +43,7 @@
|
|||
xcm(group,dim,region), vcm(group,dim,region), fcm(group,dim,region),
|
||||
bound(group,xmin,region), gyration(group,region), ke(group,reigon),
|
||||
angmom(group,dim,region), inertia(group,dimdim,region),omega(group,dim,region)
|
||||
special functions = ramp(x,y), stagger(x,y), logfreq(x,y,z), sum(x), min(x), max(x), ave(x), trap(x)
|
||||
atom value = mass[i], type[i], x[i], y[i], z[i], vx[i], vy[i], vz[i], fx[i], fy[i], fz[i]
|
||||
atom vector = mass, type, x, y, z, vx, vy, vz, fx, fy, fz
|
||||
compute references = c_ID, c_ID[i], c_ID[i][j]
|
||||
|
@ -258,9 +258,10 @@ references to other variables.
|
|||
<TR><TD >Number</TD><TD > 0.2, 100, 1.0e20, -15.4, etc</TD></TR>
|
||||
<TR><TD >Thermo keywords</TD><TD > vol, pe, ebond, etc</TD></TR>
|
||||
<TR><TD >Math operators</TD><TD > (), -x, x+y, x-y, x*y, x/y, x^y, x==y, x!=y, x<y, x<=y, x>y, x>=y, x&&y, x||y</TD></TR>
|
||||
<TR><TD >Math functions</TD><TD > sqrt(x), exp(x), ln(x), log(x), sin(x), cos(x), tan(x), asin(x), acos(x), atan(x), ceil(x), floor(x), round(x), ramp(x,y), stagger(x,y), logfreq(x,y,z)</TD></TR>
|
||||
<TR><TD >Math functions</TD><TD > sqrt(x), exp(x), ln(x), log(x), sin(x), cos(x), tan(x), asin(x), acos(x), atan(x), ceil(x), floor(x), round(x)</TD></TR>
|
||||
<TR><TD >Group functions</TD><TD > count(ID), mass(ID), charge(ID), xcm(ID,dim), vcm(ID,dim), fcm(ID,dim), bound(ID,dir), gyration(ID), ke(ID), angmom(ID,dim), inertia(ID,dimdim), omega(ID,dim)</TD></TR>
|
||||
<TR><TD >Region functions</TD><TD > count(ID,IDR), mass(ID,IDR), charge(ID,IDR), xcm(ID,dim,IDR), vcm(ID,dim,IDR), fcm(ID,dim,IDR), bound(ID,dir,IDR), gyration(ID,IDR), ke(ID,IDR), angmom(ID,dim,IDR), inertia(ID,dimdim,IDR), omega(ID,dim,IDR)</TD></TR>
|
||||
<TR><TD >Special functions</TD><TD > ramp(x,y), stagger(x,y), logfreq(x,y,z), sum(x), min(x), max(x), ave(x), trap(x)</TD></TR>
|
||||
<TR><TD >Atom values</TD><TD > mass[i], type[i], x[i], y[i], z[i], vx[i], vy[i], vz[i], fx[i], fy[i], fz[i]</TD></TR>
|
||||
<TR><TD >Atom vectors</TD><TD > mass, type, x, y, z, vx, vy, vz, fx, fy, fz</TD></TR>
|
||||
<TR><TD >Compute references</TD><TD > c_ID, c_ID[i], c_ID[i][j]</TD></TR>
|
||||
|
@ -268,13 +269,15 @@ references to other variables.
|
|||
<TR><TD >Other variables</TD><TD > v_name, v_name[i]
|
||||
</TD></TR></TABLE></DIV>
|
||||
|
||||
<HR>
|
||||
|
||||
<P>Most of the formula elements produce a scalar value. A few produce a
|
||||
per-atom vector of values. These are the atom vectors, compute
|
||||
references that represent a per-atom vector, fix references that
|
||||
represent a per-atom vector, and variables that are atom-style
|
||||
variables. Math functions that operate on scalar values produce a
|
||||
scalar value; math function that operate on per-atom vectors produce a
|
||||
per-atom vector.
|
||||
scalar value; math function that operate on per-atom vectors do so
|
||||
element-by-element and produce a per-atom vector.
|
||||
</P>
|
||||
<P>A formula for equal-style variables cannot use any formula element
|
||||
that produces a per-atom vector. A formula for an atom-style variable
|
||||
|
@ -295,12 +298,14 @@ evaluated directly in an input script (not during a run), then the
|
|||
values accessed by the thermo keyword must be current. See the
|
||||
discussion below about "Variable Accuracy".
|
||||
</P>
|
||||
<HR>
|
||||
|
||||
<P>Math operators are written in the usual way, where the "x" and "y" in
|
||||
the examples can themselves be arbitrarily complex formulas, as in the
|
||||
examples above. In this syntax, "x" and "y" can be scalar values or
|
||||
per-atom vectors. For example, "ke/natoms" is the division of two
|
||||
scalars, where "y+z" is the sum of two per-atom vectors of y- and
|
||||
z-coordinates.
|
||||
scalars, where "y+z" is the element-by-element sum of two per-atom
|
||||
vectors of y- and z-coordinates.
|
||||
</P>
|
||||
<P>Operators are evaluated left to right and have the usual C-style
|
||||
precedence: unary minus before exponentiation ("^"); exponentiation
|
||||
|
@ -330,10 +335,11 @@ to the <A HREF = "compute_reduce.html">compute reduce</A> command.
|
|||
<P>Math functions are specified as keywords followed by one or more
|
||||
parenthesized arguments "x", "y", etc, each of which can themselves be
|
||||
arbitrarily complex formulas. In this syntax, the arguments can
|
||||
represent scalar values or per-atom vectors. For example,
|
||||
"sqrt(natoms)" is the sqrt() of a scalar, where "sqrt(y*z)" is a
|
||||
per-atom vector with each element being the sqrt() of the product of
|
||||
two atom coordinates.
|
||||
represent scalar values or per-atom vectors. In the latter case, the
|
||||
math operation is performed on each element of the vector. For
|
||||
example, "sqrt(natoms)" is the sqrt() of a scalar, where "sqrt(y*z)"
|
||||
yields a per-atom vector with each element being the sqrt() of the
|
||||
product of one atom's y and z coordinates.
|
||||
</P>
|
||||
<P>Most of the math functions perform obvious operations. The ln() is
|
||||
the natural log; log() is the base 10 log. The ceil(), floor(), and
|
||||
|
@ -342,35 +348,8 @@ smallest integer not less than its argument. Floor() if the largest
|
|||
integer not greater than its argument. Round() is the nearest integer
|
||||
to its argument.
|
||||
</P>
|
||||
<P>Ramp(x,y) uses the current timestep to generate a scalar value:
|
||||
</P>
|
||||
<PRE>value = x + (y-x) * (timestep-startstep) / (stopstep-startstep)
|
||||
</PRE>
|
||||
<P>which is a value that ramps linear between x and y over the course of
|
||||
a run. The run begins on startstep and ends on stopstep. Startstep
|
||||
and stopstep can span multiple runs, using the <I>start</I> and <I>stop</I>
|
||||
keywords of the <A HREF = "run.html">run</A> command. See the <A HREF = "run.html">run</A>
|
||||
command for details of how to do this.
|
||||
</P>
|
||||
<P>Stagger(x,y) requires x,y > 0 and x > y and uses the current timestep
|
||||
to generate a new timestep, in a staggered fashion, as the sequence
|
||||
x,x+y,2x,2x+y,3x,3x+y,etc. For any current timestep, the next
|
||||
timestep in the sequence is returned. Thus if stagger(1000,100) is
|
||||
used in a variable by the <A HREF = "dump_modify.html">dump_modify every</A>
|
||||
command, it will generate the sequence of output timesteps:
|
||||
</P>
|
||||
<PRE>100,1000,1100,2000,2100,3000,etc
|
||||
</PRE>
|
||||
<P>Logfreq(x,y,z) requires x,y,z > 0 and y < z and uses the current
|
||||
timestep to generate a new timestep, in a logarithmic fashion, as the
|
||||
sequence x,2x,3x,...y*x,z*x,2*z*x,3*z*x,...y*z*x,z*z*x,2*z*x*x,etc.
|
||||
For any current timestep, the next timestep in the sequence is
|
||||
returned. Thus if logfreq(100,4,10) is used in a variable by the
|
||||
<A HREF = "dump_modify.html">dump_modify every</A> command, it will generate the
|
||||
sequence of output timesteps:
|
||||
</P>
|
||||
<PRE>100,200,300,400,1000,2000,3000,4000,10000,20000,etc
|
||||
</PRE>
|
||||
<HR>
|
||||
|
||||
<P>Group functions are specified as keywords followed by one or two
|
||||
parenthesized arguments. The first argument is the group-ID. The
|
||||
<I>dim</I> argument, if it exists, is <I>x</I> or <I>y</I> or <I>z</I>. The <I>dir</I>
|
||||
|
@ -398,6 +377,77 @@ function is computed for all atoms that are in both the group and the
|
|||
region. If the group is "all", then the only criteria for atom
|
||||
inclusion is that it be in the region.
|
||||
</P>
|
||||
<HR>
|
||||
|
||||
<P>Special functions take specific kinds of arguments, meaning their
|
||||
arguments cannot be formulas themselves. For example ramp(10.0,100.0)
|
||||
is valid, but ramp(2*5,sqrt(10000)) is not.
|
||||
</P>
|
||||
<P>Ramp(x,y) takes two integer or floating point values and uses the
|
||||
current timestep to generate a scalar value:
|
||||
</P>
|
||||
<PRE>value = x + (y-x) * (timestep-startstep) / (stopstep-startstep)
|
||||
</PRE>
|
||||
<P>which is a value that ramps linearly between x and y over the course of
|
||||
a run. The run begins on startstep and ends on stopstep. Startstep
|
||||
and stopstep can span multiple runs, using the <I>start</I> and <I>stop</I>
|
||||
keywords of the <A HREF = "run.html">run</A> command. See the <A HREF = "run.html">run</A>
|
||||
command for details of how to do this.
|
||||
</P>
|
||||
<P>Stagger(x,y) takes two integer values and uses the current timestep to
|
||||
generate a new timestep. X,y > 0 and x > y is required. The
|
||||
generated timesteps increase in a staggered fashion, as the sequence
|
||||
x,x+y,2x,2x+y,3x,3x+y,etc. For any current timestep, the next
|
||||
timestep in the sequence is returned. Thus if stagger(1000,100) is
|
||||
used in a variable by the <A HREF = "dump_modify.html">dump_modify every</A>
|
||||
command, it will generate the sequence of output timesteps:
|
||||
</P>
|
||||
<PRE>100,1000,1100,2000,2100,3000,etc
|
||||
</PRE>
|
||||
<P>Logfreq(x,y,z) takes 3 integer values and uses the current timestep to
|
||||
generate a new timestep. X,y,z > 0 and y < z is required. The
|
||||
generated timesteps increase in a logarithmic fashion, as the sequence
|
||||
x,2x,3x,...y*x,z*x,2*z*x,3*z*x,...y*z*x,z*z*x,2*z*x*x,etc. For any
|
||||
current timestep, the next timestep in the sequence is returned. Thus
|
||||
if logfreq(100,4,10) is used in a variable by the <A HREF = "dump_modify.html">dump_modify
|
||||
every</A> command, it will generate the sequence of
|
||||
output timesteps:
|
||||
</P>
|
||||
<PRE>100,200,300,400,1000,2000,3000,4000,10000,20000,etc
|
||||
</PRE>
|
||||
<P>The sum(x), min(x), max(x), ave(x), and trap(x) functions each take 1
|
||||
argument which is of the form "c_ID" or "c_ID[N]" or "f_ID" or
|
||||
"f_ID[N]". The first two are computes and the second two are fixes;
|
||||
the ID in the reference should be replaced by the ID of a compute or
|
||||
fix defined elsewhere in the input script. The compute or fix must
|
||||
produce either a global vector or array. If it produces a global
|
||||
vector, then the notation without "[N]" should be used. If it
|
||||
produces a global array, then the notation with "[N]" should be
|
||||
used, when N is an integer, to specify which column of the global
|
||||
array is being referenced.
|
||||
</P>
|
||||
<P>All of these functions operate on the global vector of inputs and
|
||||
reduce it to a single scalar value. This is analagous to the
|
||||
operation of the <A HREF = "compute_reduce.html">compute reduce</A> command, which
|
||||
invokes the same functions on per-atom and local vectors.
|
||||
</P>
|
||||
<P>The sum() function calculates the sum of all the vector elements. The
|
||||
min() and max() functions find the minimum and maximum element
|
||||
respectively. The ave() function is the same as sum() except that it
|
||||
divides the result by the length of the vector. The trap() function
|
||||
is the same as sum() except the first and last elements are multiplied
|
||||
by a weighting factor of 1/2 when performing the sum. This
|
||||
effectively implements an integratiion via the trapezoidal rule on the
|
||||
global vector of data. I.e. consider a set of points, equally spaced
|
||||
by 1 in their x coordinate: (1,V1), (2,V2), ..., (N,VN), where the Vi
|
||||
are the values in the global vector of length N. The integral from 1
|
||||
to N of these points is trap(). When appropriately normalized by the
|
||||
timestep size, this function is useful for calculating integrals of
|
||||
time-series data, like that generated by the <A HREF = "fix_ave_correlate.html">fix
|
||||
ave/correlate</A> command.
|
||||
</P>
|
||||
<HR>
|
||||
|
||||
<P>Atom values take a single integer argument I from 1 to N, where I is
|
||||
the an atom-ID, e.g. x[243], which means use the x coordinate of the
|
||||
atom with ID = 243.
|
||||
|
@ -409,6 +459,8 @@ as inputs to a variable by using the <A HREF = "compute_property_atom.html">comp
|
|||
property/atom</A> command and then specifying
|
||||
a quantity from that compute.
|
||||
</P>
|
||||
<HR>
|
||||
|
||||
<P>Compute references access quantities calculated by a
|
||||
<A HREF = "compute.html">compute</A>. The ID in the reference should be replaced by
|
||||
the ID of a compute defined elsewhere in the input script. As
|
||||
|
@ -438,6 +490,8 @@ directly in an input script (not during a run), then the values
|
|||
accessed by the compute must be current. See the discussion below
|
||||
about "Variable Accuracy".
|
||||
</P>
|
||||
<HR>
|
||||
|
||||
<P>Fix references access quantities calculated by a <A HREF = "compute.html">fix</A>.
|
||||
The ID in the reference should be replaced by the ID of a fix defined
|
||||
elsewhere in the input script. As discussed in the doc page for the
|
||||
|
@ -472,6 +526,8 @@ error is generated. For example, the <A HREF = "fix_ave_time.html">fix ave/time
|
|||
command may only generate averaged quantities every 100 steps. See
|
||||
the doc pages for individual fix commands for details.
|
||||
</P>
|
||||
<HR>
|
||||
|
||||
<P>Variable references access quantities calulated by other variables,
|
||||
which will cause those variables to be evaluated. The name in the
|
||||
reference should be replaced by the name of a variable defined
|
||||
|
|
135
doc/variable.txt
135
doc/variable.txt
|
@ -29,8 +29,7 @@ style = {delete} or {index} or {loop} or {world} or {universe} or {uloop} or {st
|
|||
x==y, x!=y, x<y, x<=y, x>y, x>=y, x&&y, x||y
|
||||
math functions = sqrt(x), exp(x), ln(x), log(x),
|
||||
sin(x), cos(x), tan(x), asin(x), acos(x), atan(x),
|
||||
ceil(x), floor(x), round(x), ramp(x,y), stagger(x,y),
|
||||
logfreq(x,y,z)
|
||||
ceil(x), floor(x), round(x)
|
||||
group functions = count(group), mass(group), charge(group),
|
||||
xcm(group,dim), vcm(group,dim), fcm(group,dim),
|
||||
bound(group,xmin), gyration(group), ke(group),
|
||||
|
@ -39,6 +38,7 @@ style = {delete} or {index} or {loop} or {world} or {universe} or {uloop} or {st
|
|||
xcm(group,dim,region), vcm(group,dim,region), fcm(group,dim,region),
|
||||
bound(group,xmin,region), gyration(group,region), ke(group,reigon),
|
||||
angmom(group,dim,region), inertia(group,dimdim,region),omega(group,dim,region)
|
||||
special functions = ramp(x,y), stagger(x,y), logfreq(x,y,z), sum(x), min(x), max(x), ave(x), trap(x)
|
||||
atom value = mass\[i\], type\[i\], x\[i\], y\[i\], z\[i\], vx\[i\], vy\[i\], vz\[i\], fx\[i\], fy\[i\], fz\[i\]
|
||||
atom vector = mass, type, x, y, z, vx, vy, vz, fx, fy, fz
|
||||
compute references = c_ID, c_ID\[i\], c_ID\[i\]\[j\]
|
||||
|
@ -251,7 +251,7 @@ references to other variables.
|
|||
Number: 0.2, 100, 1.0e20, -15.4, etc
|
||||
Thermo keywords: vol, pe, ebond, etc
|
||||
Math operators: (), -x, x+y, x-y, x*y, x/y, x^y, x==y, x!=y, x<y, x<=y, x>y, x>=y, x&&y, x||y
|
||||
Math functions: sqrt(x), exp(x), ln(x), log(x), sin(x), cos(x), tan(x), asin(x), acos(x), atan(x), ceil(x), floor(x), round(x), ramp(x,y), stagger(x,y), logfreq(x,y,z)
|
||||
Math functions: sqrt(x), exp(x), ln(x), log(x), sin(x), cos(x), tan(x), asin(x), acos(x), atan(x), ceil(x), floor(x), round(x)
|
||||
Group functions: count(ID), mass(ID), charge(ID), xcm(ID,dim), \
|
||||
vcm(ID,dim), fcm(ID,dim), bound(ID,dir), \
|
||||
gyration(ID), ke(ID), angmom(ID,dim), \
|
||||
|
@ -260,6 +260,8 @@ Region functions: count(ID,IDR), mass(ID,IDR), charge(ID,IDR), \
|
|||
xcm(ID,dim,IDR), vcm(ID,dim,IDR), fcm(ID,dim,IDR), \
|
||||
bound(ID,dir,IDR), gyration(ID,IDR), ke(ID,IDR), \
|
||||
angmom(ID,dim,IDR), inertia(ID,dimdim,IDR), omega(ID,dim,IDR)
|
||||
Special functions: ramp(x,y), stagger(x,y), logfreq(x,y,z), \
|
||||
sum(x), min(x), max(x), ave(x), trap(x)
|
||||
Atom values: mass\[i\], type\[i\], x\[i\], y\[i\], z\[i\], \
|
||||
vx\[i\], vy\[i\], vz\[i\], fx\[i\], fy\[i\], fz\[i\]
|
||||
Atom vectors: mass, type, x, y, z, vx, vy, vz, fx, fy, fz
|
||||
|
@ -267,13 +269,15 @@ Compute references: c_ID, c_ID\[i\], c_ID\[i\]\[j\]
|
|||
Fix references: f_ID, f_ID\[i\], f_ID\[i\]\[j\]
|
||||
Other variables: v_name, v_name\[i\] :tb(s=:)
|
||||
|
||||
:line
|
||||
|
||||
Most of the formula elements produce a scalar value. A few produce a
|
||||
per-atom vector of values. These are the atom vectors, compute
|
||||
references that represent a per-atom vector, fix references that
|
||||
represent a per-atom vector, and variables that are atom-style
|
||||
variables. Math functions that operate on scalar values produce a
|
||||
scalar value; math function that operate on per-atom vectors produce a
|
||||
per-atom vector.
|
||||
scalar value; math function that operate on per-atom vectors do so
|
||||
element-by-element and produce a per-atom vector.
|
||||
|
||||
A formula for equal-style variables cannot use any formula element
|
||||
that produces a per-atom vector. A formula for an atom-style variable
|
||||
|
@ -294,12 +298,14 @@ evaluated directly in an input script (not during a run), then the
|
|||
values accessed by the thermo keyword must be current. See the
|
||||
discussion below about "Variable Accuracy".
|
||||
|
||||
:line
|
||||
|
||||
Math operators are written in the usual way, where the "x" and "y" in
|
||||
the examples can themselves be arbitrarily complex formulas, as in the
|
||||
examples above. In this syntax, "x" and "y" can be scalar values or
|
||||
per-atom vectors. For example, "ke/natoms" is the division of two
|
||||
scalars, where "y+z" is the sum of two per-atom vectors of y- and
|
||||
z-coordinates.
|
||||
scalars, where "y+z" is the element-by-element sum of two per-atom
|
||||
vectors of y- and z-coordinates.
|
||||
|
||||
Operators are evaluated left to right and have the usual C-style
|
||||
precedence: unary minus before exponentiation ("^"); exponentiation
|
||||
|
@ -329,10 +335,11 @@ to the "compute reduce"_compute_reduce.html command.
|
|||
Math functions are specified as keywords followed by one or more
|
||||
parenthesized arguments "x", "y", etc, each of which can themselves be
|
||||
arbitrarily complex formulas. In this syntax, the arguments can
|
||||
represent scalar values or per-atom vectors. For example,
|
||||
"sqrt(natoms)" is the sqrt() of a scalar, where "sqrt(y*z)" is a
|
||||
per-atom vector with each element being the sqrt() of the product of
|
||||
two atom coordinates.
|
||||
represent scalar values or per-atom vectors. In the latter case, the
|
||||
math operation is performed on each element of the vector. For
|
||||
example, "sqrt(natoms)" is the sqrt() of a scalar, where "sqrt(y*z)"
|
||||
yields a per-atom vector with each element being the sqrt() of the
|
||||
product of one atom's y and z coordinates.
|
||||
|
||||
Most of the math functions perform obvious operations. The ln() is
|
||||
the natural log; log() is the base 10 log. The ceil(), floor(), and
|
||||
|
@ -341,34 +348,7 @@ smallest integer not less than its argument. Floor() if the largest
|
|||
integer not greater than its argument. Round() is the nearest integer
|
||||
to its argument.
|
||||
|
||||
Ramp(x,y) uses the current timestep to generate a scalar value:
|
||||
|
||||
value = x + (y-x) * (timestep-startstep) / (stopstep-startstep) :pre
|
||||
|
||||
which is a value that ramps linear between x and y over the course of
|
||||
a run. The run begins on startstep and ends on stopstep. Startstep
|
||||
and stopstep can span multiple runs, using the {start} and {stop}
|
||||
keywords of the "run"_run.html command. See the "run"_run.html
|
||||
command for details of how to do this.
|
||||
|
||||
Stagger(x,y) requires x,y > 0 and x > y and uses the current timestep
|
||||
to generate a new timestep, in a staggered fashion, as the sequence
|
||||
x,x+y,2x,2x+y,3x,3x+y,etc. For any current timestep, the next
|
||||
timestep in the sequence is returned. Thus if stagger(1000,100) is
|
||||
used in a variable by the "dump_modify every"_dump_modify.html
|
||||
command, it will generate the sequence of output timesteps:
|
||||
|
||||
100,1000,1100,2000,2100,3000,etc :pre
|
||||
|
||||
Logfreq(x,y,z) requires x,y,z > 0 and y < z and uses the current
|
||||
timestep to generate a new timestep, in a logarithmic fashion, as the
|
||||
sequence x,2x,3x,...y*x,z*x,2*z*x,3*z*x,...y*z*x,z*z*x,2*z*x*x,etc.
|
||||
For any current timestep, the next timestep in the sequence is
|
||||
returned. Thus if logfreq(100,4,10) is used in a variable by the
|
||||
"dump_modify every"_dump_modify.html command, it will generate the
|
||||
sequence of output timesteps:
|
||||
|
||||
100,200,300,400,1000,2000,3000,4000,10000,20000,etc :pre
|
||||
:line
|
||||
|
||||
Group functions are specified as keywords followed by one or two
|
||||
parenthesized arguments. The first argument is the group-ID. The
|
||||
|
@ -397,6 +377,77 @@ function is computed for all atoms that are in both the group and the
|
|||
region. If the group is "all", then the only criteria for atom
|
||||
inclusion is that it be in the region.
|
||||
|
||||
:line
|
||||
|
||||
Special functions take specific kinds of arguments, meaning their
|
||||
arguments cannot be formulas themselves. For example ramp(10.0,100.0)
|
||||
is valid, but ramp(2*5,sqrt(10000)) is not.
|
||||
|
||||
Ramp(x,y) takes two integer or floating point values and uses the
|
||||
current timestep to generate a scalar value:
|
||||
|
||||
value = x + (y-x) * (timestep-startstep) / (stopstep-startstep) :pre
|
||||
|
||||
which is a value that ramps linearly between x and y over the course of
|
||||
a run. The run begins on startstep and ends on stopstep. Startstep
|
||||
and stopstep can span multiple runs, using the {start} and {stop}
|
||||
keywords of the "run"_run.html command. See the "run"_run.html
|
||||
command for details of how to do this.
|
||||
|
||||
Stagger(x,y) takes two integer values and uses the current timestep to
|
||||
generate a new timestep. X,y > 0 and x > y is required. The
|
||||
generated timesteps increase in a staggered fashion, as the sequence
|
||||
x,x+y,2x,2x+y,3x,3x+y,etc. For any current timestep, the next
|
||||
timestep in the sequence is returned. Thus if stagger(1000,100) is
|
||||
used in a variable by the "dump_modify every"_dump_modify.html
|
||||
command, it will generate the sequence of output timesteps:
|
||||
|
||||
100,1000,1100,2000,2100,3000,etc :pre
|
||||
|
||||
Logfreq(x,y,z) takes 3 integer values and uses the current timestep to
|
||||
generate a new timestep. X,y,z > 0 and y < z is required. The
|
||||
generated timesteps increase in a logarithmic fashion, as the sequence
|
||||
x,2x,3x,...y*x,z*x,2*z*x,3*z*x,...y*z*x,z*z*x,2*z*x*x,etc. For any
|
||||
current timestep, the next timestep in the sequence is returned. Thus
|
||||
if logfreq(100,4,10) is used in a variable by the "dump_modify
|
||||
every"_dump_modify.html command, it will generate the sequence of
|
||||
output timesteps:
|
||||
|
||||
100,200,300,400,1000,2000,3000,4000,10000,20000,etc :pre
|
||||
|
||||
The sum(x), min(x), max(x), ave(x), and trap(x) functions each take 1
|
||||
argument which is of the form "c_ID" or "c_ID\[N\]" or "f_ID" or
|
||||
"f_ID\[N\]". The first two are computes and the second two are fixes;
|
||||
the ID in the reference should be replaced by the ID of a compute or
|
||||
fix defined elsewhere in the input script. The compute or fix must
|
||||
produce either a global vector or array. If it produces a global
|
||||
vector, then the notation without "\[N\]" should be used. If it
|
||||
produces a global array, then the notation with "\[N\]" should be
|
||||
used, when N is an integer, to specify which column of the global
|
||||
array is being referenced.
|
||||
|
||||
All of these functions operate on the global vector of inputs and
|
||||
reduce it to a single scalar value. This is analagous to the
|
||||
operation of the "compute reduce"_compute_reduce.html command, which
|
||||
invokes the same functions on per-atom and local vectors.
|
||||
|
||||
The sum() function calculates the sum of all the vector elements. The
|
||||
min() and max() functions find the minimum and maximum element
|
||||
respectively. The ave() function is the same as sum() except that it
|
||||
divides the result by the length of the vector. The trap() function
|
||||
is the same as sum() except the first and last elements are multiplied
|
||||
by a weighting factor of 1/2 when performing the sum. This
|
||||
effectively implements an integratiion via the trapezoidal rule on the
|
||||
global vector of data. I.e. consider a set of points, equally spaced
|
||||
by 1 in their x coordinate: (1,V1), (2,V2), ..., (N,VN), where the Vi
|
||||
are the values in the global vector of length N. The integral from 1
|
||||
to N of these points is trap(). When appropriately normalized by the
|
||||
timestep size, this function is useful for calculating integrals of
|
||||
time-series data, like that generated by the "fix
|
||||
ave/correlate"_fix_ave_correlate.html command.
|
||||
|
||||
:line
|
||||
|
||||
Atom values take a single integer argument I from 1 to N, where I is
|
||||
the an atom-ID, e.g. x\[243\], which means use the x coordinate of the
|
||||
atom with ID = 243.
|
||||
|
@ -408,6 +459,8 @@ as inputs to a variable by using the "compute
|
|||
property/atom"_compute_property_atom.html command and then specifying
|
||||
a quantity from that compute.
|
||||
|
||||
:line
|
||||
|
||||
Compute references access quantities calculated by a
|
||||
"compute"_compute.html. The ID in the reference should be replaced by
|
||||
the ID of a compute defined elsewhere in the input script. As
|
||||
|
@ -435,6 +488,8 @@ directly in an input script (not during a run), then the values
|
|||
accessed by the compute must be current. See the discussion below
|
||||
about "Variable Accuracy".
|
||||
|
||||
:line
|
||||
|
||||
Fix references access quantities calculated by a "fix"_compute.html.
|
||||
The ID in the reference should be replaced by the ID of a fix defined
|
||||
elsewhere in the input script. As discussed in the doc page for the
|
||||
|
@ -467,6 +522,8 @@ error is generated. For example, the "fix ave/time"_fix_ave_time.html
|
|||
command may only generate averaged quantities every 100 steps. See
|
||||
the doc pages for individual fix commands for details.
|
||||
|
||||
:line
|
||||
|
||||
Variable references access quantities calulated by other variables,
|
||||
which will cause those variables to be evaluated. The name in the
|
||||
reference should be replaced by the name of a variable defined
|
||||
|
|
Loading…
Reference in New Issue