[lammps-users] read_data is not reading right ?

Hi,

I am deforming a solid box, and while running the simulation until 10000 runs, I am dumping atomic coordinates ( xyz ) every 100 timestep. Now I take dumped coordinates at a particular timestep, and have lammps read it by read_data command. read_data command reads file in a certain format ( that’s described in its online manual ), and I made sure of the specific format it needs to scan through.

To make sure if it was read correctly, immediately after reading, I dump coordinates again before any dynamics evolve, and what I see is that lammps is changing the xhi value, keeping others ( xlo, ylo, yhi, zlo, zhi) unchanged. This is bugging me. It is not supposed to change right after reading it nothing is done on it.

As a result of this, since my box has periodic boundary condition in x, y, and z direction, I am seeing some faults at the lower and upper bounds along x direction ( cased by change in xhi dimension ). If anyone has encountered similar issues and has some insight on it, please share.

  • Piyas

Please post an example script where you read a data file, do
a dump, and the box size in the dump is not what was listed
in the data file.

Steve

Thanks, Steve, for your taking the trouble to reply back.

Here’s my input script below ( Also please see attached for the data file and also the input script ) :

units metal
boundary p p p
read_data simbox.data
pair_style eam/alloy
pair_coeff * * ni1_v2 Ni
lattice fcc 3.52
thermo 1000
thermo_style custom step temp pe ke etotal vol press
dump coords all custom 500 runstep_*.xyz x y z
dump_modify coords first yes
timestep 0.001
run 5000

  • Piyas

simbox.data (6.57 MB)

input.in (406 Bytes)

You are running with a triclinic box (not orthogonal). The
dump output for what you think is xhi is actually
a bounding box around the tilted box, which is convenient
for viz. The tilt factor is the 3rd param on the line
if you want to recover the untilted xhi.

ITEM: BOX BOUNDS xy xz yz
1.55633 126.519 4.94813
-98.1661 112.996 5.19963
-2.59694 72.2969 0.720077

This is explained on the dump doc page.

Steve

Thank you Steve. That really helps.

So, if I have got it right, while dumping, the xhi, xlo values are actually for a “bounding box” around the tilted box (not my original simulation cell ) which is dumped such a way for the purpose of ease of visualization ? If so, how do I get rid of this ‘bounding box’ and recover my original box from these dumped parameters or is there any other way to get the ‘real’ dimensions of my simulation cell including tilt factors ( for triclinic) during any snapshot by dumping or something else ?

Thanks,

  • Piyas

yes - a bounding box- the dump doc page explains this

The doc pages for region prism and Section_howto 4.12
explain the tilted box factors. The read_data doc page
has formulas for a tilted box in alternate kinds of notation.

The thermo_style custom command can output any of the
6 box shape/size factors.

Steve

I added some text to the dump doc page that
explains how the bounding box is calculated from
the xlo,xhi,xy etc factors for box size/shape.

Steve

Thanks you so much, Steve. That really helps.

  • Piyas