2006-09-22 00:22:34 +08:00
|
|
|
<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>mass command
|
|
|
|
</H3>
|
|
|
|
<P><B>Syntax:</B>
|
|
|
|
</P>
|
|
|
|
<PRE>mass I value
|
|
|
|
</PRE>
|
2008-03-01 09:13:20 +08:00
|
|
|
<UL><LI>I = atom type (see asterisk form below)
|
2006-09-22 00:22:34 +08:00
|
|
|
<LI>value = mass
|
|
|
|
</UL>
|
|
|
|
<P><B>Examples:</B>
|
|
|
|
</P>
|
|
|
|
<PRE>mass 1 1.0
|
|
|
|
mass * 62.5
|
|
|
|
mass 2* 62.5
|
|
|
|
</PRE>
|
|
|
|
<P><B>Description:</B>
|
|
|
|
</P>
|
|
|
|
<P>Set the mass for all atoms of one or more atom types. Mass values can
|
|
|
|
also be set in the <A HREF = "read_data.html">read_data</A> data file. See the
|
|
|
|
<A HREF = "units.html">units</A> command for what mass units to use.
|
|
|
|
</P>
|
2008-07-25 07:46:15 +08:00
|
|
|
<P>Most atom styles require per-type masses to be specified. One
|
|
|
|
exception is <A HREF = "atom_style.html">atom_style granular</A> or <A HREF = "atom_style.html">atom_style
|
|
|
|
peri</A>, where masses are defined for individual atoms,
|
|
|
|
not types. These are defined in the file read by the
|
|
|
|
<A HREF = "read_data.html">read_data</A> command, or set to default values by the
|
|
|
|
<A HREF = "create_atoms.html">create_atoms</A> command, or set to new values by the
|
|
|
|
<A HREF = "set.html">set density</A> command. Also note that <A HREF = "pair_eam.html">pair_style
|
|
|
|
eam</A> defines the masses of atom types in the EAM
|
|
|
|
potential file.
|
2007-06-12 00:19:29 +08:00
|
|
|
</P>
|
2006-09-22 00:22:34 +08:00
|
|
|
<P>I can be specified in one of two ways. An explicit numeric value can
|
2008-03-19 04:18:54 +08:00
|
|
|
be used, as in the 1st example above. Or a wild-card asterisk can be
|
2006-09-22 00:22:34 +08:00
|
|
|
used to set the mass for multiple atom types. This takes the form "*"
|
|
|
|
or "*n" or "n*" or "m*n". If N = the number of atom types, then an
|
2008-03-01 09:13:20 +08:00
|
|
|
asterisk with no numeric values means all types from 1 to N. A leading
|
|
|
|
asterisk means all types from 1 to n (inclusive). A trailing asterisk
|
|
|
|
means all types from n to N (inclusive). A middle asterisk means all
|
2006-09-22 00:22:34 +08:00
|
|
|
types from m to n (inclusive).
|
|
|
|
</P>
|
2007-06-12 00:19:29 +08:00
|
|
|
<P>A line in a data file that specifies mass uses the same format as the
|
|
|
|
arguments of the mass command in an input script, except that no
|
2008-03-19 04:18:54 +08:00
|
|
|
wild-card asterisk can be used. For example, under the "Masses"
|
2006-09-22 00:22:34 +08:00
|
|
|
section of a data file, the line that corresponds to the 1st example
|
|
|
|
above would be listed as
|
|
|
|
</P>
|
|
|
|
<PRE>1 1.0
|
|
|
|
</PRE>
|
|
|
|
<P><B>Restrictions:</B>
|
|
|
|
</P>
|
|
|
|
<P>This command must come after the simulation box is defined by a
|
|
|
|
<A HREF = "read_data.html">read_data</A>, <A HREF = "read_restart.html">read_restart</A>, or
|
|
|
|
<A HREF = "create_box.html">create_box</A> command.
|
|
|
|
</P>
|
|
|
|
<P>All masses must be defined before a simulation is run (if the atom
|
|
|
|
style requires masses be set). They must also all be defined before a
|
|
|
|
<A HREF = "velocity.html">velocity</A> or <A HREF = "fix_shake.html">fix shake</A> command is
|
|
|
|
used.
|
|
|
|
</P>
|
|
|
|
<P><B>Related commands:</B> none
|
|
|
|
</P>
|
|
|
|
<P><B>Default:</B> none
|
|
|
|
</P>
|
|
|
|
</HTML>
|