read data from dump file

Dear LAMMPS users,

I use write_dump command to output one frame during minimization, and later use read_dump command to read atom information from that dump file. The Nstep value need to be consistent with the timestep in dump file.

How can I read the timestep information from dump file and set it to be Nstep in Lammps?

Thank you in advance!

Best wishes,

Ann

you could use a file format that does not store the timestep and then the first (and only) frame is always at nstep == 0.

or you could use write_dump/read_dump or write_restart/read_restart. if you look through the examples in the LAMMPS examples folder, you see that when the goal is to storing the state after some operation and then resetting to it after some other operation, the use of restart files (in combination with the “clear” command) is the most common approach.

axel.