LAMMPS WWW Site - LAMMPS Documentation - LAMMPS Commands

dump command

Syntax:

dump ID group-ID style N file args 

Examples:

dump myDump all atom 100 dump.atom
dump 2 subgroup atom 50 dump.run
dump 3 all velocity 1000 dump.vels
dump 4ab all custom 100 dump.myforce tag type x y vx fx 

Description:

Dump a snapshot of atom quantities to a file every so many timesteps. When a dump is defined, the file is opened. The file is closed when an undump command is used or when LAMMPS exits. Only information for atoms in the specified group is dumped. Because snapshot data is collected from multiple processors, the order of lines (typically one per atom) written into the dump file for a single snapshot is indeterminate.

Dumps are performed on timesteps that are a multiple of N, including timestep 0. If one run ends and another begins on a timestep that is a multiple of N, only one snapshot is written.

The style determines what quantities are written to the file. Settings made via the dump_modify command can alter the output format.

For style atom, atom coordinates are written to the file. For header settings item and self of the dump_modify command, the atom ID and type are also written. For header setting xyz, only the atom type is included. By default, coordinates are in normalized units from 0.0 to 1.0. The scale setting of the dump_modify command enables unnormalized coordinates to be written out. Because periodic boundary conditions are enforced only on timesteps when neighbor lists are rebuilt, the coordinates of some atoms may be slightly outside the simulation box.

For style velocity, atom velocities are written to the file along with the atom ID and type.

For style bond, the bond topology between atoms is written, in the same format they are specified in the data file read by the read_data command. Both atoms in the bond must be in the dump group for the bond to be written. Any bonds that have been broken (see the bond_style command) are not written. Bonds that have been turned off (see the fix shake or delete_bonds commands) are written into the file.

Style custom allows you to specify a list of atom attributes to be written to the dump file for each atom. Possible attributes are described above and will appear in the order specified. Be careful not to specify a quantity that is not defined for a particular simulation - e.g. q for atom style bond, since that atom style doesn't assign charges.

The mux, muy, muz, tqy, tqx, tqy attributes are specific to dipolar systems defined with an atom style of dipole.

The centro attribute causes the centro-symmetry parameter to be computed for each atom in the dump group (Kelchner). For solid state systems this is a useful measure of the local lattice disorder around an atom and can be used to characterize whether the atom is part of a perfect lattice, a local defect (e.g. a dislocation or stacking fault), or at a surface. Computing this quantity requires a neighbor list be constructed containing all the neighbors of each atom. This is performed each time the dump is performed. Thus it could be inefficient to dump this quantity too frequently or to have multiple dump commands, each with a centro attribute.

Dumps occur at the very end of a timestep, so atom attributes will include any effects due to fixes that are applied during the timestep.

See this section for information on how to modify LAMMPS to dump other kinds of per-atom quantities.

Restrictions:

The bond style is part of the "molecular" package. It is only enabled if LAMMPS was built with that package. See the Making LAMMPS section for more info.

Related commands:

dump_modify, undump

Default: none


(Kelchner) Kelchner, Plimpton, Hamilton, Phys Rev B, 58, 11085 (1998).